_ZNK5Botan7AES_1284nameEv:
   28|    389|      std::string name() const override { return "AES-128"; }
_ZNK5Botan7AES_12810new_objectEv:
   30|  1.55k|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<AES_128>(); }
_ZNK5Botan7AES_1924nameEv:
   74|    400|      std::string name() const override { return "AES-192"; }
_ZNK5Botan7AES_19210new_objectEv:
   76|    586|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<AES_192>(); }
_ZNK5Botan7AES_2564nameEv:
  119|    450|      std::string name() const override { return "AES-256"; }
_ZNK5Botan7AES_25610new_objectEv:
  121|  1.40k|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<AES_256>(); }

_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EEC2Ev:
   62|    422|      AlignmentBuffer() = default;
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EED2Ev:
   64|    422|      ~AlignmentBuffer() { secure_zeroize_buffer(m_buffer.data(), sizeof(T) * m_buffer.size()); }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE5clearEv:
   71|   426k|      void clear() {
   72|   426k|         zeroize_buffer(m_buffer.data(), m_buffer.size());
   73|   426k|         m_position = 0;
   74|   426k|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE6appendENSt3__14spanIKhLm18446744073709551615EEE:
   90|   498k|      void append(std::span<const T> elements) {
   91|   498k|         BOTAN_ASSERT_NOMSG(elements.size() <= elements_until_alignment());
  ------------------
  |  |   77|   498k|   do {                                                                     \
  |  |   78|   498k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   498k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 498k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   498k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 498k]
  |  |  ------------------
  ------------------
   92|   498k|         std::copy(elements.begin(), elements.end(), m_buffer.begin() + m_position);
   93|   498k|         m_position += elements.size();
   94|   498k|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE24elements_until_alignmentEv:
  221|   923k|      size_t elements_until_alignment() const { return m_buffer.size() - m_position; }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE21handle_unaligned_dataERNS_12BufferSlicerE:
  166|   498k|      [[nodiscard]] std::optional<std::span<const T>> handle_unaligned_data(BufferSlicer& slicer) {
  167|       |         // When the final block is to be deferred, we would need to store and
  168|       |         // hold a buffer that contains exactly one block until more data is
  169|       |         // passed or it is explicitly consumed.
  170|   498k|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (170:31): [True: 498k, False: 0]
  ------------------
  171|       |
  172|   498k|         if(in_alignment() && slicer.remaining() >= m_buffer.size() + defer) {
  ------------------
  |  Branch (172:13): [True: 427k, False: 70.5k]
  |  Branch (172:31): [True: 0, False: 427k]
  ------------------
  173|       |            // We are currently in alignment and the passed-in data source
  174|       |            // contains enough data to benefit from aligned processing.
  175|       |            // Therefore, we don't copy anything into the intermittent buffer.
  176|      0|            return std::nullopt;
  177|      0|         }
  178|       |
  179|       |         // Fill the buffer with as much input data as needed to reach alignment
  180|       |         // or until the input source is depleted.
  181|   498k|         const auto elements_to_consume = std::min(m_buffer.size() - m_position, slicer.remaining());
  182|   498k|         append(slicer.take(elements_to_consume));
  183|       |
  184|       |         // If we collected enough data, we push out one full block. When
  185|       |         // deferring the final block is enabled, we additionally check that
  186|       |         // more input data is available to continue processing a consecutive
  187|       |         // block.
  188|   498k|         if(ready_to_consume() && (!defers_final_block() || !slicer.empty())) {
  ------------------
  |  Branch (188:13): [True: 1.68k, False: 496k]
  |  Branch (188:36): [True: 0, False: 1.68k]
  |  Branch (188:61): [True: 1.68k, False: 0]
  ------------------
  189|  1.68k|            return consume();
  190|   496k|         } else {
  191|   496k|            return std::nullopt;
  192|   496k|         }
  193|   498k|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE18defers_final_blockEv:
  233|   501k|      constexpr bool defers_final_block() const {
  234|   501k|         return FINAL_BLOCK_STRATEGY == AlignmentBufferFinalBlock::must_be_deferred;
  235|   501k|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE16ready_to_consumeEv:
  231|  1.35M|      bool ready_to_consume() const { return m_position == m_buffer.size(); }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE12in_alignmentEv:
  226|   997k|      bool in_alignment() const { return m_position == 0; }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE23aligned_data_to_processERNS_12BufferSlicerE:
  126|  1.68k|      [[nodiscard]] std::tuple<std::span<const uint8_t>, size_t> aligned_data_to_process(BufferSlicer& slicer) const {
  127|  1.68k|         BOTAN_ASSERT_NOMSG(in_alignment());
  ------------------
  |  |   77|  1.68k|   do {                                                                     \
  |  |   78|  1.68k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.68k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.68k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.68k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.68k]
  |  |  ------------------
  ------------------
  128|       |
  129|       |         // When the final block is to be deferred, the last block must not be
  130|       |         // selected for processing if there is no (unaligned) extra input data.
  131|  1.68k|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (131:31): [True: 1.68k, False: 0]
  ------------------
  132|  1.68k|         const size_t full_blocks_to_process = (slicer.remaining() - defer) / m_buffer.size();
  133|  1.68k|         return {slicer.take(full_blocks_to_process * m_buffer.size()), full_blocks_to_process};
  134|  1.68k|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE18elements_in_bufferEv:
  219|   425k|      size_t elements_in_buffer() const { return m_position; }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE18fill_up_with_zerosEv:
   79|   425k|      void fill_up_with_zeros() {
   80|   425k|         if(!ready_to_consume()) {
  ------------------
  |  Branch (80:13): [True: 425k, False: 0]
  ------------------
   81|   425k|            zeroize_buffer(&m_buffer[m_position], elements_until_alignment());
   82|   425k|            m_position = m_buffer.size();
   83|   425k|         }
   84|   425k|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE1EE7consumeEv:
  200|   427k|      [[nodiscard]] std::span<const T> consume() {
  201|   427k|         BOTAN_ASSERT_NOMSG(ready_to_consume());
  ------------------
  |  |   77|   427k|   do {                                                                     \
  |  |   78|   427k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   427k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 427k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   427k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 427k]
  |  |  ------------------
  ------------------
  202|   427k|         m_position = 0;
  203|   427k|         return m_buffer;
  204|   427k|      }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EEC2Ev:
   62|  70.1k|      AlignmentBuffer() = default;
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE5clearEv:
   71|   152k|      void clear() {
   72|   152k|         zeroize_buffer(m_buffer.data(), m_buffer.size());
   73|   152k|         m_position = 0;
   74|   152k|      }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EED2Ev:
   64|  70.1k|      ~AlignmentBuffer() { secure_zeroize_buffer(m_buffer.data(), sizeof(T) * m_buffer.size()); }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EEC2Ev:
   62|  27.0k|      AlignmentBuffer() = default;
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE5clearEv:
   71|  2.50M|      void clear() {
   72|  2.50M|         zeroize_buffer(m_buffer.data(), m_buffer.size());
   73|  2.50M|         m_position = 0;
   74|  2.50M|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EED2Ev:
   64|  27.0k|      ~AlignmentBuffer() { secure_zeroize_buffer(m_buffer.data(), sizeof(T) * m_buffer.size()); }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE21handle_unaligned_dataERNS_12BufferSlicerE:
  166|   184M|      [[nodiscard]] std::optional<std::span<const T>> handle_unaligned_data(BufferSlicer& slicer) {
  167|       |         // When the final block is to be deferred, we would need to store and
  168|       |         // hold a buffer that contains exactly one block until more data is
  169|       |         // passed or it is explicitly consumed.
  170|   184M|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (170:31): [True: 0, False: 184M]
  ------------------
  171|       |
  172|   184M|         if(in_alignment() && slicer.remaining() >= m_buffer.size() + defer) {
  ------------------
  |  Branch (172:13): [True: 34.2M, False: 150M]
  |  Branch (172:31): [True: 48.2k, False: 34.2M]
  ------------------
  173|       |            // We are currently in alignment and the passed-in data source
  174|       |            // contains enough data to benefit from aligned processing.
  175|       |            // Therefore, we don't copy anything into the intermittent buffer.
  176|  48.2k|            return std::nullopt;
  177|  48.2k|         }
  178|       |
  179|       |         // Fill the buffer with as much input data as needed to reach alignment
  180|       |         // or until the input source is depleted.
  181|   184M|         const auto elements_to_consume = std::min(m_buffer.size() - m_position, slicer.remaining());
  182|   184M|         append(slicer.take(elements_to_consume));
  183|       |
  184|       |         // If we collected enough data, we push out one full block. When
  185|       |         // deferring the final block is enabled, we additionally check that
  186|       |         // more input data is available to continue processing a consecutive
  187|       |         // block.
  188|   184M|         if(ready_to_consume() && (!defers_final_block() || !slicer.empty())) {
  ------------------
  |  Branch (188:13): [True: 34.1M, False: 150M]
  |  Branch (188:36): [True: 34.1M, False: 0]
  |  Branch (188:61): [True: 0, False: 0]
  ------------------
  189|  34.1M|            return consume();
  190|   150M|         } else {
  191|   150M|            return std::nullopt;
  192|   150M|         }
  193|   184M|      }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE18defers_final_blockEv:
  233|   253M|      constexpr bool defers_final_block() const {
  234|   253M|         return FINAL_BLOCK_STRATEGY == AlignmentBufferFinalBlock::must_be_deferred;
  235|   253M|      }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE6appendENSt3__14spanIKhLm18446744073709551615EEE:
   90|   185M|      void append(std::span<const T> elements) {
   91|   185M|         BOTAN_ASSERT_NOMSG(elements.size() <= elements_until_alignment());
  ------------------
  |  |   77|   185M|   do {                                                                     \
  |  |   78|   185M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   185M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 185M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   185M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 185M]
  |  |  ------------------
  ------------------
   92|   185M|         std::copy(elements.begin(), elements.end(), m_buffer.begin() + m_position);
   93|   185M|         m_position += elements.size();
   94|   185M|      }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE24elements_until_alignmentEv:
  221|   185M|      size_t elements_until_alignment() const { return m_buffer.size() - m_position; }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE16ready_to_consumeEv:
  231|   219M|      bool ready_to_consume() const { return m_position == m_buffer.size(); }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE7consumeEv:
  200|  34.2M|      [[nodiscard]] std::span<const T> consume() {
  201|  34.2M|         BOTAN_ASSERT_NOMSG(ready_to_consume());
  ------------------
  |  |   77|  34.2M|   do {                                                                     \
  |  |   78|  34.2M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  34.2M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 34.2M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  34.2M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 34.2M]
  |  |  ------------------
  ------------------
  202|  34.2M|         m_position = 0;
  203|  34.2M|         return m_buffer;
  204|  34.2M|      }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE12in_alignmentEv:
  226|   404M|      bool in_alignment() const { return m_position == 0; }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE23aligned_data_to_processERNS_12BufferSlicerE:
  126|  34.2M|      [[nodiscard]] std::tuple<std::span<const uint8_t>, size_t> aligned_data_to_process(BufferSlicer& slicer) const {
  127|  34.2M|         BOTAN_ASSERT_NOMSG(in_alignment());
  ------------------
  |  |   77|  34.2M|   do {                                                                     \
  |  |   78|  34.2M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  34.2M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 34.2M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  34.2M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 34.2M]
  |  |  ------------------
  ------------------
  128|       |
  129|       |         // When the final block is to be deferred, the last block must not be
  130|       |         // selected for processing if there is no (unaligned) extra input data.
  131|  34.2M|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (131:31): [True: 0, False: 34.2M]
  ------------------
  132|  34.2M|         const size_t full_blocks_to_process = (slicer.remaining() - defer) / m_buffer.size();
  133|  34.2M|         return {slicer.take(full_blocks_to_process * m_buffer.size()), full_blocks_to_process};
  134|  34.2M|      }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE18fill_up_with_zerosEv:
   79|  68.8k|      void fill_up_with_zeros() {
   80|  68.8k|         if(!ready_to_consume()) {
  ------------------
  |  Branch (80:13): [True: 68.7k, False: 34]
  ------------------
   81|  68.7k|            zeroize_buffer(&m_buffer[m_position], elements_until_alignment());
   82|  68.7k|            m_position = m_buffer.size();
   83|  68.7k|         }
   84|  68.8k|      }
_ZN5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE20directly_modify_lastEm:
  113|  68.7k|      std::span<T> directly_modify_last(size_t elements) {
  114|  68.7k|         BOTAN_ASSERT_NOMSG(size() >= elements);
  ------------------
  |  |   77|  68.7k|   do {                                                                     \
  |  |   78|  68.7k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  68.7k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 68.7k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  68.7k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 68.7k]
  |  |  ------------------
  ------------------
  115|  68.7k|         return std::span(m_buffer).last(elements);
  116|  68.7k|      }
_ZNK5Botan15AlignmentBufferIhLm64ELNS_25AlignmentBufferFinalBlockE0EE4sizeEv:
  217|  68.7k|      constexpr size_t size() const { return m_buffer.size(); }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE21handle_unaligned_dataERNS_12BufferSlicerE:
  166|  32.1M|      [[nodiscard]] std::optional<std::span<const T>> handle_unaligned_data(BufferSlicer& slicer) {
  167|       |         // When the final block is to be deferred, we would need to store and
  168|       |         // hold a buffer that contains exactly one block until more data is
  169|       |         // passed or it is explicitly consumed.
  170|  32.1M|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (170:31): [True: 0, False: 32.1M]
  ------------------
  171|       |
  172|  32.1M|         if(in_alignment() && slicer.remaining() >= m_buffer.size() + defer) {
  ------------------
  |  Branch (172:13): [True: 5.21M, False: 26.9M]
  |  Branch (172:31): [True: 2.47M, False: 2.74M]
  ------------------
  173|       |            // We are currently in alignment and the passed-in data source
  174|       |            // contains enough data to benefit from aligned processing.
  175|       |            // Therefore, we don't copy anything into the intermittent buffer.
  176|  2.47M|            return std::nullopt;
  177|  2.47M|         }
  178|       |
  179|       |         // Fill the buffer with as much input data as needed to reach alignment
  180|       |         // or until the input source is depleted.
  181|  29.6M|         const auto elements_to_consume = std::min(m_buffer.size() - m_position, slicer.remaining());
  182|  29.6M|         append(slicer.take(elements_to_consume));
  183|       |
  184|       |         // If we collected enough data, we push out one full block. When
  185|       |         // deferring the final block is enabled, we additionally check that
  186|       |         // more input data is available to continue processing a consecutive
  187|       |         // block.
  188|  29.6M|         if(ready_to_consume() && (!defers_final_block() || !slicer.empty())) {
  ------------------
  |  Branch (188:13): [True: 445k, False: 29.2M]
  |  Branch (188:36): [True: 445k, False: 0]
  |  Branch (188:61): [True: 0, False: 0]
  ------------------
  189|   445k|            return consume();
  190|  29.2M|         } else {
  191|  29.2M|            return std::nullopt;
  192|  29.2M|         }
  193|  29.6M|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE18defers_final_blockEv:
  233|  35.5M|      constexpr bool defers_final_block() const {
  234|  35.5M|         return FINAL_BLOCK_STRATEGY == AlignmentBufferFinalBlock::must_be_deferred;
  235|  35.5M|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE6appendENSt3__14spanIKhLm18446744073709551615EEE:
   90|  31.9M|      void append(std::span<const T> elements) {
   91|  31.9M|         BOTAN_ASSERT_NOMSG(elements.size() <= elements_until_alignment());
  ------------------
  |  |   77|  31.9M|   do {                                                                     \
  |  |   78|  31.9M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  31.9M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 31.9M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  31.9M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 31.9M]
  |  |  ------------------
  ------------------
   92|  31.9M|         std::copy(elements.begin(), elements.end(), m_buffer.begin() + m_position);
   93|  31.9M|         m_position += elements.size();
   94|  31.9M|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE24elements_until_alignmentEv:
  221|  38.8M|      size_t elements_until_alignment() const { return m_buffer.size() - m_position; }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE16ready_to_consumeEv:
  231|  37.0M|      bool ready_to_consume() const { return m_position == m_buffer.size(); }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE7consumeEv:
  200|  2.74M|      [[nodiscard]] std::span<const T> consume() {
  201|  2.74M|         BOTAN_ASSERT_NOMSG(ready_to_consume());
  ------------------
  |  |   77|  2.74M|   do {                                                                     \
  |  |   78|  2.74M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.74M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.74M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.74M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.74M]
  |  |  ------------------
  ------------------
  202|  2.74M|         m_position = 0;
  203|  2.74M|         return m_buffer;
  204|  2.74M|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE12in_alignmentEv:
  226|  67.2M|      bool in_alignment() const { return m_position == 0; }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE23aligned_data_to_processERNS_12BufferSlicerE:
  126|  2.92M|      [[nodiscard]] std::tuple<std::span<const uint8_t>, size_t> aligned_data_to_process(BufferSlicer& slicer) const {
  127|  2.92M|         BOTAN_ASSERT_NOMSG(in_alignment());
  ------------------
  |  |   77|  2.92M|   do {                                                                     \
  |  |   78|  2.92M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.92M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.92M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.92M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.92M]
  |  |  ------------------
  ------------------
  128|       |
  129|       |         // When the final block is to be deferred, the last block must not be
  130|       |         // selected for processing if there is no (unaligned) extra input data.
  131|  2.92M|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (131:31): [True: 0, False: 2.92M]
  ------------------
  132|  2.92M|         const size_t full_blocks_to_process = (slicer.remaining() - defer) / m_buffer.size();
  133|  2.92M|         return {slicer.take(full_blocks_to_process * m_buffer.size()), full_blocks_to_process};
  134|  2.92M|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE18fill_up_with_zerosEv:
   79|  2.30M|      void fill_up_with_zeros() {
   80|  2.30M|         if(!ready_to_consume()) {
  ------------------
  |  Branch (80:13): [True: 2.30M, False: 24]
  ------------------
   81|  2.30M|            zeroize_buffer(&m_buffer[m_position], elements_until_alignment());
   82|  2.30M|            m_position = m_buffer.size();
   83|  2.30M|         }
   84|  2.30M|      }
_ZN5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE20directly_modify_lastEm:
  113|  2.30M|      std::span<T> directly_modify_last(size_t elements) {
  114|  2.30M|         BOTAN_ASSERT_NOMSG(size() >= elements);
  ------------------
  |  |   77|  2.30M|   do {                                                                     \
  |  |   78|  2.30M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.30M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.30M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.30M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.30M]
  |  |  ------------------
  ------------------
  115|  2.30M|         return std::span(m_buffer).last(elements);
  116|  2.30M|      }
_ZNK5Botan15AlignmentBufferIhLm128ELNS_25AlignmentBufferFinalBlockE0EE4sizeEv:
  217|  2.30M|      constexpr size_t size() const { return m_buffer.size(); }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EED2Ev:
   64|  3.30k|      ~AlignmentBuffer() { secure_zeroize_buffer(m_buffer.data(), sizeof(T) * m_buffer.size()); }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EEC2Ev:
   62|  3.30k|      AlignmentBuffer() = default;
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE5clearEv:
   71|   208k|      void clear() {
   72|   208k|         zeroize_buffer(m_buffer.data(), m_buffer.size());
   73|   208k|         m_position = 0;
   74|   208k|      }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE21handle_unaligned_dataERNS_12BufferSlicerE:
  166|   443k|      [[nodiscard]] std::optional<std::span<const T>> handle_unaligned_data(BufferSlicer& slicer) {
  167|       |         // When the final block is to be deferred, we would need to store and
  168|       |         // hold a buffer that contains exactly one block until more data is
  169|       |         // passed or it is explicitly consumed.
  170|   443k|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (170:31): [True: 0, False: 443k]
  ------------------
  171|       |
  172|   443k|         if(in_alignment() && slicer.remaining() >= m_buffer.size() + defer) {
  ------------------
  |  Branch (172:13): [True: 424k, False: 19.3k]
  |  Branch (172:31): [True: 300k, False: 123k]
  ------------------
  173|       |            // We are currently in alignment and the passed-in data source
  174|       |            // contains enough data to benefit from aligned processing.
  175|       |            // Therefore, we don't copy anything into the intermittent buffer.
  176|   300k|            return std::nullopt;
  177|   300k|         }
  178|       |
  179|       |         // Fill the buffer with as much input data as needed to reach alignment
  180|       |         // or until the input source is depleted.
  181|   142k|         const auto elements_to_consume = std::min(m_buffer.size() - m_position, slicer.remaining());
  182|   142k|         append(slicer.take(elements_to_consume));
  183|       |
  184|       |         // If we collected enough data, we push out one full block. When
  185|       |         // deferring the final block is enabled, we additionally check that
  186|       |         // more input data is available to continue processing a consecutive
  187|       |         // block.
  188|   142k|         if(ready_to_consume() && (!defers_final_block() || !slicer.empty())) {
  ------------------
  |  Branch (188:13): [True: 19.3k, False: 123k]
  |  Branch (188:36): [True: 19.3k, False: 0]
  |  Branch (188:61): [True: 0, False: 0]
  ------------------
  189|  19.3k|            return consume();
  190|   123k|         } else {
  191|   123k|            return std::nullopt;
  192|   123k|         }
  193|   142k|      }
_ZNK5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE18defers_final_blockEv:
  233|   783k|      constexpr bool defers_final_block() const {
  234|   783k|         return FINAL_BLOCK_STRATEGY == AlignmentBufferFinalBlock::must_be_deferred;
  235|   783k|      }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE6appendENSt3__14spanIKhLm18446744073709551615EEE:
   90|   142k|      void append(std::span<const T> elements) {
   91|   142k|         BOTAN_ASSERT_NOMSG(elements.size() <= elements_until_alignment());
  ------------------
  |  |   77|   142k|   do {                                                                     \
  |  |   78|   142k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   142k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 142k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   142k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 142k]
  |  |  ------------------
  ------------------
   92|   142k|         std::copy(elements.begin(), elements.end(), m_buffer.begin() + m_position);
   93|   142k|         m_position += elements.size();
   94|   142k|      }
_ZNK5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE24elements_until_alignmentEv:
  221|   247k|      size_t elements_until_alignment() const { return m_buffer.size() - m_position; }
_ZNK5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE16ready_to_consumeEv:
  231|   370k|      bool ready_to_consume() const { return m_position == m_buffer.size(); }
_ZNK5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE12in_alignmentEv:
  226|  1.51M|      bool in_alignment() const { return m_position == 0; }
_ZNK5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE23aligned_data_to_processERNS_12BufferSlicerE:
  126|   320k|      [[nodiscard]] std::tuple<std::span<const uint8_t>, size_t> aligned_data_to_process(BufferSlicer& slicer) const {
  127|   320k|         BOTAN_ASSERT_NOMSG(in_alignment());
  ------------------
  |  |   77|   320k|   do {                                                                     \
  |  |   78|   320k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   320k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 320k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   320k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 320k]
  |  |  ------------------
  ------------------
  128|       |
  129|       |         // When the final block is to be deferred, the last block must not be
  130|       |         // selected for processing if there is no (unaligned) extra input data.
  131|   320k|         const size_t defer = (defers_final_block()) ? 1 : 0;
  ------------------
  |  Branch (131:31): [True: 0, False: 320k]
  ------------------
  132|   320k|         const size_t full_blocks_to_process = (slicer.remaining() - defer) / m_buffer.size();
  133|   320k|         return {slicer.take(full_blocks_to_process * m_buffer.size()), full_blocks_to_process};
  134|   320k|      }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE18fill_up_with_zerosEv:
   79|   104k|      void fill_up_with_zeros() {
   80|   104k|         if(!ready_to_consume()) {
  ------------------
  |  Branch (80:13): [True: 104k, False: 0]
  ------------------
   81|   104k|            zeroize_buffer(&m_buffer[m_position], elements_until_alignment());
   82|   104k|            m_position = m_buffer.size();
   83|   104k|         }
   84|   104k|      }
_ZN5Botan15AlignmentBufferIhLm16ELNS_25AlignmentBufferFinalBlockE0EE7consumeEv:
  200|   123k|      [[nodiscard]] std::span<const T> consume() {
  201|   123k|         BOTAN_ASSERT_NOMSG(ready_to_consume());
  ------------------
  |  |   77|   123k|   do {                                                                     \
  |  |   78|   123k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   123k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 123k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   123k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 123k]
  |  |  ------------------
  ------------------
  202|   123k|         m_position = 0;
  203|   123k|         return m_buffer;
  204|   123k|      }

_ZNK5Botan17Barrett_Reduction4cubeERKNS_6BigIntE:
   66|      3|      BigInt cube(const BigInt& x) const { return this->multiply(x, this->square(x)); }

_ZN5Botan8high_bitITkNSt3__117unsigned_integralEjEEmT_:
   73|      6|BOTAN_FORCE_INLINE constexpr size_t high_bit(T n) {
   74|      6|   size_t hb = 0;
   75|       |
   76|     36|   for(size_t s = 8 * sizeof(T) / 2; s > 0; s /= 2) {
  ------------------
  |  Branch (76:38): [True: 30, False: 6]
  ------------------
   77|       |      // Equivalent to: ((n >> s) == 0) ? 0 : s;
   78|     30|      const size_t z = s - ct_if_is_zero_ret<T>(n >> s, s);
   79|     30|      hb += z;
   80|     30|      n >>= z;
   81|     30|   }
   82|       |
   83|      6|   hb += n;
   84|       |
   85|      6|   return hb;
   86|      6|}
_ZN5Botan17ct_if_is_zero_retITkNSt3__117unsigned_integralEjEEmT_m:
   45|     30|BOTAN_FORCE_INLINE constexpr size_t ct_if_is_zero_ret(T x, size_t s) {
   46|       |   /*
   47|       |   Similar to `return ct_is_zero(x) & s` but has to account for possibility that
   48|       |   sizeof(T) is smaller than sizeof(size_t) which would lead to incomplete masking
   49|       |   */
   50|     30|   const T a = ~x & (x - 1);
   51|     30|   const size_t a_top = static_cast<size_t>(CT::value_barrier<T>(a >> (sizeof(T) * 8 - 1)));
   52|     30|   const size_t mask = static_cast<size_t>(0) - a_top;
   53|     30|   return mask & s;
   54|     30|}
_ZN5Botan9var_ctz64Em:
  180|  2.03M|BOTAN_FORCE_INLINE constexpr size_t var_ctz64(uint64_t n) {
  181|  2.03M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_ctzll)
  182|  2.03M|   if(n == 0) {
  ------------------
  |  Branch (182:7): [True: 0, False: 2.03M]
  ------------------
  183|      0|      return 64;
  184|      0|   }
  185|  2.03M|   return __builtin_ctzll(n);
  186|       |#else
  187|       |   return ctz<uint64_t>(n);
  188|       |#endif
  189|  2.03M|}
_ZN5Botan17ct_if_is_zero_retITkNSt3__117unsigned_integralEmEEmT_m:
   45|   194k|BOTAN_FORCE_INLINE constexpr size_t ct_if_is_zero_ret(T x, size_t s) {
   46|       |   /*
   47|       |   Similar to `return ct_is_zero(x) & s` but has to account for possibility that
   48|       |   sizeof(T) is smaller than sizeof(size_t) which would lead to incomplete masking
   49|       |   */
   50|   194k|   const T a = ~x & (x - 1);
   51|   194k|   const size_t a_top = static_cast<size_t>(CT::value_barrier<T>(a >> (sizeof(T) * 8 - 1)));
   52|   194k|   const size_t mask = static_cast<size_t>(0) - a_top;
   53|   194k|   return mask & s;
   54|   194k|}
_ZN5Botan9swap_bitsITkNSt3__117unsigned_integralEjEEvRT_S3_S2_m:
  202|   772M|BOTAN_FORCE_INLINE constexpr void swap_bits(T& x, T& y, T mask, size_t shift) {
  203|   772M|   const T swap = ((x >> shift) ^ y) & mask;
  204|   772M|   x ^= swap << shift;
  205|   772M|   y ^= swap;
  206|   772M|}
_ZN5Botan16bit_permute_stepITkNSt3__117unsigned_integralEmEET_S2_S2_m:
  192|   845M|BOTAN_FORCE_INLINE constexpr T bit_permute_step(T x, T mask, size_t shift) {
  193|       |   /*
  194|       |   See https://reflectionsonsecurity.wordpress.com/2014/05/11/efficient-bit-permutation-using-delta-swaps/
  195|       |   and http://programming.sirrida.de/bit_perm.html
  196|       |   */
  197|   845M|   const T swap = ((x >> shift) ^ x) & mask;
  198|   845M|   return (x ^ swap) ^ (swap << shift);
  199|   845M|}
_ZN5Botan17ct_expand_top_bitITkNSt3__117unsigned_integralEmEET_S2_:
   28|   361M|BOTAN_FORCE_INLINE constexpr T ct_expand_top_bit(T a) {
   29|   361M|   const T top = CT::value_barrier<T>(a >> (sizeof(T) * 8 - 1));
   30|   361M|   return static_cast<T>(0) - top;
   31|   361M|}
_ZN5Botan10ct_is_zeroITkNSt3__117unsigned_integralEmEET_S2_:
   37|  65.8M|BOTAN_FORCE_INLINE constexpr T ct_is_zero(T x) {
   38|  65.8M|   return ct_expand_top_bit<T>(~x & (x - 1));
   39|  65.8M|}
_ZN5Botan6chooseITkNSt3__117unsigned_integralEmEET_S2_S2_S2_:
  216|  2.15G|BOTAN_FORCE_INLINE constexpr T choose(T mask, T a, T b) {
  217|       |   //return (mask & a) | (~mask & b);
  218|  2.15G|   return (b ^ (mask & (a ^ b)));
  219|  2.15G|}
_ZN5Botan9swap_bitsITkNSt3__117unsigned_integralEmEEvRT_S3_S2_m:
  202|  87.1M|BOTAN_FORCE_INLINE constexpr void swap_bits(T& x, T& y, T mask, size_t shift) {
  203|  87.1M|   const T swap = ((x >> shift) ^ y) & mask;
  204|  87.1M|   x ^= swap << shift;
  205|  87.1M|   y ^= swap;
  206|  87.1M|}
_ZN5Botan10ct_is_zeroITkNSt3__117unsigned_integralEjEET_S2_:
   37|  40.9M|BOTAN_FORCE_INLINE constexpr T ct_is_zero(T x) {
   38|  40.9M|   return ct_expand_top_bit<T>(~x & (x - 1));
   39|  40.9M|}
_ZN5Botan17ct_expand_top_bitITkNSt3__117unsigned_integralEjEET_S2_:
   28|  40.9M|BOTAN_FORCE_INLINE constexpr T ct_expand_top_bit(T a) {
   29|  40.9M|   const T top = CT::value_barrier<T>(a >> (sizeof(T) * 8 - 1));
   30|  40.9M|   return static_cast<T>(0) - top;
   31|  40.9M|}
_ZN5Botan6chooseITkNSt3__117unsigned_integralEtEET_S2_S2_S2_:
  216|  40.4M|BOTAN_FORCE_INLINE constexpr T choose(T mask, T a, T b) {
  217|       |   //return (mask & a) | (~mask & b);
  218|  40.4M|   return (b ^ (mask & (a ^ b)));
  219|  40.4M|}
_ZN5Botan10ct_is_zeroITkNSt3__117unsigned_integralEhEET_S2_:
   37|  67.4M|BOTAN_FORCE_INLINE constexpr T ct_is_zero(T x) {
   38|  67.4M|   return ct_expand_top_bit<T>(~x & (x - 1));
   39|  67.4M|}
_ZN5Botan17ct_expand_top_bitITkNSt3__117unsigned_integralEhEET_S2_:
   28|  67.4M|BOTAN_FORCE_INLINE constexpr T ct_expand_top_bit(T a) {
   29|  67.4M|   const T top = CT::value_barrier<T>(a >> (sizeof(T) * 8 - 1));
   30|  67.4M|   return static_cast<T>(0) - top;
   31|  67.4M|}
_ZN5Botan6chooseITkNSt3__117unsigned_integralEhEET_S2_S2_S2_:
  216|  1.02k|BOTAN_FORCE_INLINE constexpr T choose(T mask, T a, T b) {
  217|       |   //return (mask & a) | (~mask & b);
  218|  1.02k|   return (b ^ (mask & (a ^ b)));
  219|  1.02k|}
_ZN5Botan13is_power_of_2ITkNSt3__117unsigned_integralEmEEbT_:
   62|  42.5M|BOTAN_FORCE_INLINE constexpr bool is_power_of_2(T arg) {
   63|  42.5M|   return (arg != 0) && (arg != 1) && ((arg & static_cast<T>(arg - 1)) == 0);
  ------------------
  |  Branch (63:11): [True: 42.5M, False: 0]
  |  Branch (63:25): [True: 42.0M, False: 552k]
  |  Branch (63:39): [True: 7.90M, False: 34.1M]
  ------------------
   64|  42.5M|}
_ZN5Botan6chooseITkNSt3__117unsigned_integralEjEET_S2_S2_S2_:
  216|  1.95G|BOTAN_FORCE_INLINE constexpr T choose(T mask, T a, T b) {
  217|       |   //return (mask & a) | (~mask & b);
  218|  1.95G|   return (b ^ (mask & (a ^ b)));
  219|  1.95G|}
_ZN5Botan8majorityITkNSt3__117unsigned_integralEjEET_S2_S2_S2_:
  222|   884M|BOTAN_FORCE_INLINE constexpr T majority(T a, T b, T c) {
  223|       |   /*
  224|       |   Considering each bit of a, b, c individually
  225|       |
  226|       |   If a xor b is set, then c is the deciding vote.
  227|       |
  228|       |   If a xor b is not set then either a and b are both set or both unset.
  229|       |   In either case the value of c doesn't matter, and examining b (or a)
  230|       |   allows us to determine which case we are in.
  231|       |   */
  232|   884M|   return choose(a ^ b, c, b);
  233|   884M|}
_ZN5Botan8majorityITkNSt3__117unsigned_integralEmEET_S2_S2_S2_:
  222|   737M|BOTAN_FORCE_INLINE constexpr T majority(T a, T b, T c) {
  223|       |   /*
  224|       |   Considering each bit of a, b, c individually
  225|       |
  226|       |   If a xor b is set, then c is the deciding vote.
  227|       |
  228|       |   If a xor b is not set then either a and b are both set or both unset.
  229|       |   In either case the value of c doesn't matter, and examining b (or a)
  230|       |   allows us to determine which case we are in.
  231|       |   */
  232|   737M|   return choose(a ^ b, c, b);
  233|   737M|}
_ZN5Botan8high_bitITkNSt3__117unsigned_integralEmEEmT_:
   73|  32.3k|BOTAN_FORCE_INLINE constexpr size_t high_bit(T n) {
   74|  32.3k|   size_t hb = 0;
   75|       |
   76|   226k|   for(size_t s = 8 * sizeof(T) / 2; s > 0; s /= 2) {
  ------------------
  |  Branch (76:38): [True: 194k, False: 32.3k]
  ------------------
   77|       |      // Equivalent to: ((n >> s) == 0) ? 0 : s;
   78|   194k|      const size_t z = s - ct_if_is_zero_ret<T>(n >> s, s);
   79|   194k|      hb += z;
   80|   194k|      n >>= z;
   81|   194k|   }
   82|       |
   83|  32.3k|   hb += n;
   84|       |
   85|  32.3k|   return hb;
   86|  32.3k|}

_ZNK5Botan7BLAKE2b13output_lengthEv:
   33|  1.27M|      size_t output_length() const override { return m_output_bits / 8; }

_ZNK5Botan8Blowfish4nameEv:
   36|     14|      std::string name() const override { return "Blowfish"; }
_ZNK5Botan8Blowfish10new_objectEv:
   38|     98|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Blowfish>(); }

_ZN5Botan13reverse_bytesITkNSt3__117unsigned_integralEtQooooooeqstT_Li1EeqstS2_Li2EeqstS2_Li4EeqstS2_Li8EEES2_S2_:
   27|  9.30M|inline constexpr T reverse_bytes(T x) {
   28|       |   if constexpr(sizeof(T) == 1) {
   29|       |      return x;
   30|  9.30M|   } else if constexpr(sizeof(T) == 2) {
   31|  9.30M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap16)
   32|  9.30M|      return static_cast<T>(__builtin_bswap16(x));
   33|       |#else
   34|       |      return static_cast<T>((x << 8) | (x >> 8));
   35|       |#endif
   36|       |   } else if constexpr(sizeof(T) == 4) {
   37|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap32)
   38|       |      return static_cast<T>(__builtin_bswap32(x));
   39|       |#else
   40|       |      // MSVC at least recognizes this as a bswap
   41|       |      return static_cast<T>(((x & 0x000000FF) << 24) | ((x & 0x0000FF00) << 8) | ((x & 0x00FF0000) >> 8) |
   42|       |                            ((x & 0xFF000000) >> 24));
   43|       |#endif
   44|       |   } else if constexpr(sizeof(T) == 8) {
   45|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap64)
   46|       |      return static_cast<T>(__builtin_bswap64(x));
   47|       |#else
   48|       |      uint32_t hi = static_cast<uint32_t>(x >> 32);
   49|       |      uint32_t lo = static_cast<uint32_t>(x);
   50|       |
   51|       |      hi = reverse_bytes(hi);
   52|       |      lo = reverse_bytes(lo);
   53|       |
   54|       |      return (static_cast<T>(lo) << 32) | hi;
   55|       |#endif
   56|       |   }
   57|  9.30M|}
_ZN5Botan13reverse_bytesITkNSt3__117unsigned_integralEjQooooooeqstT_Li1EeqstS2_Li2EeqstS2_Li4EeqstS2_Li8EEES2_S2_:
   27|   591M|inline constexpr T reverse_bytes(T x) {
   28|       |   if constexpr(sizeof(T) == 1) {
   29|       |      return x;
   30|       |   } else if constexpr(sizeof(T) == 2) {
   31|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap16)
   32|       |      return static_cast<T>(__builtin_bswap16(x));
   33|       |#else
   34|       |      return static_cast<T>((x << 8) | (x >> 8));
   35|       |#endif
   36|   591M|   } else if constexpr(sizeof(T) == 4) {
   37|   591M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap32)
   38|   591M|      return static_cast<T>(__builtin_bswap32(x));
   39|       |#else
   40|       |      // MSVC at least recognizes this as a bswap
   41|       |      return static_cast<T>(((x & 0x000000FF) << 24) | ((x & 0x0000FF00) << 8) | ((x & 0x00FF0000) >> 8) |
   42|       |                            ((x & 0xFF000000) >> 24));
   43|       |#endif
   44|       |   } else if constexpr(sizeof(T) == 8) {
   45|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap64)
   46|       |      return static_cast<T>(__builtin_bswap64(x));
   47|       |#else
   48|       |      uint32_t hi = static_cast<uint32_t>(x >> 32);
   49|       |      uint32_t lo = static_cast<uint32_t>(x);
   50|       |
   51|       |      hi = reverse_bytes(hi);
   52|       |      lo = reverse_bytes(lo);
   53|       |
   54|       |      return (static_cast<T>(lo) << 32) | hi;
   55|       |#endif
   56|       |   }
   57|   591M|}
_ZN5Botan13reverse_bytesITkNSt3__117unsigned_integralEmQooooooeqstT_Li1EeqstS2_Li2EeqstS2_Li4EeqstS2_Li8EEES2_S2_:
   27|   234M|inline constexpr T reverse_bytes(T x) {
   28|       |   if constexpr(sizeof(T) == 1) {
   29|       |      return x;
   30|       |   } else if constexpr(sizeof(T) == 2) {
   31|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap16)
   32|       |      return static_cast<T>(__builtin_bswap16(x));
   33|       |#else
   34|       |      return static_cast<T>((x << 8) | (x >> 8));
   35|       |#endif
   36|       |   } else if constexpr(sizeof(T) == 4) {
   37|       |#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap32)
   38|       |      return static_cast<T>(__builtin_bswap32(x));
   39|       |#else
   40|       |      // MSVC at least recognizes this as a bswap
   41|       |      return static_cast<T>(((x & 0x000000FF) << 24) | ((x & 0x0000FF00) << 8) | ((x & 0x00FF0000) >> 8) |
   42|       |                            ((x & 0xFF000000) >> 24));
   43|       |#endif
   44|   234M|   } else if constexpr(sizeof(T) == 8) {
   45|   234M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_bswap64)
   46|   234M|      return static_cast<T>(__builtin_bswap64(x));
   47|       |#else
   48|       |      uint32_t hi = static_cast<uint32_t>(x >> 32);
   49|       |      uint32_t lo = static_cast<uint32_t>(x);
   50|       |
   51|       |      hi = reverse_bytes(hi);
   52|       |      lo = reverse_bytes(lo);
   53|       |
   54|       |      return (static_cast<T>(lo) << 32) | hi;
   55|       |#endif
   56|   234M|   }
   57|   234M|}

_ZN5Botan12BufferSlicerC2ENSt3__14spanIKhLm18446744073709551615EEE:
   25|   236M|      explicit BufferSlicer(std::span<const uint8_t> buffer) : m_remaining(buffer) {}
_ZNK5Botan12BufferSlicer5emptyEv:
   68|   413M|      bool empty() const { return m_remaining.empty(); }
_ZN5Botan12BufferSlicer4takeEm:
   37|   265M|      std::span<const uint8_t> take(const size_t count) {
   38|   265M|         BOTAN_STATE_CHECK(remaining() >= count);
  ------------------
  |  |   51|   265M|   do {                                                         \
  |  |   52|   265M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   265M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 265M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   265M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 265M]
  |  |  ------------------
  ------------------
   39|   265M|         auto result = m_remaining.first(count);
   40|   265M|         m_remaining = m_remaining.subspan(count);
   41|   265M|         return result;
   42|   265M|      }
_ZNK5Botan12BufferSlicer9remainingEv:
   66|   622M|      size_t remaining() const { return m_remaining.size(); }
_ZN5Botan12BufferSlicer9copy_intoENSt3__14spanIhLm18446744073709551615EEE:
   59|  3.30M|      void copy_into(std::span<uint8_t> sink) {
   60|  3.30M|         const auto data = take(sink.size());
   61|  3.30M|         std::copy(data.begin(), data.end(), sink.begin());
   62|  3.30M|      }
_ZN5Botan12BufferSlicer4skipEm:
   64|  1.40M|      void skip(const size_t count) { take(count); }
_ZN5Botan12BufferSlicer4takeILm64EEENSt3__14spanIKhXT_EEEv:
   45|  34.7M|      std::span<const uint8_t, count> take() {
   46|  34.7M|         BOTAN_STATE_CHECK(remaining() >= count);
  ------------------
  |  |   51|  34.7M|   do {                                                         \
  |  |   52|  34.7M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  34.7M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 34.7M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  34.7M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 34.7M]
  |  |  ------------------
  ------------------
   47|  34.7M|         auto result = m_remaining.first<count>();
   48|  34.7M|         m_remaining = m_remaining.subspan(count);
   49|  34.7M|         return result;
   50|  34.7M|      }
_ZN5Botan12BufferSlicer4takeILm128EEENSt3__14spanIKhXT_EEEv:
   45|  9.21M|      std::span<const uint8_t, count> take() {
   46|  9.21M|         BOTAN_STATE_CHECK(remaining() >= count);
  ------------------
  |  |   51|  9.21M|   do {                                                         \
  |  |   52|  9.21M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  9.21M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 9.21M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  9.21M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 9.21M]
  |  |  ------------------
  ------------------
   47|  9.21M|         auto result = m_remaining.first<count>();
   48|  9.21M|         m_remaining = m_remaining.subspan(count);
   49|  9.21M|         return result;
   50|  9.21M|      }
_ZN5Botan12BufferSlicer4takeILm8EEENSt3__14spanIKhXT_EEEv:
   45|  6.89M|      std::span<const uint8_t, count> take() {
   46|  6.89M|         BOTAN_STATE_CHECK(remaining() >= count);
  ------------------
  |  |   51|  6.89M|   do {                                                         \
  |  |   52|  6.89M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  6.89M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 6.89M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  6.89M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 6.89M]
  |  |  ------------------
  ------------------
   47|  6.89M|         auto result = m_remaining.first<count>();
   48|  6.89M|         m_remaining = m_remaining.subspan(count);
   49|  6.89M|         return result;
   50|  6.89M|      }
_ZN5Botan12BufferSlicer4takeILm16EEENSt3__14spanIKhXT_EEEv:
   45|  2.30M|      std::span<const uint8_t, count> take() {
   46|  2.30M|         BOTAN_STATE_CHECK(remaining() >= count);
  ------------------
  |  |   51|  2.30M|   do {                                                         \
  |  |   52|  2.30M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  2.30M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 2.30M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  2.30M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 2.30M]
  |  |  ------------------
  ------------------
   47|  2.30M|         auto result = m_remaining.first<count>();
   48|  2.30M|         m_remaining = m_remaining.subspan(count);
   49|  2.30M|         return result;
   50|  2.30M|      }

_ZN5Botan13BufferStufferC2ENSt3__14spanIhLm18446744073709551615EEE:
   26|  31.6k|      constexpr explicit BufferStuffer(std::span<uint8_t> buffer) : m_buffer(buffer) {}
_ZN5Botan13BufferStuffer4nextEm:
   32|  1.72M|      constexpr std::span<uint8_t> next(size_t bytes) {
   33|  1.72M|         BOTAN_STATE_CHECK(m_buffer.size() >= bytes);
  ------------------
  |  |   51|  1.72M|   do {                                                         \
  |  |   52|  1.72M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  1.72M|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 1.72M]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  1.72M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 1.72M]
  |  |  ------------------
  ------------------
   34|       |
   35|  1.72M|         auto result = m_buffer.first(bytes);
   36|  1.72M|         m_buffer = m_buffer.subspan(bytes);
   37|  1.72M|         return result;
   38|  1.72M|      }
_ZNK5Botan13BufferStuffer18remaining_capacityEv:
   71|  1.70M|      constexpr size_t remaining_capacity() const { return m_buffer.size(); }
_ZN5Botan13BufferStuffer6appendENSt3__14spanIKhLm18446744073709551615EEE:
   59|  30.5k|      constexpr void append(std::span<const uint8_t> buffer) {
   60|  30.5k|         auto sink = next(buffer.size());
   61|  30.5k|         std::copy(buffer.begin(), buffer.end(), sink.begin());
   62|  30.5k|      }
_ZN5Botan13BufferStuffer6appendEhm:
   64|  17.5k|      constexpr void append(uint8_t b, size_t repeat = 1) {
   65|  17.5k|         auto sink = next(repeat);
   66|  17.5k|         std::fill(sink.begin(), sink.end(), b);
   67|  17.5k|      }
_ZNK5Botan13BufferStuffer4fullEv:
   69|  21.2k|      constexpr bool full() const { return m_buffer.empty(); }
_ZN5Botan13BufferStuffer4nextILm32EEENSt3__14spanIhXT_EEEv:
   41|  25.0k|      constexpr std::span<uint8_t, bytes> next() {
   42|  25.0k|         BOTAN_STATE_CHECK(m_buffer.size() >= bytes);
  ------------------
  |  |   51|  25.0k|   do {                                                         \
  |  |   52|  25.0k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  25.0k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 25.0k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  25.0k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 25.0k]
  |  |  ------------------
  ------------------
   43|       |
   44|  25.0k|         auto result = m_buffer.first<bytes>();
   45|  25.0k|         m_buffer = m_buffer.subspan(bytes);
   46|  25.0k|         return result;
   47|  25.0k|      }

_ZNK5Botan12Camellia_1284nameEv:
   26|    904|      std::string name() const override { return "Camellia-128"; }
_ZNK5Botan12Camellia_12810new_objectEv:
   31|    988|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Camellia_128>(); }
_ZNK5Botan12Camellia_1924nameEv:
   66|    497|      std::string name() const override { return "Camellia-192"; }
_ZNK5Botan12Camellia_19210new_objectEv:
   71|  1.39k|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Camellia_192>(); }
_ZNK5Botan12Camellia_2564nameEv:
  106|    113|      std::string name() const override { return "Camellia-256"; }
_ZNK5Botan12Camellia_25610new_objectEv:
  111|    354|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Camellia_256>(); }

_ZNK5Botan8CAST_1284nameEv:
   26|     22|      std::string name() const override { return "CAST-128"; }
_ZNK5Botan8CAST_12810new_objectEv:
   28|    304|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<CAST_128>(); }

_ZNK5Botan4CMAC13output_lengthEv:
   23|  16.7M|      size_t output_length() const override { return m_block_size; }
_ZNK5Botan4CMAC8key_specEv:
   30|  4.86k|      Key_Length_Specification key_spec() const override { return m_cipher->key_spec(); }

_ZN5Botan5CRC245clearEv:
   33|  8.15k|      void clear() override { m_crc = 0xCE04B7; }
_ZNK5Botan5CRC2413output_lengthEv:
   25|  24.5k|      size_t output_length() const override { return 3; }

_ZN5Botan2CT6poisonIjEEvPKT_m:
   56|  7.91M|constexpr inline void poison(const T* p, size_t n) {
   57|       |#if defined(BOTAN_HAS_VALGRIND)
   58|       |   if(!std::is_constant_evaluated()) {
   59|       |      VALGRIND_MAKE_MEM_UNDEFINED(p, n * sizeof(T));
   60|       |   }
   61|       |#endif
   62|       |
   63|  7.91M|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  7.91M|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   64|  7.91M|}
_ZN5Botan2CT8unpoisonIjEEvPKT_m:
   67|  7.94M|constexpr inline void unpoison(const T* p, size_t n) {
   68|       |#if defined(BOTAN_HAS_VALGRIND)
   69|       |   if(!std::is_constant_evaluated()) {
   70|       |      VALGRIND_MAKE_MEM_DEFINED(p, n * sizeof(T));
   71|       |   }
   72|       |#endif
   73|       |
   74|  7.94M|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  7.94M|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   75|  7.94M|}
_ZN5Botan2CT6poisonIhEEvPKT_m:
   56|  2.01M|constexpr inline void poison(const T* p, size_t n) {
   57|       |#if defined(BOTAN_HAS_VALGRIND)
   58|       |   if(!std::is_constant_evaluated()) {
   59|       |      VALGRIND_MAKE_MEM_UNDEFINED(p, n * sizeof(T));
   60|       |   }
   61|       |#endif
   62|       |
   63|  2.01M|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  2.01M|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   64|  2.01M|}
_ZN5Botan2CT8unpoisonIhEEvPKT_m:
   67|  2.29M|constexpr inline void unpoison(const T* p, size_t n) {
   68|       |#if defined(BOTAN_HAS_VALGRIND)
   69|       |   if(!std::is_constant_evaluated()) {
   70|       |      VALGRIND_MAKE_MEM_DEFINED(p, n * sizeof(T));
   71|       |   }
   72|       |#endif
   73|       |
   74|  2.29M|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  2.29M|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   75|  2.29M|}
_ZN5Botan2CT6Choice9from_maskEm:
  303|  4.41M|      constexpr static Choice from_mask(underlying_type v) { return Choice(v); }
_ZN5Botan2CT6Choice2noEv:
  307|  6.25k|      constexpr static Choice no() { return Choice(0); }
_ZNK5Botan2CT6ChoicentEv:
  309|   813k|      constexpr Choice operator!() const { return Choice(~value()); }
_ZNK5Botan2CT6ChoiceaaERKS1_:
  311|  3.09M|      constexpr Choice operator&&(const Choice& other) const { return Choice(value() & other.value()); }
_ZNK5Botan2CT6ChoiceooERKS1_:
  313|   398k|      constexpr Choice operator||(const Choice& other) const { return Choice(value() | other.value()); }
_ZNK5Botan2CT6Choice7as_boolEv:
  329|   912k|      constexpr bool as_bool() const { return m_value != 0; }
_ZNK5Botan2CT6Choice5valueEv:
  332|  9.43M|      constexpr underlying_type value() const { return value_barrier(m_value); }
_ZN5Botan2CT6ChoiceC2Em:
  341|  8.73M|      constexpr explicit Choice(underlying_type v) : m_value(CT::value_barrier<underlying_type>(v)) {}
_ZN5Botan2CT4MaskImE7is_zeroEm:
  437|  37.8M|      static constexpr Mask<T> is_zero(T x) { return Mask<T>(ct_is_zero<T>(value_barrier<T>(x))); }
_ZNK5Botan2CT4MaskImE5valueEv:
  630|   671M|      constexpr T value() const { return value_barrier<T>(m_mask); }
_ZNK5Botan2CT4MaskImEcoEv:
  533|  31.3M|      constexpr Mask<T> operator~() const { return Mask<T>(~value()); }
_ZN5Botan2CT4MaskImE6expandEm:
  392|  31.3M|      static constexpr Mask<T> expand(T v) { return ~Mask<T>::is_zero(value_barrier<T>(v)); }
_ZNK5Botan2CT4MaskImE6selectEmm:
  548|   594M|      constexpr T select(T x, T y) const { return choose(value(), x, y); }
_ZN5Botan2CT6poisonItEEvPKT_m:
   56|   730k|constexpr inline void poison(const T* p, size_t n) {
   57|       |#if defined(BOTAN_HAS_VALGRIND)
   58|       |   if(!std::is_constant_evaluated()) {
   59|       |      VALGRIND_MAKE_MEM_UNDEFINED(p, n * sizeof(T));
   60|       |   }
   61|       |#endif
   62|       |
   63|   730k|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|   730k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   64|   730k|}
_ZN5Botan2CT8unpoisonItEEvPKT_m:
   67|   730k|constexpr inline void unpoison(const T* p, size_t n) {
   68|       |#if defined(BOTAN_HAS_VALGRIND)
   69|       |   if(!std::is_constant_evaluated()) {
   70|       |      VALGRIND_MAKE_MEM_DEFINED(p, n * sizeof(T));
   71|       |   }
   72|       |#endif
   73|       |
   74|   730k|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|   730k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   75|   730k|}
_ZN5Botan2CT4MaskIhE8is_equalEhh:
  442|  67.1M|      static constexpr Mask<T> is_equal(T x, T y) {
  443|  67.1M|         const T diff = value_barrier(x) ^ value_barrier(y);
  444|  67.1M|         return Mask<T>::is_zero(diff);
  445|  67.1M|      }
_ZN5Botan2CT4MaskIhE7is_zeroEh:
  437|  67.4M|      static constexpr Mask<T> is_zero(T x) { return Mask<T>(ct_is_zero<T>(value_barrier<T>(x))); }
_ZN5Botan2CT4MaskIhEC2Eh:
  637|  67.4M|      constexpr explicit Mask(T m) : m_mask(m) {}
_ZNK5Botan2CT4MaskIhE13if_set_returnEh:
  538|  67.1M|      constexpr T if_set_return(T x) const { return value() & x; }
_ZNK5Botan2CT4MaskIhE5valueEv:
  630|  67.4M|      constexpr T value() const { return value_barrier<T>(m_mask); }
_ZN5Botan2CT4MaskIjE6expandEj:
  392|   567k|      static constexpr Mask<T> expand(T v) { return ~Mask<T>::is_zero(value_barrier<T>(v)); }
_ZN5Botan2CT4MaskIjE7is_zeroEj:
  437|   567k|      static constexpr Mask<T> is_zero(T x) { return Mask<T>(ct_is_zero<T>(value_barrier<T>(x))); }
_ZN5Botan2CT4MaskIjEC2Ej:
  637|  1.13M|      constexpr explicit Mask(T m) : m_mask(m) {}
_ZNK5Botan2CT4MaskIjEcoEv:
  533|   567k|      constexpr Mask<T> operator~() const { return Mask<T>(~value()); }
_ZNK5Botan2CT4MaskIjE5valueEv:
  630|  1.13M|      constexpr T value() const { return value_barrier<T>(m_mask); }
_ZNK5Botan2CT4MaskIjE13if_set_returnEj:
  538|   567k|      constexpr T if_set_return(T x) const { return value() & x; }
_ZN5Botan2CT8is_equalIhEENS0_4MaskIT_EEPKS3_S6_m:
  798|   268k|constexpr inline CT::Mask<T> is_equal(const T x[], const T y[], size_t len) {
  799|   268k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (799:7): [Folded, False: 268k]
  ------------------
  800|      0|      T difference = 0;
  801|       |
  802|      0|      for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (802:25): [True: 0, False: 0]
  ------------------
  803|      0|         difference = difference | (x[i] ^ y[i]);
  804|      0|      }
  805|       |
  806|      0|      return CT::Mask<T>::is_zero(difference);
  807|   268k|   } else {
  808|   268k|      volatile T difference = 0;
  809|       |
  810|  4.69M|      for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (810:25): [True: 4.42M, False: 268k]
  ------------------
  811|  4.42M|         difference = difference | (x[i] ^ y[i]);
  812|  4.42M|      }
  813|       |
  814|   268k|      return CT::Mask<T>::is_zero(difference);
  815|   268k|   }
  816|   268k|}
_ZNK5Botan2CT4MaskIhE6selectEhh:
  548|  1.02k|      constexpr T select(T x, T y) const { return choose(value(), x, y); }
_ZN5Botan2CT4MaskImE6is_lteEmm:
  463|    329|      static constexpr Mask<T> is_lte(T x, T y) { return ~Mask<T>::is_gt(x, y); }
_ZN5Botan2CT4MaskImE5is_gtEmm:
  458|    329|      static constexpr Mask<T> is_gt(T x, T y) { return Mask<T>::is_lt(y, x); }
_ZN5Botan2CT4MaskImEC2Em:
  637|   365M|      constexpr explicit Mask(T m) : m_mask(m) {}
_ZN5Botan2CT4MaskImE5is_ltEmm:
  450|  1.65M|      static constexpr Mask<T> is_lt(T x, T y) {
  451|  1.65M|         T u = x ^ ((x ^ y) | ((x - y) ^ x));
  452|  1.65M|         return Mask<T>::expand_top_bit(u);
  453|  1.65M|      }
_ZN5Botan2CT4MaskImE14expand_top_bitEm:
  415|   296M|      static constexpr Mask<T> expand_top_bit(T v) { return Mask<T>(ct_expand_top_bit<T>(v)); }
_ZNK5Botan2CT4MaskImE13if_set_returnEm:
  538|  10.5M|      constexpr T if_set_return(T x) const { return value() & x; }
_ZNK5Botan2CT4MaskIhE7as_boolEv:
  614|   274k|      constexpr bool as_bool() const { return unpoisoned_value() != 0; }
_ZNK5Botan2CT4MaskIhE16unpoisoned_valueEv:
  598|   274k|      constexpr T unpoisoned_value() const {
  599|   274k|         T r = value();
  600|   274k|         CT::unpoison(r);
  601|   274k|         return r;
  602|   274k|      }
_ZN5Botan2CT8unpoisonITkNSt3__18integralEhEEvRKT_:
  112|   274k|constexpr void unpoison(const T& p) {
  113|   274k|   unpoison(&p, 1);
  114|   274k|}
_ZN5Botan2CT4MaskImE8is_equalEmm:
  442|  2.00M|      static constexpr Mask<T> is_equal(T x, T y) {
  443|  2.00M|         const T diff = value_barrier(x) ^ value_barrier(y);
  444|  2.00M|         return Mask<T>::is_zero(diff);
  445|  2.00M|      }
_ZN5Botan2CT8unpoisonITkNSt3__18integralEmEEvRKT_:
  112|  4.76M|constexpr void unpoison(const T& p) {
  113|  4.76M|   unpoison(&p, 1);
  114|  4.76M|}
_ZN5Botan2CT8unpoisonImEEvPKT_m:
   67|  4.95M|constexpr inline void unpoison(const T* p, size_t n) {
   68|       |#if defined(BOTAN_HAS_VALGRIND)
   69|       |   if(!std::is_constant_evaluated()) {
   70|       |      VALGRIND_MAKE_MEM_DEFINED(p, n * sizeof(T));
   71|       |   }
   72|       |#endif
   73|       |
   74|  4.95M|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  4.95M|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   75|  4.95M|}
_ZN5Botan2CT20conditional_copy_memImEENS0_4MaskIT_EES3_PS3_PKS3_S7_m:
  738|  8.36k|constexpr inline Mask<T> conditional_copy_mem(T cnd, T* dest, const T* if_set, const T* if_unset, size_t elems) {
  739|  8.36k|   const auto mask = CT::Mask<T>::expand(cnd);
  740|  8.36k|   return CT::conditional_copy_mem(mask, dest, if_set, if_unset, elems);
  741|  8.36k|}
_ZN5Botan2CT20conditional_copy_memImEENS0_4MaskIT_EES4_PS3_PKS3_S7_m:
  732|  8.36k|constexpr inline Mask<T> conditional_copy_mem(Mask<T> mask, T* dest, const T* if_set, const T* if_unset, size_t elems) {
  733|  8.36k|   mask.select_n(dest, if_set, if_unset, elems);
  734|  8.36k|   return mask;
  735|  8.36k|}
_ZNK5Botan2CT4MaskImE8select_nEPmPKmS5_m:
  565|  16.2M|      constexpr void select_n(T output[], const T x[], const T y[], size_t len) const {
  566|  16.2M|         const T mask = value();
  567|  85.9M|         for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (567:28): [True: 69.7M, False: 16.2M]
  ------------------
  568|  69.7M|            output[i] = choose(mask, x[i], y[i]);
  569|  69.7M|         }
  570|  16.2M|      }
_ZNK5Botan2CT4MaskImE7as_boolEv:
  614|  51.5k|      constexpr bool as_bool() const { return unpoisoned_value() != 0; }
_ZNK5Botan2CT4MaskImE16unpoisoned_valueEv:
  598|  4.46M|      constexpr T unpoisoned_value() const {
  599|  4.46M|         T r = value();
  600|  4.46M|         CT::unpoison(r);
  601|  4.46M|         return r;
  602|  4.46M|      }
_ZNK5Botan2CT4MaskImE11select_maskES2_S2_:
  559|   402k|      Mask<T> select_mask(Mask<T> x, Mask<T> y) const { return Mask<T>(select(x.value(), y.value())); }
_ZN5Botan2CT4MaskImEoRES2_:
  510|     82|      Mask<T>& operator|=(Mask<T> o) {
  511|     82|         m_mask |= o.value();
  512|     82|         return (*this);
  513|     82|      }
_ZN5Botan2CT4MaskImEaNES2_:
  494|  14.2k|      Mask<T>& operator&=(Mask<T> o) {
  495|  14.2k|         m_mask &= o.value();
  496|  14.2k|         return (*this);
  497|  14.2k|      }
_ZN5Botan2CT4MaskIhE11expand_boolEb:
  397|  1.02k|      static constexpr Mask<T> expand_bool(bool v) { return Mask<T>::expand(static_cast<T>(v)); }
_ZN5Botan2CT4MaskIhE6expandEh:
  392|  1.02k|      static constexpr Mask<T> expand(T v) { return ~Mask<T>::is_zero(value_barrier<T>(v)); }
_ZNK5Botan2CT4MaskIhEcoEv:
  533|  1.02k|      constexpr Mask<T> operator~() const { return Mask<T>(~value()); }
_ZNK5Botan2CT4MaskImE9as_choiceEv:
  619|  4.41M|      constexpr CT::Choice as_choice() const {
  620|  4.41M|         if constexpr(sizeof(T) >= sizeof(Choice::underlying_type)) {
  621|  4.41M|            return CT::Choice::from_mask(static_cast<Choice::underlying_type>(unpoisoned_value()));
  622|       |         } else {
  623|       |            return CT::Choice::from_int(unpoisoned_value());
  624|       |         }
  625|  4.41M|      }
_ZN5Botan2CT6poisonImEEvPKT_m:
   56|  26.2k|constexpr inline void poison(const T* p, size_t n) {
   57|       |#if defined(BOTAN_HAS_VALGRIND)
   58|       |   if(!std::is_constant_evaluated()) {
   59|       |      VALGRIND_MAKE_MEM_UNDEFINED(p, n * sizeof(T));
   60|       |   }
   61|       |#endif
   62|       |
   63|  26.2k|   BOTAN_UNUSED(p, n);
  ------------------
  |  |  144|  26.2k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   64|  26.2k|}
_ZN5Botan2CTeoENS0_4MaskImEES2_:
  523|    326|      friend Mask<T> operator^(Mask<T> x, Mask<T> y) { return Mask<T>(x.value() ^ y.value()); }
_ZN5Botan2CT22conditional_assign_memImEENS0_4MaskIT_EES3_PS3_PKS3_m:
  749|  16.1M|constexpr inline Mask<T> conditional_assign_mem(T cnd, T* dest, const T* src, size_t elems) {
  750|  16.1M|   const auto mask = CT::Mask<T>::expand(cnd);
  751|  16.1M|   mask.select_n(dest, src, dest, elems);
  752|  16.1M|   return mask;
  753|  16.1M|}
_ZN5Botan2CT6Choice8from_intIjQaasr3stdE17unsigned_integralIT_Entsr3stdE7same_asIbS3_EEES1_S3_:
  268|  8.64k|      constexpr static Choice from_int(T v) {
  269|  8.64k|         if constexpr(sizeof(T) <= sizeof(underlying_type)) {
  270|  8.64k|            return !Choice(ct_is_zero<underlying_type>(v));
  271|       |         } else {
  272|       |            // Mask of T that is either |0| or |1|
  273|       |            const T v_is_0 = ct_is_zero<T>(value_barrier<T>(v));
  274|       |
  275|       |            // We want the mask to be set if v != 0 so we must check that
  276|       |            // v_is_0 is itself zero.
  277|       |            //
  278|       |            // Also sizeof(T) may not equal sizeof(underlying_type) so we must
  279|       |            // use ct_is_zero<underlying_type>. It's ok to either truncate or
  280|       |            // zero extend v_is_0 to 32 bits since we know it is |0| or |1|
  281|       |            // so even just the low bit is sufficient.
  282|       |            return Choice(ct_is_zero<underlying_type>(static_cast<underlying_type>(v_is_0)));
  283|       |         }
  284|  8.64k|      }
_ZN5Botan2CT6poisonITkNS_6ranges14spanable_rangeENSt3__14spanIKmLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEnt17custom_poisonableISB_EEEvRKSB_:
  121|  6.54k|constexpr void poison(const R& r) {
  122|  6.54k|   const std::span s{r};
  123|  6.54k|   poison(s.data(), s.size());
  124|  6.54k|}
_ZN5Botan2CT8unpoisonITkNS_6ranges14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEnt19custom_unpoisonableISC_EEEvRKSC_:
  128|  20.0k|constexpr void unpoison(const R& r) {
  129|  20.0k|   const std::span s{r};
  130|  20.0k|   unpoison(s.data(), s.size());
  131|  20.0k|}
_ZN5Botan2CT8unpoisonITkNS_6ranges14spanable_rangeENSt3__14spanIKmLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEnt19custom_unpoisonableISB_EEEvRKSB_:
  128|  6.54k|constexpr void unpoison(const R& r) {
  129|  6.54k|   const std::span s{r};
  130|  6.54k|   unpoison(s.data(), s.size());
  131|  6.54k|}
_ZN5Botan2CT6poisonITkNS_6ranges14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEnt17custom_poisonableISC_EEEvRKSC_:
  121|  18.7k|constexpr void poison(const R& r) {
  122|  18.7k|   const std::span s{r};
  123|  18.7k|   poison(s.data(), s.size());
  124|  18.7k|}
_ZN5Botan2CT9all_zerosImEENS0_4MaskIT_EEPKS3_m:
  785|  4.42M|constexpr inline CT::Mask<T> all_zeros(const T elem[], size_t len) {
  786|  4.42M|   T sum = 0;
  787|  22.1M|   for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (787:22): [True: 17.6M, False: 4.42M]
  ------------------
  788|  17.6M|      sum |= elem[i];
  789|  17.6M|   }
  790|  4.42M|   return CT::Mask<T>::is_zero(sum);
  791|  4.42M|}
_ZN5Botan2CT4MaskImE15if_set_zero_outEPmm:
  575|  1.02k|      constexpr void if_set_zero_out(T buf[], size_t elems) {
  576|  4.10k|         for(size_t i = 0; i != elems; ++i) {
  ------------------
  |  Branch (576:28): [True: 3.08k, False: 1.02k]
  ------------------
  577|  3.08k|            buf[i] = this->if_not_set_return(buf[i]);
  578|  3.08k|         }
  579|  1.02k|      }
_ZNK5Botan2CT4MaskImE17if_not_set_returnEm:
  543|  3.08k|      constexpr T if_not_set_return(T x) const { return ~value() & x; }
_ZN5Botan2CT12poison_rangeITkNSt3__16ranges5rangeENS2_6vectorINS_14Montgomery_IntENS2_9allocatorIS5_EEEEQ10poisonableINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEEEvRKSC_:
  181|  1.16k|constexpr void poison_range(const R& r) {
  182|  18.7k|   for(const auto& v : r) {
  ------------------
  |  Branch (182:22): [True: 18.7k, False: 1.16k]
  ------------------
  183|  18.7k|      poison(v);
  184|  18.7k|   }
  185|  1.16k|}
_ZN5Botan2CT6poisonITkNS0_17custom_poisonableENS_14Montgomery_IntEEEvRKT_:
  138|  18.7k|constexpr void poison(const T& x) {
  139|  18.7k|   x._const_time_poison();
  140|  18.7k|}
_ZN5Botan2CT8unpoisonITkNS0_19custom_unpoisonableENS_14Montgomery_IntEEEvRKT_:
  143|    411|constexpr void unpoison(const T& x) {
  144|    411|   x._const_time_unpoison();
  145|    411|}
_ZN5Botan2CTanENS0_4MaskImEES2_:
  518|    329|      friend Mask<T> operator&(Mask<T> x, Mask<T> y) { return Mask<T>(x.value() & y.value()); }
_ZNK5Botan2CT6Choice12into_bitmaskImQaasr3stdE17unsigned_integralIT_Entsr3stdE7same_asIbS3_EEES3_v:
  291|  1.62M|      constexpr T into_bitmask() const {
  292|  1.62M|         if constexpr(sizeof(T) <= sizeof(underlying_type)) {
  293|       |            // The inner mask is already |0| or |1| so just truncate
  294|  1.62M|            return static_cast<T>(value());
  295|       |         } else {
  296|       |            return ~ct_is_zero<T>(value());
  297|       |         }
  298|  1.62M|      }
_ZN5Botan2CT8is_equalImEENS0_4MaskIT_EEPKS3_S6_m:
  798|  12.6k|constexpr inline CT::Mask<T> is_equal(const T x[], const T y[], size_t len) {
  799|  12.6k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (799:7): [Folded, False: 12.6k]
  ------------------
  800|      0|      T difference = 0;
  801|       |
  802|      0|      for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (802:25): [True: 0, False: 0]
  ------------------
  803|      0|         difference = difference | (x[i] ^ y[i]);
  804|      0|      }
  805|       |
  806|      0|      return CT::Mask<T>::is_zero(difference);
  807|  12.6k|   } else {
  808|  12.6k|      volatile T difference = 0;
  809|       |
  810|  63.1k|      for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (810:25): [True: 50.5k, False: 12.6k]
  ------------------
  811|  50.5k|         difference = difference | (x[i] ^ y[i]);
  812|  50.5k|      }
  813|       |
  814|  12.6k|      return CT::Mask<T>::is_zero(difference);
  815|  12.6k|   }
  816|  12.6k|}
_ZN5Botan2CT4MaskImE6expandIhEES2_NS1_IT_EE:
  429|    329|      static constexpr Mask<T> expand(Mask<U> m) {
  430|    329|         static_assert(sizeof(U) < sizeof(T), "sizes ok");
  431|    329|         return ~Mask<T>::is_zero(m.value());
  432|    329|      }
_ZN5Botan2CT9all_zerosIhEENS0_4MaskIT_EEPKS3_m:
  785|  6.16k|constexpr inline CT::Mask<T> all_zeros(const T elem[], size_t len) {
  786|  6.16k|   T sum = 0;
  787|   203k|   for(size_t i = 0; i != len; ++i) {
  ------------------
  |  Branch (787:22): [True: 197k, False: 6.16k]
  ------------------
  788|   197k|      sum |= elem[i];
  789|   197k|   }
  790|  6.16k|   return CT::Mask<T>::is_zero(sum);
  791|  6.16k|}
_ZN5Botan2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS5_EEEDaDpRKS5_:
  222|   545k|[[nodiscard]] constexpr auto scoped_poison(const Ts&... xs) {
  223|   545k|   auto scope = scoped_cleanup([&] { unpoison_all(xs...); });
  224|   545k|   poison_all(xs...);
  225|   545k|   return scope;
  226|   545k|}
_ZN5Botan2CT10poison_allITpTkNS0_10poisonableEJNSt3__14spanIhLm16EEEEQgtsZT_Li0EEEvDpRKT_:
  201|   545k|constexpr void poison_all(const Ts&... ts) {
  202|   545k|   (poison(ts), ...);
  203|   545k|}
_ZN5Botan2CT6poisonITkNS_6ranges14spanable_rangeENSt3__14spanIhLm16EEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEnt17custom_poisonableISA_EEEvRKSA_:
  121|   545k|constexpr void poison(const R& r) {
  122|   545k|   const std::span s{r};
  123|   545k|   poison(s.data(), s.size());
  124|   545k|}
_ZZN5Botan2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS5_EEEDaDpRKS5_ENKUlvE_clEv:
  223|   545k|   auto scope = scoped_cleanup([&] { unpoison_all(xs...); });
_ZN5Botan2CT12unpoison_allITpTkNS0_12unpoisonableEJNSt3__14spanIhLm16EEEEQgtsZT_Li0EEEvDpRKT_:
  207|   545k|constexpr void unpoison_all(const Ts&... ts) {
  208|   545k|   (unpoison(ts), ...);
  209|   545k|}
_ZN5Botan2CT8unpoisonITkNS_6ranges14spanable_rangeENSt3__14spanIhLm16EEEQaasr3stdE23is_trivially_copyable_vINS3_11conditionalIXsr21__is_primary_templateINS3_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS3_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS3_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEnt19custom_unpoisonableISA_EEEvRKSA_:
  128|   545k|constexpr void unpoison(const R& r) {
  129|   545k|   const std::span s{r};
  130|   545k|   unpoison(s.data(), s.size());
  131|   545k|}

_ZNK5Botan9TripleDES4nameEv:
   50|     19|      std::string name() const override { return "TripleDES"; }
_ZNK5Botan9TripleDES10new_objectEv:
   52|    166|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<TripleDES>(); }
_ZNK5Botan9TripleDES11parallelismEv:
   54|    478|      size_t parallelism() const override { return 32; }

_ZNK5Botan12DL_PublicKey5groupEv:
   29|  3.38k|      const DL_Group& group() const { return m_group; }
_ZNK5Botan12DL_PublicKey10public_keyEv:
   31|  1.06k|      const BigInt& public_key() const { return m_public_key; }

_ZN5Botan14EAX_EncryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
   82|  2.21k|            EAX_Mode(std::move(cipher), tag_size) {}
_ZN5Botan14EAX_DecryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
  103|  2.64k|            EAX_Mode(std::move(cipher), tag_size) {}
_ZNK5Botan8EAX_Mode18valid_nonce_lengthEm:
   37|   239k|      bool valid_nonce_length(size_t /*length*/) const final { return true; }
_ZNK5Botan8EAX_Mode8tag_sizeEv:
   39|   393k|      size_t tag_size() const final { return m_tag_size; }
_ZNK5Botan8EAX_Mode10block_sizeEv:
   54|  4.31M|      size_t block_size() const { return m_cipher->block_size(); }
_ZNK5Botan14EAX_Encryption18minimum_final_sizeEv:
   86|  2.21k|      size_t minimum_final_size() const override { return 0; }
_ZNK5Botan14EAX_Decryption18minimum_final_sizeEv:
  107|  2.64k|      size_t minimum_final_size() const override { return tag_size(); }

_ZNK5Botan13EC_Group_Data3oidEv:
  166|  13.8k|      const OID& oid() const { return m_oid; }
_ZNK5Botan13EC_Group_Data1pEv:
  170|  25.0k|      const BigInt& p() const { return m_p; }
_ZNK5Botan13EC_Group_Data5curveEv:
  181|  6.25k|      const CurveGFp& curve() const { return m_curve; }
_ZNK5Botan13EC_Group_Data5montyEv:
  185|  31.2k|      const Montgomery_Params& monty() const { return m_monty; }
_ZNK5Botan13EC_Group_Data7p_wordsEv:
  202|  6.25k|      size_t p_words() const { return m_p_words; }
_ZNK5Botan13EC_Group_Data7p_bytesEv:
  206|  12.5k|      size_t p_bytes() const { return (m_p_bits + 7) / 8; }
_ZNK5Botan13EC_Group_Data10order_bitsEv:
  208|  11.9k|      size_t order_bits() const { return m_order_bits; }
_ZNK5Botan13EC_Group_Data11order_bytesEv:
  210|  12.4k|      size_t order_bytes() const { return m_order_bytes; }
_ZNK5Botan13EC_Group_Data6pcurveEv:
  297|  74.5k|      const PCurve::PrimeOrderCurve& pcurve() const {
  298|  74.5k|         BOTAN_ASSERT_NONNULL(m_pcurve);
  ------------------
  |  |  116|  74.5k|   do {                                                                                   \
  |  |  117|  74.5k|      if((ptr) == nullptr) {                                                              \
  |  |  ------------------
  |  |  |  Branch (117:10): [True: 0, False: 74.5k]
  |  |  ------------------
  |  |  118|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                              \
  |  |  119|      0|         Botan::assertion_failure(#ptr " is not null", "", __func__, __FILE__, __LINE__); \
  |  |  120|      0|      }                                                                                   \
  |  |  121|  74.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (121:12): [Folded, False: 74.5k]
  |  |  ------------------
  ------------------
  299|  74.5k|         return *m_pcurve;
  300|  74.5k|      }
_ZN5Botan19EC_AffinePoint_DataD2Ev:
   74|  12.5k|      virtual ~EC_AffinePoint_Data() = default;
_ZN5Botan14EC_Scalar_DataD2Ev:
   39|  49.5k|      virtual ~EC_Scalar_Data() = default;
_ZN5Botan17EC_Mul2Table_DataD2Ev:
  113|  6.25k|      virtual ~EC_Mul2Table_Data() = default;

_ZNK5Botan17EC_Scalar_Data_PC5valueEv:
   53|  30.9k|      const auto& value() const { return m_v; }
_ZNK5Botan22EC_AffinePoint_Data_PC5valueEv:
   88|  6.25k|      const PCurve::PrimeOrderCurve::AffinePoint& value() const { return m_pt; }
_ZN5Botan17EC_Scalar_Data_PCC2ENSt3__110shared_ptrIKNS_13EC_Group_DataEEENS_6PCurve15PrimeOrderCurve6ScalarE:
   19|  49.5k|            m_group(std::move(group)), m_v(std::move(v)) {}

_ZNK5Botan17EC_PublicKey_Data5groupEv:
   30|  18.7k|      const EC_Group& group() const { return m_group; }
_ZNK5Botan17EC_PublicKey_Data10public_keyEv:
   32|  6.25k|      const EC_AffinePoint& public_key() const { return m_point; }

_ZNK5Botan20Ed25519_FieldElement3sqrEv:
  122|  2.30M|      Ed25519_FieldElement sqr() const { return sqr_iter(1); }
_ZN5BotanmlERKNS_20Ed25519_FieldElementES2_:
  148|  4.41M|inline Ed25519_FieldElement operator*(const Ed25519_FieldElement& x, const Ed25519_FieldElement& y) {
  149|  4.41M|   return Ed25519_FieldElement::mul(x, y);
  150|  4.41M|}
_ZN5Botan20Ed25519_FieldElementC2Ellllllllll:
   60|  7.53M|                                     int64_t h9) {
   61|  7.53M|         m_fe[0] = static_cast<int32_t>(h0);
   62|  7.53M|         m_fe[1] = static_cast<int32_t>(h1);
   63|  7.53M|         m_fe[2] = static_cast<int32_t>(h2);
   64|  7.53M|         m_fe[3] = static_cast<int32_t>(h3);
   65|  7.53M|         m_fe[4] = static_cast<int32_t>(h4);
   66|  7.53M|         m_fe[5] = static_cast<int32_t>(h5);
   67|  7.53M|         m_fe[6] = static_cast<int32_t>(h6);
   68|  7.53M|         m_fe[7] = static_cast<int32_t>(h7);
   69|  7.53M|         m_fe[8] = static_cast<int32_t>(h8);
   70|  7.53M|         m_fe[9] = static_cast<int32_t>(h9);
   71|  7.53M|      }
_ZN5Botan20Ed25519_FieldElementC2Ev:
   33|  13.4M|      constexpr Ed25519_FieldElement() : m_fe{} {}
_ZN5Botan20Ed25519_FieldElement4zeroEv:
   35|  9.09k|      constexpr static Ed25519_FieldElement zero() { return Ed25519_FieldElement(); }
_ZN5Botan20Ed25519_FieldElement3oneEv:
   37|  15.1k|      constexpr static Ed25519_FieldElement one() {
   38|  15.1k|         auto o = Ed25519_FieldElement();
   39|  15.1k|         o.m_fe[0] = 1;
   40|  15.1k|         return o;
   41|  15.1k|      }
_ZNK5Botan20Ed25519_FieldElement7is_zeroEv:
   77|  6.16k|      bool is_zero() const {
   78|  6.16k|         std::array<uint8_t, 32> value = {};
   79|  6.16k|         this->serialize_to(value);
   80|  6.16k|         return CT::all_zeros(value.data(), value.size()).as_bool();
   81|  6.16k|      }
_ZNK5Botan20Ed25519_FieldElement11is_negativeEv:
   87|  6.05k|      bool is_negative() const {
   88|       |         // TODO could avoid most of the serialize computation here
   89|  6.05k|         std::array<uint8_t, 32> s = {};
   90|  6.05k|         this->serialize_to(s);
   91|  6.05k|         return (s[0] & 0x01) == 0x01;
   92|  6.05k|      }
_ZN5Botan20Ed25519_FieldElement3addERKS0_S2_:
   94|  2.61M|      static Ed25519_FieldElement add(const Ed25519_FieldElement& a, const Ed25519_FieldElement& b) {
   95|  2.61M|         Ed25519_FieldElement z;
   96|  28.7M|         for(size_t i = 0; i != 10; ++i) {
  ------------------
  |  Branch (96:28): [True: 26.1M, False: 2.61M]
  ------------------
   97|  26.1M|            z.m_fe[i] = a.m_fe[i] + b.m_fe[i];
   98|  26.1M|         }
   99|  2.61M|         return z;
  100|  2.61M|      }
_ZN5Botan20Ed25519_FieldElement3subERKS0_S2_:
  102|  3.10M|      static Ed25519_FieldElement sub(const Ed25519_FieldElement& a, const Ed25519_FieldElement& b) {
  103|  3.10M|         Ed25519_FieldElement z;
  104|  34.1M|         for(size_t i = 0; i != 10; ++i) {
  ------------------
  |  Branch (104:28): [True: 31.0M, False: 3.10M]
  ------------------
  105|  31.0M|            z.m_fe[i] = a.m_fe[i] - b.m_fe[i];
  106|  31.0M|         }
  107|  3.10M|         return z;
  108|  3.10M|      }
_ZN5Botan20Ed25519_FieldElement6negateERKS0_:
  110|     76|      static Ed25519_FieldElement negate(const Ed25519_FieldElement& a) {
  111|     76|         Ed25519_FieldElement z;
  112|    836|         for(size_t i = 0; i != 10; ++i) {
  ------------------
  |  Branch (112:28): [True: 760, False: 76]
  ------------------
  113|    760|            z.m_fe[i] = -a.m_fe[i];
  114|    760|         }
  115|     76|         return z;
  116|     76|      }
_ZN5BotanplERKNS_20Ed25519_FieldElementES2_:
  140|  2.61M|inline Ed25519_FieldElement operator+(const Ed25519_FieldElement& x, const Ed25519_FieldElement& y) {
  141|  2.61M|   return Ed25519_FieldElement::add(x, y);
  142|  2.61M|}
_ZN5BotanmiERKNS_20Ed25519_FieldElementES2_:
  144|  3.10M|inline Ed25519_FieldElement operator-(const Ed25519_FieldElement& x, const Ed25519_FieldElement& y) {
  145|  3.10M|   return Ed25519_FieldElement::sub(x, y);
  146|  3.10M|}
_ZN5BotanngERKNS_20Ed25519_FieldElementE:
  152|     76|inline Ed25519_FieldElement operator-(const Ed25519_FieldElement& x) {
  153|     76|   return Ed25519_FieldElement::negate(x);
  154|     76|}

_ZN5Botan6load_3EPKh:
   18|  57.6k|inline uint32_t load_3(const uint8_t in[3]) {
   19|  57.6k|   return static_cast<uint32_t>(in[0]) | (static_cast<uint32_t>(in[1]) << 8) | (static_cast<uint32_t>(in[2]) << 16);
   20|  57.6k|}
_ZN5Botan6load_4EPKh:
   22|  45.5k|inline uint32_t load_4(const uint8_t* in) {
   23|  45.5k|   return load_le<uint32_t>(in, 0);
   24|  45.5k|}
_ZN5Botan8redc_mulERlS0_S0_S0_S0_S0_S0_:
   57|  42.5k|inline void redc_mul(int64_t& s1, int64_t& s2, int64_t& s3, int64_t& s4, int64_t& s5, int64_t& s6, int64_t& X) {
   58|  42.5k|   s1 += X * 666643;
   59|  42.5k|   s2 += X * 470296;
   60|  42.5k|   s3 += X * 654183;
   61|  42.5k|   s4 -= X * 997805;
   62|  42.5k|   s5 += X * 136657;
   63|  42.5k|   s6 -= X * 683901;
   64|  42.5k|   X = 0;
   65|  42.5k|}
_ZN5Botan5carryILm26ELl1EEEvRlS1_QaagtT_Li0EltT_Li64E:
   29|  62.9M|{
   30|  62.9M|   const int64_t X1 = (static_cast<int64_t>(1) << S);
   31|  62.9M|   const int64_t X2 = (static_cast<int64_t>(1) << (S - 1));
   32|  62.9M|   const int64_t c = (h0 + X2) >> S;
   33|  62.9M|   h1 += c * MUL;
   34|  62.9M|   h0 -= c * X1;
   35|  62.9M|}
_ZN5Botan5carryILm25ELl1EEEvRlS1_QaagtT_Li0EltT_Li64E:
   29|  36.0M|{
   30|  36.0M|   const int64_t X1 = (static_cast<int64_t>(1) << S);
   31|  36.0M|   const int64_t X2 = (static_cast<int64_t>(1) << (S - 1));
   32|  36.0M|   const int64_t c = (h0 + X2) >> S;
   33|  36.0M|   h1 += c * MUL;
   34|  36.0M|   h0 -= c * X1;
   35|  36.0M|}
_ZN5Botan5carryILm25ELl19EEEvRlS1_QaagtT_Li0EltT_Li64E:
   29|  9.00M|{
   30|  9.00M|   const int64_t X1 = (static_cast<int64_t>(1) << S);
   31|  9.00M|   const int64_t X2 = (static_cast<int64_t>(1) << (S - 1));
   32|  9.00M|   const int64_t c = (h0 + X2) >> S;
   33|  9.00M|   h1 += c * MUL;
   34|  9.00M|   h0 -= c * X1;
   35|  9.00M|}
_ZN5Botan6carry0ILm26EEEvRiS1_QaagtT_Li0EltT_Li32E:
   50|  76.1k|{
   51|  76.1k|   const int32_t X1 = (static_cast<int64_t>(1) << S);
   52|  76.1k|   const int32_t c = h0 >> S;
   53|  76.1k|   h1 += c;
   54|  76.1k|   h0 -= c * X1;
   55|  76.1k|}
_ZN5Botan6carry0ILm25EEEvRiS1_QaagtT_Li0EltT_Li32E:
   50|  60.9k|{
   51|  60.9k|   const int32_t X1 = (static_cast<int64_t>(1) << S);
   52|  60.9k|   const int32_t c = h0 >> S;
   53|  60.9k|   h1 += c;
   54|  60.9k|   h0 -= c * X1;
   55|  60.9k|}
_ZN5Botan5carryILm21ELl1EEEvRlS1_QaagtT_Li0EltT_Li64E:
   29|  69.8k|{
   30|  69.8k|   const int64_t X1 = (static_cast<int64_t>(1) << S);
   31|  69.8k|   const int64_t X2 = (static_cast<int64_t>(1) << (S - 1));
   32|  69.8k|   const int64_t c = (h0 + X2) >> S;
   33|  69.8k|   h1 += c * MUL;
   34|  69.8k|   h0 -= c * X1;
   35|  69.8k|}
_ZN5Botan6carry0ILm21EEEvRlS1_QaagtT_Li0EltT_Li64E:
   40|  72.8k|{
   41|  72.8k|   const int64_t X1 = (static_cast<int64_t>(1) << S);
   42|  72.8k|   const int64_t c = h0 >> S;
   43|  72.8k|   h1 += c;
   44|  72.8k|   h0 -= c * X1;
   45|  72.8k|}

ffi.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ16botan_hex_encodeE3$_0EEiPKcT_:
   95|  55.3k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  55.3k|   ffi_clear_last_exception();
   97|       |
   98|  55.3k|   try {
   99|  55.3k|      return thunk();
  100|  55.3k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  55.3k|}
ffi.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ16botan_hex_decodeE3$_0EEiPKcT_:
   95|   134k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|   134k|   ffi_clear_last_exception();
   97|       |
   98|   134k|   try {
   99|   134k|      return thunk();
  100|   134k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|   134k|}
_ZN9Botan_FFI16write_vec_outputEPhPmNSt3__14spanIKhLm18446744073709551615EEE:
  267|   134k|inline int write_vec_output(uint8_t out[], size_t* out_len, std::span<const uint8_t> buf) {
  268|   134k|   return write_output<uint8_t>(out, out_len, buf.data(), buf.size());
  269|   134k|}
_ZN9Botan_FFI12write_outputITkNSt3__18integralEhEEiPT_PmPKS2_m:
  252|   134k|inline int write_output(T out[], size_t* out_len, const T buf[], size_t buf_len) {
  253|   134k|   static_assert(sizeof(T) == 1, "T should be either uint8_t or char");
  254|       |
  255|   134k|   const auto rc = check_and_prepare_output_space(out, out_len, buf_len);
  256|   134k|   if(rc != BOTAN_FFI_SUCCESS) {
  ------------------
  |  Branch (256:7): [True: 0, False: 134k]
  ------------------
  257|      0|      return rc;
  258|      0|   }
  259|       |
  260|   134k|   if(out != nullptr) {
  ------------------
  |  Branch (260:7): [True: 134k, False: 0]
  ------------------
  261|   134k|      std::memcpy(out, buf, sizeof(T) * buf_len);
  262|   134k|   }
  263|       |
  264|   134k|   return BOTAN_FFI_SUCCESS;
  265|   134k|}
_ZN9Botan_FFI30check_and_prepare_output_spaceITkNSt3__18integralEhQeqstT_Li1EEEiPS2_Pmm:
  233|   134k|inline int check_and_prepare_output_space(T out[], size_t* out_len, size_t required_len) {
  234|   134k|   if(out_len == nullptr) {
  ------------------
  |  Branch (234:7): [True: 0, False: 134k]
  ------------------
  235|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  236|      0|   }
  237|       |
  238|   134k|   const size_t avail = *out_len;
  239|   134k|   *out_len = required_len;
  240|       |
  241|   134k|   if(avail < required_len || out == nullptr) {
  ------------------
  |  Branch (241:7): [True: 0, False: 134k]
  |  Branch (241:31): [True: 0, False: 134k]
  ------------------
  242|      0|      if(out != nullptr) {
  ------------------
  |  Branch (242:10): [True: 0, False: 0]
  ------------------
  243|      0|         std::memset(out, 0, sizeof(T) * avail);
  244|      0|      }
  245|      0|      return BOTAN_FFI_ERROR_INSUFFICIENT_BUFFER_SPACE;
  246|   134k|   } else {
  247|   134k|      return BOTAN_FFI_SUCCESS;
  248|   134k|   }
  249|   134k|}
ffi_block.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ23botan_block_cipher_initE3$_0EEiPKcT_:
   95|  12.3k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  12.3k|   ffi_clear_last_exception();
   97|       |
   98|  12.3k|   try {
   99|  12.3k|      return thunk();
  100|  12.3k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  12.3k|}
_ZN9Botan_FFI14ffi_new_objectIP25botan_block_cipher_structJNSt3__110unique_ptrIN5Botan11BlockCipherENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  12.3k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  12.3k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 12.3k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  12.3k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  12.3k|   return BOTAN_FFI_SUCCESS;
  185|  12.3k|}
_ZN25botan_block_cipher_structC2ENSt3__110unique_ptrIN5Botan11BlockCipherENS0_14default_deleteIS3_EEEE:
   63|  12.3k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN9Botan_FFI12botan_structIN5Botan11BlockCipherELj1690474262EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  12.3k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan11BlockCipherELj1690474262EED2Ev:
   40|  12.3k|      virtual ~botan_struct() {
   41|  12.3k|         m_magic = 0;
   42|  12.3k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  12.3k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan11BlockCipherELj1690474262EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  12.3k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  12.3k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  12.3k|      if(obj == nullptr) {
  165|  12.3k|         return BOTAN_FFI_SUCCESS;
  166|  12.3k|      }
  167|       |
  168|  12.3k|      if(!obj->magic_ok()) {
  169|  12.3k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  12.3k|      }
  171|       |
  172|  12.3k|      delete obj;  // NOLINT(*-owning-memory)
  173|  12.3k|      return BOTAN_FFI_SUCCESS;
  174|  12.3k|   });
  175|  12.3k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan11BlockCipherELj1690474262EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  12.3k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  12.3k|   ffi_clear_last_exception();
   97|       |
   98|  12.3k|   try {
   99|  12.3k|      return thunk();
  100|  12.3k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  12.3k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan11BlockCipherELj1690474262EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  12.3k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  12.3k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 12.3k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  12.3k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 12.3k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  12.3k|      delete obj;  // NOLINT(*-owning-memory)
  173|  12.3k|      return BOTAN_FFI_SUCCESS;
  174|  12.3k|   });
_ZNK9Botan_FFI12botan_structIN5Botan11BlockCipherELj1690474262EE8magic_okEv:
   50|  3.36M|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan11BlockCipherELj1690474262EE10unsafe_getEv:
   52|  3.35M|      T* unsafe_get() const { return m_obj.get(); }
ffi_block.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ26botan_block_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  12.3k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  12.3k|   using RetT = std::invoke_result_t<F, T&>;
  116|  12.3k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  12.3k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  12.3k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 12.3k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  12.3k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 12.3k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  12.3k|   T* p = o->unsafe_get();
  128|  12.3k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 12.3k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  12.3k|   if constexpr(std::is_void_v<RetT>) {
  133|  12.3k|      return ffi_guard_thunk(func_name, [&] {
  134|  12.3k|         func(*p);
  135|  12.3k|         return BOTAN_FFI_SUCCESS;
  136|  12.3k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  12.3k|}
ffi_block.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ26botan_block_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  12.3k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  12.3k|   ffi_clear_last_exception();
   97|       |
   98|  12.3k|   try {
   99|  12.3k|      return thunk();
  100|  12.3k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  12.3k|}
ffi_block.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ26botan_block_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  12.3k|      return ffi_guard_thunk(func_name, [&] {
  134|  12.3k|         func(*p);
  135|  12.3k|         return BOTAN_FFI_SUCCESS;
  136|  12.3k|      });
ffi_block.cpp:_ZZ26botan_block_cipher_set_keyENK3$_0clIN5Botan11BlockCipherEEEDaRT_:
  158|  12.3k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_block.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ33botan_block_cipher_encrypt_blocksE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  3.34M|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  3.34M|   using RetT = std::invoke_result_t<F, T&>;
  116|  3.34M|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  3.34M|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  3.34M|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 3.34M]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  3.34M|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 3.34M]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  3.34M|   T* p = o->unsafe_get();
  128|  3.34M|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 3.34M]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  3.34M|   if constexpr(std::is_void_v<RetT>) {
  133|  3.34M|      return ffi_guard_thunk(func_name, [&] {
  134|  3.34M|         func(*p);
  135|  3.34M|         return BOTAN_FFI_SUCCESS;
  136|  3.34M|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  3.34M|}
ffi_block.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ33botan_block_cipher_encrypt_blocksE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  3.34M|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  3.34M|   ffi_clear_last_exception();
   97|       |
   98|  3.34M|   try {
   99|  3.34M|      return thunk();
  100|  3.34M|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  3.34M|}
ffi_block.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11BlockCipherELj1690474262EZ33botan_block_cipher_encrypt_blocksE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  3.34M|      return ffi_guard_thunk(func_name, [&] {
  134|  3.34M|         func(*p);
  135|  3.34M|         return BOTAN_FFI_SUCCESS;
  136|  3.34M|      });
ffi_block.cpp:_ZZ33botan_block_cipher_encrypt_blocksENK3$_0clIN5Botan11BlockCipherEEEDaRKT_:
  158|  3.34M|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
_ZN19botan_pubkey_structC2ENSt3__110unique_ptrIN5Botan10Public_KeyENS0_14default_deleteIS3_EEEE:
   63|  10.8k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN16botan_rng_structC2ENSt3__110unique_ptrIN5Botan21RandomNumberGeneratorENS0_14default_deleteIS3_EEEE:
   63|  12.7k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ17botan_cipher_initE3$_0EEiPKcT_:
   95|  15.8k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  15.8k|   ffi_clear_last_exception();
   97|       |
   98|  15.8k|   try {
   99|  15.8k|      return thunk();
  100|  15.8k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|    369|   } catch(Botan::Exception& e) {
  105|    369|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|    369|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  15.8k|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_cipher_structJNSt3__110unique_ptrIN5Botan11Cipher_ModeENS3_14default_deleteIS6_EEEERKmSB_EEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  15.5k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  15.5k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 15.5k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  15.5k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  15.5k|   return BOTAN_FFI_SUCCESS;
  185|  15.5k|}
_ZN9Botan_FFI12botan_structIN5Botan11Cipher_ModeELj3030564764EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  15.5k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan11Cipher_ModeELj3030564764EED2Ev:
   40|  15.5k|      virtual ~botan_struct() {
   41|  15.5k|         m_magic = 0;
   42|  15.5k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  15.5k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan11Cipher_ModeELj3030564764EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  15.5k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  15.5k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  15.5k|      if(obj == nullptr) {
  165|  15.5k|         return BOTAN_FFI_SUCCESS;
  166|  15.5k|      }
  167|       |
  168|  15.5k|      if(!obj->magic_ok()) {
  169|  15.5k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  15.5k|      }
  171|       |
  172|  15.5k|      delete obj;  // NOLINT(*-owning-memory)
  173|  15.5k|      return BOTAN_FFI_SUCCESS;
  174|  15.5k|   });
  175|  15.5k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan11Cipher_ModeELj3030564764EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  15.5k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  15.5k|   ffi_clear_last_exception();
   97|       |
   98|  15.5k|   try {
   99|  15.5k|      return thunk();
  100|  15.5k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  15.5k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan11Cipher_ModeELj3030564764EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  15.5k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  15.5k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 15.5k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  15.5k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 15.5k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  15.5k|      delete obj;  // NOLINT(*-owning-memory)
  173|  15.5k|      return BOTAN_FFI_SUCCESS;
  174|  15.5k|   });
_ZNK9Botan_FFI12botan_structIN5Botan11Cipher_ModeELj3030564764EE8magic_okEv:
   50|  2.93M|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan11Cipher_ModeELj3030564764EE10unsafe_getEv:
   52|  2.92M|      T* unsafe_get() const { return m_obj.get(); }
ffi_cipher.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ18botan_cipher_resetE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|   720k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|   720k|   using RetT = std::invoke_result_t<F, T&>;
  116|   720k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|   720k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|   720k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 720k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|   720k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 720k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|   720k|   T* p = o->unsafe_get();
  128|   720k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 720k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|   720k|   if constexpr(std::is_void_v<RetT>) {
  133|   720k|      return ffi_guard_thunk(func_name, [&] {
  134|   720k|         func(*p);
  135|   720k|         return BOTAN_FFI_SUCCESS;
  136|   720k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|   720k|}
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ18botan_cipher_resetE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|   720k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|   720k|   ffi_clear_last_exception();
   97|       |
   98|   720k|   try {
   99|   720k|      return thunk();
  100|   720k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|   720k|}
ffi_cipher.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ18botan_cipher_resetE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|   720k|      return ffi_guard_thunk(func_name, [&] {
  134|   720k|         func(*p);
  135|   720k|         return BOTAN_FFI_SUCCESS;
  136|   720k|      });
ffi_cipher.cpp:_ZZ18botan_cipher_resetENK3$_0clIN5Botan11Cipher_ModeEEEDaRT_:
  158|   720k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_cipher.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ20botan_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  15.5k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  15.5k|   using RetT = std::invoke_result_t<F, T&>;
  116|  15.5k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  15.5k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  15.5k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 15.5k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  15.5k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 15.5k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  15.5k|   T* p = o->unsafe_get();
  128|  15.5k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 15.5k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  15.5k|   if constexpr(std::is_void_v<RetT>) {
  133|  15.5k|      return ffi_guard_thunk(func_name, [&] {
  134|  15.5k|         func(*p);
  135|  15.5k|         return BOTAN_FFI_SUCCESS;
  136|  15.5k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  15.5k|}
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ20botan_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  15.5k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  15.5k|   ffi_clear_last_exception();
   97|       |
   98|  15.5k|   try {
   99|  15.5k|      return thunk();
  100|  15.5k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  15.5k|}
ffi_cipher.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ20botan_cipher_set_keyE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  15.5k|      return ffi_guard_thunk(func_name, [&] {
  134|  15.5k|         func(*p);
  135|  15.5k|         return BOTAN_FFI_SUCCESS;
  136|  15.5k|      });
ffi_cipher.cpp:_ZZ20botan_cipher_set_keyENK3$_0clIN5Botan11Cipher_ModeEEEDaRT_:
  158|  15.5k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ18botan_cipher_startE3$_0EEiPKcT_:
   95|   721k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|   721k|   ffi_clear_last_exception();
   97|       |
   98|   721k|   try {
   99|   721k|      return thunk();
  100|   721k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|   721k|}
_ZN9Botan_FFI8safe_getIN5Botan11Cipher_ModeELj3030564764EEERT_PNS_12botan_structIS3_XT0_EEE:
   79|  1.44M|T& safe_get(botan_struct<T, M>* p) {
   80|  1.44M|   if(!p) {
  ------------------
  |  Branch (80:7): [True: 0, False: 1.44M]
  ------------------
   81|      0|      throw FFI_Error("Null pointer argument", BOTAN_FFI_ERROR_NULL_POINTER);
   82|      0|   }
   83|  1.44M|   if(!p->magic_ok()) {
  ------------------
  |  Branch (83:7): [True: 0, False: 1.44M]
  ------------------
   84|      0|      throw FFI_Error("Bad magic in ffi object", BOTAN_FFI_ERROR_INVALID_OBJECT);
   85|      0|   }
   86|       |
   87|  1.44M|   if(T* t = p->unsafe_get()) {
  ------------------
  |  Branch (87:10): [True: 1.44M, False: 0]
  ------------------
   88|  1.44M|      return *t;
   89|  1.44M|   }
   90|       |
   91|      0|   throw FFI_Error("Invalid object pointer", BOTAN_FFI_ERROR_INVALID_OBJECT);
   92|  1.44M|}
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ19botan_cipher_updateE3$_0EEiPKcT_:
   95|   727k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|   727k|   ffi_clear_last_exception();
   97|       |
   98|   727k|   try {
   99|   727k|      return thunk();
  100|   727k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|   727k|}
ffi_cipher.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ32botan_cipher_set_associated_dataE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|   721k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|   721k|   using RetT = std::invoke_result_t<F, T&>;
  116|   721k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|   721k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|   721k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 721k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|   721k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 721k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|   721k|   T* p = o->unsafe_get();
  128|   721k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 721k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|       |   if constexpr(std::is_void_v<RetT>) {
  133|       |      return ffi_guard_thunk(func_name, [&] {
  134|       |         func(*p);
  135|       |         return BOTAN_FFI_SUCCESS;
  136|       |      });
  137|   721k|   } else {
  138|   721k|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|   721k|   }
  140|   721k|}
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ32botan_cipher_set_associated_dataE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|   721k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|   721k|   ffi_clear_last_exception();
   97|       |
   98|   721k|   try {
   99|   721k|      return thunk();
  100|   721k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|   721k|}
ffi_cipher.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ32botan_cipher_set_associated_dataE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  138|   721k|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
ffi_cipher.cpp:_ZZ32botan_cipher_set_associated_dataENK3$_0clIN5Botan11Cipher_ModeEEEDaRT_:
  158|  2.16M|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  |  Branch (158:59): [True: 721k, False: 0]
  ------------------
ffi_cipher.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ35botan_cipher_get_update_granularityE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  15.5k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  15.5k|   using RetT = std::invoke_result_t<F, T&>;
  116|  15.5k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  15.5k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  15.5k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 15.5k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  15.5k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 15.5k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  15.5k|   T* p = o->unsafe_get();
  128|  15.5k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 15.5k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  15.5k|   if constexpr(std::is_void_v<RetT>) {
  133|  15.5k|      return ffi_guard_thunk(func_name, [&] {
  134|  15.5k|         func(*p);
  135|  15.5k|         return BOTAN_FFI_SUCCESS;
  136|  15.5k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  15.5k|}
ffi_cipher.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ35botan_cipher_get_update_granularityE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  15.5k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  15.5k|   ffi_clear_last_exception();
   97|       |
   98|  15.5k|   try {
   99|  15.5k|      return thunk();
  100|  15.5k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  15.5k|}
ffi_cipher.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11Cipher_ModeELj3030564764EZ35botan_cipher_get_update_granularityE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  15.5k|      return ffi_guard_thunk(func_name, [&] {
  134|  15.5k|         func(*p);
  135|  15.5k|         return BOTAN_FFI_SUCCESS;
  136|  15.5k|      });
ffi_cipher.cpp:_ZZ35botan_cipher_get_update_granularityENK3$_0clIN5Botan11Cipher_ModeEEEDaRKT_:
  158|  15.5k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
_ZN9Botan_FFI8safe_getIN5Botan6BigIntELj3358112210EEERT_PNS_12botan_structIS3_XT0_EEE:
   79|  17.9k|T& safe_get(botan_struct<T, M>* p) {
   80|  17.9k|   if(!p) {
  ------------------
  |  Branch (80:7): [True: 0, False: 17.9k]
  ------------------
   81|      0|      throw FFI_Error("Null pointer argument", BOTAN_FFI_ERROR_NULL_POINTER);
   82|      0|   }
   83|  17.9k|   if(!p->magic_ok()) {
  ------------------
  |  Branch (83:7): [True: 0, False: 17.9k]
  ------------------
   84|      0|      throw FFI_Error("Bad magic in ffi object", BOTAN_FFI_ERROR_INVALID_OBJECT);
   85|      0|   }
   86|       |
   87|  17.9k|   if(T* t = p->unsafe_get()) {
  ------------------
  |  Branch (87:10): [True: 17.9k, False: 0]
  ------------------
   88|  17.9k|      return *t;
   89|  17.9k|   }
   90|       |
   91|      0|   throw FFI_Error("Invalid object pointer", BOTAN_FFI_ERROR_INVALID_OBJECT);
   92|  17.9k|}
_ZNK9Botan_FFI12botan_structIN5Botan6BigIntELj3358112210EE8magic_okEv:
   50|  53.7k|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan6BigIntELj3358112210EE10unsafe_getEv:
   52|  35.8k|      T* unsafe_get() const { return m_obj.get(); }
_ZN9Botan_FFI14ffi_new_objectIP15botan_mp_structJNSt3__110unique_ptrIN5Botan6BigIntENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  17.9k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  17.9k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 17.9k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  17.9k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  17.9k|   return BOTAN_FFI_SUCCESS;
  185|  17.9k|}
_ZN15botan_mp_structC2ENSt3__110unique_ptrIN5Botan6BigIntENS0_14default_deleteIS3_EEEE:
   63|  17.9k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN9Botan_FFI12botan_structIN5Botan6BigIntELj3358112210EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  17.9k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan6BigIntELj3358112210EED2Ev:
   40|  17.9k|      virtual ~botan_struct() {
   41|  17.9k|         m_magic = 0;
   42|  17.9k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  17.9k|      }
_ZN9Botan_FFI8safe_getIN5Botan21RandomNumberGeneratorELj1224866241EEERT_PNS_12botan_structIS3_XT0_EEE:
   79|     41|T& safe_get(botan_struct<T, M>* p) {
   80|     41|   if(!p) {
  ------------------
  |  Branch (80:7): [True: 0, False: 41]
  ------------------
   81|      0|      throw FFI_Error("Null pointer argument", BOTAN_FFI_ERROR_NULL_POINTER);
   82|      0|   }
   83|     41|   if(!p->magic_ok()) {
  ------------------
  |  Branch (83:7): [True: 0, False: 41]
  ------------------
   84|      0|      throw FFI_Error("Bad magic in ffi object", BOTAN_FFI_ERROR_INVALID_OBJECT);
   85|      0|   }
   86|       |
   87|     41|   if(T* t = p->unsafe_get()) {
  ------------------
  |  Branch (87:10): [True: 41, False: 0]
  ------------------
   88|     41|      return *t;
   89|     41|   }
   90|       |
   91|      0|   throw FFI_Error("Invalid object pointer", BOTAN_FFI_ERROR_INVALID_OBJECT);
   92|     41|}
_ZNK9Botan_FFI12botan_structIN5Botan21RandomNumberGeneratorELj1224866241EE8magic_okEv:
   50|  39.2k|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan21RandomNumberGeneratorELj1224866241EE10unsafe_getEv:
   52|  26.4k|      T* unsafe_get() const { return m_obj.get(); }
ffi_hash.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ15botan_hash_initE3$_0EEiPKcT_:
   95|  40.5k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  40.5k|   ffi_clear_last_exception();
   97|       |
   98|  40.5k|   try {
   99|  40.5k|      return thunk();
  100|  40.5k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  40.5k|}
_ZN9Botan_FFI14ffi_new_objectIP17botan_hash_structJNSt3__110unique_ptrIN5Botan12HashFunctionENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  40.4k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  40.4k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 40.4k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  40.4k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  40.4k|   return BOTAN_FFI_SUCCESS;
  185|  40.4k|}
_ZN17botan_hash_structC2ENSt3__110unique_ptrIN5Botan12HashFunctionENS0_14default_deleteIS3_EEEE:
   63|  40.4k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN9Botan_FFI12botan_structIN5Botan12HashFunctionELj520769412EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  40.4k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan12HashFunctionELj520769412EED2Ev:
   40|  40.4k|      virtual ~botan_struct() {
   41|  40.4k|         m_magic = 0;
   42|  40.4k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  40.4k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan12HashFunctionELj520769412EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  40.4k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  40.4k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  40.4k|      if(obj == nullptr) {
  165|  40.4k|         return BOTAN_FFI_SUCCESS;
  166|  40.4k|      }
  167|       |
  168|  40.4k|      if(!obj->magic_ok()) {
  169|  40.4k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  40.4k|      }
  171|       |
  172|  40.4k|      delete obj;  // NOLINT(*-owning-memory)
  173|  40.4k|      return BOTAN_FFI_SUCCESS;
  174|  40.4k|   });
  175|  40.4k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan12HashFunctionELj520769412EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  40.4k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  40.4k|   ffi_clear_last_exception();
   97|       |
   98|  40.4k|   try {
   99|  40.4k|      return thunk();
  100|  40.4k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  40.4k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan12HashFunctionELj520769412EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  40.4k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  40.4k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 40.4k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  40.4k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 40.4k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  40.4k|      delete obj;  // NOLINT(*-owning-memory)
  173|  40.4k|      return BOTAN_FFI_SUCCESS;
  174|  40.4k|   });
_ZNK9Botan_FFI12botan_structIN5Botan12HashFunctionELj520769412EE8magic_okEv:
   50|  27.5M|      bool magic_ok() const { return (m_magic == MAGIC); }
ffi_hash.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ24botan_hash_output_lengthE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  40.4k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  40.4k|   using RetT = std::invoke_result_t<F, T&>;
  116|  40.4k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  40.4k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  40.4k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 40.4k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  40.4k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 40.4k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  40.4k|   T* p = o->unsafe_get();
  128|  40.4k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 40.4k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  40.4k|   if constexpr(std::is_void_v<RetT>) {
  133|  40.4k|      return ffi_guard_thunk(func_name, [&] {
  134|  40.4k|         func(*p);
  135|  40.4k|         return BOTAN_FFI_SUCCESS;
  136|  40.4k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  40.4k|}
_ZNK9Botan_FFI12botan_structIN5Botan12HashFunctionELj520769412EE10unsafe_getEv:
   52|  27.5M|      T* unsafe_get() const { return m_obj.get(); }
ffi_hash.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ24botan_hash_output_lengthE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  40.4k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  40.4k|   ffi_clear_last_exception();
   97|       |
   98|  40.4k|   try {
   99|  40.4k|      return thunk();
  100|  40.4k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  40.4k|}
ffi_hash.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ24botan_hash_output_lengthE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  40.4k|      return ffi_guard_thunk(func_name, [&] {
  134|  40.4k|         func(*p);
  135|  40.4k|         return BOTAN_FFI_SUCCESS;
  136|  40.4k|      });
ffi_hash.cpp:_ZZ24botan_hash_output_lengthENK3$_0clIN5Botan12HashFunctionEEEDaRKT_:
  158|  40.4k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_hash.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ17botan_hash_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  27.4M|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  27.4M|   using RetT = std::invoke_result_t<F, T&>;
  116|  27.4M|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  27.4M|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  27.4M|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 27.4M]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  27.4M|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 27.4M]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  27.4M|   T* p = o->unsafe_get();
  128|  27.4M|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 27.4M]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  27.4M|   if constexpr(std::is_void_v<RetT>) {
  133|  27.4M|      return ffi_guard_thunk(func_name, [&] {
  134|  27.4M|         func(*p);
  135|  27.4M|         return BOTAN_FFI_SUCCESS;
  136|  27.4M|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  27.4M|}
ffi_hash.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ17botan_hash_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  27.4M|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  27.4M|   ffi_clear_last_exception();
   97|       |
   98|  27.4M|   try {
   99|  27.4M|      return thunk();
  100|  27.4M|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  27.4M|}
ffi_hash.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ17botan_hash_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  27.4M|      return ffi_guard_thunk(func_name, [&] {
  134|  27.4M|         func(*p);
  135|  27.4M|         return BOTAN_FFI_SUCCESS;
  136|  27.4M|      });
ffi_hash.cpp:_ZZ17botan_hash_updateENK3$_0clIN5Botan12HashFunctionEEEDaRT_:
  158|  27.4M|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_hash.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ16botan_hash_finalE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  26.3k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  26.3k|   using RetT = std::invoke_result_t<F, T&>;
  116|  26.3k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  26.3k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  26.3k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 26.3k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  26.3k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 26.3k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  26.3k|   T* p = o->unsafe_get();
  128|  26.3k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 26.3k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  26.3k|   if constexpr(std::is_void_v<RetT>) {
  133|  26.3k|      return ffi_guard_thunk(func_name, [&] {
  134|  26.3k|         func(*p);
  135|  26.3k|         return BOTAN_FFI_SUCCESS;
  136|  26.3k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  26.3k|}
ffi_hash.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ16botan_hash_finalE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  26.3k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  26.3k|   ffi_clear_last_exception();
   97|       |
   98|  26.3k|   try {
   99|  26.3k|      return thunk();
  100|  26.3k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  26.3k|}
ffi_hash.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan12HashFunctionELj520769412EZ16botan_hash_finalE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  26.3k|      return ffi_guard_thunk(func_name, [&] {
  134|  26.3k|         func(*p);
  135|  26.3k|         return BOTAN_FFI_SUCCESS;
  136|  26.3k|      });
ffi_hash.cpp:_ZZ16botan_hash_finalENK3$_0clIN5Botan12HashFunctionEEEDaRT_:
  158|  26.3k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_kdf.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ13botan_pwdhashE3$_0EEiPKcT_:
   95|  20.5k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  20.5k|   ffi_clear_last_exception();
   97|       |
   98|  20.5k|   try {
   99|  20.5k|      return thunk();
  100|  20.5k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|     30|   } catch(Botan::Exception& e) {
  105|     30|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|     30|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  20.5k|}
ffi_kdf.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ9botan_kdfE3$_0EEiPKcT_:
   95|  6.79k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  6.79k|   ffi_clear_last_exception();
   97|       |
   98|  6.79k|   try {
   99|  6.79k|      return thunk();
  100|  6.79k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  6.79k|}
ffi_mp.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ13botan_mp_initE3$_0EEiPKcT_:
   95|  17.9k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  17.9k|   ffi_clear_last_exception();
   97|       |
   98|  17.9k|   try {
   99|  17.9k|      return thunk();
  100|  17.9k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  17.9k|}
ffi_mp.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan6BigIntELj3358112210EZ17botan_mp_from_binE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  17.9k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  17.9k|   using RetT = std::invoke_result_t<F, T&>;
  116|  17.9k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  17.9k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  17.9k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 17.9k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  17.9k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 17.9k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  17.9k|   T* p = o->unsafe_get();
  128|  17.9k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 17.9k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  17.9k|   if constexpr(std::is_void_v<RetT>) {
  133|  17.9k|      return ffi_guard_thunk(func_name, [&] {
  134|  17.9k|         func(*p);
  135|  17.9k|         return BOTAN_FFI_SUCCESS;
  136|  17.9k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  17.9k|}
ffi_mp.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan6BigIntELj3358112210EZ17botan_mp_from_binE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  17.9k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  17.9k|   ffi_clear_last_exception();
   97|       |
   98|  17.9k|   try {
   99|  17.9k|      return thunk();
  100|  17.9k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  17.9k|}
ffi_mp.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan6BigIntELj3358112210EZ17botan_mp_from_binE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  17.9k|      return ffi_guard_thunk(func_name, [&] {
  134|  17.9k|         func(*p);
  135|  17.9k|         return BOTAN_FFI_SUCCESS;
  136|  17.9k|      });
ffi_mp.cpp:_ZZ17botan_mp_from_binENK3$_0clIN5Botan6BigIntEEEDaRT_:
  158|  17.9k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
_ZN9Botan_FFI17ffi_delete_objectIN5Botan6BigIntELj3358112210EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  17.9k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  17.9k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  17.9k|      if(obj == nullptr) {
  165|  17.9k|         return BOTAN_FFI_SUCCESS;
  166|  17.9k|      }
  167|       |
  168|  17.9k|      if(!obj->magic_ok()) {
  169|  17.9k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  17.9k|      }
  171|       |
  172|  17.9k|      delete obj;  // NOLINT(*-owning-memory)
  173|  17.9k|      return BOTAN_FFI_SUCCESS;
  174|  17.9k|   });
  175|  17.9k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan6BigIntELj3358112210EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  17.9k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  17.9k|   ffi_clear_last_exception();
   97|       |
   98|  17.9k|   try {
   99|  17.9k|      return thunk();
  100|  17.9k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  17.9k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan6BigIntELj3358112210EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  17.9k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  17.9k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 17.9k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  17.9k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 17.9k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  17.9k|      delete obj;  // NOLINT(*-owning-memory)
  173|  17.9k|      return BOTAN_FFI_SUCCESS;
  174|  17.9k|   });
ffi_pk_op.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ26botan_pk_op_encrypt_createE3$_0EEiPKcT_:
   95|     41|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|     41|   ffi_clear_last_exception();
   97|       |
   98|     41|   try {
   99|     41|      return thunk();
  100|     41|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|     41|}
_ZN9Botan_FFI8safe_getIN5Botan10Public_KeyELj740844825EEERT_PNS_12botan_structIS3_XT0_EEE:
   79|  10.8k|T& safe_get(botan_struct<T, M>* p) {
   80|  10.8k|   if(!p) {
  ------------------
  |  Branch (80:7): [True: 0, False: 10.8k]
  ------------------
   81|      0|      throw FFI_Error("Null pointer argument", BOTAN_FFI_ERROR_NULL_POINTER);
   82|      0|   }
   83|  10.8k|   if(!p->magic_ok()) {
  ------------------
  |  Branch (83:7): [True: 0, False: 10.8k]
  ------------------
   84|      0|      throw FFI_Error("Bad magic in ffi object", BOTAN_FFI_ERROR_INVALID_OBJECT);
   85|      0|   }
   86|       |
   87|  10.8k|   if(T* t = p->unsafe_get()) {
  ------------------
  |  Branch (87:10): [True: 10.8k, False: 0]
  ------------------
   88|  10.8k|      return *t;
   89|  10.8k|   }
   90|       |
   91|      0|   throw FFI_Error("Invalid object pointer", BOTAN_FFI_ERROR_INVALID_OBJECT);
   92|  10.8k|}
_ZNK9Botan_FFI12botan_structIN5Botan10Public_KeyELj740844825EE8magic_okEv:
   50|  21.6k|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan10Public_KeyELj740844825EE10unsafe_getEv:
   52|  10.8k|      T* unsafe_get() const { return m_obj.get(); }
_ZN9Botan_FFI14ffi_new_objectIP26botan_pk_op_encrypt_structJNSt3__110unique_ptrIN5Botan16PK_Encryptor_EMEENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|     41|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|     41|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 41]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|     41|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|     41|   return BOTAN_FFI_SUCCESS;
  185|     41|}
_ZN26botan_pk_op_encrypt_structC2ENSt3__110unique_ptrIN5Botan12PK_EncryptorENS0_14default_deleteIS3_EEEE:
   63|     41|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN9Botan_FFI12botan_structIN5Botan12PK_EncryptorELj2300526531EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|     41|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan12PK_EncryptorELj2300526531EED2Ev:
   40|     41|      virtual ~botan_struct() {
   41|     41|         m_magic = 0;
   42|     41|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|     41|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan12PK_EncryptorELj2300526531EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|     41|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|     41|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|     41|      if(obj == nullptr) {
  165|     41|         return BOTAN_FFI_SUCCESS;
  166|     41|      }
  167|       |
  168|     41|      if(!obj->magic_ok()) {
  169|     41|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|     41|      }
  171|       |
  172|     41|      delete obj;  // NOLINT(*-owning-memory)
  173|     41|      return BOTAN_FFI_SUCCESS;
  174|     41|   });
  175|     41|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan12PK_EncryptorELj2300526531EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|     41|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|     41|   ffi_clear_last_exception();
   97|       |
   98|     41|   try {
   99|     41|      return thunk();
  100|     41|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|     41|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan12PK_EncryptorELj2300526531EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|     41|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|     41|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 41]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|     41|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 41]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|     41|      delete obj;  // NOLINT(*-owning-memory)
  173|     41|      return BOTAN_FFI_SUCCESS;
  174|     41|   });
_ZNK9Botan_FFI12botan_structIN5Botan12PK_EncryptorELj2300526531EE8magic_okEv:
   50|     82|      bool magic_ok() const { return (m_magic == MAGIC); }
_ZNK9Botan_FFI12botan_structIN5Botan12PK_EncryptorELj2300526531EE10unsafe_getEv:
   52|     41|      T* unsafe_get() const { return m_obj.get(); }
ffi_pk_op.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan12PK_EncryptorELj2300526531EZ19botan_pk_op_encryptE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|     41|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|     41|   using RetT = std::invoke_result_t<F, T&>;
  116|     41|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|     41|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|     41|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 41]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|     41|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 41]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|     41|   T* p = o->unsafe_get();
  128|     41|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 41]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|       |   if constexpr(std::is_void_v<RetT>) {
  133|       |      return ffi_guard_thunk(func_name, [&] {
  134|       |         func(*p);
  135|       |         return BOTAN_FFI_SUCCESS;
  136|       |      });
  137|     41|   } else {
  138|     41|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|     41|   }
  140|     41|}
ffi_pk_op.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan12PK_EncryptorELj2300526531EZ19botan_pk_op_encryptE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|     41|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|     41|   ffi_clear_last_exception();
   97|       |
   98|     41|   try {
   99|     41|      return thunk();
  100|     41|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|     41|}
ffi_pk_op.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan12PK_EncryptorELj2300526531EZ19botan_pk_op_encryptE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  138|     41|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
ffi_pk_op.cpp:_ZZ19botan_pk_op_encryptENK3$_0clIN5Botan12PK_EncryptorEEEDaRKT_:
  158|     41|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_pk_op.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ25botan_pk_op_verify_createE3$_0EEiPKcT_:
   95|  10.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  10.7k|   ffi_clear_last_exception();
   97|       |
   98|  10.7k|   try {
   99|  10.7k|      return thunk();
  100|  10.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  10.7k|}
_ZN9Botan_FFI14ffi_new_objectIP25botan_pk_op_verify_structJNSt3__110unique_ptrIN5Botan11PK_VerifierENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  10.7k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  10.7k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 10.7k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  10.7k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  10.7k|   return BOTAN_FFI_SUCCESS;
  185|  10.7k|}
_ZN25botan_pk_op_verify_structC2ENSt3__110unique_ptrIN5Botan11PK_VerifierENS0_14default_deleteIS3_EEEE:
   63|  10.7k|         explicit NAME(std::unique_ptr<TYPE> x) : botan_struct(std::move(x)) {} \
_ZN9Botan_FFI12botan_structIN5Botan11PK_VerifierELj730986806EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  10.7k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan11PK_VerifierELj730986806EED2Ev:
   40|  10.7k|      virtual ~botan_struct() {
   41|  10.7k|         m_magic = 0;
   42|  10.7k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  10.7k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan11PK_VerifierELj730986806EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  10.7k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  10.7k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  10.7k|      if(obj == nullptr) {
  165|  10.7k|         return BOTAN_FFI_SUCCESS;
  166|  10.7k|      }
  167|       |
  168|  10.7k|      if(!obj->magic_ok()) {
  169|  10.7k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  10.7k|      }
  171|       |
  172|  10.7k|      delete obj;  // NOLINT(*-owning-memory)
  173|  10.7k|      return BOTAN_FFI_SUCCESS;
  174|  10.7k|   });
  175|  10.7k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan11PK_VerifierELj730986806EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  10.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  10.7k|   ffi_clear_last_exception();
   97|       |
   98|  10.7k|   try {
   99|  10.7k|      return thunk();
  100|  10.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  10.7k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan11PK_VerifierELj730986806EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  10.7k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  10.7k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 10.7k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  10.7k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 10.7k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  10.7k|      delete obj;  // NOLINT(*-owning-memory)
  173|  10.7k|      return BOTAN_FFI_SUCCESS;
  174|  10.7k|   });
_ZNK9Botan_FFI12botan_structIN5Botan11PK_VerifierELj730986806EE8magic_okEv:
   50|  32.3k|      bool magic_ok() const { return (m_magic == MAGIC); }
ffi_pk_op.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  10.7k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  10.7k|   using RetT = std::invoke_result_t<F, T&>;
  116|  10.7k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  10.7k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  10.7k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 10.7k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  10.7k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 10.7k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  10.7k|   T* p = o->unsafe_get();
  128|  10.7k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 10.7k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  10.7k|   if constexpr(std::is_void_v<RetT>) {
  133|  10.7k|      return ffi_guard_thunk(func_name, [&] {
  134|  10.7k|         func(*p);
  135|  10.7k|         return BOTAN_FFI_SUCCESS;
  136|  10.7k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  10.7k|}
_ZNK9Botan_FFI12botan_structIN5Botan11PK_VerifierELj730986806EE10unsafe_getEv:
   52|  21.5k|      T* unsafe_get() const { return m_obj.get(); }
ffi_pk_op.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  10.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  10.7k|   ffi_clear_last_exception();
   97|       |
   98|  10.7k|   try {
   99|  10.7k|      return thunk();
  100|  10.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  10.7k|}
ffi_pk_op.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_updateE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  10.7k|      return ffi_guard_thunk(func_name, [&] {
  134|  10.7k|         func(*p);
  135|  10.7k|         return BOTAN_FFI_SUCCESS;
  136|  10.7k|      });
ffi_pk_op.cpp:_ZZ25botan_pk_op_verify_updateENK3$_0clIN5Botan11PK_VerifierEEEDaRT_:
  158|  10.7k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
ffi_pk_op.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_finishE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  10.7k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  10.7k|   using RetT = std::invoke_result_t<F, T&>;
  116|  10.7k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  10.7k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  10.7k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 10.7k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  10.7k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 10.7k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  10.7k|   T* p = o->unsafe_get();
  128|  10.7k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 10.7k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|       |   if constexpr(std::is_void_v<RetT>) {
  133|       |      return ffi_guard_thunk(func_name, [&] {
  134|       |         func(*p);
  135|       |         return BOTAN_FFI_SUCCESS;
  136|       |      });
  137|  10.7k|   } else {
  138|  10.7k|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|  10.7k|   }
  140|  10.7k|}
ffi_pk_op.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_finishE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  10.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  10.7k|   ffi_clear_last_exception();
   97|       |
   98|  10.7k|   try {
   99|  10.7k|      return thunk();
  100|  10.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  10.7k|}
ffi_pk_op.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan11PK_VerifierELj730986806EZ25botan_pk_op_verify_finishE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  138|  10.7k|      return ffi_guard_thunk(func_name, [&] { return func(*p); });
ffi_pk_op.cpp:_ZZ25botan_pk_op_verify_finishENK3$_0clIN5Botan11PK_VerifierEEEDaRT_:
  158|  32.3k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  |  Branch (158:59): [True: 444, False: 10.3k]
  ------------------
_ZN9Botan_FFI12botan_structIN5Botan10Public_KeyELj740844825EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  10.8k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan10Public_KeyELj740844825EED2Ev:
   40|  10.8k|      virtual ~botan_struct() {
   41|  10.8k|         m_magic = 0;
   42|  10.8k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  10.8k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan10Public_KeyELj740844825EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  10.9k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  10.9k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  10.9k|      if(obj == nullptr) {
  165|  10.9k|         return BOTAN_FFI_SUCCESS;
  166|  10.9k|      }
  167|       |
  168|  10.9k|      if(!obj->magic_ok()) {
  169|  10.9k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  10.9k|      }
  171|       |
  172|  10.9k|      delete obj;  // NOLINT(*-owning-memory)
  173|  10.9k|      return BOTAN_FFI_SUCCESS;
  174|  10.9k|   });
  175|  10.9k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan10Public_KeyELj740844825EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  10.9k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  10.9k|   ffi_clear_last_exception();
   97|       |
   98|  10.9k|   try {
   99|  10.9k|      return thunk();
  100|  10.9k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  10.9k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan10Public_KeyELj740844825EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  10.9k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  10.9k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 126, False: 10.8k]
  ------------------
  165|    126|         return BOTAN_FFI_SUCCESS;
  166|    126|      }
  167|       |
  168|  10.8k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 10.8k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  10.8k|      delete obj;  // NOLINT(*-owning-memory)
  173|  10.8k|      return BOTAN_FFI_SUCCESS;
  174|  10.8k|   });
ffi_pkey_algs.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ21botan_pubkey_load_rsaE3$_0EEiPKcT_:
   95|    429|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|    429|   ffi_clear_last_exception();
   97|       |
   98|    429|   try {
   99|    429|      return thunk();
  100|    429|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|     81|   } catch(Botan::Exception& e) {
  105|     81|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|     81|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|    429|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_pubkey_structJNSt3__110unique_ptrIN5Botan13RSA_PublicKeyENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|    348|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|    348|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 348]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|    348|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|    348|   return BOTAN_FFI_SUCCESS;
  185|    348|}
ffi_pkey_algs.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ21botan_pubkey_load_dsaE3$_0EEiPKcT_:
   95|  1.08k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  1.08k|   ffi_clear_last_exception();
   97|       |
   98|  1.08k|   try {
   99|  1.08k|      return thunk();
  100|  1.08k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      1|   } catch(Botan::Exception& e) {
  105|      1|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      1|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  1.08k|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_pubkey_structJNSt3__110unique_ptrIN5Botan13DSA_PublicKeyENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  1.08k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  1.08k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 1.08k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  1.08k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  1.08k|   return BOTAN_FFI_SUCCESS;
  185|  1.08k|}
ffi_pkey_algs.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ23botan_pubkey_load_ecdsaE3$_0EEiPKcT_:
   95|  6.29k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  6.29k|   ffi_clear_last_exception();
   97|       |
   98|  6.29k|   try {
   99|  6.29k|      return thunk();
  100|  6.29k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  6.29k|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_pubkey_structJNSt3__110unique_ptrIN5Botan15ECDSA_PublicKeyENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  6.25k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  6.25k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 6.25k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  6.25k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  6.25k|   return BOTAN_FFI_SUCCESS;
  185|  6.25k|}
ffi_pkey_algs.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ25botan_pubkey_load_elgamalE3$_0EEiPKcT_:
   95|     41|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|     41|   ffi_clear_last_exception();
   97|       |
   98|     41|   try {
   99|     41|      return thunk();
  100|     41|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|     41|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_pubkey_structJNSt3__110unique_ptrIN5Botan17ElGamal_PublicKeyENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|     41|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|     41|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 41]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|     41|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|     41|   return BOTAN_FFI_SUCCESS;
  185|     41|}
ffi_pkey_algs.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ25botan_pubkey_load_ed25519E3$_0EEiPKcT_:
   95|  3.08k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  3.08k|   ffi_clear_last_exception();
   97|       |
   98|  3.08k|   try {
   99|  3.08k|      return thunk();
  100|  3.08k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  3.08k|}
_ZN9Botan_FFI14ffi_new_objectIP19botan_pubkey_structJNSt3__110unique_ptrIN5Botan17Ed25519_PublicKeyENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  3.08k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  3.08k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 3.08k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  3.08k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  3.08k|   return BOTAN_FFI_SUCCESS;
  185|  3.08k|}
ffi_rng.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZ14botan_rng_initE3$_0EEiPKcT_:
   95|  12.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  12.7k|   ffi_clear_last_exception();
   97|       |
   98|  12.7k|   try {
   99|  12.7k|      return thunk();
  100|  12.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  12.7k|}
_ZN9Botan_FFI14ffi_new_objectIP16botan_rng_structJNSt3__110unique_ptrIN5Botan21RandomNumberGeneratorENS3_14default_deleteIS6_EEEEEEE15BOTAN_FFI_ERRORPT_DpOT0_:
  178|  12.7k|BOTAN_FFI_ERROR ffi_new_object(T* obj, Args&&... args) {
  179|  12.7k|   if(obj == nullptr) {
  ------------------
  |  Branch (179:7): [True: 0, False: 12.7k]
  ------------------
  180|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  181|      0|   }
  182|       |   // NOLINTNEXTLINE(*-owning-memory)
  183|  12.7k|   *obj = new std::remove_pointer_t<T>(std::forward<Args>(args)...);
  184|  12.7k|   return BOTAN_FFI_SUCCESS;
  185|  12.7k|}
_ZN9Botan_FFI12botan_structIN5Botan21RandomNumberGeneratorELj1224866241EEC2ENSt3__110unique_ptrIS2_NS4_14default_deleteIS2_EEEE:
   38|  12.7k|      explicit botan_struct(std::unique_ptr<T> obj) : m_magic(MAGIC), m_obj(std::move(obj)) {}
_ZN9Botan_FFI12botan_structIN5Botan21RandomNumberGeneratorELj1224866241EED2Ev:
   40|  12.7k|      virtual ~botan_struct() {
   41|  12.7k|         m_magic = 0;
   42|  12.7k|         m_obj.reset();  // NOLINT(*-ambiguous-smartptr-reset-call)
   43|  12.7k|      }
_ZN9Botan_FFI17ffi_delete_objectIN5Botan21RandomNumberGeneratorELj1224866241EEEiPNS_12botan_structIT_XT0_EEEPKc:
  161|  12.7k|int ffi_delete_object(botan_struct<T, M>* obj, const char* func_name) {
  162|  12.7k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  12.7k|      if(obj == nullptr) {
  165|  12.7k|         return BOTAN_FFI_SUCCESS;
  166|  12.7k|      }
  167|       |
  168|  12.7k|      if(!obj->magic_ok()) {
  169|  12.7k|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|  12.7k|      }
  171|       |
  172|  12.7k|      delete obj;  // NOLINT(*-owning-memory)
  173|  12.7k|      return BOTAN_FFI_SUCCESS;
  174|  12.7k|   });
  175|  12.7k|}
_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_17ffi_delete_objectIN5Botan21RandomNumberGeneratorELj1224866241EEEiPNS_12botan_structIT_XT0_EEEPKcEUlvE_EEiSA_S6_:
   95|  12.7k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  12.7k|   ffi_clear_last_exception();
   97|       |
   98|  12.7k|   try {
   99|  12.7k|      return thunk();
  100|  12.7k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  12.7k|}
_ZZN9Botan_FFI17ffi_delete_objectIN5Botan21RandomNumberGeneratorELj1224866241EEEiPNS_12botan_structIT_XT0_EEEPKcENKUlvE_clEv:
  162|  12.7k|   return ffi_guard_thunk(func_name, [=]() -> int {
  163|       |      // ignore delete of null objects
  164|  12.7k|      if(obj == nullptr) {
  ------------------
  |  Branch (164:10): [True: 0, False: 12.7k]
  ------------------
  165|      0|         return BOTAN_FFI_SUCCESS;
  166|      0|      }
  167|       |
  168|  12.7k|      if(!obj->magic_ok()) {
  ------------------
  |  Branch (168:10): [True: 0, False: 12.7k]
  ------------------
  169|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT;
  170|      0|      }
  171|       |
  172|  12.7k|      delete obj;  // NOLINT(*-owning-memory)
  173|  12.7k|      return BOTAN_FFI_SUCCESS;
  174|  12.7k|   });
ffi_rng.cpp:_ZN9Botan_FFI15botan_ffi_visitIN5Botan21RandomNumberGeneratorELj1224866241EZ13botan_rng_getE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKc:
  114|  26.4k|int botan_ffi_visit(botan_struct<T, M>* o, F func, const char* func_name) {
  115|  26.4k|   using RetT = std::invoke_result_t<F, T&>;
  116|  26.4k|   static_assert(std::is_void_v<RetT> || std::is_same_v<RetT, BOTAN_FFI_ERROR> || std::is_same_v<RetT, int>,
  117|  26.4k|                 "BOTAN_FFI_DO must be used with a block that returns either nothing, int or BOTAN_FFI_ERROR");
  118|       |
  119|  26.4k|   if(!o) {
  ------------------
  |  Branch (119:7): [True: 0, False: 26.4k]
  ------------------
  120|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  121|      0|   }
  122|       |
  123|  26.4k|   if(!o->magic_ok()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 26.4k]
  ------------------
  124|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  125|      0|   }
  126|       |
  127|  26.4k|   T* p = o->unsafe_get();
  128|  26.4k|   if(p == nullptr) {
  ------------------
  |  Branch (128:7): [True: 0, False: 26.4k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_INVALID_OBJECT;
  130|      0|   }
  131|       |
  132|  26.4k|   if constexpr(std::is_void_v<RetT>) {
  133|  26.4k|      return ffi_guard_thunk(func_name, [&] {
  134|  26.4k|         func(*p);
  135|  26.4k|         return BOTAN_FFI_SUCCESS;
  136|  26.4k|      });
  137|       |   } else {
  138|       |      return ffi_guard_thunk(func_name, [&] { return func(*p); });
  139|       |   }
  140|  26.4k|}
ffi_rng.cpp:_ZN9Botan_FFI15ffi_guard_thunkITkNSt3__19invocableEZNS_15botan_ffi_visitIN5Botan21RandomNumberGeneratorELj1224866241EZ13botan_rng_getE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcEUlvE_EEiSC_S7_:
   95|  26.4k|int ffi_guard_thunk(const char* func_name, T thunk) {
   96|  26.4k|   ffi_clear_last_exception();
   97|       |
   98|  26.4k|   try {
   99|  26.4k|      return thunk();
  100|  26.4k|   } catch(std::bad_alloc&) {
  101|      0|      return ffi_error_exception_thrown(func_name, "bad_alloc", BOTAN_FFI_ERROR_OUT_OF_MEMORY);
  102|      0|   } catch(Botan_FFI::FFI_Error& e) {
  103|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_code());
  104|      0|   } catch(Botan::Exception& e) {
  105|      0|      return ffi_error_exception_thrown(func_name, e.what(), e.error_type());
  106|      0|   } catch(std::exception& e) {
  107|      0|      return ffi_error_exception_thrown(func_name, e.what(), BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  108|      0|   } catch(...) {
  109|      0|      return ffi_error_exception_thrown(func_name, "unknown exception", BOTAN_FFI_ERROR_EXCEPTION_THROWN);
  110|      0|   }
  111|  26.4k|}
ffi_rng.cpp:_ZZN9Botan_FFI15botan_ffi_visitIN5Botan21RandomNumberGeneratorELj1224866241EZ13botan_rng_getE3$_0EEiPNS_12botan_structIT_XT0_EEET1_PKcENKUlvE_clEv:
  133|  26.4k|      return ffi_guard_thunk(func_name, [&] {
  134|  26.4k|         func(*p);
  135|  26.4k|         return BOTAN_FFI_SUCCESS;
  136|  26.4k|      });
ffi_rng.cpp:_ZZ13botan_rng_getENK3$_0clIN5Botan21RandomNumberGeneratorEEEDaRT_:
  158|  26.4k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)

_ZN5Botan3fmtIJNSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEEEENS1_12basic_stringIcS4_NS1_9allocatorIcEEEES5_DpRKT_:
   53|  6.79k|std::string fmt(std::string_view format, const T&... args) {
   54|  6.79k|   std::ostringstream oss;
   55|  6.79k|   oss.imbue(std::locale::classic());
   56|  6.79k|   fmt_detail::do_fmt(oss, format, args...);
   57|  6.79k|   return oss.str();
   58|  6.79k|}
_ZN5Botan10fmt_detail6do_fmtINSt3__117basic_string_viewIcNS2_11char_traitsIcEEEEJEEEvRNS2_19basic_ostringstreamIcS5_NS2_9allocatorIcEEEES6_RKT_DpRKT0_:
   25|  7.83k|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|  7.83k|   size_t i = 0;
   27|       |
   28|  42.8k|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 42.8k, False: 0]
  ------------------
   29|  42.8k|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 7.83k, False: 35.0k]
  |  Branch (29:30): [True: 7.83k, False: 0]
  |  Branch (29:59): [True: 7.83k, False: 0]
  ------------------
   30|  7.83k|         oss << val;
   31|  7.83k|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|  35.0k|      } else {
   33|  35.0k|         oss << format[i];
   34|  35.0k|      }
   35|       |
   36|  35.0k|      i += 1;
   37|  35.0k|   }
   38|  7.83k|}
_ZN5Botan10fmt_detail6do_fmtERNSt3__119basic_ostringstreamIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS1_17basic_string_viewIcS4_EE:
   20|  8.71k|inline void do_fmt(std::ostringstream& oss, std::string_view format) {
   21|  8.71k|   oss << format;
   22|  8.71k|}
_ZN5Botan10fmt_detail6do_fmtIPKcJEEEvRNSt3__119basic_ostringstreamIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_17basic_string_viewIcS7_EERKT_DpRKT0_:
   25|    307|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|    307|   size_t i = 0;
   27|       |
   28|    614|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 614, False: 0]
  ------------------
   29|    614|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 307, False: 307]
  |  Branch (29:30): [True: 307, False: 0]
  |  Branch (29:59): [True: 307, False: 0]
  ------------------
   30|    307|         oss << val;
   31|    307|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|    307|      } else {
   33|    307|         oss << format[i];
   34|    307|      }
   35|       |
   36|    307|      i += 1;
   37|    307|   }
   38|    307|}
_ZN5Botan3fmtIJmEEENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS1_17basic_string_viewIcS4_EEDpRKT_:
   53|    571|std::string fmt(std::string_view format, const T&... args) {
   54|    571|   std::ostringstream oss;
   55|    571|   oss.imbue(std::locale::classic());
   56|    571|   fmt_detail::do_fmt(oss, format, args...);
   57|    571|   return oss.str();
   58|    571|}
_ZN5Botan10fmt_detail6do_fmtImJEEEvRNSt3__119basic_ostringstreamIcNS2_11char_traitsIcEENS2_9allocatorIcEEEENS2_17basic_string_viewIcS5_EERKT_DpRKT0_:
   25|    571|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|    571|   size_t i = 0;
   27|       |
   28|  4.41k|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 4.41k, False: 0]
  ------------------
   29|  4.41k|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 571, False: 3.84k]
  |  Branch (29:30): [True: 571, False: 0]
  |  Branch (29:59): [True: 571, False: 0]
  ------------------
   30|    571|         oss << val;
   31|    571|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|  3.84k|      } else {
   33|  3.84k|         oss << format[i];
   34|  3.84k|      }
   35|       |
   36|  3.84k|      i += 1;
   37|  3.84k|   }
   38|    571|}
_ZN5Botan3fmtIJPKcS2_S2_EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEENS3_17basic_string_viewIcS6_EEDpRKT_:
   53|    307|std::string fmt(std::string_view format, const T&... args) {
   54|    307|   std::ostringstream oss;
   55|    307|   oss.imbue(std::locale::classic());
   56|    307|   fmt_detail::do_fmt(oss, format, args...);
   57|    307|   return oss.str();
   58|    307|}
_ZN5Botan10fmt_detail6do_fmtIPKcJS3_S3_EEEvRNSt3__119basic_ostringstreamIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_17basic_string_viewIcS7_EERKT_DpRKT0_:
   25|    307|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|    307|   size_t i = 0;
   27|       |
   28|    307|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 307, False: 0]
  ------------------
   29|    307|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 307, False: 0]
  |  Branch (29:30): [True: 307, False: 0]
  |  Branch (29:59): [True: 307, False: 0]
  ------------------
   30|    307|         oss << val;
   31|    307|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|    307|      } else {
   33|      0|         oss << format[i];
   34|      0|      }
   35|       |
   36|      0|      i += 1;
   37|      0|   }
   38|    307|}
_ZN5Botan10fmt_detail6do_fmtIPKcJS3_EEEvRNSt3__119basic_ostringstreamIcNS4_11char_traitsIcEENS4_9allocatorIcEEEENS4_17basic_string_viewIcS7_EERKT_DpRKT0_:
   25|    307|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|    307|   size_t i = 0;
   27|       |
   28|  1.53k|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 1.53k, False: 0]
  ------------------
   29|  1.53k|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 307, False: 1.22k]
  |  Branch (29:30): [True: 307, False: 0]
  |  Branch (29:59): [True: 307, False: 0]
  ------------------
   30|    307|         oss << val;
   31|    307|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|  1.22k|      } else {
   33|  1.22k|         oss << format[i];
   34|  1.22k|      }
   35|       |
   36|  1.22k|      i += 1;
   37|  1.22k|   }
   38|    307|}
_ZN5Botan3fmtIJPKcNSt3__117basic_string_viewIcNS3_11char_traitsIcEEEEEEENS3_12basic_stringIcS6_NS3_9allocatorIcEEEES7_DpRKT_:
   53|  1.03k|std::string fmt(std::string_view format, const T&... args) {
   54|  1.03k|   std::ostringstream oss;
   55|  1.03k|   oss.imbue(std::locale::classic());
   56|  1.03k|   fmt_detail::do_fmt(oss, format, args...);
   57|  1.03k|   return oss.str();
   58|  1.03k|}
_ZN5Botan10fmt_detail6do_fmtIPKcJNSt3__117basic_string_viewIcNS4_11char_traitsIcEEEEEEEvRNS4_19basic_ostringstreamIcS7_NS4_9allocatorIcEEEES8_RKT_DpRKT0_:
   25|  1.03k|void do_fmt(std::ostringstream& oss, std::string_view format, const T& val, const Ts&... rest) {
   26|  1.03k|   size_t i = 0;
   27|       |
   28|  1.03k|   while(i < format.size()) {
  ------------------
  |  Branch (28:10): [True: 1.03k, False: 0]
  ------------------
   29|  1.03k|      if(format[i] == '{' && (format.size() > (i + 1)) && format.at(i + 1) == '}') {
  ------------------
  |  Branch (29:10): [True: 1.03k, False: 0]
  |  Branch (29:30): [True: 1.03k, False: 0]
  |  Branch (29:59): [True: 1.03k, False: 0]
  ------------------
   30|  1.03k|         oss << val;
   31|  1.03k|         return do_fmt(oss, format.substr(i + 2), rest...);
   32|  1.03k|      } else {
   33|      0|         oss << format[i];
   34|      0|      }
   35|       |
   36|      0|      i += 1;
   37|      0|   }
   38|  1.03k|}

_ZN5Botan14GCM_EncryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
   80|  1.84k|            GCM_Mode(std::move(cipher), tag_size) {}
_ZN5Botan14GCM_DecryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
  101|  1.55k|            GCM_Mode(std::move(cipher), tag_size) {}
_ZNK5Botan8GCM_Mode8tag_sizeEv:
   40|   265k|      size_t tag_size() const final { return m_tag_size; }
_ZNK5Botan14GCM_Encryption18minimum_final_sizeEv:
   84|  1.76k|      size_t minimum_final_size() const override { return 0; }
_ZNK5Botan14GCM_Decryption18minimum_final_sizeEv:
  105|  1.54k|      size_t minimum_final_size() const override { return tag_size(); }

_ZNK5Botan5GHASH8key_specEv:
   42|  3.30k|      Key_Length_Specification key_spec() const override { return Key_Length_Specification(16); }

_ZN5Botan12HKDF_ExtractC2ENSt3__110unique_ptrINS_25MessageAuthenticationCodeENS1_14default_deleteIS3_EEEE:
   49|  6.79k|      explicit HKDF_Extract(std::unique_ptr<MessageAuthenticationCode> prf) : m_prf(std::move(prf)) {}
_ZN5Botan11HKDF_ExpandC2ENSt3__110unique_ptrINS_25MessageAuthenticationCodeENS1_14default_deleteIS3_EEEE:
   73|  6.79k|      explicit HKDF_Expand(std::unique_ptr<MessageAuthenticationCode> prf) : m_prf(std::move(prf)) {}
_ZN5Botan4HKDFC2ENSt3__110unique_ptrINS_25MessageAuthenticationCodeENS1_14default_deleteIS3_EEEE:
   25|  6.79k|      explicit HKDF(std::unique_ptr<MessageAuthenticationCode> prf) : m_prf(std::move(prf)) {}

_ZNK5Botan4IDEA4nameEv:
   28|     38|      std::string name() const override { return "IDEA"; }
_ZNK5Botan4IDEA10new_objectEv:
   30|  1.41k|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<IDEA>(); }

_ZN5Botan11checked_addITkNSt3__117unsigned_integralEjEENS1_8optionalIT_EES3_S3_:
   19|      3|constexpr inline std::optional<T> checked_add(T a, T b) {
   20|      3|   const T r = a + b;
   21|      3|   if(r < a || r < b) {
  ------------------
  |  Branch (21:7): [True: 0, False: 3]
  |  Branch (21:16): [True: 0, False: 3]
  ------------------
   22|      0|      return {};
   23|      0|   }
   24|      3|   return r;
   25|      3|}
_ZN5Botan11checked_addITkNSt3__117unsigned_integralEmEENS1_8optionalIT_EES3_S3_:
   19|  19.9k|constexpr inline std::optional<T> checked_add(T a, T b) {
   20|  19.9k|   const T r = a + b;
   21|  19.9k|   if(r < a || r < b) {
  ------------------
  |  Branch (21:7): [True: 0, False: 19.9k]
  |  Branch (21:16): [True: 0, False: 19.9k]
  ------------------
   22|      0|      return {};
   23|      0|   }
   24|  19.9k|   return r;
   25|  19.9k|}
_ZN5Botan11checked_mulITkNSt3__117unsigned_integralEmEENS1_8optionalIT_EES3_S3_:
   46|  3.20M|constexpr inline std::optional<T> checked_mul(T a, T b) {
   47|       |   // Multiplication by 1U is a hack to work around C's insane
   48|       |   // integer promotion rules.
   49|       |   // https://stackoverflow.com/questions/24795651
   50|  3.20M|   const T r = (1U * a) * b;
   51|       |   // If a == 0 then the multiply certainly did not overflow
   52|       |   // Otherwise r / a == b unless overflow occurred
   53|  3.20M|   if(a != 0 && r / a != b) {
  ------------------
  |  Branch (53:7): [True: 3.20M, False: 0]
  |  Branch (53:17): [True: 0, False: 3.20M]
  ------------------
   54|      0|      return {};
   55|      0|   }
   56|  3.20M|   return r;
   57|  3.20M|}
_ZN5Botan13swar_in_rangeITkNSt3__117unsigned_integralEmEET_S2_S2_S2_:
  144|  7.47M|constexpr T swar_in_range(T v, T lower, T upper) {
  145|       |   // The constant 0x808080... as a T
  146|  7.47M|   constexpr T hi1 = (static_cast<T>(-1) / 255) << 7;
  147|       |   // The constant 0x7F7F7F... as a T
  148|  7.47M|   constexpr T lo7 = ~hi1;
  149|       |
  150|  7.47M|   const T sub = ((v | hi1) - (lower & lo7)) ^ ((v ^ (~lower)) & hi1);
  151|  7.47M|   const T a_lo = sub & lo7;
  152|  7.47M|   const T a_hi = sub & hi1;
  153|  7.47M|   return (lo7 - a_lo + upper) & hi1 & ~a_hi;
  154|  7.47M|}
_ZN5Botan7swar_ltITkNSt3__117unsigned_integralEtEET_S2_S2_:
  121|  1.08M|constexpr T swar_lt(T a, T b) {
  122|       |   // The constant 0x808080... as a T
  123|  1.08M|   constexpr T hi1 = (static_cast<T>(-1) / 255) << 7;
  124|       |   // The constant 0x7F7F7F... as a T
  125|  1.08M|   constexpr T lo7 = static_cast<T>(~hi1);
  126|  1.08M|   T r = (lo7 - a + b) & hi1;
  127|       |   // Currently the mask is 80 if lt, otherwise 00. Convert to FF/00
  128|  1.08M|   return (r << 1) - (r >> 7);
  129|  1.08M|}
_ZN5Botan23index_of_first_set_byteITkNSt3__117unsigned_integralEmEEmT_:
  160|  7.47M|constexpr size_t index_of_first_set_byte(T v) {
  161|       |   // The constant 0x010101... as a T
  162|  7.47M|   constexpr T lo1 = (static_cast<T>(-1) / 255);
  163|       |   // The constant 0x808080... as a T
  164|  7.47M|   constexpr T hi1 = lo1 << 7;
  165|       |   // How many bits to shift in order to get the top byte
  166|  7.47M|   constexpr size_t bits = (sizeof(T) * 8) - 8;
  167|       |
  168|  7.47M|   return static_cast<size_t>((((((v & hi1) - 1) & lo1) * lo1) >> bits) - 1);
  169|  7.47M|}
_ZN5Botan12add_or_throwITkNSt3__117unsigned_integralEmEET_S2_S2_NS1_17basic_string_viewIcNS1_11char_traitsIcEEEE:
   66|  19.9k|constexpr T add_or_throw(T a, T b, std::string_view msg) {
   67|  19.9k|   if(auto r = checked_add(a, b)) {
  ------------------
  |  Branch (67:12): [True: 19.9k, False: 0]
  ------------------
   68|  19.9k|      return r.value();
   69|  19.9k|   } else {
   70|      0|      throw Invalid_Argument(msg);
   71|      0|   }
   72|  19.9k|}
_ZN5Botan11checked_subITkNSt3__117unsigned_integralEmEENS1_8optionalIT_EES3_S3_:
   28|     41|constexpr std::optional<T> checked_sub(T a, T b) {
   29|     41|   if(b > a) {
  ------------------
  |  Branch (29:7): [True: 0, False: 41]
  ------------------
   30|      0|      return {};
   31|      0|   }
   32|     41|   return a - b;
   33|     41|}

_ZN5Botan13KeccakPadding4sha3Ev:
   24|  9.53k|      static constexpr KeccakPadding sha3() { return {.padding = 0b10 /* little-endian */, .bit_len = 2}; }
_ZN5Botan18Keccak_PermutationC2ENS0_6ConfigE:
   69|  9.53k|            Sponge({.bit_rate = state_bits() - config.capacity_bits, .initial_state = {}}), m_padding(config.padding) {}

_ZN5Botan24Keccak_Permutation_roundEPmPKmm:
   15|  14.4M|BOTAN_FORCE_INLINE void Keccak_Permutation_round(uint64_t T[25], const uint64_t A[25], uint64_t RC) {
   16|  14.4M|   const uint64_t C0 = A[0] ^ A[5] ^ A[10] ^ A[15] ^ A[20];
   17|  14.4M|   const uint64_t C1 = A[1] ^ A[6] ^ A[11] ^ A[16] ^ A[21];
   18|  14.4M|   const uint64_t C2 = A[2] ^ A[7] ^ A[12] ^ A[17] ^ A[22];
   19|  14.4M|   const uint64_t C3 = A[3] ^ A[8] ^ A[13] ^ A[18] ^ A[23];
   20|  14.4M|   const uint64_t C4 = A[4] ^ A[9] ^ A[14] ^ A[19] ^ A[24];
   21|       |
   22|  14.4M|   const uint64_t D0 = rotl<1>(C0) ^ C3;
   23|  14.4M|   const uint64_t D1 = rotl<1>(C1) ^ C4;
   24|  14.4M|   const uint64_t D2 = rotl<1>(C2) ^ C0;
   25|  14.4M|   const uint64_t D3 = rotl<1>(C3) ^ C1;
   26|  14.4M|   const uint64_t D4 = rotl<1>(C4) ^ C2;
   27|       |
   28|  14.4M|   const uint64_t B00 = A[0] ^ D1;
   29|  14.4M|   const uint64_t B01 = rotl<44>(A[6] ^ D2);
   30|  14.4M|   const uint64_t B02 = rotl<43>(A[12] ^ D3);
   31|  14.4M|   const uint64_t B03 = rotl<21>(A[18] ^ D4);
   32|  14.4M|   const uint64_t B04 = rotl<14>(A[24] ^ D0);
   33|  14.4M|   T[0] = B00 ^ (~B01 & B02) ^ RC;
   34|  14.4M|   T[1] = B01 ^ (~B02 & B03);
   35|  14.4M|   T[2] = B02 ^ (~B03 & B04);
   36|  14.4M|   T[3] = B03 ^ (~B04 & B00);
   37|  14.4M|   T[4] = B04 ^ (~B00 & B01);
   38|       |
   39|  14.4M|   const uint64_t B05 = rotl<28>(A[3] ^ D4);
   40|  14.4M|   const uint64_t B06 = rotl<20>(A[9] ^ D0);
   41|  14.4M|   const uint64_t B07 = rotl<3>(A[10] ^ D1);
   42|  14.4M|   const uint64_t B08 = rotl<45>(A[16] ^ D2);
   43|  14.4M|   const uint64_t B09 = rotl<61>(A[22] ^ D3);
   44|  14.4M|   T[5] = B05 ^ (~B06 & B07);
   45|  14.4M|   T[6] = B06 ^ (~B07 & B08);
   46|  14.4M|   T[7] = B07 ^ (~B08 & B09);
   47|  14.4M|   T[8] = B08 ^ (~B09 & B05);
   48|  14.4M|   T[9] = B09 ^ (~B05 & B06);
   49|       |
   50|  14.4M|   const uint64_t B10 = rotl<1>(A[1] ^ D2);
   51|  14.4M|   const uint64_t B11 = rotl<6>(A[7] ^ D3);
   52|  14.4M|   const uint64_t B12 = rotl<25>(A[13] ^ D4);
   53|  14.4M|   const uint64_t B13 = rotl<8>(A[19] ^ D0);
   54|  14.4M|   const uint64_t B14 = rotl<18>(A[20] ^ D1);
   55|  14.4M|   T[10] = B10 ^ (~B11 & B12);
   56|  14.4M|   T[11] = B11 ^ (~B12 & B13);
   57|  14.4M|   T[12] = B12 ^ (~B13 & B14);
   58|  14.4M|   T[13] = B13 ^ (~B14 & B10);
   59|  14.4M|   T[14] = B14 ^ (~B10 & B11);
   60|       |
   61|  14.4M|   const uint64_t B15 = rotl<27>(A[4] ^ D0);
   62|  14.4M|   const uint64_t B16 = rotl<36>(A[5] ^ D1);
   63|  14.4M|   const uint64_t B17 = rotl<10>(A[11] ^ D2);
   64|  14.4M|   const uint64_t B18 = rotl<15>(A[17] ^ D3);
   65|  14.4M|   const uint64_t B19 = rotl<56>(A[23] ^ D4);
   66|  14.4M|   T[15] = B15 ^ (~B16 & B17);
   67|  14.4M|   T[16] = B16 ^ (~B17 & B18);
   68|  14.4M|   T[17] = B17 ^ (~B18 & B19);
   69|  14.4M|   T[18] = B18 ^ (~B19 & B15);
   70|  14.4M|   T[19] = B19 ^ (~B15 & B16);
   71|       |
   72|  14.4M|   const uint64_t B20 = rotl<62>(A[2] ^ D3);
   73|  14.4M|   const uint64_t B21 = rotl<55>(A[8] ^ D4);
   74|  14.4M|   const uint64_t B22 = rotl<39>(A[14] ^ D0);
   75|  14.4M|   const uint64_t B23 = rotl<41>(A[15] ^ D1);
   76|  14.4M|   const uint64_t B24 = rotl<2>(A[21] ^ D2);
   77|  14.4M|   T[20] = B20 ^ (~B21 & B22);
   78|  14.4M|   T[21] = B21 ^ (~B22 & B23);
   79|  14.4M|   T[22] = B22 ^ (~B23 & B24);
   80|  14.4M|   T[23] = B23 ^ (~B24 & B20);
   81|  14.4M|   T[24] = B24 ^ (~B20 & B21);
   82|  14.4M|}

_ZN5Botan8get_byteILm0EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan11make_uint32Ehhhh:
  104|  17.4M|inline constexpr uint32_t make_uint32(uint8_t i0, uint8_t i1, uint8_t i2, uint8_t i3) {
  105|  17.4M|   return ((static_cast<uint32_t>(i0) << 24) | (static_cast<uint32_t>(i1) << 16) | (static_cast<uint32_t>(i2) << 8) |
  106|  17.4M|           (static_cast<uint32_t>(i3)));
  107|  17.4M|}
_ZN5Botan12get_byte_varImEEhmT_:
   69|    300|inline constexpr uint8_t get_byte_var(size_t byte_num, T input) {
   70|    300|   return static_cast<uint8_t>(input >> (((~byte_num) & (sizeof(T) - 1)) << 3));
   71|    300|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEtTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm2EEEQnt15custom_storableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEEvS9_OT1_:
  525|  4.65M|inline constexpr void store_any(WrappedInT wrapped_in, OutR&& out_range) {
  526|  4.65M|   const auto in = detail::unwrap_strong_type_or_enum(wrapped_in);
  527|  4.65M|   using InT = decltype(in);
  528|  4.65M|   ranges::assert_exact_byte_length<sizeof(in)>(out_range);
  529|  4.65M|   const std::span out{out_range};
  530|       |
  531|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  532|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  533|       |   // in a `constexpr` context.
  534|  4.65M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (534:7): [Folded, False: 4.65M]
  ------------------
  535|      0|      return fallback_store_any<endianness, InT>(in, std::forward<OutR>(out_range));
  536|  4.65M|   } else {
  537|       |      if constexpr(sizeof(InT) == 1) {
  538|       |         out[0] = static_cast<uint8_t>(in);
  539|       |      } else if constexpr(endianness == std::endian::native) {
  540|       |         typecast_copy(out, in);
  541|  4.65M|      } else {
  542|  4.65M|         static_assert(opposite(endianness) == std::endian::native);
  543|  4.65M|         typecast_copy(out, reverse_bytes(in));
  544|  4.65M|      }
  545|  4.65M|   }
  546|  4.65M|}
_ZN5Botan6detail26unwrap_strong_type_or_enumITkNS0_20unsigned_integralishEtEEDaT_:
  190|  4.65M|constexpr auto unwrap_strong_type_or_enum(InT t) {
  191|       |   if constexpr(std::is_enum_v<InT>) {
  192|       |      // TODO: C++23: use std::to_underlying(in) instead
  193|       |      return static_cast<std::underlying_type_t<InT>>(t);
  194|  4.65M|   } else {
  195|  4.65M|      return Botan::unwrap_strong_type(t);
  196|  4.65M|   }
  197|  4.65M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvS6_Ph:
  711|  2.45M|inline constexpr void store_any(T in, uint8_t out[]) {
  712|       |   // asserts that *out points to enough bytes to write into
  713|  2.45M|   store_any<endianness, InT>(in, std::span<uint8_t, sizeof(T)>(out, sizeof(T)));
  714|  2.45M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEEQsr3stdE7same_asIS4_T0_EEEvT1_OT2_:
  646|  2.45M|inline constexpr void store_any(T in, OutR&& out_range) {
  647|  2.45M|   store_any<endianness, T>(in, std::forward<OutR>(out_range));
  648|  2.45M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEEQnt15custom_storableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEEvS9_OT1_:
  525|  56.9M|inline constexpr void store_any(WrappedInT wrapped_in, OutR&& out_range) {
  526|  56.9M|   const auto in = detail::unwrap_strong_type_or_enum(wrapped_in);
  527|  56.9M|   using InT = decltype(in);
  528|  56.9M|   ranges::assert_exact_byte_length<sizeof(in)>(out_range);
  529|  56.9M|   const std::span out{out_range};
  530|       |
  531|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  532|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  533|       |   // in a `constexpr` context.
  534|  56.9M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (534:7): [Folded, False: 56.9M]
  ------------------
  535|      0|      return fallback_store_any<endianness, InT>(in, std::forward<OutR>(out_range));
  536|  56.9M|   } else {
  537|       |      if constexpr(sizeof(InT) == 1) {
  538|       |         out[0] = static_cast<uint8_t>(in);
  539|       |      } else if constexpr(endianness == std::endian::native) {
  540|       |         typecast_copy(out, in);
  541|  56.9M|      } else {
  542|  56.9M|         static_assert(opposite(endianness) == std::endian::native);
  543|  56.9M|         typecast_copy(out, reverse_bytes(in));
  544|  56.9M|      }
  545|  56.9M|   }
  546|  56.9M|}
_ZN5Botan6detail26unwrap_strong_type_or_enumITkNS0_20unsigned_integralishEjEEDaT_:
  190|  63.8M|constexpr auto unwrap_strong_type_or_enum(InT t) {
  191|       |   if constexpr(std::is_enum_v<InT>) {
  192|       |      // TODO: C++23: use std::to_underlying(in) instead
  193|       |      return static_cast<std::underlying_type_t<InT>>(t);
  194|  63.8M|   } else {
  195|  63.8M|      return Botan::unwrap_strong_type(t);
  196|  63.8M|   }
  197|  63.8M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEmQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvS6_Ph:
  711|  12.8M|inline constexpr void store_any(T in, uint8_t out[]) {
  712|       |   // asserts that *out points to enough bytes to write into
  713|  12.8M|   store_any<endianness, InT>(in, std::span<uint8_t, sizeof(T)>(out, sizeof(T)));
  714|  12.8M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEEQsr3stdE7same_asIS4_T0_EEEvT1_OT2_:
  646|  12.8M|inline constexpr void store_any(T in, OutR&& out_range) {
  647|  12.8M|   store_any<endianness, T>(in, std::forward<OutR>(out_range));
  648|  12.8M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEEQnt15custom_storableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEEvS9_OT1_:
  525|  56.0M|inline constexpr void store_any(WrappedInT wrapped_in, OutR&& out_range) {
  526|  56.0M|   const auto in = detail::unwrap_strong_type_or_enum(wrapped_in);
  527|  56.0M|   using InT = decltype(in);
  528|  56.0M|   ranges::assert_exact_byte_length<sizeof(in)>(out_range);
  529|  56.0M|   const std::span out{out_range};
  530|       |
  531|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  532|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  533|       |   // in a `constexpr` context.
  534|  56.0M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (534:7): [Folded, False: 56.0M]
  ------------------
  535|      0|      return fallback_store_any<endianness, InT>(in, std::forward<OutR>(out_range));
  536|  56.0M|   } else {
  537|       |      if constexpr(sizeof(InT) == 1) {
  538|       |         out[0] = static_cast<uint8_t>(in);
  539|       |      } else if constexpr(endianness == std::endian::native) {
  540|       |         typecast_copy(out, in);
  541|  56.0M|      } else {
  542|  56.0M|         static_assert(opposite(endianness) == std::endian::native);
  543|  56.0M|         typecast_copy(out, reverse_bytes(in));
  544|  56.0M|      }
  545|  56.0M|   }
  546|  56.0M|}
_ZN5Botan6detail26unwrap_strong_type_or_enumITkNS0_20unsigned_integralishEmEEDaT_:
  190|  56.0M|constexpr auto unwrap_strong_type_or_enum(InT t) {
  191|       |   if constexpr(std::is_enum_v<InT>) {
  192|       |      // TODO: C++23: use std::to_underlying(in) instead
  193|       |      return static_cast<std::underlying_type_t<InT>>(t);
  194|  56.0M|   } else {
  195|  56.0M|      return Botan::unwrap_strong_type(t);
  196|  56.0M|   }
  197|  56.0M|}
_ZN5Botan8store_leINS_6detail10AutoDetectEJRjRA4_hEEEDaDpOT0_:
  736|  43.4k|inline constexpr auto store_le(ParamTs&&... params) {
  737|  43.4k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|  43.4k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEjQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvS6_Ph:
  711|  43.4k|inline constexpr void store_any(T in, uint8_t out[]) {
  712|       |   // asserts that *out points to enough bytes to write into
  713|  43.4k|   store_any<endianness, InT>(in, std::span<uint8_t, sizeof(T)>(out, sizeof(T)));
  714|  43.4k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEEQsr3stdE7same_asIS4_T0_EEEvT1_OT2_:
  646|  43.4k|inline constexpr void store_any(T in, OutR&& out_range) {
  647|  43.4k|   store_any<endianness, T>(in, std::forward<OutR>(out_range));
  648|  43.4k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEEQnt15custom_storableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEEvS9_OT1_:
  525|  6.93M|inline constexpr void store_any(WrappedInT wrapped_in, OutR&& out_range) {
  526|  6.93M|   const auto in = detail::unwrap_strong_type_or_enum(wrapped_in);
  527|  6.93M|   using InT = decltype(in);
  528|  6.93M|   ranges::assert_exact_byte_length<sizeof(in)>(out_range);
  529|  6.93M|   const std::span out{out_range};
  530|       |
  531|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  532|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  533|       |   // in a `constexpr` context.
  534|  6.93M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (534:7): [Folded, False: 6.93M]
  ------------------
  535|      0|      return fallback_store_any<endianness, InT>(in, std::forward<OutR>(out_range));
  536|  6.93M|   } else {
  537|       |      if constexpr(sizeof(InT) == 1) {
  538|       |         out[0] = static_cast<uint8_t>(in);
  539|  6.93M|      } else if constexpr(endianness == std::endian::native) {
  540|  6.93M|         typecast_copy(out, in);
  541|       |      } else {
  542|       |         static_assert(opposite(endianness) == std::endian::native);
  543|       |         typecast_copy(out, reverse_bytes(in));
  544|       |      }
  545|  6.93M|   }
  546|  6.93M|}
_ZN5Botan8store_leINS_6detail10AutoDetectEJRmRA8_hEEEDaDpOT0_:
  736|  27.0k|inline constexpr auto store_le(ParamTs&&... params) {
  737|  27.0k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|  27.0k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEmQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvS6_Ph:
  711|  47.5k|inline constexpr void store_any(T in, uint8_t out[]) {
  712|       |   // asserts that *out points to enough bytes to write into
  713|  47.5k|   store_any<endianness, InT>(in, std::span<uint8_t, sizeof(T)>(out, sizeof(T)));
  714|  47.5k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEEQsr3stdE7same_asIS4_T0_EEEvT1_OT2_:
  646|  47.5k|inline constexpr void store_any(T in, OutR&& out_range) {
  647|  47.5k|   store_any<endianness, T>(in, std::forward<OutR>(out_range));
  648|  47.5k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEEQnt15custom_storableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEEvS9_OT1_:
  525|  47.5k|inline constexpr void store_any(WrappedInT wrapped_in, OutR&& out_range) {
  526|  47.5k|   const auto in = detail::unwrap_strong_type_or_enum(wrapped_in);
  527|  47.5k|   using InT = decltype(in);
  528|  47.5k|   ranges::assert_exact_byte_length<sizeof(in)>(out_range);
  529|  47.5k|   const std::span out{out_range};
  530|       |
  531|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  532|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  533|       |   // in a `constexpr` context.
  534|  47.5k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (534:7): [Folded, False: 47.5k]
  ------------------
  535|      0|      return fallback_store_any<endianness, InT>(in, std::forward<OutR>(out_range));
  536|  47.5k|   } else {
  537|       |      if constexpr(sizeof(InT) == 1) {
  538|       |         out[0] = static_cast<uint8_t>(in);
  539|  47.5k|      } else if constexpr(endianness == std::endian::native) {
  540|  47.5k|         typecast_copy(out, in);
  541|       |      } else {
  542|       |         static_assert(opposite(endianness) == std::endian::native);
  543|       |         typecast_copy(out, reverse_bytes(in));
  544|       |      }
  545|  47.5k|   }
  546|  47.5k|}
_ZN5Botan8get_byteILm1EtEEhT0_QltT_stS1_:
   81|  1.08M|{
   82|  1.08M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|  1.08M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|  1.08M|}
_ZN5Botan8get_byteILm0EtEEhT0_QltT_stS1_:
   81|  1.08M|{
   82|  1.08M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|  1.08M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|  1.08M|}
_ZN5Botan8get_byteILm3EjEEhT0_QltT_stS1_:
   81|   171M|{
   82|   171M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   171M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   171M|}
_ZN5Botan8get_byteILm2EjEEhT0_QltT_stS1_:
   81|   171M|{
   82|   171M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   171M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   171M|}
_ZN5Botan8get_byteILm1EjEEhT0_QltT_stS1_:
   81|   171M|{
   82|   171M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   171M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   171M|}
_ZN5Botan8get_byteILm0EjEEhT0_QltT_stS1_:
   81|   171M|{
   82|   171M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   171M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   171M|}
_ZN5Botan8get_byteILm7EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm6EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm5EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm4EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm3EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm2EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan8get_byteILm1EmEEhT0_QltT_stS1_:
   81|   240M|{
   82|   240M|   const size_t shift = ((~B) & (sizeof(T) - 1)) << 3;
   83|   240M|   return static_cast<uint8_t>((input >> shift) & 0xFF);
   84|   240M|}
_ZN5Botan7load_beINS_6detail10AutoDetectEJRA8_jRPKhmEEEDaDpOT0_:
  504|  7.91M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  7.91M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  7.91M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvPS6_PKhm:
  483|  7.91M|inline constexpr void load_any(T out[], const uint8_t in[], size_t count) {
  484|       |   // asserts that *in and *out point to the correct amount of memory
  485|  7.91M|   load_any<endianness, OutT>(std::span<T>(out, count), std::span<const uint8_t>(in, count * sizeof(T)));
  486|  7.91M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanIjLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_:
  355|  7.91M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  7.91M|   ranges::assert_equal_byte_lengths(out, in);
  357|  7.91M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  7.91M|   auto load_elementwise = [&] {
  360|  7.91M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  7.91M|      std::span<const uint8_t> in_s(in);
  362|  7.91M|      for(auto& out_elem : out) {
  363|  7.91M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  7.91M|         in_s = in_s.subspan(bytes_per_element);
  365|  7.91M|      }
  366|  7.91M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  7.91M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 7.91M]
  ------------------
  372|      0|      load_elementwise();
  373|  7.91M|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  7.91M|      } else {
  377|  7.91M|         load_elementwise();
  378|  7.91M|      }
  379|  7.91M|   }
  380|  7.91M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanIjLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_ENKUlvE_clEv:
  359|  7.91M|   auto load_elementwise = [&] {
  360|  7.91M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  7.91M|      std::span<const uint8_t> in_s(in);
  362|  43.3M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 43.3M, False: 7.91M]
  ------------------
  363|  43.3M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  43.3M|         in_s = in_s.subspan(bytes_per_element);
  365|  43.3M|      }
  366|  7.91M|   };
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEjTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm4EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|   534M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|   534M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|   534M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|   534M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|   534M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|   534M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|   534M|      } else {
  289|   534M|         const std::span in{in_range};
  290|   534M|         if constexpr(sizeof(OutT) == 1) {
  291|   534M|            return static_cast<OutT>(in[0]);
  292|   534M|         } else if constexpr(endianness == std::endian::native) {
  293|   534M|            return typecast_copy<OutT>(in);
  294|   534M|         } else {
  295|   534M|            static_assert(opposite(endianness) == std::endian::native);
  296|   534M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|   534M|         }
  298|   534M|      }
  299|   534M|   }());
  300|   534M|}
_ZN5Botan6detail24wrap_strong_type_or_enumITkNS0_20unsigned_integralishEjTkNSt3__117unsigned_integralEjEEDaT0_:
  200|   541M|constexpr auto wrap_strong_type_or_enum(T t) {
  201|       |   if constexpr(std::is_enum_v<OutT>) {
  202|       |      return static_cast<OutT>(t);
  203|   541M|   } else {
  204|   541M|      return Botan::wrap_strong_type<OutT>(t);
  205|   541M|   }
  206|   541M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEjTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm4EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|   534M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|   534M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 534M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|   534M|      } else {
  289|   534M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|       |         } else if constexpr(endianness == std::endian::native) {
  293|       |            return typecast_copy<OutT>(in);
  294|   534M|         } else {
  295|   534M|            static_assert(opposite(endianness) == std::endian::native);
  296|   534M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|   534M|         }
  298|   534M|      }
  299|   534M|   }());
_ZN5Botan11copy_out_beITkNS_6ranges14spanable_rangeEA8_jEEvNSt3__14spanIhLm18446744073709551615EEERKT_:
  773|  7.91M|inline void copy_out_be(std::span<uint8_t> out, const InR& in) {
  774|  7.91M|   using T = std::ranges::range_value_t<InR>;
  775|  7.91M|   std::span<const T> in_s{in};
  776|  7.91M|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::big>(out, in_s);
  777|       |
  778|       |   // copy remaining bytes as a partial word
  779|  7.91M|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (779:22): [True: 0, False: 7.91M]
  ------------------
  780|      0|      out[i] = get_byte_var(i, in_s.front());
  781|      0|   }
  782|  7.91M|}
_ZN5Botan6detail33copy_out_any_word_aligned_portionILNSt3__16endianE64206ETkNS0_20unsigned_integralishEjEEmRNS2_4spanIhLm18446744073709551615EEERNS4_IKT0_Lm18446744073709551615EEE:
  752|  7.96M|inline size_t copy_out_any_word_aligned_portion(std::span<uint8_t>& out, std::span<const T>& in) {
  753|  7.96M|   const size_t full_words = out.size() / sizeof(T);
  754|  7.96M|   const size_t full_word_bytes = full_words * sizeof(T);
  755|  7.96M|   const size_t remaining_bytes = out.size() - full_word_bytes;
  756|  7.96M|   BOTAN_ASSERT_NOMSG(in.size_bytes() >= full_word_bytes + remaining_bytes);
  ------------------
  |  |   77|  7.96M|   do {                                                                     \
  |  |   78|  7.96M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  7.96M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 7.96M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  7.96M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 7.96M]
  |  |  ------------------
  ------------------
  757|       |
  758|       |   // copy full words
  759|  7.96M|   store_any<endianness, T>(out.first(full_word_bytes), in.first(full_words));
  760|  7.96M|   out = out.subspan(full_word_bytes);
  761|  7.96M|   in = in.subspan(full_words);
  762|       |
  763|  7.96M|   return remaining_bytes;
  764|  7.96M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKjLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|  7.96M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|  7.96M|   ranges::assert_equal_byte_lengths(out, in);
  605|  7.96M|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|  7.96M|   auto store_elementwise = [&] {
  608|  7.96M|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  7.96M|      std::span<uint8_t> out_s(out);
  610|  7.96M|      for(auto in_elem : in) {
  611|  7.96M|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  7.96M|         out_s = out_s.subspan(bytes_per_element);
  613|  7.96M|      }
  614|  7.96M|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|  7.96M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 7.96M]
  ------------------
  620|      0|      store_elementwise();
  621|  7.96M|   } else {
  622|       |      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|       |         typecast_copy(out, in);
  624|  7.96M|      } else {
  625|  7.96M|         store_elementwise();
  626|  7.96M|      }
  627|  7.96M|   }
  628|  7.96M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKjLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_ENKUlvE_clEv:
  607|  7.96M|   auto store_elementwise = [&] {
  608|  7.96M|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  7.96M|      std::span<uint8_t> out_s(out);
  610|  43.6M|      for(auto in_elem : in) {
  ------------------
  |  Branch (610:24): [True: 43.6M, False: 7.96M]
  ------------------
  611|  43.6M|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  43.6M|         out_s = out_s.subspan(bytes_per_element);
  613|  43.6M|      }
  614|  7.96M|   };
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEETpTkNS0_20unsigned_integralishEJjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|  43.6M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|  43.6M|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|  43.6M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  43.6M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  43.6M|      off += sizeof(T);
  587|  43.6M|   };
  588|       |
  589|  43.6M|   (store_one(std::span{out}, ins), ...);
  590|  43.6M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm4EEETpTkNS0_20unsigned_integralishEJjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  43.6M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  43.6M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  43.6M|      off += sizeof(T);
  587|  43.6M|   };
_ZN5Botan7load_beIjJRPKhRmEEEDaDpOT0_:
  504|   101k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   101k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   101k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEjEET0_PKhm:
  454|  10.2M|inline constexpr OutT load_any(const uint8_t in[], size_t off) {
  455|       |   // asserts that *in points to enough bytes to read at offset off
  456|  10.2M|   constexpr size_t out_size = sizeof(OutT);
  457|  10.2M|   return load_any<endianness, OutT>(std::span<const uint8_t, out_size>(in + off * out_size, out_size));
  458|  10.2M|}
_ZN5Botan7load_beIjJRPKhiEEEDaDpOT0_:
  504|  9.64M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  9.64M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  9.64M|}
_ZN5Botan8store_beINS_6detail10AutoDetectEJRPhRjS5_S5_S5_S5_S5_S5_S5_EEEDaDpOT0_:
  745|   716k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   716k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   716k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTpTkNS0_20unsigned_integralishEJjjjjjjjEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|   716k|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|   716k|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|   716k|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|   716k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|   716k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|   716k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|   716k|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|   716k|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|   716k|      off += sizeof(T);
  587|   716k|   };
  588|       |
  589|   716k|   (store_one(std::span{out}, ins), ...);
  590|   716k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  5.72M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  5.72M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  5.72M|      off += sizeof(T);
  587|  5.72M|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJRPhRjS5_EEEDaDpOT0_:
  745|   850k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   850k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   850k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTpTkNS0_20unsigned_integralishEJjEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|   850k|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|   850k|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|   850k|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|   850k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|   850k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|   850k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|   850k|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|   850k|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|   850k|      off += sizeof(T);
  587|   850k|   };
  588|       |
  589|   850k|   (store_one(std::span{out}, ins), ...);
  590|   850k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  1.70M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  1.70M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  1.70M|      off += sizeof(T);
  587|  1.70M|   };
_ZN5Botan7load_beImJRPKhmEEEDaDpOT0_:
  504|  22.0M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  22.0M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  22.0M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmEET0_PKhm:
  454|  24.3M|inline constexpr OutT load_any(const uint8_t in[], size_t off) {
  455|       |   // asserts that *in points to enough bytes to read at offset off
  456|  24.3M|   constexpr size_t out_size = sizeof(OutT);
  457|  24.3M|   return load_any<endianness, OutT>(std::span<const uint8_t, out_size>(in + off * out_size, out_size));
  458|  24.3M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|   178M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|   178M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|   178M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|   178M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|   178M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|   178M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|   178M|      } else {
  289|   178M|         const std::span in{in_range};
  290|   178M|         if constexpr(sizeof(OutT) == 1) {
  291|   178M|            return static_cast<OutT>(in[0]);
  292|   178M|         } else if constexpr(endianness == std::endian::native) {
  293|   178M|            return typecast_copy<OutT>(in);
  294|   178M|         } else {
  295|   178M|            static_assert(opposite(endianness) == std::endian::native);
  296|   178M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|   178M|         }
  298|   178M|      }
  299|   178M|   }());
  300|   178M|}
_ZN5Botan6detail24wrap_strong_type_or_enumITkNS0_20unsigned_integralishEmTkNSt3__117unsigned_integralEmEEDaT0_:
  200|   189M|constexpr auto wrap_strong_type_or_enum(T t) {
  201|       |   if constexpr(std::is_enum_v<OutT>) {
  202|       |      return static_cast<OutT>(t);
  203|   189M|   } else {
  204|   189M|      return Botan::wrap_strong_type<OutT>(t);
  205|   189M|   }
  206|   189M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|   178M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|   178M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 178M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|   178M|      } else {
  289|   178M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|       |         } else if constexpr(endianness == std::endian::native) {
  293|       |            return typecast_copy<OutT>(in);
  294|   178M|         } else {
  295|   178M|            static_assert(opposite(endianness) == std::endian::native);
  296|   178M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|   178M|         }
  298|   178M|      }
  299|   178M|   }());
_ZN5Botan8store_beINS_6detail10AutoDetectEJPhRmS4_EEEDaDpOT0_:
  745|  11.0M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  11.0M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  11.0M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEmTpTkNS0_20unsigned_integralishEJmEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|  11.0M|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|  11.0M|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|  11.0M|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|  11.0M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJmmEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|  11.0M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|  11.0M|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|  11.0M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  11.0M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  11.0M|      off += sizeof(T);
  587|  11.0M|   };
  588|       |
  589|  11.0M|   (store_one(std::span{out}, ins), ...);
  590|  11.0M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJmmEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clImS7_EEDaS9_SE_:
  584|  22.0M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  22.0M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  22.0M|      off += sizeof(T);
  587|  22.0M|   };
_ZN5Botan7load_beImJPKhiEEEDaDpOT0_:
  504|  29.7k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  29.7k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  29.7k|}
_ZN5Botan7load_beINS_6detail10AutoDetectEJRPKhRjS6_S6_S6_EEEDaDpOT0_:
  504|   141k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   141k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   141k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJjjjjEQaaaagtsZT1_Li0E10all_same_vIDpT1_Eooaasr3stdE7same_asIS4_T0_E10all_same_vIS6_Eaa20unsigned_integralishIS7_E10all_same_vIS7_S6_EEEvPKhDpRS5_:
  469|   141k|inline constexpr void load_any(const uint8_t in[], Ts&... outs) {
  470|   141k|   constexpr auto bytes = (sizeof(outs) + ...);
  471|       |   // asserts that *in points to the correct amount of memory
  472|   141k|   load_any<endianness, OutT>(std::span<const uint8_t, bytes>(in, bytes), outs...);
  473|   141k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_:
  332|   141k|inline constexpr void load_any(const InR& in, Ts&... outs) {
  333|   141k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(in);
  334|   141k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   141k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   141k|      off += sizeof(T);
  337|   141k|   };
  338|       |
  339|   141k|   (load_one(std::span{in}, outs), ...);
  340|   141k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_ENUlTySA_RT_E_clIjS9_EEDaSA_SJ_:
  334|   564k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   564k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   564k|      off += sizeof(T);
  337|   564k|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJRPhRjS5_S5_S5_EEEDaDpOT0_:
  745|   836k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   836k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   836k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTpTkNS0_20unsigned_integralishEJjjjEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|   836k|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|   836k|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|   836k|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|   836k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|   836k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|   836k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|   836k|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|   836k|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|   836k|      off += sizeof(T);
  587|   836k|   };
  588|       |
  589|   836k|   (store_one(std::span{out}, ins), ...);
  590|   836k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  3.34M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  3.34M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  3.34M|      off += sizeof(T);
  587|  3.34M|   };
_ZN5Botan7load_beINS_6detail10AutoDetectEJRPKhRjS6_EEEDaDpOT0_:
  504|   283k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   283k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   283k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJjjEQaaaagtsZT1_Li0E10all_same_vIDpT1_Eooaasr3stdE7same_asIS4_T0_E10all_same_vIS6_Eaa20unsigned_integralishIS7_E10all_same_vIS7_S6_EEEvPKhDpRS5_:
  469|   283k|inline constexpr void load_any(const uint8_t in[], Ts&... outs) {
  470|   283k|   constexpr auto bytes = (sizeof(outs) + ...);
  471|       |   // asserts that *in points to the correct amount of memory
  472|   283k|   load_any<endianness, OutT>(std::span<const uint8_t, bytes>(in, bytes), outs...);
  473|   283k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEETpTkNS0_20unsigned_integralishEJjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_:
  332|   283k|inline constexpr void load_any(const InR& in, Ts&... outs) {
  333|   283k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(in);
  334|   283k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   283k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   283k|      off += sizeof(T);
  337|   283k|   };
  338|       |
  339|   283k|   (load_one(std::span{in}, outs), ...);
  340|   283k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEETpTkNS0_20unsigned_integralishEJjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_ENUlTySA_RT_E_clIjS9_EEDaSA_SJ_:
  334|   567k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   567k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   567k|      off += sizeof(T);
  337|   567k|   };
_ZN5Botan7load_beIjJPhRmEEEDaDpOT0_:
  504|  2.62k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  2.62k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  2.62k|}
_ZN5Botan7load_beImJRA32_mRPKhRmEEEDaDpOT0_:
  504|   544k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   544k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   544k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS0_20unsigned_integralishEmQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asIT1_S5_EEEvPS6_PKhm:
  483|   544k|inline constexpr void load_any(T out[], const uint8_t in[], size_t count) {
  484|       |   // asserts that *in and *out point to the correct amount of memory
  485|   544k|   load_any<endianness, OutT>(std::span<T>(out, count), std::span<const uint8_t>(in, count * sizeof(T)));
  486|   544k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeENS2_4spanImLm18446744073709551615EEETkNS4_16contiguous_rangeIhEENS5_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISH_EESI_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISP_SN_EEEvOSE_RKT2_:
  355|   544k|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|   544k|   ranges::assert_equal_byte_lengths(out, in);
  357|   544k|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|   544k|   auto load_elementwise = [&] {
  360|   544k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|   544k|      std::span<const uint8_t> in_s(in);
  362|   544k|      for(auto& out_elem : out) {
  363|   544k|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   544k|         in_s = in_s.subspan(bytes_per_element);
  365|   544k|      }
  366|   544k|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|   544k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 544k]
  ------------------
  372|      0|      load_elementwise();
  373|   544k|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|   544k|      } else {
  377|   544k|         load_elementwise();
  378|   544k|      }
  379|   544k|   }
  380|   544k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeENS2_4spanImLm18446744073709551615EEETkNS4_16contiguous_rangeIhEENS5_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISH_EESI_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISP_SN_EEEvOSE_RKT2_ENKUlvE_clEv:
  359|   544k|   auto load_elementwise = [&] {
  360|   544k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|   544k|      std::span<const uint8_t> in_s(in);
  362|  1.07M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 1.07M, False: 544k]
  ------------------
  363|  1.07M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  1.07M|         in_s = in_s.subspan(bytes_per_element);
  365|  1.07M|      }
  366|   544k|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJPhRmEEEDaDpOT0_:
  745|  1.07M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  1.07M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  1.07M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEmTpTkNS0_20unsigned_integralishEJEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|  1.07M|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|  1.07M|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|  1.07M|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|  1.07M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJmEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|  21.0M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|  21.0M|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|  21.0M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  21.0M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  21.0M|      off += sizeof(T);
  587|  21.0M|   };
  588|       |
  589|  21.0M|   (store_one(std::span{out}, ins), ...);
  590|  21.0M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJmEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clImS7_EEDaS9_SE_:
  584|  21.0M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  21.0M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  21.0M|      off += sizeof(T);
  587|  21.0M|   };
_ZN5Botan7load_beINS_6detail10AutoDetectEJPKhRtS5_S5_S5_EEEDaDpOT0_:
  504|  1.16M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  1.16M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  1.16M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJttttEQaaaagtsZT1_Li0E10all_same_vIDpT1_Eooaasr3stdE7same_asIS4_T0_E10all_same_vIS6_Eaa20unsigned_integralishIS7_E10all_same_vIS7_S6_EEEvPKhDpRS5_:
  469|  1.16M|inline constexpr void load_any(const uint8_t in[], Ts&... outs) {
  470|  1.16M|   constexpr auto bytes = (sizeof(outs) + ...);
  471|       |   // asserts that *in points to the correct amount of memory
  472|  1.16M|   load_any<endianness, OutT>(std::span<const uint8_t, bytes>(in, bytes), outs...);
  473|  1.16M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEETpTkNS0_20unsigned_integralishEJttttEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_:
  332|  1.16M|inline constexpr void load_any(const InR& in, Ts&... outs) {
  333|  1.16M|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(in);
  334|  1.16M|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|  1.16M|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|  1.16M|      off += sizeof(T);
  337|  1.16M|   };
  338|       |
  339|  1.16M|   (load_one(std::span{in}, outs), ...);
  340|  1.16M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEETpTkNS0_20unsigned_integralishEJttttEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_ENUlTySA_RT_E_clItS9_EEDaSA_SJ_:
  334|  4.65M|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|  4.65M|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|  4.65M|      off += sizeof(T);
  337|  4.65M|   };
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEtTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm2EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|  4.65M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|  4.65M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|  4.65M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|  4.65M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  4.65M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|  4.65M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  4.65M|      } else {
  289|  4.65M|         const std::span in{in_range};
  290|  4.65M|         if constexpr(sizeof(OutT) == 1) {
  291|  4.65M|            return static_cast<OutT>(in[0]);
  292|  4.65M|         } else if constexpr(endianness == std::endian::native) {
  293|  4.65M|            return typecast_copy<OutT>(in);
  294|  4.65M|         } else {
  295|  4.65M|            static_assert(opposite(endianness) == std::endian::native);
  296|  4.65M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  4.65M|         }
  298|  4.65M|      }
  299|  4.65M|   }());
  300|  4.65M|}
_ZN5Botan6detail24wrap_strong_type_or_enumITkNS0_20unsigned_integralishEtTkNSt3__117unsigned_integralEtEEDaT0_:
  200|  4.65M|constexpr auto wrap_strong_type_or_enum(T t) {
  201|       |   if constexpr(std::is_enum_v<OutT>) {
  202|       |      return static_cast<OutT>(t);
  203|  4.65M|   } else {
  204|  4.65M|      return Botan::wrap_strong_type<OutT>(t);
  205|  4.65M|   }
  206|  4.65M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEtTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm2EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|  4.65M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  4.65M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 4.65M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  4.65M|      } else {
  289|  4.65M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|       |         } else if constexpr(endianness == std::endian::native) {
  293|       |            return typecast_copy<OutT>(in);
  294|  4.65M|         } else {
  295|  4.65M|            static_assert(opposite(endianness) == std::endian::native);
  296|  4.65M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  4.65M|         }
  298|  4.65M|      }
  299|  4.65M|   }());
_ZN5Botan8store_beINS_6detail10AutoDetectEJPhRtS4_S4_S4_EEEDaDpOT0_:
  745|  1.16M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  1.16M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  1.16M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEtTpTkNS0_20unsigned_integralishEJtttEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|  1.16M|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|  1.16M|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|  1.16M|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|  1.16M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EtTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJttttEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|  1.16M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|  1.16M|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|  1.16M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  1.16M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  1.16M|      off += sizeof(T);
  587|  1.16M|   };
  588|       |
  589|  1.16M|   (store_one(std::span{out}, ins), ...);
  590|  1.16M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EtTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm8EEETpTkNS0_20unsigned_integralishEJttttEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clItS7_EEDaS9_SE_:
  584|  4.65M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  4.65M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  4.65M|      off += sizeof(T);
  587|  4.65M|   };
_ZN5Botan7load_beIjJPKhiEEEDaDpOT0_:
  504|  8.19k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  8.19k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  8.19k|}
_ZN5Botan7load_leINS_6detail10AutoDetectEJRPKhRjS6_S6_S6_S6_S6_S6_S6_EEEDaDpOT0_:
  495|   512k|inline constexpr auto load_le(ParamTs&&... params) {
  496|   512k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|   512k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaaaagtsZT1_Li0E10all_same_vIDpT1_Eooaasr3stdE7same_asIS4_T0_E10all_same_vIS6_Eaa20unsigned_integralishIS7_E10all_same_vIS7_S6_EEEvPKhDpRS5_:
  469|   512k|inline constexpr void load_any(const uint8_t in[], Ts&... outs) {
  470|   512k|   constexpr auto bytes = (sizeof(outs) + ...);
  471|       |   // asserts that *in points to the correct amount of memory
  472|   512k|   load_any<endianness, OutT>(std::span<const uint8_t, bytes>(in, bytes), outs...);
  473|   512k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_:
  332|   512k|inline constexpr void load_any(const InR& in, Ts&... outs) {
  333|   512k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(in);
  334|   512k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   512k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   512k|      off += sizeof(T);
  337|   512k|   };
  338|       |
  339|   512k|   (load_one(std::span{in}, outs), ...);
  340|   512k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_ENUlTySA_RT_E_clIjS9_EEDaSA_SJ_:
  334|  4.10M|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|  4.10M|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|  4.10M|      off += sizeof(T);
  337|  4.10M|   };
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEjTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm4EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|  6.93M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|  6.93M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|  6.93M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|  6.93M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  6.93M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|  6.93M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  6.93M|      } else {
  289|  6.93M|         const std::span in{in_range};
  290|  6.93M|         if constexpr(sizeof(OutT) == 1) {
  291|  6.93M|            return static_cast<OutT>(in[0]);
  292|  6.93M|         } else if constexpr(endianness == std::endian::native) {
  293|  6.93M|            return typecast_copy<OutT>(in);
  294|  6.93M|         } else {
  295|  6.93M|            static_assert(opposite(endianness) == std::endian::native);
  296|  6.93M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  6.93M|         }
  298|  6.93M|      }
  299|  6.93M|   }());
  300|  6.93M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEjTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm4EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|  6.93M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  6.93M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 6.93M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  6.93M|      } else {
  289|  6.93M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|  6.93M|         } else if constexpr(endianness == std::endian::native) {
  293|  6.93M|            return typecast_copy<OutT>(in);
  294|       |         } else {
  295|       |            static_assert(opposite(endianness) == std::endian::native);
  296|       |            return reverse_bytes(typecast_copy<OutT>(in));
  297|       |         }
  298|  6.93M|      }
  299|  6.93M|   }());
_ZN5Botan8store_leINS_6detail10AutoDetectEJRPhRjS5_S5_S5_S5_S5_S5_S5_EEEDaDpOT0_:
  736|   512k|inline constexpr auto store_le(ParamTs&&... params) {
  737|   512k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|   512k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTpTkNS0_20unsigned_integralishEJjjjjjjjEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|   512k|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|   512k|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|   512k|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|   512k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|   512k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|   512k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|   512k|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|   512k|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|   512k|      off += sizeof(T);
  587|   512k|   };
  588|       |
  589|   512k|   (store_one(std::span{out}, ins), ...);
  590|   512k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE57005EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm32EEETpTkNS0_20unsigned_integralishEJjjjjjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  4.10M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  4.10M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  4.10M|      off += sizeof(T);
  587|  4.10M|   };
_ZN5Botan7load_leINS_6detail10AutoDetectEJRPKhRjS6_S6_S6_EEEDaDpOT0_:
  495|   697k|inline constexpr auto load_le(ParamTs&&... params) {
  496|   697k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|   697k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJjjjjEQaaaagtsZT1_Li0E10all_same_vIDpT1_Eooaasr3stdE7same_asIS4_T0_E10all_same_vIS6_Eaa20unsigned_integralishIS7_E10all_same_vIS7_S6_EEEvPKhDpRS5_:
  469|   697k|inline constexpr void load_any(const uint8_t in[], Ts&... outs) {
  470|   697k|   constexpr auto bytes = (sizeof(outs) + ...);
  471|       |   // asserts that *in points to the correct amount of memory
  472|   697k|   load_any<endianness, OutT>(std::span<const uint8_t, bytes>(in, bytes), outs...);
  473|   697k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_:
  332|   697k|inline constexpr void load_any(const InR& in, Ts&... outs) {
  333|   697k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(in);
  334|   697k|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|   697k|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|   697k|      off += sizeof(T);
  337|   697k|   };
  338|       |
  339|   697k|   (load_one(std::span{in}, outs), ...);
  340|   697k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asIS4_T0_E10all_same_vIDpT2_Eaa20unsigned_integralishISA_E10all_same_vISA_SC_EEEvRKT1_DpRSB_ENUlTySA_RT_E_clIjS9_EEDaSA_SJ_:
  334|  2.79M|   auto load_one = [off = 0]<typename T>(auto i, T& o) mutable {
  335|  2.79M|      o = load_any<endianness, T>(i.subspan(off).template first<sizeof(T)>());
  336|  2.79M|      off += sizeof(T);
  337|  2.79M|   };
_ZN5Botan8store_leINS_6detail10AutoDetectEJRPhRjS5_S5_S5_EEEDaDpOT0_:
  736|   697k|inline constexpr auto store_le(ParamTs&&... params) {
  737|   697k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|   697k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEjTpTkNS0_20unsigned_integralishEJjjjEQaaoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_E10all_same_vIS6_DpT2_EEEvPhS6_S8_:
  723|   697k|inline constexpr void store_any(uint8_t out[], T0 in0, Ts... ins) {
  724|   697k|   constexpr auto bytes = sizeof(in0) + (sizeof(ins) + ... + 0);
  725|       |   // asserts that *out points to the correct amount of memory
  726|   697k|   store_any<endianness, T0>(std::span<uint8_t, bytes>(out, bytes), in0, ins...);
  727|   697k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_:
  582|   697k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, Ts... ins) {
  583|   697k|   ranges::assert_exact_byte_length<(sizeof(Ts) + ...)>(out);
  584|   697k|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|   697k|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|   697k|      off += sizeof(T);
  587|   697k|   };
  588|       |
  589|   697k|   (store_one(std::span{out}, ins), ...);
  590|   697k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE57005EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm16EEETpTkNS0_20unsigned_integralishEJjjjjEQaagtsZT2_Li0Eooaasr3stdE7same_asINS0_10AutoDetectET0_E10all_same_vIDpT2_Eaa20unsigned_integralishIS9_E10all_same_vIS9_SB_EEEvOT1_SB_ENUlTyS9_T_E_clIjS7_EEDaS9_SE_:
  584|  2.79M|   auto store_one = [off = 0]<typename T>(auto o, T i) mutable {
  585|  2.79M|      store_any<endianness, T>(i, o.subspan(off).template first<sizeof(T)>());
  586|  2.79M|      off += sizeof(T);
  587|  2.79M|   };
_ZN5Botan7load_leINS_6detail10AutoDetectEJRA16_mRPKhiEEEDaDpOT0_:
  495|   427k|inline constexpr auto load_le(ParamTs&&... params) {
  496|   427k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|   427k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEmQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvPS6_PKhm:
  483|   852k|inline constexpr void load_any(T out[], const uint8_t in[], size_t count) {
  484|       |   // asserts that *in and *out point to the correct amount of memory
  485|   852k|   load_any<endianness, OutT>(std::span<T>(out, count), std::span<const uint8_t>(in, count * sizeof(T)));
  486|   852k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanImLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_:
  355|   852k|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|   852k|   ranges::assert_equal_byte_lengths(out, in);
  357|   852k|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|   852k|   auto load_elementwise = [&] {
  360|   852k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|   852k|      std::span<const uint8_t> in_s(in);
  362|   852k|      for(auto& out_elem : out) {
  363|   852k|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   852k|         in_s = in_s.subspan(bytes_per_element);
  365|   852k|      }
  366|   852k|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|   852k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 852k]
  ------------------
  372|      0|      load_elementwise();
  373|   852k|   } else {
  374|   852k|      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|   852k|         typecast_copy(out, in);
  376|       |      } else {
  377|       |         load_elementwise();
  378|       |      }
  379|   852k|   }
  380|   852k|}
_ZN5Botan11copy_out_leITkNS_6ranges14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEEEEvNS2_4spanIhLm18446744073709551615EEERKT_:
  789|   425k|inline void copy_out_le(std::span<uint8_t> out, const InR& in) {
  790|   425k|   using T = std::ranges::range_value_t<InR>;
  791|   425k|   std::span<const T> in_s{in};
  792|   425k|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::little>(out, in_s);
  793|       |
  794|       |   // copy remaining bytes as a partial word
  795|   425k|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (795:22): [True: 0, False: 425k]
  ------------------
  796|      0|      out[i] = get_byte_var(sizeof(T) - 1 - i, in_s.front());
  797|      0|   }
  798|   425k|}
_ZN5Botan6detail33copy_out_any_word_aligned_portionILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmEEmRNS2_4spanIhLm18446744073709551615EEERNS4_IKT0_Lm18446744073709551615EEE:
  752|   425k|inline size_t copy_out_any_word_aligned_portion(std::span<uint8_t>& out, std::span<const T>& in) {
  753|   425k|   const size_t full_words = out.size() / sizeof(T);
  754|   425k|   const size_t full_word_bytes = full_words * sizeof(T);
  755|   425k|   const size_t remaining_bytes = out.size() - full_word_bytes;
  756|   425k|   BOTAN_ASSERT_NOMSG(in.size_bytes() >= full_word_bytes + remaining_bytes);
  ------------------
  |  |   77|   425k|   do {                                                                     \
  |  |   78|   425k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   425k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 425k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   425k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 425k]
  |  |  ------------------
  ------------------
  757|       |
  758|       |   // copy full words
  759|   425k|   store_any<endianness, T>(out.first(full_word_bytes), in.first(full_words));
  760|   425k|   out = out.subspan(full_word_bytes);
  761|   425k|   in = in.subspan(full_words);
  762|       |
  763|   425k|   return remaining_bytes;
  764|   425k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKmLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|   425k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|   425k|   ranges::assert_equal_byte_lengths(out, in);
  605|   425k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|   425k|   auto store_elementwise = [&] {
  608|   425k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|   425k|      std::span<uint8_t> out_s(out);
  610|   425k|      for(auto in_elem : in) {
  611|   425k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|   425k|         out_s = out_s.subspan(bytes_per_element);
  613|   425k|      }
  614|   425k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|   425k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 425k]
  ------------------
  620|      0|      store_elementwise();
  621|   425k|   } else {
  622|   425k|      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|   425k|         typecast_copy(out, in);
  624|       |      } else {
  625|       |         store_elementwise();
  626|       |      }
  627|   425k|   }
  628|   425k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|  6.90M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|  6.90M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|  6.90M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|  6.90M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  6.90M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|  6.90M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  6.90M|      } else {
  289|  6.90M|         const std::span in{in_range};
  290|  6.90M|         if constexpr(sizeof(OutT) == 1) {
  291|  6.90M|            return static_cast<OutT>(in[0]);
  292|  6.90M|         } else if constexpr(endianness == std::endian::native) {
  293|  6.90M|            return typecast_copy<OutT>(in);
  294|  6.90M|         } else {
  295|  6.90M|            static_assert(opposite(endianness) == std::endian::native);
  296|  6.90M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  6.90M|         }
  298|  6.90M|      }
  299|  6.90M|   }());
  300|  6.90M|}
_ZN5Botan7load_leINS_6detail10AutoDetectEJRA4_jPKhiEEEDaDpOT0_:
  495|  7.22M|inline constexpr auto load_le(ParamTs&&... params) {
  496|  7.22M|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  7.22M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS0_20unsigned_integralishEjQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvPS6_PKhm:
  483|  7.22M|inline constexpr void load_any(T out[], const uint8_t in[], size_t count) {
  484|       |   // asserts that *in and *out point to the correct amount of memory
  485|  7.22M|   load_any<endianness, OutT>(std::span<T>(out, count), std::span<const uint8_t>(in, count * sizeof(T)));
  486|  7.22M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanIjLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_:
  355|  7.22M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  7.22M|   ranges::assert_equal_byte_lengths(out, in);
  357|  7.22M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  7.22M|   auto load_elementwise = [&] {
  360|  7.22M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  7.22M|      std::span<const uint8_t> in_s(in);
  362|  7.22M|      for(auto& out_elem : out) {
  363|  7.22M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  7.22M|         in_s = in_s.subspan(bytes_per_element);
  365|  7.22M|      }
  366|  7.22M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  7.22M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 7.22M]
  ------------------
  372|      0|      load_elementwise();
  373|  7.22M|   } else {
  374|  7.22M|      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|  7.22M|         typecast_copy(out, in);
  376|       |      } else {
  377|       |         load_elementwise();
  378|       |      }
  379|  7.22M|   }
  380|  7.22M|}
_ZN5Botan7load_leINS_6detail10AutoDetectEJRNSt3__15arrayIjLm16EEENS3_4spanIKhLm64EEEEEEDaDpOT0_:
  495|  4.82M|inline constexpr auto load_le(ParamTs&&... params) {
  496|  4.82M|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  4.82M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_5arrayIjLm16EEETkNS5_16contiguous_rangeIhEENS2_4spanIKhLm64EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISR_SQ_EEEvOSH_RKT2_:
  355|  4.82M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  4.82M|   ranges::assert_equal_byte_lengths(out, in);
  357|  4.82M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  4.82M|   auto load_elementwise = [&] {
  360|  4.82M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  4.82M|      std::span<const uint8_t> in_s(in);
  362|  4.82M|      for(auto& out_elem : out) {
  363|  4.82M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  4.82M|         in_s = in_s.subspan(bytes_per_element);
  365|  4.82M|      }
  366|  4.82M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  4.82M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 4.82M]
  ------------------
  372|      0|      load_elementwise();
  373|  4.82M|   } else {
  374|  4.82M|      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|  4.82M|         typecast_copy(out, in);
  376|       |      } else {
  377|       |         load_elementwise();
  378|       |      }
  379|  4.82M|   }
  380|  4.82M|}
_ZN5Botan8store_leINS_6detail10AutoDetectEJRKmPhEEEDaDpOT0_:
  736|  20.5k|inline constexpr auto store_le(ParamTs&&... params) {
  737|  20.5k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|  20.5k|}
_ZN5Botan11copy_out_leITkNS_6ranges14spanable_rangeENSt3__16vectorIjNS_16secure_allocatorIjEEEEEEvNS2_4spanIhLm18446744073709551615EEERKT_:
  789|  20.5k|inline void copy_out_le(std::span<uint8_t> out, const InR& in) {
  790|  20.5k|   using T = std::ranges::range_value_t<InR>;
  791|  20.5k|   std::span<const T> in_s{in};
  792|  20.5k|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::little>(out, in_s);
  793|       |
  794|       |   // copy remaining bytes as a partial word
  795|  20.5k|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (795:22): [True: 0, False: 20.5k]
  ------------------
  796|      0|      out[i] = get_byte_var(sizeof(T) - 1 - i, in_s.front());
  797|      0|   }
  798|  20.5k|}
_ZN5Botan6detail33copy_out_any_word_aligned_portionILNSt3__16endianE57005ETkNS0_20unsigned_integralishEjEEmRNS2_4spanIhLm18446744073709551615EEERNS4_IKT0_Lm18446744073709551615EEE:
  752|  20.5k|inline size_t copy_out_any_word_aligned_portion(std::span<uint8_t>& out, std::span<const T>& in) {
  753|  20.5k|   const size_t full_words = out.size() / sizeof(T);
  754|  20.5k|   const size_t full_word_bytes = full_words * sizeof(T);
  755|  20.5k|   const size_t remaining_bytes = out.size() - full_word_bytes;
  756|  20.5k|   BOTAN_ASSERT_NOMSG(in.size_bytes() >= full_word_bytes + remaining_bytes);
  ------------------
  |  |   77|  20.5k|   do {                                                                     \
  |  |   78|  20.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  20.5k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 20.5k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  20.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 20.5k]
  |  |  ------------------
  ------------------
  757|       |
  758|       |   // copy full words
  759|  20.5k|   store_any<endianness, T>(out.first(full_word_bytes), in.first(full_words));
  760|  20.5k|   out = out.subspan(full_word_bytes);
  761|  20.5k|   in = in.subspan(full_words);
  762|       |
  763|  20.5k|   return remaining_bytes;
  764|  20.5k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005EjTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKjLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|  20.5k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|  20.5k|   ranges::assert_equal_byte_lengths(out, in);
  605|  20.5k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|  20.5k|   auto store_elementwise = [&] {
  608|  20.5k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  20.5k|      std::span<uint8_t> out_s(out);
  610|  20.5k|      for(auto in_elem : in) {
  611|  20.5k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  20.5k|         out_s = out_s.subspan(bytes_per_element);
  613|  20.5k|      }
  614|  20.5k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|  20.5k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 20.5k]
  ------------------
  620|      0|      store_elementwise();
  621|  20.5k|   } else {
  622|  20.5k|      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|  20.5k|         typecast_copy(out, in);
  624|       |      } else {
  625|       |         store_elementwise();
  626|       |      }
  627|  20.5k|   }
  628|  20.5k|}
_ZN5Botan7load_beINS_6detail10AutoDetectEJRNSt3__14spanIjLm16EEENS4_IKhLm64EEEEEEDaDpOT0_:
  504|  23.4M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  23.4M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  23.4M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_4spanIjLm16EEETkNS5_16contiguous_rangeIhEENS6_IKhLm64EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISQ_SP_EEEvOSG_RKT2_:
  355|  23.4M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  23.4M|   ranges::assert_equal_byte_lengths(out, in);
  357|  23.4M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  23.4M|   auto load_elementwise = [&] {
  360|  23.4M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  23.4M|      std::span<const uint8_t> in_s(in);
  362|  23.4M|      for(auto& out_elem : out) {
  363|  23.4M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  23.4M|         in_s = in_s.subspan(bytes_per_element);
  365|  23.4M|      }
  366|  23.4M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  23.4M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 23.4M]
  ------------------
  372|      0|      load_elementwise();
  373|  23.4M|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  23.4M|      } else {
  377|  23.4M|         load_elementwise();
  378|  23.4M|      }
  379|  23.4M|   }
  380|  23.4M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_4spanIjLm16EEETkNS5_16contiguous_rangeIhEENS6_IKhLm64EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISQ_SP_EEEvOSG_RKT2_ENKUlvE_clEv:
  359|  23.4M|   auto load_elementwise = [&] {
  360|  23.4M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  23.4M|      std::span<const uint8_t> in_s(in);
  362|   375M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 375M, False: 23.4M]
  ------------------
  363|   375M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   375M|         in_s = in_s.subspan(bytes_per_element);
  365|   375M|      }
  366|  23.4M|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJRKmPhEEEDaDpOT0_:
  745|  2.40M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  2.40M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  2.40M|}
_ZN5Botan11copy_out_beITkNS_6ranges14spanable_rangeENSt3__16vectorIjNS_16secure_allocatorIjEEEEEEvNS2_4spanIhLm18446744073709551615EEERKT_:
  773|  48.1k|inline void copy_out_be(std::span<uint8_t> out, const InR& in) {
  774|  48.1k|   using T = std::ranges::range_value_t<InR>;
  775|  48.1k|   std::span<const T> in_s{in};
  776|  48.1k|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::big>(out, in_s);
  777|       |
  778|       |   // copy remaining bytes as a partial word
  779|  48.1k|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (779:22): [True: 0, False: 48.1k]
  ------------------
  780|      0|      out[i] = get_byte_var(i, in_s.front());
  781|      0|   }
  782|  48.1k|}
_ZN5Botan7load_beINS_6detail10AutoDetectEJRNSt3__15arrayIjLm16EEENS3_4spanIKhLm64EEEEEEDaDpOT0_:
  504|  6.51M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  6.51M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  6.51M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_5arrayIjLm16EEETkNS5_16contiguous_rangeIhEENS2_4spanIKhLm64EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISR_SQ_EEEvOSH_RKT2_:
  355|  6.51M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  6.51M|   ranges::assert_equal_byte_lengths(out, in);
  357|  6.51M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  6.51M|   auto load_elementwise = [&] {
  360|  6.51M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  6.51M|      std::span<const uint8_t> in_s(in);
  362|  6.51M|      for(auto& out_elem : out) {
  363|  6.51M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  6.51M|         in_s = in_s.subspan(bytes_per_element);
  365|  6.51M|      }
  366|  6.51M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  6.51M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 6.51M]
  ------------------
  372|      0|      load_elementwise();
  373|  6.51M|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  6.51M|      } else {
  377|  6.51M|         load_elementwise();
  378|  6.51M|      }
  379|  6.51M|   }
  380|  6.51M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_5arrayIjLm16EEETkNS5_16contiguous_rangeIhEENS2_4spanIKhLm64EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISR_SQ_EEEvOSH_RKT2_ENKUlvE_clEv:
  359|  6.51M|   auto load_elementwise = [&] {
  360|  6.51M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  6.51M|      std::span<const uint8_t> in_s(in);
  362|   104M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 104M, False: 6.51M]
  ------------------
  363|   104M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   104M|         in_s = in_s.subspan(bytes_per_element);
  365|   104M|      }
  366|  6.51M|   };
_ZN5Botan7load_beINS_6detail10AutoDetectEJRNSt3__15arrayImLm16EEENS3_4spanIKhLm128EEEEEEDaDpOT0_:
  504|  9.21M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  9.21M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  9.21M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm16EEETkNS5_16contiguous_rangeIhEENS2_4spanIKhLm128EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISR_SQ_EEEvOSH_RKT2_:
  355|  9.21M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  9.21M|   ranges::assert_equal_byte_lengths(out, in);
  357|  9.21M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  9.21M|   auto load_elementwise = [&] {
  360|  9.21M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  9.21M|      std::span<const uint8_t> in_s(in);
  362|  9.21M|      for(auto& out_elem : out) {
  363|  9.21M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  9.21M|         in_s = in_s.subspan(bytes_per_element);
  365|  9.21M|      }
  366|  9.21M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  9.21M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 9.21M]
  ------------------
  372|      0|      load_elementwise();
  373|  9.21M|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  9.21M|      } else {
  377|  9.21M|         load_elementwise();
  378|  9.21M|      }
  379|  9.21M|   }
  380|  9.21M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm16EEETkNS5_16contiguous_rangeIhEENS2_4spanIKhLm128EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISR_SQ_EEEvOSH_RKT2_ENKUlvE_clEv:
  359|  9.21M|   auto load_elementwise = [&] {
  360|  9.21M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  9.21M|      std::span<const uint8_t> in_s(in);
  362|   147M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 147M, False: 9.21M]
  ------------------
  363|   147M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   147M|         in_s = in_s.subspan(bytes_per_element);
  365|   147M|      }
  366|  9.21M|   };
_ZN5Botan11copy_out_beITkNS_6ranges14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEEEEvNS2_4spanIhLm18446744073709551615EEERKT_:
  773|  2.30M|inline void copy_out_be(std::span<uint8_t> out, const InR& in) {
  774|  2.30M|   using T = std::ranges::range_value_t<InR>;
  775|  2.30M|   std::span<const T> in_s{in};
  776|  2.30M|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::big>(out, in_s);
  777|       |
  778|       |   // copy remaining bytes as a partial word
  779|  2.30M|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (779:22): [True: 0, False: 2.30M]
  ------------------
  780|      0|      out[i] = get_byte_var(i, in_s.front());
  781|      0|   }
  782|  2.30M|}
_ZN5Botan6detail33copy_out_any_word_aligned_portionILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmEEmRNS2_4spanIhLm18446744073709551615EEERNS4_IKT0_Lm18446744073709551615EEE:
  752|  2.37M|inline size_t copy_out_any_word_aligned_portion(std::span<uint8_t>& out, std::span<const T>& in) {
  753|  2.37M|   const size_t full_words = out.size() / sizeof(T);
  754|  2.37M|   const size_t full_word_bytes = full_words * sizeof(T);
  755|  2.37M|   const size_t remaining_bytes = out.size() - full_word_bytes;
  756|  2.37M|   BOTAN_ASSERT_NOMSG(in.size_bytes() >= full_word_bytes + remaining_bytes);
  ------------------
  |  |   77|  2.37M|   do {                                                                     \
  |  |   78|  2.37M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.37M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.37M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.37M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.37M]
  |  |  ------------------
  ------------------
  757|       |
  758|       |   // copy full words
  759|  2.37M|   store_any<endianness, T>(out.first(full_word_bytes), in.first(full_words));
  760|  2.37M|   out = out.subspan(full_word_bytes);
  761|  2.37M|   in = in.subspan(full_words);
  762|       |
  763|  2.37M|   return remaining_bytes;
  764|  2.37M|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKmLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|  2.37M|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|  2.37M|   ranges::assert_equal_byte_lengths(out, in);
  605|  2.37M|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|  2.37M|   auto store_elementwise = [&] {
  608|  2.37M|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  2.37M|      std::span<uint8_t> out_s(out);
  610|  2.37M|      for(auto in_elem : in) {
  611|  2.37M|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  2.37M|         out_s = out_s.subspan(bytes_per_element);
  613|  2.37M|      }
  614|  2.37M|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|  2.37M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 2.37M]
  ------------------
  620|      0|      store_elementwise();
  621|  2.37M|   } else {
  622|       |      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|       |         typecast_copy(out, in);
  624|  2.37M|      } else {
  625|  2.37M|         store_elementwise();
  626|  2.37M|      }
  627|  2.37M|   }
  628|  2.37M|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEENS2_4spanIhLm18446744073709551615EEETkNS4_14spanable_rangeENS6_IKmLm18446744073709551615EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_ENKUlvE_clEv:
  607|  2.37M|   auto store_elementwise = [&] {
  608|  2.37M|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  2.37M|      std::span<uint8_t> out_s(out);
  610|  18.5M|      for(auto in_elem : in) {
  ------------------
  |  Branch (610:24): [True: 18.5M, False: 2.37M]
  ------------------
  611|  18.5M|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  18.5M|         out_s = out_s.subspan(bytes_per_element);
  613|  18.5M|      }
  614|  2.37M|   };
_ZN5Botan7load_beImJNSt3__14spanIKhLm8EEEEEEDaDpOT0_:
  504|   176k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   176k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   176k|}
_ZN5Botan7load_beImJRNSt3__15arrayIhLm8EEEEEEDaDpOT0_:
  504|  4.87k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  4.87k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  4.87k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|  4.87k|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|  4.87k|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|  4.87k|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|  4.87k|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  4.87k|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|  4.87k|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  4.87k|      } else {
  289|  4.87k|         const std::span in{in_range};
  290|  4.87k|         if constexpr(sizeof(OutT) == 1) {
  291|  4.87k|            return static_cast<OutT>(in[0]);
  292|  4.87k|         } else if constexpr(endianness == std::endian::native) {
  293|  4.87k|            return typecast_copy<OutT>(in);
  294|  4.87k|         } else {
  295|  4.87k|            static_assert(opposite(endianness) == std::endian::native);
  296|  4.87k|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  4.87k|         }
  298|  4.87k|      }
  299|  4.87k|   }());
  300|  4.87k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|  4.87k|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  4.87k|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 4.87k]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  4.87k|      } else {
  289|  4.87k|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|       |         } else if constexpr(endianness == std::endian::native) {
  293|       |            return typecast_copy<OutT>(in);
  294|  4.87k|         } else {
  295|  4.87k|            static_assert(opposite(endianness) == std::endian::native);
  296|  4.87k|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  4.87k|         }
  298|  4.87k|      }
  299|  4.87k|   }());
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEjEET0_PKhm:
  454|  45.5k|inline constexpr OutT load_any(const uint8_t in[], size_t off) {
  455|       |   // asserts that *in points to enough bytes to read at offset off
  456|  45.5k|   constexpr size_t out_size = sizeof(OutT);
  457|  45.5k|   return load_any<endianness, OutT>(std::span<const uint8_t, out_size>(in + off * out_size, out_size));
  458|  45.5k|}
_ZN5Botan7load_beImJPKhmEEEDaDpOT0_:
  504|   174k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   174k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   174k|}
_ZN5Botan8store_beINS_6detail10AutoDetectEJRNSt3__14spanIhLm32EEERNS3_5arrayImLm4EEEEEEDaDpOT0_:
  745|  43.5k|inline constexpr auto store_be(ParamTs&&... params) {
  746|  43.5k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  43.5k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeIhEERNS2_4spanIhLm32EEETkNS5_14spanable_rangeENS2_5arrayImLm4EEEQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISC_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEEEvOT1_RKSH_:
  603|  43.5k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|  43.5k|   ranges::assert_equal_byte_lengths(out, in);
  605|  43.5k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|  43.5k|   auto store_elementwise = [&] {
  608|  43.5k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  43.5k|      std::span<uint8_t> out_s(out);
  610|  43.5k|      for(auto in_elem : in) {
  611|  43.5k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  43.5k|         out_s = out_s.subspan(bytes_per_element);
  613|  43.5k|      }
  614|  43.5k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|  43.5k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 43.5k]
  ------------------
  620|      0|      store_elementwise();
  621|  43.5k|   } else {
  622|       |      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|       |         typecast_copy(out, in);
  624|  43.5k|      } else {
  625|  43.5k|         store_elementwise();
  626|  43.5k|      }
  627|  43.5k|   }
  628|  43.5k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeIhEERNS2_4spanIhLm32EEETkNS5_14spanable_rangeENS2_5arrayImLm4EEEQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISC_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEEEvOT1_RKSH_ENKUlvE_clEv:
  607|  43.5k|   auto store_elementwise = [&] {
  608|  43.5k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  43.5k|      std::span<uint8_t> out_s(out);
  610|   174k|      for(auto in_elem : in) {
  ------------------
  |  Branch (610:24): [True: 174k, False: 43.5k]
  ------------------
  611|   174k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|   174k|         out_s = out_s.subspan(bytes_per_element);
  613|   174k|      }
  614|  43.5k|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJRmPhEEEDaDpOT0_:
  745|  8.50M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  8.50M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  8.50M|}
_ZN5Botan7load_beImJPhiEEEDaDpOT0_:
  504|  2.07M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  2.07M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  2.07M|}
_ZN5Botan7load_leINS_6detail10AutoDetectEJPmRA64_hiEEEDaDpOT0_:
  495|   425k|inline constexpr auto load_le(ParamTs&&... params) {
  496|   425k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|   425k|}
_ZN5Botan7load_leINS_6detail10AutoDetectEJRNSt3__15arrayIhLm8EEEEEEDaDpOT0_:
  495|  3.30M|inline constexpr auto load_le(ParamTs&&... params) {
  496|  3.30M|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  3.30M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQoosr3stdE7same_asIS4_T0_Eaaoosr6rangesE25statically_spanable_rangeISA_Esr8conceptsE19resizable_containerISA_E20unsigned_integralishINSA_10value_typeEEEEDaOT1_:
  397|  3.30M|inline constexpr auto load_any(InR&& in_range) {
  398|  3.30M|   auto out = []([[maybe_unused]] const auto& in) {
  399|  3.30M|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  3.30M|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  3.30M|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  3.30M|            using type =
  405|  3.30M|               std::conditional_t<extent == 1, uint8_t,
  406|  3.30M|               std::conditional_t<extent == 2, uint16_t,
  407|  3.30M|               std::conditional_t<extent == 4, uint32_t,
  408|  3.30M|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  3.30M|            static_assert(
  412|  3.30M|               !std::is_void_v<type>,
  413|  3.30M|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  3.30M|            return type{};
  416|  3.30M|         } else {
  417|  3.30M|            static_assert(
  418|  3.30M|               !std::same_as<AutoDetect, OutT>,
  419|  3.30M|               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|  3.30M|         }
  421|  3.30M|      } else if constexpr(concepts::resizable_container<OutT>) {
  422|  3.30M|         const size_t in_bytes = std::span{in}.size_bytes();
  423|  3.30M|         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|  3.30M|         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|  3.30M|                         "Input range is not word-aligned with the requested output range");
  426|  3.30M|         return OutT(in_bytes / out_elem_bytes);
  427|  3.30M|      } else {
  428|  3.30M|         return OutT{};
  429|  3.30M|      }
  430|  3.30M|   }(in_range);
  431|       |
  432|  3.30M|   using out_type = decltype(out);
  433|  3.30M|   if constexpr(unsigned_integralish<out_type>) {
  434|  3.30M|      out = load_any<endianness, out_type>(std::forward<InR>(in_range));
  435|       |   } else {
  436|       |      static_assert(ranges::contiguous_range<out_type>);
  437|       |      using out_range_type = std::ranges::range_value_t<out_type>;
  438|       |      load_any<endianness, out_range_type>(out, std::forward<InR>(in_range));
  439|       |   }
  440|  3.30M|   return out;
  441|  3.30M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQoosr3stdE7same_asIS4_T0_Eaaoosr6rangesE25statically_spanable_rangeISA_Esr8conceptsE19resizable_containerISA_E20unsigned_integralishINSA_10value_typeEEEEDaOT1_ENKUlRKT_E_clIS8_EEDaSG_:
  398|  3.30M|   auto out = []([[maybe_unused]] const auto& in) {
  399|  3.30M|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  3.30M|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  3.30M|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  3.30M|            using type =
  405|  3.30M|               std::conditional_t<extent == 1, uint8_t,
  406|  3.30M|               std::conditional_t<extent == 2, uint16_t,
  407|  3.30M|               std::conditional_t<extent == 4, uint32_t,
  408|  3.30M|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  3.30M|            static_assert(
  412|  3.30M|               !std::is_void_v<type>,
  413|  3.30M|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  3.30M|            return type{};
  416|       |         } else {
  417|       |            static_assert(
  418|       |               !std::same_as<AutoDetect, OutT>,
  419|       |               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|       |         }
  421|       |      } else if constexpr(concepts::resizable_container<OutT>) {
  422|       |         const size_t in_bytes = std::span{in}.size_bytes();
  423|       |         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|       |         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|       |                         "Input range is not word-aligned with the requested output range");
  426|       |         return OutT(in_bytes / out_elem_bytes);
  427|       |      } else {
  428|       |         return OutT{};
  429|       |      }
  430|  3.30M|   }(in_range);
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_:
  278|  3.30M|inline constexpr WrappedOutT load_any(InR&& in_range) {
  279|  3.30M|   using OutT = detail::wrapped_type<WrappedOutT>;
  280|  3.30M|   ranges::assert_exact_byte_length<sizeof(OutT)>(in_range);
  281|       |
  282|  3.30M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  3.30M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  287|  3.30M|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  3.30M|      } else {
  289|  3.30M|         const std::span in{in_range};
  290|  3.30M|         if constexpr(sizeof(OutT) == 1) {
  291|  3.30M|            return static_cast<OutT>(in[0]);
  292|  3.30M|         } else if constexpr(endianness == std::endian::native) {
  293|  3.30M|            return typecast_copy<OutT>(in);
  294|  3.30M|         } else {
  295|  3.30M|            static_assert(opposite(endianness) == std::endian::native);
  296|  3.30M|            return reverse_bytes(typecast_copy<OutT>(in));
  297|  3.30M|         }
  298|  3.30M|      }
  299|  3.30M|   }());
  300|  3.30M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEERNS2_5arrayIhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|  3.30M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  3.30M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 3.30M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  3.30M|      } else {
  289|  3.30M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|  3.30M|         } else if constexpr(endianness == std::endian::native) {
  293|  3.30M|            return typecast_copy<OutT>(in);
  294|       |         } else {
  295|       |            static_assert(opposite(endianness) == std::endian::native);
  296|       |            return reverse_bytes(typecast_copy<OutT>(in));
  297|       |         }
  298|  3.30M|      }
  299|  3.30M|   }());
_ZN5Botan7load_leINS_6detail10AutoDetectEJNSt3__14spanIKhLm8EEEEEEDaDpOT0_:
  495|  6.89M|inline constexpr auto load_le(ParamTs&&... params) {
  496|  6.89M|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  6.89M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQoosr3stdE7same_asIS4_T0_Eaaoosr6rangesE25statically_spanable_rangeISA_Esr8conceptsE19resizable_containerISA_E20unsigned_integralishINSA_10value_typeEEEEDaOT1_:
  397|  6.89M|inline constexpr auto load_any(InR&& in_range) {
  398|  6.89M|   auto out = []([[maybe_unused]] const auto& in) {
  399|  6.89M|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  6.89M|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  6.89M|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  6.89M|            using type =
  405|  6.89M|               std::conditional_t<extent == 1, uint8_t,
  406|  6.89M|               std::conditional_t<extent == 2, uint16_t,
  407|  6.89M|               std::conditional_t<extent == 4, uint32_t,
  408|  6.89M|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  6.89M|            static_assert(
  412|  6.89M|               !std::is_void_v<type>,
  413|  6.89M|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  6.89M|            return type{};
  416|  6.89M|         } else {
  417|  6.89M|            static_assert(
  418|  6.89M|               !std::same_as<AutoDetect, OutT>,
  419|  6.89M|               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|  6.89M|         }
  421|  6.89M|      } else if constexpr(concepts::resizable_container<OutT>) {
  422|  6.89M|         const size_t in_bytes = std::span{in}.size_bytes();
  423|  6.89M|         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|  6.89M|         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|  6.89M|                         "Input range is not word-aligned with the requested output range");
  426|  6.89M|         return OutT(in_bytes / out_elem_bytes);
  427|  6.89M|      } else {
  428|  6.89M|         return OutT{};
  429|  6.89M|      }
  430|  6.89M|   }(in_range);
  431|       |
  432|  6.89M|   using out_type = decltype(out);
  433|  6.89M|   if constexpr(unsigned_integralish<out_type>) {
  434|  6.89M|      out = load_any<endianness, out_type>(std::forward<InR>(in_range));
  435|       |   } else {
  436|       |      static_assert(ranges::contiguous_range<out_type>);
  437|       |      using out_range_type = std::ranges::range_value_t<out_type>;
  438|       |      load_any<endianness, out_range_type>(out, std::forward<InR>(in_range));
  439|       |   }
  440|  6.89M|   return out;
  441|  6.89M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQoosr3stdE7same_asIS4_T0_Eaaoosr6rangesE25statically_spanable_rangeISA_Esr8conceptsE19resizable_containerISA_E20unsigned_integralishINSA_10value_typeEEEEDaOT1_ENKUlRKT_E_clIS9_EEDaSG_:
  398|  6.89M|   auto out = []([[maybe_unused]] const auto& in) {
  399|  6.89M|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  6.89M|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  6.89M|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  6.89M|            using type =
  405|  6.89M|               std::conditional_t<extent == 1, uint8_t,
  406|  6.89M|               std::conditional_t<extent == 2, uint16_t,
  407|  6.89M|               std::conditional_t<extent == 4, uint32_t,
  408|  6.89M|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  6.89M|            static_assert(
  412|  6.89M|               !std::is_void_v<type>,
  413|  6.89M|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  6.89M|            return type{};
  416|       |         } else {
  417|       |            static_assert(
  418|       |               !std::same_as<AutoDetect, OutT>,
  419|       |               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|       |         }
  421|       |      } else if constexpr(concepts::resizable_container<OutT>) {
  422|       |         const size_t in_bytes = std::span{in}.size_bytes();
  423|       |         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|       |         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|       |                         "Input range is not word-aligned with the requested output range");
  426|       |         return OutT(in_bytes / out_elem_bytes);
  427|       |      } else {
  428|       |         return OutT{};
  429|       |      }
  430|  6.89M|   }(in_range);
_ZZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmTkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm8EEEQnt15custom_loadableINS0_19wrapped_type_helperIu14__remove_cvrefIT0_EE4typeEEEESA_OT1_ENKUlvE_clEv:
  282|  6.90M|   return detail::wrap_strong_type_or_enum<WrappedOutT>([&]() -> OutT {
  283|       |      // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  284|       |      // internally to copy ranges on a byte-by-byte basis, which is not allowed
  285|       |      // in a `constexpr` context.
  286|  6.90M|      if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (286:10): [Folded, False: 6.90M]
  ------------------
  287|      0|         return fallback_load_any<endianness, OutT>(std::forward<InR>(in_range));
  288|  6.90M|      } else {
  289|  6.90M|         const std::span in{in_range};
  290|       |         if constexpr(sizeof(OutT) == 1) {
  291|       |            return static_cast<OutT>(in[0]);
  292|  6.90M|         } else if constexpr(endianness == std::endian::native) {
  293|  6.90M|            return typecast_copy<OutT>(in);
  294|       |         } else {
  295|       |            static_assert(opposite(endianness) == std::endian::native);
  296|       |            return reverse_bytes(typecast_copy<OutT>(in));
  297|       |         }
  298|  6.90M|      }
  299|  6.90M|   }());
_ZN5Botan8store_leINS_6detail10AutoDetectEJRmEEEDaDpOT0_:
  736|  23.8k|inline constexpr auto store_le(ParamTs&&... params) {
  737|  23.8k|   return detail::store_any<std::endian::little, ModifierT>(std::forward<ParamTs>(params)...);
  738|  23.8k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJmEQ10all_same_vIDpT1_EEEDaS6_:
  696|  23.8k|inline constexpr auto store_any(Ts... ins) {
  697|  23.8k|   return store_any<endianness, OutR>(std::array{ins...});
  698|  23.8k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges14spanable_rangeENS2_5arrayImLm1EEEQoooosr3stdE7same_asIS4_T0_Eaasr6rangesE25statically_spanable_rangeIS8_Esr3stdE21default_initializableIS8_Esr8conceptsE21resizable_byte_bufferIS8_EEEDaOT1_:
  663|  23.8k|inline constexpr auto store_any(InR&& in_range) {
  664|  23.8k|   auto out = []([[maybe_unused]] const auto& in) {
  665|  23.8k|      if constexpr(std::same_as<AutoDetect, OutR>) {
  666|  23.8k|         if constexpr(ranges::statically_spanable_range<InR>) {
  667|  23.8k|            constexpr size_t bytes = decltype(std::span{in})::extent * sizeof(std::ranges::range_value_t<InR>);
  668|  23.8k|            return std::array<uint8_t, bytes>();
  669|  23.8k|         } else {
  670|  23.8k|            static_assert(
  671|  23.8k|               !std::same_as<AutoDetect, OutR>,
  672|  23.8k|               "cannot infer a suitable result container type from the given parameters at compile time, please specify it explicitly");
  673|  23.8k|         }
  674|  23.8k|      } else if constexpr(concepts::resizable_byte_buffer<OutR>) {
  675|  23.8k|         return OutR(std::span{in}.size_bytes());
  676|  23.8k|      } else {
  677|  23.8k|         return OutR{};
  678|  23.8k|      }
  679|  23.8k|   }(in_range);
  680|       |
  681|  23.8k|   store_any<endianness, std::ranges::range_value_t<InR>>(out, std::forward<InR>(in_range));
  682|  23.8k|   return out;
  683|  23.8k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE57005ENS0_10AutoDetectETkNS_6ranges14spanable_rangeENS2_5arrayImLm1EEEQoooosr3stdE7same_asIS4_T0_Eaasr6rangesE25statically_spanable_rangeIS8_Esr3stdE21default_initializableIS8_Esr8conceptsE21resizable_byte_bufferIS8_EEEDaOT1_ENKUlRKT_E_clIS7_EEDaSD_:
  664|  23.8k|   auto out = []([[maybe_unused]] const auto& in) {
  665|  23.8k|      if constexpr(std::same_as<AutoDetect, OutR>) {
  666|  23.8k|         if constexpr(ranges::statically_spanable_range<InR>) {
  667|  23.8k|            constexpr size_t bytes = decltype(std::span{in})::extent * sizeof(std::ranges::range_value_t<InR>);
  668|  23.8k|            return std::array<uint8_t, bytes>();
  669|       |         } else {
  670|       |            static_assert(
  671|       |               !std::same_as<AutoDetect, OutR>,
  672|       |               "cannot infer a suitable result container type from the given parameters at compile time, please specify it explicitly");
  673|       |         }
  674|       |      } else if constexpr(concepts::resizable_byte_buffer<OutR>) {
  675|       |         return OutR(std::span{in}.size_bytes());
  676|       |      } else {
  677|       |         return OutR{};
  678|       |      }
  679|  23.8k|   }(in_range);
_ZN5Botan6detail9store_anyILNSt3__16endianE57005EmTkNS_6ranges23contiguous_output_rangeIhEERNS2_5arrayIhLm8EEETkNS4_14spanable_rangeENS6_ImLm1EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|  23.8k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|  23.8k|   ranges::assert_equal_byte_lengths(out, in);
  605|  23.8k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|  23.8k|   auto store_elementwise = [&] {
  608|  23.8k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|  23.8k|      std::span<uint8_t> out_s(out);
  610|  23.8k|      for(auto in_elem : in) {
  611|  23.8k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  23.8k|         out_s = out_s.subspan(bytes_per_element);
  613|  23.8k|      }
  614|  23.8k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|  23.8k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 23.8k]
  ------------------
  620|      0|      store_elementwise();
  621|  23.8k|   } else {
  622|  23.8k|      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|  23.8k|         typecast_copy(out, in);
  624|       |      } else {
  625|       |         store_elementwise();
  626|       |      }
  627|  23.8k|   }
  628|  23.8k|}
_ZN5Botan7load_leImJPKhiEEEDaDpOT0_:
  495|  12.1k|inline constexpr auto load_le(ParamTs&&... params) {
  496|  12.1k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  12.1k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE57005ETkNS0_20unsigned_integralishEmEET0_PKhm:
  454|  12.1k|inline constexpr OutT load_any(const uint8_t in[], size_t off) {
  455|       |   // asserts that *in points to enough bytes to read at offset off
  456|  12.1k|   constexpr size_t out_size = sizeof(OutT);
  457|  12.1k|   return load_any<endianness, OutT>(std::span<const uint8_t, out_size>(in + off * out_size, out_size));
  458|  12.1k|}
_ZN5Botan7load_leIjJRPKhiEEEDaDpOT0_:
  495|  45.5k|inline constexpr auto load_le(ParamTs&&... params) {
  496|  45.5k|   return detail::load_any<std::endian::little, OutT>(std::forward<ParamTs>(params)...);
  497|  45.5k|}
_ZN5Botan8store_beINS_6detail10AutoDetectEJRKjPhEEEDaDpOT0_:
  745|   709k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   709k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   709k|}
_ZN5Botan7load_beIjJPhiEEEDaDpOT0_:
  504|   488k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   488k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   488k|}
_ZN5Botan8store_beINS_6detail10AutoDetectEJjPhEEEDaDpOT0_:
  745|  1.74M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  1.74M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  1.74M|}
_ZN5Botan8store_beINS_6detail10AutoDetectEJmPhEEEDaDpOT0_:
  745|  1.94M|inline constexpr auto store_be(ParamTs&&... params) {
  746|  1.94M|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|  1.94M|}
_ZN5Botan7load_beINSt3__15arrayImLm2EEEJRNS1_4spanIhLm16EEEEEEDaDpOT0_:
  504|   545k|inline constexpr auto load_be(ParamTs&&... params) {
  505|   545k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|   545k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEERNS2_4spanIhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISC_Esr8conceptsE19resizable_containerISC_E20unsigned_integralishINSC_10value_typeEEEEDaOT1_:
  397|   545k|inline constexpr auto load_any(InR&& in_range) {
  398|   545k|   auto out = []([[maybe_unused]] const auto& in) {
  399|   545k|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|   545k|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|   545k|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|   545k|            using type =
  405|   545k|               std::conditional_t<extent == 1, uint8_t,
  406|   545k|               std::conditional_t<extent == 2, uint16_t,
  407|   545k|               std::conditional_t<extent == 4, uint32_t,
  408|   545k|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|   545k|            static_assert(
  412|   545k|               !std::is_void_v<type>,
  413|   545k|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|   545k|            return type{};
  416|   545k|         } else {
  417|   545k|            static_assert(
  418|   545k|               !std::same_as<AutoDetect, OutT>,
  419|   545k|               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|   545k|         }
  421|   545k|      } else if constexpr(concepts::resizable_container<OutT>) {
  422|   545k|         const size_t in_bytes = std::span{in}.size_bytes();
  423|   545k|         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|   545k|         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|   545k|                         "Input range is not word-aligned with the requested output range");
  426|   545k|         return OutT(in_bytes / out_elem_bytes);
  427|   545k|      } else {
  428|   545k|         return OutT{};
  429|   545k|      }
  430|   545k|   }(in_range);
  431|       |
  432|   545k|   using out_type = decltype(out);
  433|       |   if constexpr(unsigned_integralish<out_type>) {
  434|       |      out = load_any<endianness, out_type>(std::forward<InR>(in_range));
  435|   545k|   } else {
  436|   545k|      static_assert(ranges::contiguous_range<out_type>);
  437|   545k|      using out_range_type = std::ranges::range_value_t<out_type>;
  438|   545k|      load_any<endianness, out_range_type>(out, std::forward<InR>(in_range));
  439|   545k|   }
  440|   545k|   return out;
  441|   545k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEERNS2_4spanIhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISC_Esr8conceptsE19resizable_containerISC_E20unsigned_integralishINSC_10value_typeEEEEDaOT1_ENKUlRKT_E_clIS9_EEDaSI_:
  398|   545k|   auto out = []([[maybe_unused]] const auto& in) {
  399|       |      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|       |         if constexpr(ranges::statically_spanable_range<InR>) {
  401|       |            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|       |            using type =
  405|       |               std::conditional_t<extent == 1, uint8_t,
  406|       |               std::conditional_t<extent == 2, uint16_t,
  407|       |               std::conditional_t<extent == 4, uint32_t,
  408|       |               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|       |            static_assert(
  412|       |               !std::is_void_v<type>,
  413|       |               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|       |            return type{};
  416|       |         } else {
  417|       |            static_assert(
  418|       |               !std::same_as<AutoDetect, OutT>,
  419|       |               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|       |         }
  421|       |      } else if constexpr(concepts::resizable_container<OutT>) {
  422|       |         const size_t in_bytes = std::span{in}.size_bytes();
  423|       |         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|       |         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|       |                         "Input range is not word-aligned with the requested output range");
  426|       |         return OutT(in_bytes / out_elem_bytes);
  427|   545k|      } else {
  428|   545k|         return OutT{};
  429|   545k|      }
  430|   545k|   }(in_range);
_ZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm2EEETkNS4_16contiguous_rangeIhEENS2_4spanIhLm16EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISQ_SO_EEEvOSF_RKT2_:
  355|   545k|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|   545k|   ranges::assert_equal_byte_lengths(out, in);
  357|   545k|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|   545k|   auto load_elementwise = [&] {
  360|   545k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|   545k|      std::span<const uint8_t> in_s(in);
  362|   545k|      for(auto& out_elem : out) {
  363|   545k|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   545k|         in_s = in_s.subspan(bytes_per_element);
  365|   545k|      }
  366|   545k|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|   545k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 545k]
  ------------------
  372|      0|      load_elementwise();
  373|   545k|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|   545k|      } else {
  377|   545k|         load_elementwise();
  378|   545k|      }
  379|   545k|   }
  380|   545k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm2EEETkNS4_16contiguous_rangeIhEENS2_4spanIhLm16EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISQ_SO_EEEvOSF_RKT2_ENKUlvE_clEv:
  359|   545k|   auto load_elementwise = [&] {
  360|   545k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|   545k|      std::span<const uint8_t> in_s(in);
  362|  1.09M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 1.09M, False: 545k]
  ------------------
  363|  1.09M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  1.09M|         in_s = in_s.subspan(bytes_per_element);
  365|  1.09M|      }
  366|   545k|   };
_ZN5Botan7load_beINSt3__15arrayImLm2EEEJNS1_4spanIKhLm16EEEEEEDaDpOT0_:
  504|  2.30M|inline constexpr auto load_be(ParamTs&&... params) {
  505|  2.30M|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  2.30M|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISC_Esr8conceptsE19resizable_containerISC_E20unsigned_integralishINSC_10value_typeEEEEDaOT1_:
  397|  2.30M|inline constexpr auto load_any(InR&& in_range) {
  398|  2.30M|   auto out = []([[maybe_unused]] const auto& in) {
  399|  2.30M|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  2.30M|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  2.30M|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  2.30M|            using type =
  405|  2.30M|               std::conditional_t<extent == 1, uint8_t,
  406|  2.30M|               std::conditional_t<extent == 2, uint16_t,
  407|  2.30M|               std::conditional_t<extent == 4, uint32_t,
  408|  2.30M|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  2.30M|            static_assert(
  412|  2.30M|               !std::is_void_v<type>,
  413|  2.30M|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  2.30M|            return type{};
  416|  2.30M|         } else {
  417|  2.30M|            static_assert(
  418|  2.30M|               !std::same_as<AutoDetect, OutT>,
  419|  2.30M|               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|  2.30M|         }
  421|  2.30M|      } else if constexpr(concepts::resizable_container<OutT>) {
  422|  2.30M|         const size_t in_bytes = std::span{in}.size_bytes();
  423|  2.30M|         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|  2.30M|         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|  2.30M|                         "Input range is not word-aligned with the requested output range");
  426|  2.30M|         return OutT(in_bytes / out_elem_bytes);
  427|  2.30M|      } else {
  428|  2.30M|         return OutT{};
  429|  2.30M|      }
  430|  2.30M|   }(in_range);
  431|       |
  432|  2.30M|   using out_type = decltype(out);
  433|       |   if constexpr(unsigned_integralish<out_type>) {
  434|       |      out = load_any<endianness, out_type>(std::forward<InR>(in_range));
  435|  2.30M|   } else {
  436|  2.30M|      static_assert(ranges::contiguous_range<out_type>);
  437|  2.30M|      using out_range_type = std::ranges::range_value_t<out_type>;
  438|  2.30M|      load_any<endianness, out_range_type>(out, std::forward<InR>(in_range));
  439|  2.30M|   }
  440|  2.30M|   return out;
  441|  2.30M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEENS2_4spanIKhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISC_Esr8conceptsE19resizable_containerISC_E20unsigned_integralishINSC_10value_typeEEEEDaOT1_ENKUlRKT_E_clISA_EEDaSI_:
  398|  2.30M|   auto out = []([[maybe_unused]] const auto& in) {
  399|       |      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|       |         if constexpr(ranges::statically_spanable_range<InR>) {
  401|       |            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|       |            using type =
  405|       |               std::conditional_t<extent == 1, uint8_t,
  406|       |               std::conditional_t<extent == 2, uint16_t,
  407|       |               std::conditional_t<extent == 4, uint32_t,
  408|       |               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|       |            static_assert(
  412|       |               !std::is_void_v<type>,
  413|       |               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|       |            return type{};
  416|       |         } else {
  417|       |            static_assert(
  418|       |               !std::same_as<AutoDetect, OutT>,
  419|       |               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|       |         }
  421|       |      } else if constexpr(concepts::resizable_container<OutT>) {
  422|       |         const size_t in_bytes = std::span{in}.size_bytes();
  423|       |         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|       |         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|       |                         "Input range is not word-aligned with the requested output range");
  426|       |         return OutT(in_bytes / out_elem_bytes);
  427|  2.30M|      } else {
  428|  2.30M|         return OutT{};
  429|  2.30M|      }
  430|  2.30M|   }(in_range);
_ZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm2EEETkNS4_16contiguous_rangeIhEENS2_4spanIKhLm16EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISR_SP_EEEvOSG_RKT2_:
  355|  2.30M|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  2.30M|   ranges::assert_equal_byte_lengths(out, in);
  357|  2.30M|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  2.30M|   auto load_elementwise = [&] {
  360|  2.30M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  2.30M|      std::span<const uint8_t> in_s(in);
  362|  2.30M|      for(auto& out_elem : out) {
  363|  2.30M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  2.30M|         in_s = in_s.subspan(bytes_per_element);
  365|  2.30M|      }
  366|  2.30M|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  2.30M|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 2.30M]
  ------------------
  372|      0|      load_elementwise();
  373|  2.30M|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  2.30M|      } else {
  377|  2.30M|         load_elementwise();
  378|  2.30M|      }
  379|  2.30M|   }
  380|  2.30M|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeERNS2_5arrayImLm2EEETkNS4_16contiguous_rangeIhEENS2_4spanIKhLm16EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISR_SP_EEEvOSG_RKT2_ENKUlvE_clEv:
  359|  2.30M|   auto load_elementwise = [&] {
  360|  2.30M|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  2.30M|      std::span<const uint8_t> in_s(in);
  362|  4.60M|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 4.60M, False: 2.30M]
  ------------------
  363|  4.60M|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  4.60M|         in_s = in_s.subspan(bytes_per_element);
  365|  4.60M|      }
  366|  2.30M|   };
_ZN5Botan8store_beINS_6detail10AutoDetectEJRNSt3__14spanIhLm16EEERNS3_5arrayImLm2EEEEEEDaDpOT0_:
  745|   545k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   545k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   545k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeIhEERNS2_4spanIhLm16EEETkNS5_14spanable_rangeENS2_5arrayImLm2EEEQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISC_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEEEvOT1_RKSH_:
  603|   545k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|   545k|   ranges::assert_equal_byte_lengths(out, in);
  605|   545k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|   545k|   auto store_elementwise = [&] {
  608|   545k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|   545k|      std::span<uint8_t> out_s(out);
  610|   545k|      for(auto in_elem : in) {
  611|   545k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|   545k|         out_s = out_s.subspan(bytes_per_element);
  613|   545k|      }
  614|   545k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|   545k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 545k]
  ------------------
  620|      0|      store_elementwise();
  621|   545k|   } else {
  622|       |      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|       |         typecast_copy(out, in);
  624|   545k|      } else {
  625|   545k|         store_elementwise();
  626|   545k|      }
  627|   545k|   }
  628|   545k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeIhEERNS2_4spanIhLm16EEETkNS5_14spanable_rangeENS2_5arrayImLm2EEEQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISC_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISK_EESL_E4type10value_typeEEEEvOT1_RKSH_ENKUlvE_clEv:
  607|   545k|   auto store_elementwise = [&] {
  608|   545k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|   545k|      std::span<uint8_t> out_s(out);
  610|  1.09M|      for(auto in_elem : in) {
  ------------------
  |  Branch (610:24): [True: 1.09M, False: 545k]
  ------------------
  611|  1.09M|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|  1.09M|         out_s = out_s.subspan(bytes_per_element);
  613|  1.09M|      }
  614|   545k|   };
_ZN5Botan7load_beINSt3__15arrayImLm2EEEJRNS1_4spanIKhLm16EEEEEEDaDpOT0_:
  504|  3.30k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  3.30k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  3.30k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEERNS2_4spanIKhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISD_Esr8conceptsE19resizable_containerISD_E20unsigned_integralishINSD_10value_typeEEEEDaOT1_:
  397|  3.30k|inline constexpr auto load_any(InR&& in_range) {
  398|  3.30k|   auto out = []([[maybe_unused]] const auto& in) {
  399|  3.30k|      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|  3.30k|         if constexpr(ranges::statically_spanable_range<InR>) {
  401|  3.30k|            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|  3.30k|            using type =
  405|  3.30k|               std::conditional_t<extent == 1, uint8_t,
  406|  3.30k|               std::conditional_t<extent == 2, uint16_t,
  407|  3.30k|               std::conditional_t<extent == 4, uint32_t,
  408|  3.30k|               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|  3.30k|            static_assert(
  412|  3.30k|               !std::is_void_v<type>,
  413|  3.30k|               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|  3.30k|            return type{};
  416|  3.30k|         } else {
  417|  3.30k|            static_assert(
  418|  3.30k|               !std::same_as<AutoDetect, OutT>,
  419|  3.30k|               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|  3.30k|         }
  421|  3.30k|      } else if constexpr(concepts::resizable_container<OutT>) {
  422|  3.30k|         const size_t in_bytes = std::span{in}.size_bytes();
  423|  3.30k|         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|  3.30k|         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|  3.30k|                         "Input range is not word-aligned with the requested output range");
  426|  3.30k|         return OutT(in_bytes / out_elem_bytes);
  427|  3.30k|      } else {
  428|  3.30k|         return OutT{};
  429|  3.30k|      }
  430|  3.30k|   }(in_range);
  431|       |
  432|  3.30k|   using out_type = decltype(out);
  433|       |   if constexpr(unsigned_integralish<out_type>) {
  434|       |      out = load_any<endianness, out_type>(std::forward<InR>(in_range));
  435|  3.30k|   } else {
  436|  3.30k|      static_assert(ranges::contiguous_range<out_type>);
  437|  3.30k|      using out_range_type = std::ranges::range_value_t<out_type>;
  438|  3.30k|      load_any<endianness, out_range_type>(out, std::forward<InR>(in_range));
  439|  3.30k|   }
  440|  3.30k|   return out;
  441|  3.30k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS2_5arrayImLm2EEETkNS_6ranges16contiguous_rangeIhEERNS2_4spanIKhLm16EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Eaaoosr6rangesE25statically_spanable_rangeISD_Esr8conceptsE19resizable_containerISD_E20unsigned_integralishINSD_10value_typeEEEEDaOT1_ENKUlRKT_E_clISA_EEDaSJ_:
  398|  3.30k|   auto out = []([[maybe_unused]] const auto& in) {
  399|       |      if constexpr(std::same_as<AutoDetect, OutT>) {
  400|       |         if constexpr(ranges::statically_spanable_range<InR>) {
  401|       |            constexpr size_t extent = decltype(std::span{in})::extent;
  402|       |
  403|       |            // clang-format off
  404|       |            using type =
  405|       |               std::conditional_t<extent == 1, uint8_t,
  406|       |               std::conditional_t<extent == 2, uint16_t,
  407|       |               std::conditional_t<extent == 4, uint32_t,
  408|       |               std::conditional_t<extent == 8, uint64_t, void>>>>;
  409|       |            // clang-format on
  410|       |
  411|       |            static_assert(
  412|       |               !std::is_void_v<type>,
  413|       |               "Cannot determine the output type based on a statically sized bytearray with length other than those: 1, 2, 4, 8");
  414|       |
  415|       |            return type{};
  416|       |         } else {
  417|       |            static_assert(
  418|       |               !std::same_as<AutoDetect, OutT>,
  419|       |               "cannot infer return type from a dynamic range at compile time, please specify it explicitly");
  420|       |         }
  421|       |      } else if constexpr(concepts::resizable_container<OutT>) {
  422|       |         const size_t in_bytes = std::span{in}.size_bytes();
  423|       |         constexpr size_t out_elem_bytes = sizeof(typename OutT::value_type);
  424|       |         BOTAN_ARG_CHECK(in_bytes % out_elem_bytes == 0,
  425|       |                         "Input range is not word-aligned with the requested output range");
  426|       |         return OutT(in_bytes / out_elem_bytes);
  427|  3.30k|      } else {
  428|  3.30k|         return OutT{};
  429|  3.30k|      }
  430|  3.30k|   }(in_range);
_ZN5Botan8store_beINS_6detail10AutoDetectEJmmEEEDaDpOT0_:
  745|   102k|inline constexpr auto store_be(ParamTs&&... params) {
  746|   102k|   return detail::store_any<std::endian::big, ModifierT>(std::forward<ParamTs>(params)...);
  747|   102k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETpTkNS0_20unsigned_integralishEJmmEQ10all_same_vIDpT1_EEEDaS6_:
  696|   102k|inline constexpr auto store_any(Ts... ins) {
  697|   102k|   return store_any<endianness, OutR>(std::array{ins...});
  698|   102k|}
_ZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges14spanable_rangeENS2_5arrayImLm2EEEQoooosr3stdE7same_asIS4_T0_Eaasr6rangesE25statically_spanable_rangeIS8_Esr3stdE21default_initializableIS8_Esr8conceptsE21resizable_byte_bufferIS8_EEEDaOT1_:
  663|   102k|inline constexpr auto store_any(InR&& in_range) {
  664|   102k|   auto out = []([[maybe_unused]] const auto& in) {
  665|   102k|      if constexpr(std::same_as<AutoDetect, OutR>) {
  666|   102k|         if constexpr(ranges::statically_spanable_range<InR>) {
  667|   102k|            constexpr size_t bytes = decltype(std::span{in})::extent * sizeof(std::ranges::range_value_t<InR>);
  668|   102k|            return std::array<uint8_t, bytes>();
  669|   102k|         } else {
  670|   102k|            static_assert(
  671|   102k|               !std::same_as<AutoDetect, OutR>,
  672|   102k|               "cannot infer a suitable result container type from the given parameters at compile time, please specify it explicitly");
  673|   102k|         }
  674|   102k|      } else if constexpr(concepts::resizable_byte_buffer<OutR>) {
  675|   102k|         return OutR(std::span{in}.size_bytes());
  676|   102k|      } else {
  677|   102k|         return OutR{};
  678|   102k|      }
  679|   102k|   }(in_range);
  680|       |
  681|   102k|   store_any<endianness, std::ranges::range_value_t<InR>>(out, std::forward<InR>(in_range));
  682|   102k|   return out;
  683|   102k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges14spanable_rangeENS2_5arrayImLm2EEEQoooosr3stdE7same_asIS4_T0_Eaasr6rangesE25statically_spanable_rangeIS8_Esr3stdE21default_initializableIS8_Esr8conceptsE21resizable_byte_bufferIS8_EEEDaOT1_ENKUlRKT_E_clIS7_EEDaSD_:
  664|   102k|   auto out = []([[maybe_unused]] const auto& in) {
  665|   102k|      if constexpr(std::same_as<AutoDetect, OutR>) {
  666|   102k|         if constexpr(ranges::statically_spanable_range<InR>) {
  667|   102k|            constexpr size_t bytes = decltype(std::span{in})::extent * sizeof(std::ranges::range_value_t<InR>);
  668|   102k|            return std::array<uint8_t, bytes>();
  669|       |         } else {
  670|       |            static_assert(
  671|       |               !std::same_as<AutoDetect, OutR>,
  672|       |               "cannot infer a suitable result container type from the given parameters at compile time, please specify it explicitly");
  673|       |         }
  674|       |      } else if constexpr(concepts::resizable_byte_buffer<OutR>) {
  675|       |         return OutR(std::span{in}.size_bytes());
  676|       |      } else {
  677|       |         return OutR{};
  678|       |      }
  679|   102k|   }(in_range);
_ZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEERNS2_5arrayIhLm16EEETkNS4_14spanable_rangeENS6_ImLm2EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_:
  603|   102k|inline constexpr void store_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  604|   102k|   ranges::assert_equal_byte_lengths(out, in);
  605|   102k|   using element_type = std::ranges::range_value_t<InR>;
  606|       |
  607|   102k|   auto store_elementwise = [&] {
  608|   102k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|   102k|      std::span<uint8_t> out_s(out);
  610|   102k|      for(auto in_elem : in) {
  611|   102k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|   102k|         out_s = out_s.subspan(bytes_per_element);
  613|   102k|      }
  614|   102k|   };
  615|       |
  616|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  617|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  618|       |   // in a `constexpr` context.
  619|   102k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (619:7): [Folded, False: 102k]
  ------------------
  620|      0|      store_elementwise();
  621|   102k|   } else {
  622|       |      if constexpr(endianness == std::endian::native && !custom_storable<element_type>) {
  623|       |         typecast_copy(out, in);
  624|   102k|      } else {
  625|   102k|         store_elementwise();
  626|   102k|      }
  627|   102k|   }
  628|   102k|}
_ZZN5Botan6detail9store_anyILNSt3__16endianE64206EmTkNS_6ranges23contiguous_output_rangeIhEERNS2_5arrayIhLm16EEETkNS4_14spanable_rangeENS6_ImLm2EEEQoosr3stdE7same_asINS0_10AutoDetectET0_Esr3stdE7same_asISB_NS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT2_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISJ_EESK_E4type10value_typeEEEEvOT1_RKSG_ENKUlvE_clEv:
  607|   102k|   auto store_elementwise = [&] {
  608|   102k|      constexpr size_t bytes_per_element = sizeof(element_type);
  609|   102k|      std::span<uint8_t> out_s(out);
  610|   204k|      for(auto in_elem : in) {
  ------------------
  |  Branch (610:24): [True: 204k, False: 102k]
  ------------------
  611|   204k|         store_any<endianness, element_type>(out_s.template first<bytes_per_element>(), in_elem);
  612|   204k|         out_s = out_s.subspan(bytes_per_element);
  613|   204k|      }
  614|   102k|   };
_ZN5Botan7load_beINS_6detail10AutoDetectEJRA1_mRPKhmEEEDaDpOT0_:
  504|  1.98k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  1.98k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  1.98k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS0_20unsigned_integralishEmQoosr3stdE7same_asIS4_T0_Esr3stdE7same_asIT1_S5_EEEvPS6_PKhm:
  483|  77.6k|inline constexpr void load_any(T out[], const uint8_t in[], size_t count) {
  484|       |   // asserts that *in and *out point to the correct amount of memory
  485|  77.6k|   load_any<endianness, OutT>(std::span<T>(out, count), std::span<const uint8_t>(in, count * sizeof(T)));
  486|  77.6k|}
_ZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanImLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_:
  355|  77.6k|inline constexpr void load_any(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  356|  77.6k|   ranges::assert_equal_byte_lengths(out, in);
  357|  77.6k|   using element_type = std::ranges::range_value_t<OutR>;
  358|       |
  359|  77.6k|   auto load_elementwise = [&] {
  360|  77.6k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  77.6k|      std::span<const uint8_t> in_s(in);
  362|  77.6k|      for(auto& out_elem : out) {
  363|  77.6k|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|  77.6k|         in_s = in_s.subspan(bytes_per_element);
  365|  77.6k|      }
  366|  77.6k|   };
  367|       |
  368|       |   // At compile time we cannot use `typecast_copy` as it uses `std::memcpy`
  369|       |   // internally to copy ranges on a byte-by-byte basis, which is not allowed
  370|       |   // in a `constexpr` context.
  371|  77.6k|   if(std::is_constant_evaluated()) /* TODO: C++23: if consteval {} */ {
  ------------------
  |  Branch (371:7): [Folded, False: 77.6k]
  ------------------
  372|      0|      load_elementwise();
  373|  77.6k|   } else {
  374|       |      if constexpr(endianness == std::endian::native && !custom_loadable<element_type>) {
  375|       |         typecast_copy(out, in);
  376|  77.6k|      } else {
  377|  77.6k|         load_elementwise();
  378|  77.6k|      }
  379|  77.6k|   }
  380|  77.6k|}
_ZZN5Botan6detail8load_anyILNSt3__16endianE64206ENS0_10AutoDetectETkNS_6ranges23contiguous_output_rangeENS2_4spanImLm18446744073709551615EEETkNS5_16contiguous_rangeIhEENS6_IKhLm18446744073709551615EEEQaa20unsigned_integralishINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT1_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeEEoosr3stdE7same_asIS4_T0_Esr3stdE7same_asISP_SO_EEEvOSF_RKT2_ENKUlvE_clEv:
  359|  77.6k|   auto load_elementwise = [&] {
  360|  77.6k|      constexpr size_t bytes_per_element = sizeof(element_type);
  361|  77.6k|      std::span<const uint8_t> in_s(in);
  362|   153k|      for(auto& out_elem : out) {
  ------------------
  |  Branch (362:26): [True: 153k, False: 77.6k]
  ------------------
  363|   153k|         out_elem = load_any<endianness, element_type>(in_s.template first<bytes_per_element>());
  364|   153k|         in_s = in_s.subspan(bytes_per_element);
  365|   153k|      }
  366|  77.6k|   };
_ZN5Botan11copy_out_beITkNS_6ranges14spanable_rangeEA1_mEEvNSt3__14spanIhLm18446744073709551615EEERKT_:
  773|  1.98k|inline void copy_out_be(std::span<uint8_t> out, const InR& in) {
  774|  1.98k|   using T = std::ranges::range_value_t<InR>;
  775|  1.98k|   std::span<const T> in_s{in};
  776|  1.98k|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::big>(out, in_s);
  777|       |
  778|       |   // copy remaining bytes as a partial word
  779|  1.98k|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (779:22): [True: 0, False: 1.98k]
  ------------------
  780|      0|      out[i] = get_byte_var(i, in_s.front());
  781|      0|   }
  782|  1.98k|}
_ZN5Botan7load_beINS_6detail10AutoDetectEJRA2_mRPKhmEEEDaDpOT0_:
  504|  75.6k|inline constexpr auto load_be(ParamTs&&... params) {
  505|  75.6k|   return detail::load_any<std::endian::big, OutT>(std::forward<ParamTs>(params)...);
  506|  75.6k|}
_ZN5Botan11copy_out_beITkNS_6ranges14spanable_rangeEA2_mEEvNSt3__14spanIhLm18446744073709551615EEERKT_:
  773|  75.6k|inline void copy_out_be(std::span<uint8_t> out, const InR& in) {
  774|  75.6k|   using T = std::ranges::range_value_t<InR>;
  775|  75.6k|   std::span<const T> in_s{in};
  776|  75.6k|   const auto remaining_bytes = detail::copy_out_any_word_aligned_portion<std::endian::big>(out, in_s);
  777|       |
  778|       |   // copy remaining bytes as a partial word
  779|  75.6k|   for(size_t i = 0; i < remaining_bytes; ++i) {
  ------------------
  |  Branch (779:22): [True: 0, False: 75.6k]
  ------------------
  780|      0|      out[i] = get_byte_var(i, in_s.front());
  781|      0|   }
  782|  75.6k|}

_ZNK5Botan3MD54nameEv:
   32|    242|      std::string name() const override { return "MD5"; }
_ZNK5Botan3MD513output_lengthEv:
   34|  29.0k|      size_t output_length() const override { return output_bytes; }

_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EEC2Ev:
   42|  4.80k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE5clearEv:
   70|  8.66k|      void clear() {
   71|  8.66k|         MD::init(m_digest);
   72|  8.66k|         m_buffer.clear();
   73|  8.66k|         m_count = 0;
   74|  8.66k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EEC2Ev:
   42|  1.07k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE5clearEv:
   70|  1.66k|      void clear() {
   71|  1.66k|         MD::init(m_digest);
   72|  1.66k|         m_buffer.clear();
   73|  1.66k|         m_count = 0;
   74|  1.66k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EEC2Ev:
   42|  39.7k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE5clearEv:
   70|  96.9k|      void clear() {
   71|  96.9k|         MD::init(m_digest);
   72|  96.9k|         m_buffer.clear();
   73|  96.9k|         m_count = 0;
   74|  96.9k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EEC2Ev:
   42|  3.75k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE5clearEv:
   70|  4.96k|      void clear() {
   71|  4.96k|         MD::init(m_digest);
   72|  4.96k|         m_buffer.clear();
   73|  4.96k|         m_count = 0;
   74|  4.96k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EEC2Ev:
   42|  23.3k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE5clearEv:
   70|  2.49M|      void clear() {
   71|  2.49M|         MD::init(m_digest);
   72|  2.49M|         m_buffer.clear();
   73|  2.49M|         m_count = 0;
   74|  2.49M|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EEC2Ev:
   42|  5.92k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE5clearEv:
   70|  10.0k|      void clear() {
   71|  10.0k|         MD::init(m_digest);
   72|  10.0k|         m_buffer.clear();
   73|  10.0k|         m_count = 0;
   74|  10.0k|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EEC2Ev:
   42|  18.2k|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE5clearEv:
   70|  34.6k|      void clear() {
   71|  34.6k|         MD::init(m_digest);
   72|  34.6k|         m_buffer.clear();
   73|  34.6k|         m_count = 0;
   74|  34.6k|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EEC2Ev:
   42|    365|      MerkleDamgard_Hash() { clear(); }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE5clearEv:
   70|    491|      void clear() {
   71|    491|         MD::init(m_digest);
   72|    491|         m_buffer.clear();
   73|    491|         m_count = 0;
   74|    491|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|  13.3M|      void update(std::span<const uint8_t> input) {
   45|  13.3M|         BufferSlicer in(input);
   46|       |
   47|  29.7M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 16.3M, False: 13.3M]
  ------------------
   48|  16.3M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 3.42M, False: 12.9M]
  ------------------
   49|  3.42M|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  3.42M|            }
   51|       |
   52|  16.3M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 3.42M, False: 12.9M]
  ------------------
   53|  3.42M|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  3.42M|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 6.48k, False: 3.42M]
  ------------------
   55|  6.48k|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  6.48k|               }
   57|  3.42M|            }
   58|  16.3M|         }
   59|       |
   60|  13.3M|         m_count += input.size();
   61|  13.3M|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  16.4k|      void final(std::span<uint8_t> output) {
   64|  16.4k|         append_padding_bit();
   65|  16.4k|         append_counter_and_finalize();
   66|  16.4k|         copy_output(output);
   67|  16.4k|         clear();
   68|  16.4k|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE18append_padding_bitEv:
   77|  16.4k|      void append_padding_bit() {
   78|  16.4k|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  16.4k|   do {                                                                     \
  |  |   78|  16.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  16.4k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 16.4k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  16.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 16.4k]
  |  |  ------------------
  ------------------
   79|  16.4k|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  16.4k|            const uint8_t final_byte = 0x80;
   81|  16.4k|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  16.4k|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE27append_counter_and_finalizeEv:
   88|  16.4k|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  16.4k|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 4, False: 16.4k]
  ------------------
   92|      4|            m_buffer.fill_up_with_zeros();
   93|      4|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|      4|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  16.4k|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  16.4k|   do {                                                                     \
  |  |   78|  16.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  16.4k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 16.4k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  16.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 16.4k]
  |  |  ------------------
  ------------------
   98|  16.4k|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  16.4k|         const uint64_t bit_count = m_count * 8;
  102|  16.4k|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|       |         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|       |            store_be(bit_count, last_bytes.data());
  105|  16.4k|         } else {
  106|  16.4k|            store_le(bit_count, last_bytes.data());
  107|  16.4k|         }
  108|       |
  109|       |         // Compress the very last block.
  110|  16.4k|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  16.4k|      }
_ZN5Botan18MerkleDamgard_HashINS_3MD5EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  16.4k|      void copy_output(std::span<uint8_t> output) {
  114|  16.4k|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  16.4k|   do {                                                                     \
  |  |   78|  16.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  16.4k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 16.4k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  16.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 16.4k]
  |  |  ------------------
  ------------------
  115|       |
  116|       |         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|       |            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|  16.4k|         } else {
  119|  16.4k|            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|  16.4k|         }
  121|  16.4k|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|  3.43M|      void update(std::span<const uint8_t> input) {
   45|  3.43M|         BufferSlicer in(input);
   46|       |
   47|  7.66M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 4.22M, False: 3.43M]
  ------------------
   48|  4.22M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 995k, False: 3.23M]
  ------------------
   49|   995k|               MD::compress_n(m_digest, one_block.value(), 1);
   50|   995k|            }
   51|       |
   52|  4.22M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 996k, False: 3.23M]
  ------------------
   53|   996k|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|   996k|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 1.99k, False: 994k]
  ------------------
   55|  1.99k|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  1.99k|               }
   57|   996k|            }
   58|  4.22M|         }
   59|       |
   60|  3.43M|         m_count += input.size();
   61|  3.43M|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  4.17k|      void final(std::span<uint8_t> output) {
   64|  4.17k|         append_padding_bit();
   65|  4.17k|         append_counter_and_finalize();
   66|  4.17k|         copy_output(output);
   67|  4.17k|         clear();
   68|  4.17k|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE18append_padding_bitEv:
   77|  4.17k|      void append_padding_bit() {
   78|  4.17k|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  4.17k|   do {                                                                     \
  |  |   78|  4.17k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.17k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.17k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.17k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.17k]
  |  |  ------------------
  ------------------
   79|  4.17k|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  4.17k|            const uint8_t final_byte = 0x80;
   81|  4.17k|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  4.17k|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE27append_counter_and_finalizeEv:
   88|  4.17k|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  4.17k|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 13, False: 4.15k]
  ------------------
   92|     13|            m_buffer.fill_up_with_zeros();
   93|     13|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|     13|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  4.17k|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  4.17k|   do {                                                                     \
  |  |   78|  4.17k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.17k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.17k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.17k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.17k]
  |  |  ------------------
  ------------------
   98|  4.17k|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  4.17k|         const uint64_t bit_count = m_count * 8;
  102|  4.17k|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|       |         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|       |            store_be(bit_count, last_bytes.data());
  105|  4.17k|         } else {
  106|  4.17k|            store_le(bit_count, last_bytes.data());
  107|  4.17k|         }
  108|       |
  109|       |         // Compress the very last block.
  110|  4.17k|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  4.17k|      }
_ZN5Botan18MerkleDamgard_HashINS_10RIPEMD_160EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  4.17k|      void copy_output(std::span<uint8_t> output) {
  114|  4.17k|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  4.17k|   do {                                                                     \
  |  |   78|  4.17k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.17k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.17k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.17k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.17k]
  |  |  ------------------
  ------------------
  115|       |
  116|       |         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|       |            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|  4.17k|         } else {
  119|  4.17k|            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|  4.17k|         }
  121|  4.17k|      }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|   115M|      void update(std::span<const uint8_t> input) {
   45|   115M|         BufferSlicer in(input);
   46|       |
   47|   250M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 134M, False: 115M]
  ------------------
   48|   134M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 23.4M, False: 111M]
  ------------------
   49|  23.4M|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  23.4M|            }
   51|       |
   52|   134M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 23.4M, False: 111M]
  ------------------
   53|  23.4M|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  23.4M|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 0, False: 23.4M]
  ------------------
   55|      0|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|      0|               }
   57|  23.4M|            }
   58|   134M|         }
   59|       |
   60|   115M|         m_count += input.size();
   61|   115M|      }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  3.86k|      void final(std::span<uint8_t> output) {
   64|  3.86k|         append_padding_bit();
   65|  3.86k|         append_counter_and_finalize();
   66|  3.86k|         copy_output(output);
   67|  3.86k|         clear();
   68|  3.86k|      }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE18append_padding_bitEv:
   77|  3.86k|      void append_padding_bit() {
   78|  3.86k|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  3.86k|   do {                                                                     \
  |  |   78|  3.86k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.86k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.86k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.86k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.86k]
  |  |  ------------------
  ------------------
   79|  3.86k|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  3.86k|            const uint8_t final_byte = 0x80;
   81|  3.86k|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  3.86k|      }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE27append_counter_and_finalizeEv:
   88|  3.86k|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  3.86k|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 0, False: 3.86k]
  ------------------
   92|      0|            m_buffer.fill_up_with_zeros();
   93|      0|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|      0|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  3.86k|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  3.86k|   do {                                                                     \
  |  |   78|  3.86k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.86k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.86k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.86k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.86k]
  |  |  ------------------
  ------------------
   98|  3.86k|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  3.86k|         const uint64_t bit_count = m_count * 8;
  102|  3.86k|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|  3.86k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|  3.86k|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|  3.86k|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  3.86k|      }
_ZN5Botan18MerkleDamgard_HashINS_5SHA_1EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  3.86k|      void copy_output(std::span<uint8_t> output) {
  114|  3.86k|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  3.86k|   do {                                                                     \
  |  |   78|  3.86k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.86k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.86k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.86k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.86k]
  |  |  ------------------
  ------------------
  115|       |
  116|  3.86k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|  3.86k|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|  3.86k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|  5.67M|      void update(std::span<const uint8_t> input) {
   45|  5.67M|         BufferSlicer in(input);
   46|       |
   47|  13.0M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 7.41M, False: 5.67M]
  ------------------
   48|  7.41M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 1.92M, False: 5.49M]
  ------------------
   49|  1.92M|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  1.92M|            }
   51|       |
   52|  7.41M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 1.92M, False: 5.49M]
  ------------------
   53|  1.92M|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  1.92M|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 5.47k, False: 1.91M]
  ------------------
   55|  5.47k|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  5.47k|               }
   57|  1.92M|            }
   58|  7.41M|         }
   59|       |
   60|  5.67M|         m_count += input.size();
   61|  5.67M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|    594|      void final(std::span<uint8_t> output) {
   64|    594|         append_padding_bit();
   65|    594|         append_counter_and_finalize();
   66|    594|         copy_output(output);
   67|    594|         clear();
   68|    594|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE18append_padding_bitEv:
   77|    594|      void append_padding_bit() {
   78|    594|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|    594|   do {                                                                     \
  |  |   78|    594|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    594|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 594]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    594|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 594]
  |  |  ------------------
  ------------------
   79|    594|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|    594|            const uint8_t final_byte = 0x80;
   81|    594|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|    594|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE27append_counter_and_finalizeEv:
   88|    594|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|    594|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 24, False: 570]
  ------------------
   92|     24|            m_buffer.fill_up_with_zeros();
   93|     24|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|     24|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|    594|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|    594|   do {                                                                     \
  |  |   78|    594|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    594|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 594]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    594|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 594]
  |  |  ------------------
  ------------------
   98|    594|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|    594|         const uint64_t bit_count = m_count * 8;
  102|    594|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|    594|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|    594|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|    594|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|    594|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_224EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|    594|      void copy_output(std::span<uint8_t> output) {
  114|    594|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|    594|   do {                                                                     \
  |  |   78|    594|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    594|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 594]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    594|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 594]
  |  |  ------------------
  ------------------
  115|       |
  116|    594|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|    594|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|    594|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|  18.8M|      void update(std::span<const uint8_t> input) {
   45|  18.8M|         BufferSlicer in(input);
   46|       |
   47|  40.9M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 22.1M, False: 18.8M]
  ------------------
   48|  22.1M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 4.30M, False: 17.8M]
  ------------------
   49|  4.30M|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  4.30M|            }
   51|       |
   52|  22.1M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 4.35M, False: 17.8M]
  ------------------
   53|  4.35M|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  4.35M|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 47.0k, False: 4.30M]
  ------------------
   55|  47.0k|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  47.0k|               }
   57|  4.35M|            }
   58|  22.1M|         }
   59|       |
   60|  18.8M|         m_count += input.size();
   61|  18.8M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  43.5k|      void final(std::span<uint8_t> output) {
   64|  43.5k|         append_padding_bit();
   65|  43.5k|         append_counter_and_finalize();
   66|  43.5k|         copy_output(output);
   67|  43.5k|         clear();
   68|  43.5k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE18append_padding_bitEv:
   77|  43.5k|      void append_padding_bit() {
   78|  43.5k|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  43.5k|   do {                                                                     \
  |  |   78|  43.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  43.5k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 43.5k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  43.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 43.5k]
  |  |  ------------------
  ------------------
   79|  43.5k|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  43.5k|            const uint8_t final_byte = 0x80;
   81|  43.5k|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  43.5k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE27append_counter_and_finalizeEv:
   88|  43.5k|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  43.5k|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 18, False: 43.5k]
  ------------------
   92|     18|            m_buffer.fill_up_with_zeros();
   93|     18|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|     18|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  43.5k|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  43.5k|   do {                                                                     \
  |  |   78|  43.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  43.5k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 43.5k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  43.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 43.5k]
  |  |  ------------------
  ------------------
   98|  43.5k|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  43.5k|         const uint64_t bit_count = m_count * 8;
  102|  43.5k|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|  43.5k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|  43.5k|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|  43.5k|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  43.5k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_256EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  43.5k|      void copy_output(std::span<uint8_t> output) {
  114|  43.5k|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  43.5k|   do {                                                                     \
  |  |   78|  43.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  43.5k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 43.5k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  43.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 43.5k]
  |  |  ------------------
  ------------------
  115|       |
  116|  43.5k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|  43.5k|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|  43.5k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|   978k|      void update(std::span<const uint8_t> input) {
   45|   978k|         BufferSlicer in(input);
   46|       |
   47|  1.97M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 998k, False: 978k]
  ------------------
   48|   998k|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 47.3k, False: 950k]
  ------------------
   49|  47.3k|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  47.3k|            }
   51|       |
   52|   998k|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 47.7k, False: 950k]
  ------------------
   53|  47.7k|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  47.7k|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 718, False: 47.0k]
  ------------------
   55|    718|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|    718|               }
   57|  47.7k|            }
   58|   998k|         }
   59|       |
   60|   978k|         m_count += input.size();
   61|   978k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|  30.9M|      void update(std::span<const uint8_t> input) {
   45|  30.9M|         BufferSlicer in(input);
   46|       |
   47|  62.1M|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 31.1M, False: 30.9M]
  ------------------
   48|  31.1M|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 398k, False: 30.7M]
  ------------------
   49|   398k|               MD::compress_n(m_digest, one_block.value(), 1);
   50|   398k|            }
   51|       |
   52|  31.1M|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 2.87M, False: 28.2M]
  ------------------
   53|  2.87M|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  2.87M|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 2.52M, False: 349k]
  ------------------
   55|  2.52M|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  2.52M|               }
   57|  2.87M|            }
   58|  31.1M|         }
   59|       |
   60|  30.9M|         m_count += input.size();
   61|  30.9M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  1.21k|      void final(std::span<uint8_t> output) {
   64|  1.21k|         append_padding_bit();
   65|  1.21k|         append_counter_and_finalize();
   66|  1.21k|         copy_output(output);
   67|  1.21k|         clear();
   68|  1.21k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE18append_padding_bitEv:
   77|  1.21k|      void append_padding_bit() {
   78|  1.21k|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  1.21k|   do {                                                                     \
  |  |   78|  1.21k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.21k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.21k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.21k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.21k]
  |  |  ------------------
  ------------------
   79|  1.21k|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  1.21k|            const uint8_t final_byte = 0x80;
   81|  1.21k|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  1.21k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE27append_counter_and_finalizeEv:
   88|  1.21k|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  1.21k|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 10, False: 1.20k]
  ------------------
   92|     10|            m_buffer.fill_up_with_zeros();
   93|     10|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|     10|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  1.21k|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  1.21k|   do {                                                                     \
  |  |   78|  1.21k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.21k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.21k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.21k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.21k]
  |  |  ------------------
  ------------------
   98|  1.21k|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  1.21k|         const uint64_t bit_count = m_count * 8;
  102|  1.21k|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|  1.21k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|  1.21k|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|  1.21k|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  1.21k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_384EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  1.21k|      void copy_output(std::span<uint8_t> output) {
  114|  1.21k|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  1.21k|   do {                                                                     \
  |  |   78|  1.21k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.21k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.21k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.21k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.21k]
  |  |  ------------------
  ------------------
  115|       |
  116|  1.21k|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|  1.21k|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|  1.21k|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|  2.29M|      void final(std::span<uint8_t> output) {
   64|  2.29M|         append_padding_bit();
   65|  2.29M|         append_counter_and_finalize();
   66|  2.29M|         copy_output(output);
   67|  2.29M|         clear();
   68|  2.29M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE18append_padding_bitEv:
   77|  2.29M|      void append_padding_bit() {
   78|  2.29M|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|  2.29M|   do {                                                                     \
  |  |   78|  2.29M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.29M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.29M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.29M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.29M]
  |  |  ------------------
  ------------------
   79|  2.29M|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|  2.29M|            const uint8_t final_byte = 0x80;
   81|  2.29M|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|  2.29M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE27append_counter_and_finalizeEv:
   88|  2.29M|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|  2.29M|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 80, False: 2.29M]
  ------------------
   92|     80|            m_buffer.fill_up_with_zeros();
   93|     80|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|     80|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|  2.29M|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|  2.29M|   do {                                                                     \
  |  |   78|  2.29M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.29M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.29M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.29M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.29M]
  |  |  ------------------
  ------------------
   98|  2.29M|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|  2.29M|         const uint64_t bit_count = m_count * 8;
  102|  2.29M|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|  2.29M|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|  2.29M|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|  2.29M|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|  2.29M|      }
_ZN5Botan18MerkleDamgard_HashINS_7SHA_512EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|  2.29M|      void copy_output(std::span<uint8_t> output) {
  114|  2.29M|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|  2.29M|   do {                                                                     \
  |  |   78|  2.29M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.29M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.29M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.29M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.29M]
  |  |  ------------------
  ------------------
  115|       |
  116|  2.29M|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|  2.29M|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|  2.29M|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE6updateENSt3__14spanIKhLm18446744073709551615EEE:
   44|   244k|      void update(std::span<const uint8_t> input) {
   45|   244k|         BufferSlicer in(input);
   46|       |
   47|   536k|         while(!in.empty()) {
  ------------------
  |  Branch (47:16): [True: 292k, False: 244k]
  ------------------
   48|   292k|            if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (48:27): [True: 57.5k, False: 235k]
  ------------------
   49|  57.5k|               MD::compress_n(m_digest, one_block.value(), 1);
   50|  57.5k|            }
   51|       |
   52|   292k|            if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (52:16): [True: 57.7k, False: 234k]
  ------------------
   53|  57.7k|               const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
   54|  57.7k|               if(full_blocks > 0) {
  ------------------
  |  Branch (54:19): [True: 1.65k, False: 56.0k]
  ------------------
   55|  1.65k|                  MD::compress_n(m_digest, aligned_data, full_blocks);
   56|  1.65k|               }
   57|  57.7k|            }
   58|   292k|         }
   59|       |
   60|   244k|         m_count += input.size();
   61|   244k|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE5finalENSt3__14spanIhLm18446744073709551615EEE:
   63|    126|      void final(std::span<uint8_t> output) {
   64|    126|         append_padding_bit();
   65|    126|         append_counter_and_finalize();
   66|    126|         copy_output(output);
   67|    126|         clear();
   68|    126|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE18append_padding_bitEv:
   77|    126|      void append_padding_bit() {
   78|    126|         BOTAN_ASSERT_NOMSG(!m_buffer.ready_to_consume());
  ------------------
  |  |   77|    126|   do {                                                                     \
  |  |   78|    126|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    126|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 126]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    126|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 126]
  |  |  ------------------
  ------------------
   79|    126|         if constexpr(MD::bit_endianness == MD_Endian::Big) {
   80|    126|            const uint8_t final_byte = 0x80;
   81|    126|            m_buffer.append({&final_byte, 1});
   82|       |         } else {
   83|       |            const uint8_t final_byte = 0x01;
   84|       |            m_buffer.append({&final_byte, 1});
   85|       |         }
   86|    126|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE27append_counter_and_finalizeEv:
   88|    126|      void append_counter_and_finalize() {
   89|       |         // Compress the remaining data if the final data block does not provide
   90|       |         // enough space for the counter bytes.
   91|    126|         if(m_buffer.elements_until_alignment() < MD::ctr_bytes) {
  ------------------
  |  Branch (91:13): [True: 2, False: 124]
  ------------------
   92|      2|            m_buffer.fill_up_with_zeros();
   93|      2|            MD::compress_n(m_digest, m_buffer.consume(), 1);
   94|      2|         }
   95|       |
   96|       |         // Make sure that any remaining bytes in the very last block are zero.
   97|    126|         BOTAN_ASSERT_NOMSG(m_buffer.elements_until_alignment() >= MD::ctr_bytes);
  ------------------
  |  |   77|    126|   do {                                                                     \
  |  |   78|    126|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    126|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 126]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    126|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 126]
  |  |  ------------------
  ------------------
   98|    126|         m_buffer.fill_up_with_zeros();
   99|       |
  100|       |         // Replace a bunch of the right-most zero-padding with the counter bytes.
  101|    126|         const uint64_t bit_count = m_count * 8;
  102|    126|         auto last_bytes = m_buffer.directly_modify_last(sizeof(bit_count));
  103|    126|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  104|    126|            store_be(bit_count, last_bytes.data());
  105|       |         } else {
  106|       |            store_le(bit_count, last_bytes.data());
  107|       |         }
  108|       |
  109|       |         // Compress the very last block.
  110|    126|         MD::compress_n(m_digest, m_buffer.consume(), 1);
  111|    126|      }
_ZN5Botan18MerkleDamgard_HashINS_3SM3EE11copy_outputENSt3__14spanIhLm18446744073709551615EEE:
  113|    126|      void copy_output(std::span<uint8_t> output) {
  114|    126|         BOTAN_ASSERT_NOMSG(output.size() >= MD::output_bytes);
  ------------------
  |  |   77|    126|   do {                                                                     \
  |  |   78|    126|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    126|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 126]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    126|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 126]
  |  |  ------------------
  ------------------
  115|       |
  116|    126|         if constexpr(MD::byte_endianness == MD_Endian::Big) {
  117|    126|            copy_out_be(output.first(MD::output_bytes), m_digest);
  118|       |         } else {
  119|       |            copy_out_le(output.first(MD::output_bytes), m_digest);
  120|       |         }
  121|    126|      }

_ZN5Botan16as_span_of_bytesEPKcm:
   59|  20.1k|inline std::span<const uint8_t> as_span_of_bytes(const char* s, size_t len) {
   60|  20.1k|   const uint8_t* b = reinterpret_cast<const uint8_t*>(s);
   61|  20.1k|   return std::span{b, len};
   62|  20.1k|}
_ZN5Botan17any_null_pointersIJPKcPmEEEbDpT_:
   54|   134k|bool any_null_pointers(Ptrs... ptr) {
   55|   134k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|   268k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 134k]
  |  Branch (56:19): [True: 0, False: 134k]
  ------------------
   57|   134k|}
_ZN5Botan17any_null_pointersIJPKhPhEEEbDpT_:
   54|  3.34M|bool any_null_pointers(Ptrs... ptr) {
   55|  3.34M|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  6.68M|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 3.34M]
  |  Branch (56:19): [True: 0, False: 3.34M]
  ------------------
   57|  3.34M|}
_ZN5Botan17any_null_pointersIJPmS1_EEEbDpT_:
   54|   727k|bool any_null_pointers(Ptrs... ptr) {
   55|   727k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  1.45M|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 727k]
  |  Branch (56:19): [True: 0, False: 727k]
  ------------------
   57|   727k|}
_ZN5Botan17any_null_pointersIJPP19botan_cipher_structPKcEEEbDpT_:
   54|  15.8k|bool any_null_pointers(Ptrs... ptr) {
   55|  15.8k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  31.7k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 15.8k]
  |  Branch (56:19): [True: 0, False: 15.8k]
  ------------------
   57|  15.8k|}
_ZN5Botan17any_null_pointersIJPKcS2_EEEbDpT_:
   54|  20.5k|bool any_null_pointers(Ptrs... ptr) {
   55|  20.5k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  41.1k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 20.5k]
  |  Branch (56:19): [True: 0, False: 20.5k]
  ------------------
   57|  20.5k|}
_ZN5Botan17any_null_pointersIJPP26botan_pk_op_encrypt_structPKcEEEbDpT_:
   54|     41|bool any_null_pointers(Ptrs... ptr) {
   55|     41|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|     82|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 41]
  |  Branch (56:19): [True: 0, False: 41]
  ------------------
   57|     41|}
_ZN5Botan17any_null_pointersIJPP25botan_pk_op_verify_structPKcEEEbDpT_:
   54|  10.7k|bool any_null_pointers(Ptrs... ptr) {
   55|  10.7k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  21.5k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 10.7k]
  |  Branch (56:19): [True: 0, False: 10.7k]
  ------------------
   57|  10.7k|}
_ZN5Botan17any_null_pointersIJPP19botan_pubkey_structPKhEEEbDpT_:
   54|  3.08k|bool any_null_pointers(Ptrs... ptr) {
   55|  3.08k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  6.16k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 3.08k]
  |  Branch (56:19): [True: 0, False: 3.08k]
  ------------------
   57|  3.08k|}
_ZN5Botan17any_null_pointersIJPP19botan_pubkey_structPKcEEEbDpT_:
   54|  6.29k|bool any_null_pointers(Ptrs... ptr) {
   55|  6.29k|   static_assert((... && std::is_pointer_v<Ptrs>), "All arguments must be pointers");
   56|  12.5k|   return (... || (ptr == nullptr));
  ------------------
  |  Branch (56:19): [True: 0, False: 6.29k]
  |  Branch (56:19): [True: 0, False: 6.29k]
  ------------------
   57|  6.29k|}
_ZN5Botan14zeroize_bufferITkNSt3__117unsigned_integralEhEEvPT_m:
   37|  6.18M|inline void zeroize_buffer(T buf[], size_t n) {
   38|  6.18M|   if(n > 0) {
  ------------------
  |  Branch (38:7): [True: 6.18M, False: 0]
  ------------------
   39|  6.18M|      std::memset(buf, 0, sizeof(T) * n);
   40|  6.18M|   }
   41|  6.18M|}
_ZN5Botan14zeroize_bufferITkNSt3__117unsigned_integralEmEEvPT_m:
   37|  1.53M|inline void zeroize_buffer(T buf[], size_t n) {
   38|  1.53M|   if(n > 0) {
  ------------------
  |  Branch (38:7): [True: 873k, False: 662k]
  ------------------
   39|   873k|      std::memset(buf, 0, sizeof(T) * n);
   40|   873k|   }
   41|  1.53M|}
_ZN5Botan21unchecked_copy_memoryITkNSt3__117unsigned_integralEmEEvPT_PKS2_m:
   44|   710k|inline void unchecked_copy_memory(T* out, const T* in, size_t n) {
   45|   710k|   if(in != nullptr && out != nullptr && n > 0) {
  ------------------
  |  Branch (45:7): [True: 710k, False: 0]
  |  Branch (45:24): [True: 710k, False: 0]
  |  Branch (45:42): [True: 710k, False: 0]
  ------------------
   46|   710k|      std::memmove(out, in, sizeof(T) * n);
   47|   710k|   }
   48|   710k|}

_ZNK5Botan17Montgomery_Params1pEv:
   41|   403k|      const BigInt& p() const { return m_data->p(); }
_ZNK5Botan17Montgomery_Params2R1Ev:
   43|  8.77k|      const BigInt& R1() const { return m_data->r1(); }
_ZNK5Botan17Montgomery_Params2R2Ev:
   45|  16.0k|      const BigInt& R2() const { return m_data->r2(); }
_ZNK5Botan17Montgomery_Params6p_dashEv:
   49|   395k|      word p_dash() const { return m_data->p_dash(); }
_ZNK5Botan17Montgomery_Params7p_wordsEv:
   51|   289k|      size_t p_words() const { return m_data->p_size(); }
_ZNK5Botan17Montgomery_Params4Data1pEv:
   76|   403k|            const BigInt& p() const { return m_p; }
_ZNK5Botan17Montgomery_Params4Data2r1Ev:
   78|  8.77k|            const BigInt& r1() const { return m_r1; }
_ZNK5Botan17Montgomery_Params4Data2r2Ev:
   80|  16.0k|            const BigInt& r2() const { return m_r2; }
_ZNK5Botan17Montgomery_Params4Data6p_dashEv:
   84|   395k|            word p_dash() const { return m_p_dash; }
_ZNK5Botan17Montgomery_Params4Data6p_sizeEv:
   86|   289k|            size_t p_size() const { return m_p_words; }
_ZNK5Botan14Montgomery_Int4reprEv:
  143|   335k|      const secure_vector<word>& repr() const { return m_v; }
_ZNK5Botan14Montgomery_Int18_const_time_poisonEv:
  159|  18.7k|      void _const_time_poison() const { CT::poison(m_v); }
_ZNK5Botan14Montgomery_Int20_const_time_unpoisonEv:
  161|    411|      void _const_time_unpoison() const { CT::unpoison(m_v); }
_ZNK5Botan14Montgomery_Int7_paramsEv:
  163|  1.49k|      const Montgomery_Params& _params() const { return m_params; }

_ZN5Botan10word8_add2ITkNS_8WordTypeEmEET_PS1_PKS1_S1_:
  268|  7.79k|inline constexpr auto word8_add2(W x[8], const W y[8], W carry) -> W {
  269|  7.79k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  270|  7.79k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (270:7): [True: 0, Folded]
  |  Branch (270:36): [True: 0, Folded]
  ------------------
  271|  7.79k|      asm volatile(ADD_OR_SUBTRACT(DO_8_TIMES(ADDSUB2_OP, "adcq"))
  272|  7.79k|                   : [carry] "=r"(carry)
  273|  7.79k|                   : [x] "r"(x), [y] "r"(y), "0"(carry)
  274|  7.79k|                   : "cc", "memory");
  275|  7.79k|      return carry;
  276|  7.79k|   }
  277|      0|#endif
  278|       |
  279|      0|   x[0] = word_add(x[0], y[0], &carry);
  280|      0|   x[1] = word_add(x[1], y[1], &carry);
  281|      0|   x[2] = word_add(x[2], y[2], &carry);
  282|      0|   x[3] = word_add(x[3], y[3], &carry);
  283|      0|   x[4] = word_add(x[4], y[4], &carry);
  284|      0|   x[5] = word_add(x[5], y[5], &carry);
  285|      0|   x[6] = word_add(x[6], y[6], &carry);
  286|      0|   x[7] = word_add(x[7], y[7], &carry);
  287|      0|   return carry;
  288|  7.79k|}
_ZN5Botan8word_addITkNS_8WordTypeEmEET_S1_S1_PS1_:
  231|   181M|inline constexpr auto word_add(W x, W y, W* carry) -> W {
  232|   181M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_addc)
  233|   181M|   if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (233:7): [True: 181M, Folded]
  ------------------
  234|       |      if constexpr(std::same_as<W, unsigned int>) {
  235|       |         return __builtin_addc(x, y, *carry & 1, carry);
  236|   181M|      } else if constexpr(std::same_as<W, unsigned long>) {
  237|   181M|         return __builtin_addcl(x, y, *carry & 1, carry);
  238|       |      } else if constexpr(std::same_as<W, unsigned long long>) {
  239|       |         return __builtin_addcll(x, y, *carry & 1, carry);
  240|       |      }
  241|   181M|   }
  242|      0|#endif
  243|       |
  244|       |   if constexpr(WordInfo<W>::dword_is_native && use_dword_for_word_add) {
  245|       |      /*
  246|       |      TODO(Botan4) this is largely a performance hack for GCCs that don't
  247|       |      support __builtin_addc, if we increase the minimum supported version of
  248|       |      GCC to GCC 14 then we can remove this and not worry about it
  249|       |      */
  250|       |      const W cb = *carry & 1;
  251|       |      const auto s = typename WordInfo<W>::dword(x) + y + cb;
  252|       |      *carry = static_cast<W>(s >> WordInfo<W>::bits);
  253|       |      return static_cast<W>(s);
  254|   181M|   } else {
  255|   181M|      const W cb = *carry & 1;
  256|   181M|      W z = x + y;
  257|   181M|      W c1 = (z < x);
  258|   181M|      z += cb;
  259|   181M|      *carry = c1 | (z < cb);
  260|   181M|      return z;
  261|   181M|   }
  262|   181M|}
_ZN5Botan10word8_sub2ITkNS_8WordTypeEmEET_PS1_PKS1_S1_:
  345|   108k|inline constexpr auto word8_sub2(W x[8], const W y[8], W carry) -> W {
  346|   108k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  347|   108k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (347:7): [True: 0, Folded]
  |  Branch (347:36): [True: 0, Folded]
  ------------------
  348|   108k|      asm volatile(ADD_OR_SUBTRACT(DO_8_TIMES(ADDSUB2_OP, "sbbq"))
  349|   108k|                   : [carry] "=r"(carry)
  350|   108k|                   : [x] "r"(x), [y] "r"(y), "0"(carry)
  351|   108k|                   : "cc", "memory");
  352|   108k|      return carry;
  353|   108k|   }
  354|      0|#endif
  355|       |
  356|      0|   x[0] = word_sub(x[0], y[0], &carry);
  357|      0|   x[1] = word_sub(x[1], y[1], &carry);
  358|      0|   x[2] = word_sub(x[2], y[2], &carry);
  359|      0|   x[3] = word_sub(x[3], y[3], &carry);
  360|      0|   x[4] = word_sub(x[4], y[4], &carry);
  361|      0|   x[5] = word_sub(x[5], y[5], &carry);
  362|      0|   x[6] = word_sub(x[6], y[6], &carry);
  363|      0|   x[7] = word_sub(x[7], y[7], &carry);
  364|      0|   return carry;
  365|   108k|}
_ZN5Botan8word_subITkNS_8WordTypeEmEET_S1_S1_PS1_:
  320|   213M|inline constexpr auto word_sub(W x, W y, W* carry) -> W {
  321|   213M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_subc)
  322|   213M|   if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (322:7): [True: 213M, Folded]
  ------------------
  323|       |      if constexpr(std::same_as<W, unsigned int>) {
  324|       |         return __builtin_subc(x, y, *carry & 1, carry);
  325|   213M|      } else if constexpr(std::same_as<W, unsigned long>) {
  326|   213M|         return __builtin_subcl(x, y, *carry & 1, carry);
  327|       |      } else if constexpr(std::same_as<W, unsigned long long>) {
  328|       |         return __builtin_subcll(x, y, *carry & 1, carry);
  329|       |      }
  330|   213M|   }
  331|      0|#endif
  332|       |
  333|      0|   const W cb = *carry & 1;
  334|   213M|   W t0 = x - y;
  335|   213M|   W c1 = (t0 > x);
  336|   213M|   W z = t0 - cb;
  337|   213M|   *carry = c1 | (z > t0);
  338|   213M|   return z;
  339|   213M|}
_ZN5Botan10word8_sub3ITkNS_8WordTypeEmEET_PS1_PKS1_S4_S1_:
  371|  57.6k|inline constexpr auto word8_sub3(W z[8], const W x[8], const W y[8], W carry) -> W {
  372|  57.6k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  373|  57.6k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (373:7): [True: 0, Folded]
  |  Branch (373:36): [True: 0, Folded]
  ------------------
  374|  57.6k|      asm volatile(ADD_OR_SUBTRACT(DO_8_TIMES(ADDSUB3_OP, "sbbq"))
  375|  57.6k|                   : [carry] "=r"(carry)
  376|  57.6k|                   : [x] "r"(x), [y] "r"(y), [z] "r"(z), "0"(carry)
  377|  57.6k|                   : "cc", "memory");
  378|  57.6k|      return carry;
  379|  57.6k|   }
  380|      0|#endif
  381|       |
  382|      0|   z[0] = word_sub(x[0], y[0], &carry);
  383|      0|   z[1] = word_sub(x[1], y[1], &carry);
  384|      0|   z[2] = word_sub(x[2], y[2], &carry);
  385|      0|   z[3] = word_sub(x[3], y[3], &carry);
  386|      0|   z[4] = word_sub(x[4], y[4], &carry);
  387|      0|   z[5] = word_sub(x[5], y[5], &carry);
  388|      0|   z[6] = word_sub(x[6], y[6], &carry);
  389|      0|   z[7] = word_sub(x[7], y[7], &carry);
  390|      0|   return carry;
  391|  57.6k|}
_ZN5Botan10word8_add3ITkNS_8WordTypeEmEET_PS1_PKS1_S4_S1_:
  294|  7.79k|inline constexpr auto word8_add3(W z[8], const W x[8], const W y[8], W carry) -> W {
  295|  7.79k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  296|  7.79k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (296:7): [True: 0, Folded]
  |  Branch (296:36): [True: 0, Folded]
  ------------------
  297|  7.79k|      asm volatile(ADD_OR_SUBTRACT(DO_8_TIMES(ADDSUB3_OP, "adcq"))
  298|  7.79k|                   : [carry] "=r"(carry)
  299|  7.79k|                   : [x] "r"(x), [y] "r"(y), [z] "r"(z), "0"(carry)
  300|  7.79k|                   : "cc", "memory");
  301|  7.79k|      return carry;
  302|  7.79k|   }
  303|      0|#endif
  304|       |
  305|      0|   z[0] = word_add(x[0], y[0], &carry);
  306|      0|   z[1] = word_add(x[1], y[1], &carry);
  307|      0|   z[2] = word_add(x[2], y[2], &carry);
  308|      0|   z[3] = word_add(x[3], y[3], &carry);
  309|      0|   z[4] = word_add(x[4], y[4], &carry);
  310|      0|   z[5] = word_add(x[5], y[5], &carry);
  311|      0|   z[6] = word_add(x[6], y[6], &carry);
  312|      0|   z[7] = word_add(x[7], y[7], &carry);
  313|      0|   return carry;
  314|  7.79k|}
_ZN5Botan13word8_linmul3ITkNS_8WordTypeEmEET_PS1_PKS1_S1_S1_:
  397|  82.5k|inline constexpr auto word8_linmul3(W z[8], const W x[8], W y, W carry) -> W {
  398|  82.5k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  399|  82.5k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (399:7): [True: 0, Folded]
  |  Branch (399:36): [True: 0, Folded]
  ------------------
  400|  82.5k|      asm volatile(DO_8_TIMES(LINMUL_OP, "z")
  401|  82.5k|                   : [carry] "=r"(carry)
  402|  82.5k|                   : [z] "r"(z), [x] "r"(x), [y] "rm"(y), "0"(carry)
  403|  82.5k|                   : "cc", "%rax", "%rdx", "memory");
  404|  82.5k|      return carry;
  405|  82.5k|   }
  406|      0|#endif
  407|       |
  408|      0|   z[0] = word_madd2(x[0], y, &carry);
  409|      0|   z[1] = word_madd2(x[1], y, &carry);
  410|      0|   z[2] = word_madd2(x[2], y, &carry);
  411|      0|   z[3] = word_madd2(x[3], y, &carry);
  412|      0|   z[4] = word_madd2(x[4], y, &carry);
  413|      0|   z[5] = word_madd2(x[5], y, &carry);
  414|      0|   z[6] = word_madd2(x[6], y, &carry);
  415|      0|   z[7] = word_madd2(x[7], y, &carry);
  416|      0|   return carry;
  417|  82.5k|}
_ZN5Botan10word_madd2ITkNS_8WordTypeEmEET_S1_S1_PS1_:
   90|  5.24M|inline constexpr auto word_madd2(W a, W b, W* c) -> W {
   91|  5.24M|#if defined(BOTAN_MP_USE_X86_64_ASM)
   92|  5.24M|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (92:7): [True: 0, Folded]
  |  Branch (92:36): [True: 0, Folded]
  ------------------
   93|  5.24M|      asm(R"(
   94|  5.24M|         mulq %[b]
   95|  5.24M|         addq %[c],%[a]
   96|  5.24M|         adcq $0,%[carry]
   97|  5.24M|         )"
   98|  5.24M|          : [a] "=a"(a), [b] "=rm"(b), [carry] "=&d"(*c)
   99|  5.24M|          : "0"(a), "1"(b), [c] "g"(*c)
  100|  5.24M|          : "cc");
  101|       |
  102|  5.24M|      return a;
  103|  5.24M|   }
  104|       |#elif defined(BOTAN_MP_USE_AARCH64_ASM)
  105|       |   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  106|       |      W lo = 0;
  107|       |      W hi = 0;
  108|       |      asm(R"(
  109|       |         mul  %[lo], %[a], %[b]
  110|       |         umulh %[hi], %[a], %[b]
  111|       |         adds %[lo], %[lo], %[c]
  112|       |         adc  %[hi], %[hi], xzr
  113|       |         )"
  114|       |          : [lo] "=&r"(lo), [hi] "=&r"(hi)
  115|       |          : [a] "r"(a), [b] "r"(b), [c] "r"(*c)
  116|       |          : "cc");
  117|       |
  118|       |      *c = hi;
  119|       |      return lo;
  120|       |   }
  121|       |#endif
  122|       |
  123|      0|   typedef typename WordInfo<W>::dword dword;
  124|      0|   const dword s = dword(a) * b + *c;
  125|      0|   *c = static_cast<W>(s >> WordInfo<W>::bits);
  126|      0|   return static_cast<W>(s);
  127|  5.24M|}
_ZN5Botan5word3ImEC2Ev:
  458|  26.8M|      constexpr word3() : m_w(0) {}
_ZN5Botan5word3ImE3mulEmm:
  460|   425M|      inline constexpr void mul(W x, W y) { m_w += static_cast<W3>(x) * y; }
_ZN5Botan5word3ImE7extractEv:
  466|   226M|      inline constexpr W extract() {
  467|   226M|         W r = static_cast<W>(m_w);
  468|   226M|         m_w >>= WordInfo<W>::bits;
  469|   226M|         return r;
  470|   226M|      }
_ZN5Botan5word3ImE6mul_x2Emm:
  462|  94.7M|      inline constexpr void mul_x2(W x, W y) { m_w += static_cast<W3>(x) * y * 2; }
_ZN5Botan11word8_madd3ITkNS_8WordTypeEmEET_PS1_PKS1_S1_S1_:
  423|   336k|inline constexpr auto word8_madd3(W z[8], const W x[8], W y, W carry) -> W {
  424|   336k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  425|   336k|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (425:7): [True: 0, Folded]
  |  Branch (425:36): [True: 0, Folded]
  ------------------
  426|   336k|      asm volatile(DO_8_TIMES(MULADD_OP, "")
  427|   336k|                   : [carry] "=r"(carry)
  428|   336k|                   : [z] "r"(z), [x] "r"(x), [y] "rm"(y), "0"(carry)
  429|   336k|                   : "cc", "%rax", "%rdx", "memory");
  430|   336k|      return carry;
  431|   336k|   }
  432|      0|#endif
  433|       |
  434|      0|   z[0] = word_madd3(x[0], y, z[0], &carry);
  435|      0|   z[1] = word_madd3(x[1], y, z[1], &carry);
  436|      0|   z[2] = word_madd3(x[2], y, z[2], &carry);
  437|      0|   z[3] = word_madd3(x[3], y, z[3], &carry);
  438|      0|   z[4] = word_madd3(x[4], y, z[4], &carry);
  439|      0|   z[5] = word_madd3(x[5], y, z[5], &carry);
  440|      0|   z[6] = word_madd3(x[6], y, z[6], &carry);
  441|      0|   z[7] = word_madd3(x[7], y, z[7], &carry);
  442|      0|   return carry;
  443|   336k|}
_ZN5Botan10word_madd3ITkNS_8WordTypeEmEET_S1_S1_S1_PS1_:
  133|  20.0M|inline constexpr auto word_madd3(W a, W b, W c, W* d) -> W {
  134|  20.0M|#if defined(BOTAN_MP_USE_X86_64_ASM)
  135|  20.0M|   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  ------------------
  |  Branch (135:7): [True: 0, Folded]
  |  Branch (135:36): [True: 0, Folded]
  ------------------
  136|  20.0M|      asm(R"(
  137|  20.0M|         mulq %[b]
  138|  20.0M|
  139|  20.0M|         addq %[c],%[a]
  140|  20.0M|         adcq $0,%[carry]
  141|  20.0M|
  142|  20.0M|         addq %[d],%[a]
  143|  20.0M|         adcq $0,%[carry]
  144|  20.0M|         )"
  145|  20.0M|          : [a] "=a"(a), [b] "=rm"(b), [carry] "=&d"(*d)
  146|  20.0M|          : "0"(a), "1"(b), [c] "g"(c), [d] "g"(*d)
  147|  20.0M|          : "cc");
  148|       |
  149|  20.0M|      return a;
  150|  20.0M|   }
  151|       |#elif defined(BOTAN_MP_USE_AARCH64_ASM)
  152|       |   if(std::same_as<W, uint64_t> && !std::is_constant_evaluated()) {
  153|       |      W lo = 0;
  154|       |      W hi = 0;
  155|       |      asm(R"(
  156|       |         mul  %[lo], %[a], %[b]
  157|       |         umulh %[hi], %[a], %[b]
  158|       |         adds %[lo], %[lo], %[c]
  159|       |         adc  %[hi], %[hi], xzr
  160|       |         adds %[lo], %[lo], %[d]
  161|       |         adc  %[hi], %[hi], xzr
  162|       |         )"
  163|       |          : [lo] "=&r"(lo), [hi] "=&r"(hi)
  164|       |          : [a] "r"(a), [b] "r"(b), [c] "r"(c), [d] "r"(*d)
  165|       |          : "cc");
  166|       |
  167|       |      *d = hi;
  168|       |      return lo;
  169|       |   }
  170|       |#endif
  171|       |
  172|      0|   typedef typename WordInfo<W>::dword dword;
  173|      0|   const dword s = dword(a) * b + c + *d;
  174|      0|   *d = static_cast<W>(s >> WordInfo<W>::bits);
  175|      0|   return static_cast<W>(s);
  176|  20.0M|}
_ZN5Botan5word3ImE3addEm:
  464|  12.9M|      inline constexpr void add(W x) { m_w += x; }
_ZN5Botan5word3ImE10monty_stepEmm:
  472|  6.46M|      inline constexpr W monty_step(W p0, W p_dash) {
  473|  6.46M|         const W w0 = static_cast<W>(m_w);
  474|  6.46M|         const W r = w0 * p_dash;
  475|  6.46M|         mul(r, p0);
  476|  6.46M|         m_w >>= WordInfo<W>::bits;
  477|  6.46M|         return r;
  478|  6.46M|      }

_ZN5Botan17bigint_monty_redcEPmPKmS2_mmS0_m:
  924|   395k|   word r[], const word z[], const word p[], size_t p_size, word p_dash, word ws[], size_t ws_size) {
  925|   395k|   const size_t z_size = 2 * p_size;
  926|       |
  927|   395k|   BOTAN_ARG_CHECK(ws_size >= p_size, "Montgomery reduction workspace too small");
  ------------------
  |  |   35|   395k|   do {                                                          \
  |  |   36|   395k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   395k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 395k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   395k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 395k]
  |  |  ------------------
  ------------------
  928|       |
  929|   395k|   if(p_size == 4) {
  ------------------
  |  Branch (929:7): [True: 12.5k, False: 383k]
  ------------------
  930|  12.5k|      bigint_monty_redc_4(r, z, p, p_dash, ws);
  931|   383k|   } else if(p_size == 6) {
  ------------------
  |  Branch (931:14): [True: 0, False: 383k]
  ------------------
  932|      0|      bigint_monty_redc_6(r, z, p, p_dash, ws);
  933|   383k|   } else if(p_size == 8) {
  ------------------
  |  Branch (933:14): [True: 0, False: 383k]
  ------------------
  934|      0|      bigint_monty_redc_8(r, z, p, p_dash, ws);
  935|   383k|   } else if(p_size == 12) {
  ------------------
  |  Branch (935:14): [True: 0, False: 383k]
  ------------------
  936|      0|      bigint_monty_redc_12(r, z, p, p_dash, ws);
  937|   383k|   } else if(p_size == 16) {
  ------------------
  |  Branch (937:14): [True: 382k, False: 323]
  ------------------
  938|   382k|      bigint_monty_redc_16(r, z, p, p_dash, ws);
  939|   382k|   } else if(p_size == 24) {
  ------------------
  |  Branch (939:14): [True: 0, False: 323]
  ------------------
  940|      0|      bigint_monty_redc_24(r, z, p, p_dash, ws);
  941|    323|   } else if(p_size == 32) {
  ------------------
  |  Branch (941:14): [True: 0, False: 323]
  ------------------
  942|      0|      bigint_monty_redc_32(r, z, p, p_dash, ws);
  943|    323|   } else {
  944|    323|      bigint_monty_redc_generic(r, z, z_size, p, p_size, p_dash, ws);
  945|    323|   }
  946|   395k|}
_ZN5Botan25bigint_monty_redc_inplaceEPmPKmmmS0_m:
  948|   395k|inline void bigint_monty_redc_inplace(word z[], const word p[], size_t p_size, word p_dash, word ws[], size_t ws_size) {
  949|   395k|   bigint_monty_redc(z, z, p, p_size, p_dash, ws, ws_size);
  950|   395k|   zeroize_buffer(z + p_size, p_size);
  951|   395k|}
_ZN5Botan11bigint_add2ITkNS_8WordTypeEmEET_PS1_mPKS1_m:
   94|  6.97M|inline constexpr auto bigint_add2(W x[], size_t x_size, const W y[], size_t y_size) -> W {
   95|  6.97M|   W carry = 0;
   96|       |
   97|  6.97M|   BOTAN_ASSERT(x_size >= y_size, "Expected sizes");
  ------------------
  |  |   64|  6.97M|   do {                                                                                 \
  |  |   65|  6.97M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  6.97M|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 6.97M]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  6.97M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 6.97M]
  |  |  ------------------
  ------------------
   98|       |
   99|  6.97M|   const size_t blocks = y_size - (y_size % 8);
  100|       |
  101|  6.98M|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (101:22): [True: 7.79k, False: 6.97M]
  ------------------
  102|  7.79k|      carry = word8_add2(x + i, y + i, carry);
  103|  7.79k|   }
  104|       |
  105|  24.9M|   for(size_t i = blocks; i != y_size; ++i) {
  ------------------
  |  Branch (105:27): [True: 17.9M, False: 6.97M]
  ------------------
  106|  17.9M|      x[i] = word_add(x[i], y[i], &carry);
  107|  17.9M|   }
  108|       |
  109|  16.9M|   for(size_t i = y_size; i != x_size; ++i) {
  ------------------
  |  Branch (109:27): [True: 9.99M, False: 6.97M]
  ------------------
  110|  9.99M|      x[i] = word_add(x[i], static_cast<W>(0), &carry);
  111|  9.99M|   }
  112|       |
  113|  6.97M|   return carry;
  114|  6.97M|}
_ZN5Botan10bigint_cmpITkNS_8WordTypeEmEEiPKT_mS3_m:
  439|  82.3k|inline constexpr int32_t bigint_cmp(const W x[], size_t x_size, const W y[], size_t y_size) {
  440|  82.3k|   static_assert(sizeof(W) >= sizeof(uint32_t), "Size assumption");
  441|       |
  442|  82.3k|   const W LT = static_cast<W>(-1);
  443|  82.3k|   const W EQ = 0;
  444|  82.3k|   const W GT = 1;
  445|       |
  446|  82.3k|   const size_t common_elems = std::min(x_size, y_size);
  447|       |
  448|  82.3k|   W result = EQ;  // until found otherwise
  449|       |
  450|  1.33M|   for(size_t i = 0; i != common_elems; i++) {
  ------------------
  |  Branch (450:22): [True: 1.25M, False: 82.3k]
  ------------------
  451|  1.25M|      const auto is_eq = CT::Mask<W>::is_equal(x[i], y[i]);
  452|  1.25M|      const auto is_lt = CT::Mask<W>::is_lt(x[i], y[i]);
  453|       |
  454|  1.25M|      result = is_eq.select(result, is_lt.select(LT, GT));
  455|  1.25M|   }
  456|       |
  457|  82.3k|   if(x_size < y_size) {
  ------------------
  |  Branch (457:7): [True: 390, False: 81.9k]
  ------------------
  458|    390|      W mask = 0;
  459|  4.41k|      for(size_t i = x_size; i != y_size; i++) {
  ------------------
  |  Branch (459:30): [True: 4.02k, False: 390]
  ------------------
  460|  4.02k|         mask |= y[i];
  461|  4.02k|      }
  462|       |
  463|       |      // If any bits were set in high part of y, then x < y
  464|    390|      result = CT::Mask<W>::is_zero(mask).select(result, LT);
  465|  81.9k|   } else if(y_size < x_size) {
  ------------------
  |  Branch (465:14): [True: 1.48k, False: 80.4k]
  ------------------
  466|  1.48k|      W mask = 0;
  467|  2.98k|      for(size_t i = y_size; i != x_size; i++) {
  ------------------
  |  Branch (467:30): [True: 1.49k, False: 1.48k]
  ------------------
  468|  1.49k|         mask |= x[i];
  469|  1.49k|      }
  470|       |
  471|       |      // If any bits were set in high part of x, then x > y
  472|  1.48k|      result = CT::Mask<W>::is_zero(mask).select(result, GT);
  473|  1.48k|   }
  474|       |
  475|  82.3k|   CT::unpoison(result);
  476|  82.3k|   BOTAN_DEBUG_ASSERT(result == LT || result == GT || result == EQ);
  ------------------
  |  |  130|  82.3k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  82.3k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 82.3k]
  |  |  ------------------
  ------------------
  477|  82.3k|   return static_cast<int32_t>(result);
  478|  82.3k|}
_ZN5Botan11bigint_sub2ITkNS_8WordTypeEmEET_PS1_mPKS1_m:
  148|  52.9k|inline constexpr auto bigint_sub2(W x[], size_t x_size, const W y[], size_t y_size) -> W {
  149|  52.9k|   W borrow = 0;
  150|       |
  151|  52.9k|   BOTAN_ASSERT(x_size >= y_size, "Expected sizes");
  ------------------
  |  |   64|  52.9k|   do {                                                                                 \
  |  |   65|  52.9k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  52.9k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 52.9k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  52.9k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 52.9k]
  |  |  ------------------
  ------------------
  152|       |
  153|  52.9k|   const size_t blocks = y_size - (y_size % 8);
  154|       |
  155|   161k|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (155:22): [True: 108k, False: 52.9k]
  ------------------
  156|   108k|      borrow = word8_sub2(x + i, y + i, borrow);
  157|   108k|   }
  158|       |
  159|   236k|   for(size_t i = blocks; i != y_size; ++i) {
  ------------------
  |  Branch (159:27): [True: 183k, False: 52.9k]
  ------------------
  160|   183k|      x[i] = word_sub(x[i], y[i], &borrow);
  161|   183k|   }
  162|       |
  163|  77.7k|   for(size_t i = y_size; i != x_size; ++i) {
  ------------------
  |  Branch (163:27): [True: 24.7k, False: 52.9k]
  ------------------
  164|  24.7k|      x[i] = word_sub(x[i], static_cast<W>(0), &borrow);
  165|  24.7k|   }
  166|       |
  167|  52.9k|   return borrow;
  168|  52.9k|}
_ZN5Botan11bigint_sub3ITkNS_8WordTypeEmEET_PS1_PKS1_mS4_m:
  192|  3.29M|inline constexpr auto bigint_sub3(W z[], const W x[], size_t x_size, const W y[], size_t y_size) -> W {
  193|  3.29M|   W borrow = 0;
  194|       |
  195|  3.29M|   BOTAN_ASSERT(x_size >= y_size, "Expected sizes");
  ------------------
  |  |   64|  3.29M|   do {                                                                                 \
  |  |   65|  3.29M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  3.29M|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 3.29M]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  3.29M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 3.29M]
  |  |  ------------------
  ------------------
  196|       |
  197|  3.29M|   const size_t blocks = y_size - (y_size % 8);
  198|       |
  199|  3.32M|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (199:22): [True: 26.7k, False: 3.29M]
  ------------------
  200|  26.7k|      borrow = word8_sub3(z + i, x + i, y + i, borrow);
  201|  26.7k|   }
  202|       |
  203|  16.4M|   for(size_t i = blocks; i != y_size; ++i) {
  ------------------
  |  Branch (203:27): [True: 13.1M, False: 3.29M]
  ------------------
  204|  13.1M|      z[i] = word_sub(x[i], y[i], &borrow);
  205|  13.1M|   }
  206|       |
  207|  3.31M|   for(size_t i = y_size; i != x_size; ++i) {
  ------------------
  |  Branch (207:27): [True: 16.7k, False: 3.29M]
  ------------------
  208|  16.7k|      z[i] = word_sub(x[i], static_cast<W>(0), &borrow);
  209|  16.7k|   }
  210|       |
  211|  3.29M|   return borrow;
  212|  3.29M|}
_ZN5Botan11bigint_add3ITkNS_8WordTypeEmEET_PS1_PKS1_mS4_m:
  120|  1.49k|inline constexpr auto bigint_add3(W z[], const W x[], size_t x_size, const W y[], size_t y_size) -> W {
  121|  1.49k|   if(x_size < y_size) {
  ------------------
  |  Branch (121:7): [True: 0, False: 1.49k]
  ------------------
  122|      0|      return bigint_add3(z, y, y_size, x, x_size);
  123|      0|   }
  124|       |
  125|  1.49k|   W carry = 0;
  126|       |
  127|  1.49k|   const size_t blocks = y_size - (y_size % 8);
  128|       |
  129|  9.28k|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (129:22): [True: 7.79k, False: 1.49k]
  ------------------
  130|  7.79k|      carry = word8_add3(z + i, x + i, y + i, carry);
  131|  7.79k|   }
  132|       |
  133|  1.74k|   for(size_t i = blocks; i != y_size; ++i) {
  ------------------
  |  Branch (133:27): [True: 245, False: 1.49k]
  ------------------
  134|    245|      z[i] = word_add(x[i], y[i], &carry);
  135|    245|   }
  136|       |
  137|  1.50k|   for(size_t i = y_size; i != x_size; ++i) {
  ------------------
  |  Branch (137:27): [True: 7, False: 1.49k]
  ------------------
  138|      7|      z[i] = word_add(x[i], static_cast<W>(0), &carry);
  139|      7|   }
  140|       |
  141|  1.49k|   return carry;
  142|  1.49k|}
_ZN5Botan14bigint_cnd_addITkNS_8WordTypeEmEET_S1_PS1_PKS1_m:
   45|   986k|inline constexpr W bigint_cnd_add(W cnd, W x[], const W y[], size_t size) {
   46|   986k|   const auto mask = CT::Mask<W>::expand(cnd).value();
   47|       |
   48|   986k|   W carry = 0;
   49|       |
   50|  3.96M|   for(size_t i = 0; i != size; ++i) {
  ------------------
  |  Branch (50:22): [True: 2.98M, False: 986k]
  ------------------
   51|  2.98M|      x[i] = word_add(x[i], y[i] & mask, &carry);
   52|  2.98M|   }
   53|       |
   54|   986k|   return (mask & carry);
   55|   986k|}
_ZN5Botan14bigint_linmul3ITkNS_8WordTypeEmEEvPT_PKS1_mS1_:
  416|  43.2k|inline constexpr void bigint_linmul3(W z[], const W x[], size_t x_size, W y) {
  417|  43.2k|   const size_t blocks = x_size - (x_size % 8);
  418|       |
  419|  43.2k|   W carry = 0;
  420|       |
  421|   125k|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (421:22): [True: 82.5k, False: 43.2k]
  ------------------
  422|  82.5k|      carry = word8_linmul3(z + i, x + i, y, carry);
  423|  82.5k|   }
  424|       |
  425|   203k|   for(size_t i = blocks; i != x_size; ++i) {
  ------------------
  |  Branch (425:27): [True: 159k, False: 43.2k]
  ------------------
  426|   159k|      z[i] = word_madd2(x[i], y, &carry);
  427|   159k|   }
  428|       |
  429|  43.2k|   z[x_size] = carry;
  430|  43.2k|}
_ZN5Botan14divide_precompImEC2Em:
  574|  3.59k|      explicit constexpr divide_precomp(W divisor) : m_divisor(divisor) {
  575|  3.59k|         BOTAN_ARG_CHECK(m_divisor != 0, "Division by zero");
  ------------------
  |  |   35|  3.59k|   do {                                                          \
  |  |   36|  3.59k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  3.59k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 3.59k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  3.59k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 3.59k]
  |  |  ------------------
  ------------------
  576|  3.59k|      }
_ZNK5Botan14divide_precompImE16vartime_div_2to1Emm:
  581|  44.7k|      inline constexpr W vartime_div_2to1(W n1, W n0) const {
  582|  44.7k|         BOTAN_ASSERT_NOMSG(n1 < m_divisor);
  ------------------
  |  |   77|  44.7k|   do {                                                                     \
  |  |   78|  44.7k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  44.7k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 44.7k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  44.7k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 44.7k]
  |  |  ------------------
  ------------------
  583|       |
  584|  44.7k|         if(m_divisor == WordInfo<W>::max) {
  ------------------
  |  Branch (584:13): [True: 15, False: 44.7k]
  ------------------
  585|     15|            return vartime_div_2to1_max_d(n1, n0);
  586|     15|         }
  587|       |
  588|  44.7k|         if(m_divisor == WordInfo<W>::top_bit) {
  ------------------
  |  Branch (588:13): [True: 0, False: 44.7k]
  ------------------
  589|       |            // Simply a shift by N-1 bits
  590|      0|            return (n1 << 1) | (n0 >> (WordInfo<W>::bits - 1));
  591|      0|         }
  592|       |
  593|  44.7k|         if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (593:13): [True: 44.7k, Folded]
  ------------------
  594|  44.7k|#if defined(BOTAN_MP_USE_X86_64_ASM)
  595|  44.7k|            if constexpr(std::same_as<W, uint64_t>) {
  596|  44.7k|               W quotient = 0;
  597|  44.7k|               W remainder = 0;
  598|       |               // NOLINTNEXTLINE(*-no-assembler)
  599|  44.7k|               asm("divq %[v]" : "=a"(quotient), "=d"(remainder) : [v] "r"(m_divisor), "a"(n0), "d"(n1) : "cc");
  600|  44.7k|               return quotient;
  601|  44.7k|            }
  602|      0|#endif
  603|       |
  604|      0|#if !defined(BOTAN_BUILD_COMPILER_IS_CLANGCL)
  605|       |
  606|       |            /* clang-cl has a bug where on encountering a 128/64 division it emits
  607|       |            * a call to __udivti3() but then fails to link the relevant builtin into
  608|       |            * the binary, causing a link failure. Work around this by simply omitting
  609|       |            * such code for clang-cl
  610|       |            *
  611|       |            * See https://github.com/llvm/llvm-project/issues/25679
  612|       |            */
  613|  44.7k|            if constexpr(WordInfo<W>::dword_is_native) {
  614|  44.7k|               typename WordInfo<W>::dword n = n1;
  615|  44.7k|               n <<= WordInfo<W>::bits;
  616|  44.7k|               n |= n0;
  617|  44.7k|               return static_cast<W>(n / m_divisor);
  618|  44.7k|            }
  619|  44.7k|#endif
  620|  44.7k|         }
  621|       |
  622|      0|         W high = n1;
  623|  44.7k|         W quotient = 0;
  624|       |
  625|  44.7k|         for(size_t i = 0; i != WordInfo<W>::bits; ++i) {
  ------------------
  |  Branch (625:28): [True: 0, False: 44.7k]
  ------------------
  626|      0|            const W high_top_bit = high >> (WordInfo<W>::bits - 1);
  627|       |
  628|      0|            high <<= 1;
  629|      0|            high |= (n0 >> (WordInfo<W>::bits - 1 - i)) & 1;
  630|      0|            quotient <<= 1;
  631|       |
  632|      0|            if(high_top_bit || high >= m_divisor) {
  ------------------
  |  Branch (632:16): [True: 0, False: 0]
  |  Branch (632:32): [True: 0, False: 0]
  ------------------
  633|      0|               high -= m_divisor;
  634|      0|               quotient |= 1;
  635|      0|            }
  636|      0|         }
  637|       |
  638|  44.7k|         return quotient;
  639|  44.7k|      }
_ZN5Botan14divide_precompImE22vartime_div_2to1_max_dEmm:
  657|     15|      static inline constexpr W vartime_div_2to1_max_d(W n1, W n0) {
  658|       |         /*
  659|       |         Use k to refer to WordInfo<W>::bits
  660|       |
  661|       |         We are dividing n = (n1 * 2^k) + n0 by 2^k - 1
  662|       |
  663|       |         Recall that 2^k = 1 (mod 2^k - 1)
  664|       |
  665|       |         Rewrite n = n1*2^k + n0 as n1*(2^k - 1) + n1 + n0
  666|       |
  667|       |         The result of dividing n by (2^k - 1) will be equal to
  668|       |         (n1*(2^k-1) + n1 + n0) / (2^k-1) =
  669|       |         n1 + ((n1 + n0) / (2^k-1)
  670|       |
  671|       |         Use c to refer to ((n1 + n0) / (2^k-1))
  672|       |
  673|       |         If (n1 + n0) < (2^k - 1) then c is 0
  674|       |         If (n1 + n0) >= (2^k - 1) then c is 1
  675|       |
  676|       |         Since n1 < 2^k - 1 [*] and n0 <= 2^k - 1 it is impossible for (n1 + n0) / (2^k -1)
  677|       |         to be greater than 1.
  678|       |
  679|       |         [*] We require n1 be strictly less than the divisor to ensure that the
  680|       |         output fits in a single word; this is checked at the start of vartime_div_2to1.
  681|       |         */
  682|       |
  683|     15|         const W s = n0 + n1;
  684|       |         // did n0 + n1 overflow? or does (n0 + n1) == 2^k - 1? if either, c == 1
  685|     15|         if(s < n0 || s == WordInfo<W>::max) {
  ------------------
  |  Branch (685:13): [True: 0, False: 15]
  |  Branch (685:23): [True: 0, False: 15]
  ------------------
  686|      0|            n1 += 1;
  687|      0|         }
  688|       |
  689|     15|         return n1;
  690|     15|      }
_ZN5Botan11bigint_shl1ITkNS_8WordTypeEmEEvPT_mmm:
  309|  3.14k|inline constexpr void bigint_shl1(W x[], size_t x_size, size_t x_words, size_t shift) {
  310|  3.14k|   const size_t word_shift = shift / WordInfo<W>::bits;
  311|  3.14k|   const size_t bit_shift = shift % WordInfo<W>::bits;
  312|       |
  313|  3.14k|   BOTAN_ASSERT_NOMSG(word_shift <= x_size);
  ------------------
  |  |   77|  3.14k|   do {                                                                     \
  |  |   78|  3.14k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.14k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.14k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.14k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.14k]
  |  |  ------------------
  ------------------
  314|  3.14k|   BOTAN_ASSERT_NOMSG(x_words <= x_size - word_shift);
  ------------------
  |  |   77|  3.14k|   do {                                                                     \
  |  |   78|  3.14k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.14k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.14k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.14k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.14k]
  |  |  ------------------
  ------------------
  315|       |
  316|  3.14k|   unchecked_copy_memory(x + word_shift, x, x_words);
  317|  3.14k|   zeroize_buffer(x, word_shift);
  318|       |
  319|  3.14k|   const auto carry_mask = CT::Mask<W>::expand(bit_shift);
  320|  3.14k|   const W carry_shift = carry_mask.if_set_return(WordInfo<W>::bits - bit_shift);
  321|       |
  322|  3.14k|   W carry = 0;
  323|  29.0k|   for(size_t i = word_shift; i != x_size; ++i) {
  ------------------
  |  Branch (323:31): [True: 25.9k, False: 3.14k]
  ------------------
  324|  25.9k|      const W w = x[i];
  325|  25.9k|      x[i] = (w << bit_shift) | carry;
  326|  25.9k|      carry = carry_mask.if_set_return(w >> carry_shift);
  327|  25.9k|   }
  328|  3.14k|}
_ZN5Botan11bigint_shr1ITkNS_8WordTypeEmEEvPT_mm:
  331|   704k|inline constexpr void bigint_shr1(W x[], size_t x_size, size_t shift) {
  332|   704k|   const size_t word_shift = shift / WordInfo<W>::bits;
  333|   704k|   const size_t bit_shift = shift % WordInfo<W>::bits;
  334|       |
  335|   704k|   const size_t top = x_size >= word_shift ? (x_size - word_shift) : 0;
  ------------------
  |  Branch (335:23): [True: 704k, False: 0]
  ------------------
  336|       |
  337|   704k|   if(top > 0) {
  ------------------
  |  Branch (337:7): [True: 704k, False: 0]
  ------------------
  338|   704k|      unchecked_copy_memory(x, x + word_shift, top);
  339|   704k|   }
  340|   704k|   zeroize_buffer(x + top, std::min(word_shift, x_size));
  341|       |
  342|   704k|   const auto carry_mask = CT::Mask<W>::expand(bit_shift);
  343|   704k|   const W carry_shift = carry_mask.if_set_return(WordInfo<W>::bits - bit_shift);
  344|       |
  345|   704k|   W carry = 0;
  346|       |
  347|  4.24M|   for(size_t i = 0; i != top; ++i) {
  ------------------
  |  Branch (347:22): [True: 3.53M, False: 704k]
  ------------------
  348|  3.53M|      const W w = x[top - i - 1];
  349|  3.53M|      x[top - i - 1] = (w >> bit_shift) | carry;
  350|  3.53M|      carry = carry_mask.if_set_return(w << carry_shift);
  351|  3.53M|   }
  352|   704k|}
_ZN5Botan11bigint_shl2ITkNS_8WordTypeEmEEvPT_mPKS1_mm:
  355|  3.59k|inline constexpr void bigint_shl2(W y[], size_t y_size, const W x[], size_t x_size, size_t shift) {
  356|  3.59k|   const size_t word_shift = shift / WordInfo<W>::bits;
  357|  3.59k|   const size_t bit_shift = shift % WordInfo<W>::bits;
  358|       |
  359|  3.59k|   BOTAN_ASSERT_NOMSG(word_shift <= y_size);
  ------------------
  |  |   77|  3.59k|   do {                                                                     \
  |  |   78|  3.59k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.59k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.59k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.59k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.59k]
  |  |  ------------------
  ------------------
  360|  3.59k|   BOTAN_ASSERT_NOMSG(x_size < y_size - word_shift);
  ------------------
  |  |   77|  3.59k|   do {                                                                     \
  |  |   78|  3.59k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.59k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.59k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.59k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.59k]
  |  |  ------------------
  ------------------
  361|       |
  362|  3.59k|   unchecked_copy_memory(y + word_shift, x, x_size);
  363|  3.59k|   zeroize_buffer(y, word_shift);
  364|  3.59k|   zeroize_buffer(y + word_shift + x_size, y_size - word_shift - x_size);
  365|       |
  366|  3.59k|   const auto carry_mask = CT::Mask<W>::expand(bit_shift);
  367|  3.59k|   const W carry_shift = carry_mask.if_set_return(WordInfo<W>::bits - bit_shift);
  368|       |
  369|  3.59k|   W carry = 0;
  370|  38.1k|   for(size_t i = word_shift; i != x_size + word_shift + 1; ++i) {
  ------------------
  |  Branch (370:31): [True: 34.5k, False: 3.59k]
  ------------------
  371|  34.5k|      const W w = y[i];
  372|  34.5k|      y[i] = (w << bit_shift) | carry;
  373|  34.5k|      carry = carry_mask.if_set_return(w >> carry_shift);
  374|  34.5k|   }
  375|  3.59k|}
_ZN5Botan15bigint_ct_is_eqITkNS_8WordTypeEmEENS_2CT4MaskIT_EEPKS3_mS6_m:
  519|  1.03k|inline constexpr auto bigint_ct_is_eq(const W x[], size_t x_size, const W y[], size_t y_size) -> CT::Mask<W> {
  520|  1.03k|   const size_t common_elems = std::min(x_size, y_size);
  521|       |
  522|  1.03k|   W diff = 0;
  523|       |
  524|  9.30k|   for(size_t i = 0; i != common_elems; i++) {
  ------------------
  |  Branch (524:22): [True: 8.27k, False: 1.03k]
  ------------------
  525|  8.27k|      diff |= (x[i] ^ y[i]);
  526|  8.27k|   }
  527|       |
  528|       |   // If any bits were set in high part of x/y, then they are not equal
  529|  1.03k|   if(x_size < y_size) {
  ------------------
  |  Branch (529:7): [True: 0, False: 1.03k]
  ------------------
  530|      0|      for(size_t i = x_size; i != y_size; i++) {
  ------------------
  |  Branch (530:30): [True: 0, False: 0]
  ------------------
  531|      0|         diff |= y[i];
  532|      0|      }
  533|  1.03k|   } else if(y_size < x_size) {
  ------------------
  |  Branch (533:14): [True: 1.02k, False: 6]
  ------------------
  534|  25.6k|      for(size_t i = y_size; i != x_size; i++) {
  ------------------
  |  Branch (534:30): [True: 24.6k, False: 1.02k]
  ------------------
  535|  24.6k|         diff |= x[i];
  536|  24.6k|      }
  537|  1.02k|   }
  538|       |
  539|  1.03k|   return CT::Mask<W>::is_zero(diff);
  540|  1.03k|}
_ZN5Botan15bigint_ct_is_ltITkNS_8WordTypeEmEENS_2CT4MaskIT_EEPKS3_mS6_mb:
  487|  57.8k|   -> CT::Mask<W> {
  488|  57.8k|   const size_t common_elems = std::min(x_size, y_size);
  489|       |
  490|  57.8k|   auto is_lt = CT::Mask<W>::expand(lt_or_equal);
  491|       |
  492|   460k|   for(size_t i = 0; i != common_elems; i++) {
  ------------------
  |  Branch (492:22): [True: 402k, False: 57.8k]
  ------------------
  493|   402k|      const auto eq = CT::Mask<W>::is_equal(x[i], y[i]);
  494|   402k|      const auto lt = CT::Mask<W>::is_lt(x[i], y[i]);
  495|   402k|      is_lt = eq.select_mask(is_lt, lt);
  496|   402k|   }
  497|       |
  498|  57.8k|   if(x_size < y_size) {
  ------------------
  |  Branch (498:7): [True: 82, False: 57.7k]
  ------------------
  499|     82|      W mask = 0;
  500|    738|      for(size_t i = x_size; i != y_size; i++) {
  ------------------
  |  Branch (500:30): [True: 656, False: 82]
  ------------------
  501|    656|         mask |= y[i];
  502|    656|      }
  503|       |      // If any bits were set in high part of y, then is_lt should be forced true
  504|     82|      is_lt |= CT::Mask<W>::expand(mask);
  505|  57.7k|   } else if(y_size < x_size) {
  ------------------
  |  Branch (505:14): [True: 12.1k, False: 45.5k]
  ------------------
  506|  12.1k|      W mask = 0;
  507|   215k|      for(size_t i = y_size; i != x_size; i++) {
  ------------------
  |  Branch (507:30): [True: 202k, False: 12.1k]
  ------------------
  508|   202k|         mask |= x[i];
  509|   202k|      }
  510|       |
  511|       |      // If any bits were set in high part of x, then is_lt should be false
  512|  12.1k|      is_lt &= CT::Mask<W>::is_zero(mask);
  513|  12.1k|   }
  514|       |
  515|  57.8k|   return is_lt;
  516|  57.8k|}
_ZN5Botan15bigint_cnd_swapITkNS_8WordTypeEmEEvT_PS1_S2_m:
   29|   328k|inline constexpr void bigint_cnd_swap(W cnd, W x[], W y[], size_t size) {
   30|   328k|   const auto mask = CT::Mask<W>::expand(cnd);
   31|       |
   32|  1.31M|   for(size_t i = 0; i != size; ++i) {
  ------------------
  |  Branch (32:22): [True: 985k, False: 328k]
  ------------------
   33|   985k|      const W a = x[i];
   34|   985k|      const W b = y[i];
   35|   985k|      x[i] = mask.select(b, a);
   36|   985k|      y[i] = mask.select(a, b);
   37|   985k|   }
   38|   328k|}
_ZN5Botan14bigint_sub_absITkNS_8WordTypeEmEENS_2CT4MaskIT_EEPS3_PKS3_S7_mS5_:
  279|  8.36k|inline constexpr auto bigint_sub_abs(W z[], const W x[], const W y[], size_t N, W ws[]) -> CT::Mask<W> {
  280|       |   // Subtract in both direction then conditional copy out the result
  281|       |
  282|  8.36k|   W* ws0 = ws;
  283|  8.36k|   W* ws1 = ws + N;
  284|       |
  285|  8.36k|   W borrow0 = 0;
  286|  8.36k|   W borrow1 = 0;
  287|       |
  288|  8.36k|   const size_t blocks = N - (N % 8);
  289|       |
  290|  22.5k|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (290:22): [True: 14.1k, False: 8.36k]
  ------------------
  291|  14.1k|      borrow0 = word8_sub3(ws0 + i, x + i, y + i, borrow0);
  292|  14.1k|      borrow1 = word8_sub3(ws1 + i, y + i, x + i, borrow1);
  293|  14.1k|   }
  294|       |
  295|  21.3k|   for(size_t i = blocks; i != N; ++i) {
  ------------------
  |  Branch (295:27): [True: 13.0k, False: 8.36k]
  ------------------
  296|  13.0k|      ws0[i] = word_sub(x[i], y[i], &borrow0);
  297|  13.0k|      ws1[i] = word_sub(y[i], x[i], &borrow1);
  298|  13.0k|   }
  299|       |
  300|  8.36k|   return CT::conditional_copy_mem(borrow0, z, ws1, ws0, N);
  301|  8.36k|}
_ZN5Botan14bigint_cnd_subITkNS_8WordTypeEmEET_S1_PS1_PKS1_m:
   62|   657k|inline constexpr auto bigint_cnd_sub(W cnd, W x[], const W y[], size_t size) -> W {
   63|   657k|   const auto mask = CT::Mask<W>::expand(cnd).value();
   64|       |
   65|   657k|   W carry = 0;
   66|       |
   67|  2.65M|   for(size_t i = 0; i != size; ++i) {
  ------------------
  |  Branch (67:22): [True: 1.99M, False: 657k]
  ------------------
   68|  1.99M|      x[i] = word_sub(x[i], y[i] & mask, &carry);
   69|  1.99M|   }
   70|       |
   71|   657k|   return (mask & carry);
   72|   657k|}
_ZN5Botan22bigint_monty_maybe_subITkNS_8WordTypeEmEEvmPT_S1_PKS1_S4_:
  225|    323|inline constexpr void bigint_monty_maybe_sub(size_t N, W z[], W x0, const W x[], const W p[]) {
  226|    323|   W borrow = 0;
  227|       |
  228|    323|   const size_t blocks = N - (N % 8);
  229|       |
  230|  2.90k|   for(size_t i = 0; i != blocks; i += 8) {
  ------------------
  |  Branch (230:22): [True: 2.58k, False: 323]
  ------------------
  231|  2.58k|      borrow = word8_sub3(z + i, x + i, p + i, borrow);
  232|  2.58k|   }
  233|       |
  234|    323|   for(size_t i = blocks; i != N; ++i) {
  ------------------
  |  Branch (234:27): [True: 0, False: 323]
  ------------------
  235|      0|      z[i] = word_sub(x[i], p[i], &borrow);
  236|      0|   }
  237|       |
  238|    323|   borrow = (x0 - borrow) > x0;
  239|       |
  240|    323|   CT::conditional_assign_mem(borrow, z, x, N);
  241|    323|}
_ZN5Botan22bigint_monty_maybe_subILm4ETkNS_8WordTypeEmEEvPT0_S1_PKS1_S4_:
  254|  10.8M|inline constexpr void bigint_monty_maybe_sub(W z[N], W x0, const W x[N], const W y[N]) {
  255|  10.8M|   W borrow = 0;
  256|       |
  257|  54.2M|   for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (257:22): [True: 43.3M, False: 10.8M]
  ------------------
  258|  43.3M|      z[i] = word_sub(x[i], y[i], &borrow);
  259|  43.3M|   }
  260|       |
  261|  10.8M|   borrow = (x0 - borrow) > x0;
  262|       |
  263|  10.8M|   CT::conditional_assign_mem(borrow, z, x, N);
  264|  10.8M|}
_ZN5Botan22bigint_monty_maybe_subILm16ETkNS_8WordTypeEmEEvPT0_S1_PKS1_S4_:
  254|   382k|inline constexpr void bigint_monty_maybe_sub(W z[N], W x0, const W x[N], const W y[N]) {
  255|   382k|   W borrow = 0;
  256|       |
  257|  6.50M|   for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (257:22): [True: 6.12M, False: 382k]
  ------------------
  258|  6.12M|      z[i] = word_sub(x[i], y[i], &borrow);
  259|  6.12M|   }
  260|       |
  261|   382k|   borrow = (x0 - borrow) > x0;
  262|       |
  263|   382k|   CT::conditional_assign_mem(borrow, z, x, N);
  264|   382k|}
_ZN5Botan14bigint_cnd_absITkNS_8WordTypeEmEEvT_PS1_m:
   80|   328k|inline constexpr void bigint_cnd_abs(W cnd, W x[], size_t size) {
   81|   328k|   const auto mask = CT::Mask<W>::expand(cnd);
   82|       |
   83|   328k|   W carry = mask.if_set_return(1);
   84|  1.31M|   for(size_t i = 0; i != size; ++i) {
  ------------------
  |  Branch (84:22): [True: 985k, False: 328k]
  ------------------
   85|   985k|      const W z = word_add(~x[i], static_cast<W>(0), &carry);
   86|   985k|      x[i] = mask.select(z, x[i]);
   87|   985k|   }
   88|   328k|}
_ZN5Botan13monty_inverseITkNS_8WordTypeEmEET_S1_:
  703|  1.47k|inline constexpr auto monty_inverse(W a) -> W {
  704|  1.47k|   BOTAN_ARG_CHECK(a % 2 == 1, "Cannot compute Montgomery inverse of an even integer");
  ------------------
  |  |   35|  1.47k|   do {                                                          \
  |  |   36|  1.47k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.47k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.47k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.47k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.47k]
  |  |  ------------------
  ------------------
  705|       |
  706|       |   // Newton's Method, following https://lemire.me/blog/2017/09/18/computing-the-inverse-of-odd-integers/
  707|       |
  708|  1.47k|   constexpr size_t iter = WordInfo<W>::bits == 64 ? 4 : 3;
  ------------------
  |  Branch (708:28): [True: 0, Folded]
  ------------------
  709|       |
  710|       |   // Initial guess provides 5 bits of accuracy
  711|  1.47k|   W r = (3 * a) ^ 2;
  712|       |
  713|       |   // Each iteration doubles the accuracy
  714|  7.39k|   for(size_t i = 0; i != iter; ++i) {
  ------------------
  |  Branch (714:22): [True: 5.91k, False: 1.47k]
  ------------------
  715|  5.91k|      r = r * (2 - r * a);
  716|  5.91k|   }
  717|       |
  718|       |   // Now invert in addition space
  719|  1.47k|   r = (WordInfo<W>::max - r) + 1;
  720|       |
  721|  1.47k|   return r;
  722|  1.47k|}
_ZN5Botan10shift_leftILm1ETkNS_8WordTypeEmLm4EEET0_RNSt3__15arrayIS1_XT1_EEE:
  725|  6.00M|inline constexpr W shift_left(std::array<W, N>& x) {
  726|  6.00M|   static_assert(N >= 1, "Invalid input size");
  727|  6.00M|   static_assert(S > 0, "Zero shift not supported");
  728|  6.00M|   static_assert(S < WordInfo<W>::bits, "Shift too large");
  729|       |
  730|  6.00M|   const W carry = x[N - 1] >> (WordInfo<W>::bits - S);
  731|       |
  732|  24.0M|   for(size_t i = N - 1; i != 0; --i) {
  ------------------
  |  Branch (732:26): [True: 18.0M, False: 6.00M]
  ------------------
  733|  18.0M|      x[i] = (x[i] << S) | (x[i - 1] >> (WordInfo<W>::bits - S));
  734|  18.0M|   }
  735|  6.00M|   x[0] <<= S;
  736|       |
  737|  6.00M|   return carry;
  738|  6.00M|}
_ZN5Botan9comba_sqrILm4ETkNS_8WordTypeEmEEvPT0_PKS1_:
  854|  10.4M|constexpr inline void comba_sqr(W z[2 * N], const W x[N]) {
  855|  10.4M|   if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (855:7): [True: 10.4M, Folded]
  ------------------
  856|  10.4M|      if constexpr(std::same_as<W, word> && N == 4) {
  857|  10.4M|         return bigint_comba_sqr4(z, x);
  858|  10.4M|      }
  859|       |      if constexpr(std::same_as<W, word> && N == 6) {
  860|       |         return bigint_comba_sqr6(z, x);
  861|       |      }
  862|       |      if constexpr(std::same_as<W, word> && N == 7) {
  863|       |         return bigint_comba_sqr7(z, x);
  864|       |      }
  865|       |      if constexpr(std::same_as<W, word> && N == 8) {
  866|       |         return bigint_comba_sqr8(z, x);
  867|       |      }
  868|       |      if constexpr(std::same_as<W, word> && N == 9) {
  869|       |         return bigint_comba_sqr9(z, x);
  870|       |      }
  871|       |      if constexpr(std::same_as<W, word> && N == 16) {
  872|       |         return bigint_comba_sqr16(z, x);
  873|       |      }
  874|  10.4M|   }
  875|       |
  876|      0|   word3<W> accum;
  877|       |
  878|  10.4M|   for(size_t i = 0; i != 2 * N; ++i) {
  ------------------
  |  Branch (878:22): [True: 0, False: 10.4M]
  ------------------
  879|      0|      const size_t start = i + 1 < N ? 0 : i + 1 - N;
  ------------------
  |  Branch (879:28): [True: 0, False: 0]
  ------------------
  880|      0|      const size_t end = std::min(N, i + 1);
  881|       |
  882|      0|      for(size_t j = start; j != end; ++j) {
  ------------------
  |  Branch (882:29): [True: 0, False: 0]
  ------------------
  883|      0|         accum.mul(x[j], x[i - j]);
  884|      0|      }
  885|      0|      z[i] = accum.extract();
  886|      0|   }
  887|  10.4M|}
_ZN5Botan13redc_crandallITkNS_8WordTypeEmLm4ETnT_Lm4294968273EEENSt3__15arrayIS1_XT0_EEENS2_4spanIKS1_XmlLi2ET0_EEE:
  992|  4.96M|constexpr std::array<W, N> redc_crandall(std::span<const W, 2 * N> z) {
  993|  4.96M|   static_assert(N >= 2);
  994|       |
  995|  4.96M|   std::array<W, N> hi = {};
  996|       |
  997|       |   // hi = hi * c + lo
  998|       |
  999|  4.96M|   W carry = 0;
 1000|  24.8M|   for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (1000:22): [True: 19.8M, False: 4.96M]
  ------------------
 1001|  19.8M|      hi[i] = word_madd3(z[i + N], C, z[i], &carry);
 1002|  19.8M|   }
 1003|       |
 1004|       |   // hi += carry * C
 1005|  4.96M|   word carry_c[2] = {0};
 1006|  4.96M|   carry_c[0] = word_madd2(carry, C, &carry_c[1]);
 1007|       |
 1008|  4.96M|   carry = bigint_add2(hi.data(), N, carry_c, 2);
 1009|       |
 1010|  4.96M|   constexpr W P0 = WordInfo<W>::max - (C - 1);
 1011|       |
 1012|  4.96M|   std::array<W, N> r = {};
 1013|       |
 1014|  4.96M|   W borrow = 0;
 1015|       |
 1016|       |   /*
 1017|       |   * For undetermined reasons, on GCC (only) removing this asm block causes
 1018|       |   * massive (up to 20%) performance regressions in secp256k1.
 1019|       |   *
 1020|       |   * The generated code without the asm seems quite reasonable, and timing
 1021|       |   * repeated calls to redc_crandall with the cycle counter show that GCC
 1022|       |   * computes it in about the same number of cycles with or without the asm.
 1023|       |   *
 1024|       |   * So the cause of the regression is unclear. But it is reproducible across
 1025|       |   * machines and GCC versions.
 1026|       |   */
 1027|       |#if defined(BOTAN_MP_USE_X86_64_ASM) && defined(__GNUC__) && !defined(__clang__)
 1028|       |   if constexpr(N == 4 && std::same_as<W, uint64_t>) {
 1029|       |      if(!std::is_constant_evaluated()) {
 1030|       |         asm volatile(R"(
 1031|       |                      movq 0(%[x]), %[borrow]
 1032|       |                      subq %[p0], %[borrow]
 1033|       |                      movq %[borrow], 0(%[r])
 1034|       |                      movq 8(%[x]), %[borrow]
 1035|       |                      sbbq $-1, %[borrow]
 1036|       |                      movq %[borrow], 8(%[r])
 1037|       |                      movq 16(%[x]), %[borrow]
 1038|       |                      sbbq $-1, %[borrow]
 1039|       |                      movq %[borrow], 16(%[r])
 1040|       |                      movq 24(%[x]), %[borrow]
 1041|       |                      sbbq $-1, %[borrow]
 1042|       |                      movq %[borrow], 24(%[r])
 1043|       |                      sbbq %[borrow],%[borrow]
 1044|       |                      negq %[borrow]
 1045|       |                      )"
 1046|       |                      : [borrow] "=r"(borrow)
 1047|       |                      : [x] "r"(hi.data()), [p0] "r"(P0), [r] "r"(r.data()), "0"(borrow)
 1048|       |                      : "cc", "memory");
 1049|       |
 1050|       |         borrow = (carry - borrow) > carry;
 1051|       |         CT::conditional_assign_mem(borrow, r.data(), hi.data(), N);
 1052|       |         return r;
 1053|       |      }
 1054|       |   }
 1055|       |#endif
 1056|       |
 1057|  4.96M|   r[0] = word_sub(hi[0], P0, &borrow);
 1058|  19.8M|   for(size_t i = 1; i != N; ++i) {
  ------------------
  |  Branch (1058:22): [True: 14.8M, False: 4.96M]
  ------------------
 1059|  14.8M|      r[i] = word_sub(hi[i], WordInfo<W>::max, &borrow);
 1060|  14.8M|   }
 1061|       |
 1062|  4.96M|   borrow = (carry - borrow) > carry;
 1063|       |
 1064|  4.96M|   CT::conditional_assign_mem(borrow, r.data(), hi.data(), N);
 1065|       |
 1066|  4.96M|   return r;
 1067|  4.96M|}
_ZN5Botan9comba_mulILm4ETkNS_8WordTypeEmEEvPT0_PKS1_S4_:
  818|  15.4M|constexpr inline void comba_mul(W z[2 * N], const W x[N], const W y[N]) {
  819|  15.4M|   if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (819:7): [True: 15.4M, Folded]
  ------------------
  820|  15.4M|      if constexpr(std::same_as<W, word> && N == 4) {
  821|  15.4M|         return bigint_comba_mul4(z, x, y);
  822|  15.4M|      }
  823|       |      if constexpr(std::same_as<W, word> && N == 6) {
  824|       |         return bigint_comba_mul6(z, x, y);
  825|       |      }
  826|       |      if constexpr(std::same_as<W, word> && N == 7) {
  827|       |         return bigint_comba_mul7(z, x, y);
  828|       |      }
  829|       |      if constexpr(std::same_as<W, word> && N == 8) {
  830|       |         return bigint_comba_mul8(z, x, y);
  831|       |      }
  832|       |      if constexpr(std::same_as<W, word> && N == 9) {
  833|       |         return bigint_comba_mul9(z, x, y);
  834|       |      }
  835|       |      if constexpr(std::same_as<W, word> && N == 16) {
  836|       |         return bigint_comba_mul16(z, x, y);
  837|       |      }
  838|  15.4M|   }
  839|       |
  840|      0|   word3<W> accum;
  841|       |
  842|  15.4M|   for(size_t i = 0; i != 2 * N; ++i) {
  ------------------
  |  Branch (842:22): [True: 0, False: 15.4M]
  ------------------
  843|      0|      const size_t start = i + 1 < N ? 0 : i + 1 - N;
  ------------------
  |  Branch (843:28): [True: 0, False: 0]
  ------------------
  844|      0|      const size_t end = std::min(N, i + 1);
  845|       |
  846|      0|      for(size_t j = start; j != end; ++j) {
  ------------------
  |  Branch (846:29): [True: 0, False: 0]
  ------------------
  847|      0|         accum.mul(x[j], y[i - j]);
  848|      0|      }
  849|      0|      z[i] = accum.extract();
  850|      0|   }
  851|  15.4M|}
_ZN5Botan11shift_rightILm1ETkNS_8WordTypeEmLm4EEET0_RNSt3__15arrayIS1_XT1_EEE:
  741|  9.54M|inline constexpr W shift_right(std::array<W, N>& x) {
  742|  9.54M|   static_assert(N >= 1, "Invalid input size");
  743|  9.54M|   static_assert(S > 0, "Zero shift not supported");
  744|  9.54M|   static_assert(S < WordInfo<W>::bits, "Shift too large");
  745|       |
  746|  9.54M|   const W carry = x[0] << (WordInfo<W>::bits - S);
  747|       |
  748|  38.1M|   for(size_t i = 0; i != N - 1; ++i) {
  ------------------
  |  Branch (748:22): [True: 28.6M, False: 9.54M]
  ------------------
  749|  28.6M|      x[i] = (x[i] >> S) | (x[i + 1] << (WordInfo<W>::bits - S));
  750|  28.6M|   }
  751|  9.54M|   x[N - 1] >>= S;
  752|       |
  753|  9.54M|   return carry;
  754|  9.54M|}
_ZN5Botan16read_window_bitsILm3EhLm32EEEmNSt3__14spanIKT0_XT1_EEEm:
 1071|  1.06M|constexpr size_t read_window_bits(std::span<const W, N> words, size_t offset) {
 1072|  1.06M|   static_assert(WindowBits >= 1 && WindowBits <= 7);
 1073|       |
 1074|  1.06M|   constexpr uint8_t WindowMask = static_cast<uint8_t>(1 << WindowBits) - 1;
 1075|       |
 1076|  1.06M|   constexpr size_t W_bits = sizeof(W) * 8;
 1077|  1.06M|   const auto bit_shift = offset % W_bits;
 1078|  1.06M|   const auto word_offset = words.size() - 1 - (offset / W_bits);
 1079|       |
 1080|  1.06M|   const bool single_byte_window = bit_shift <= (W_bits - WindowBits) || word_offset == 0;
  ------------------
  |  Branch (1080:36): [True: 791k, False: 271k]
  |  Branch (1080:74): [True: 12.3k, False: 259k]
  ------------------
 1081|       |
 1082|  1.06M|   const auto w0 = words[word_offset];
 1083|       |
 1084|  1.06M|   if(single_byte_window) {
  ------------------
  |  Branch (1084:7): [True: 803k, False: 259k]
  ------------------
 1085|   803k|      return (w0 >> bit_shift) & WindowMask;
 1086|   803k|   } else {
 1087|       |      // Otherwise we must join two words and extract the result
 1088|   259k|      const auto w1 = words[word_offset - 1];
 1089|   259k|      const auto combined = ((w0 >> bit_shift) | (w1 << (W_bits - bit_shift)));
 1090|   259k|      return combined & WindowMask;
 1091|   259k|   }
 1092|  1.06M|}

_ZN5Botan14OCB_EncryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
  102|  3.82k|            OCB_Mode(std::move(cipher), tag_size) {}
_ZN5Botan14OCB_DecryptionC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
  121|  3.78k|            OCB_Mode(std::move(cipher), tag_size) {}
_ZNK5Botan8OCB_Mode8tag_sizeEv:
   47|  1.07M|      size_t tag_size() const final { return m_tag_size; }
_ZNK5Botan8OCB_Mode10block_sizeEv:
   64|  3.85M|      size_t block_size() const { return m_block_size; }
_ZNK5Botan8OCB_Mode10par_blocksEv:
   66|  1.57M|      size_t par_blocks() const { return m_par_blocks; }
_ZNK5Botan14OCB_Encryption18minimum_final_sizeEv:
  106|  3.75k|      size_t minimum_final_size() const override { return 0; }
_ZNK5Botan14OCB_Decryption18minimum_final_sizeEv:
  125|  3.57k|      size_t minimum_final_size() const override { return tag_size(); }

_ZN5Botan6PCurve15PrimeOrderCurve6ScalarD2Ev:
   74|   154k|            ~Scalar() { _zeroize(); }
_ZNK5Botan6PCurve15PrimeOrderCurve6Scalar6_curveEv:
   78|  61.8k|            const auto& _curve() const { return m_curve; }
_ZNK5Botan6PCurve15PrimeOrderCurve6Scalar6_valueEv:
   80|  61.8k|            const auto& _value() const { return m_value; }
_ZN5Botan6PCurve15PrimeOrderCurve6Scalar7_createENSt3__110shared_ptrIKS1_EENS3_5arrayImLm9EEE:
   82|  37.1k|            static Scalar _create(CurvePtr curve, StorageUnit v) { return Scalar(std::move(curve), v); }
_ZN5Botan6PCurve15PrimeOrderCurve6ScalarC2ENSt3__110shared_ptrIKS1_EENS3_5arrayImLm9EEE:
   85|  37.1k|            Scalar(CurvePtr curve, StorageUnit v) : m_curve(std::move(curve)), m_value(v) {}
_ZNK5Botan6PCurve15PrimeOrderCurve11AffinePoint6_curveEv:
  106|  31.2k|            const auto& _curve() const { return m_curve; }
_ZNK5Botan6PCurve15PrimeOrderCurve11AffinePoint2_xEv:
  108|  31.2k|            const auto& _x() const { return m_x; }
_ZNK5Botan6PCurve15PrimeOrderCurve11AffinePoint2_yEv:
  110|  31.2k|            const auto& _y() const { return m_y; }
_ZN5Botan6PCurve15PrimeOrderCurve11AffinePoint7_createENSt3__110shared_ptrIKS1_EENS3_5arrayImLm9EEES8_:
  112|  6.25k|            static AffinePoint _create(CurvePtr curve, StorageUnit x, StorageUnit y) {
  113|  6.25k|               return AffinePoint(std::move(curve), x, y);
  114|  6.25k|            }
_ZN5Botan6PCurve15PrimeOrderCurve11AffinePointC2ENSt3__110shared_ptrIKS1_EENS3_5arrayImLm9EEES8_:
  117|  6.25k|            AffinePoint(CurvePtr curve, StorageUnit x, StorageUnit y) : m_curve(std::move(curve)), m_x(x), m_y(y) {}
_ZN5Botan6PCurve15PrimeOrderCurveD2Ev:
  165|      3|      virtual ~PrimeOrderCurve() = default;
_ZN5Botan6PCurve15PrimeOrderCurve20PrecomputedMul2TableD2Ev:
  162|  6.25k|            virtual ~PrecomputedMul2Table() = default;
_ZN5Botan6PCurve15PrimeOrderCurve11AffinePointC2EOS2_:
   99|  25.0k|            AffinePoint(AffinePoint&& other) = default;
_ZN5Botan6PCurve15PrimeOrderCurve11AffinePointD2Ev:
  102|  37.5k|            ~AffinePoint() = default;
_ZN5Botan6PCurve15PrimeOrderCurve6ScalarC2EOS2_:
   69|  92.8k|            Scalar(Scalar&& other) = default;
_ZN5Botan6PCurve15PrimeOrderCurve6ScalarC2ERKS2_:
   68|  24.7k|            Scalar(const Scalar& other) = default;
_ZN5Botan6PCurve15PrimeOrderCurve11AffinePointC2ERKS2_:
   98|  6.25k|            AffinePoint(const AffinePoint& other) = default;

pcurves_secp256k1.cpp:_ZN5Botan10dbl_a_zeroINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EEEET_RKSE_:
  381|  20.1k|inline constexpr ProjectivePoint dbl_a_zero(const ProjectivePoint& pt) {
  382|       |   // If a == 0 then 3*x^2 + a*z^4 == 3*x^2
  383|       |   // Cost: 1S + 1*3
  384|  20.1k|   const auto m = pt.x().square().mul3();
  385|       |
  386|       |   // Remaining cost: 3M + 3S + 3A + 2*2 + 1*4 + 1*8
  387|  20.1k|   const auto y2 = pt.y().square();
  388|  20.1k|   const auto s = pt.x().mul4() * y2;
  389|  20.1k|   const auto nx = m.square() - s.mul2();
  390|  20.1k|   const auto ny = m * (s - nx) - y2.square().mul8();
  391|  20.1k|   const auto nz = pt.y().mul2() * pt.z();
  392|       |
  393|  20.1k|   return ProjectivePoint(nx, ny, nz);
  394|  20.1k|}
pcurves_secp256k1.cpp:_ZN5Botan9point_addINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EESC_EET_RKSE_SG_:
  187|  35.4k|inline constexpr ProjectivePoint point_add(const ProjectivePoint& a, const ProjectivePoint& b) {
  188|  35.4k|   const auto a_is_identity = a.is_identity();
  189|  35.4k|   const auto b_is_identity = b.is_identity();
  190|       |
  191|  35.4k|   const auto Z1Z1 = a.z().square();
  192|  35.4k|   const auto Z2Z2 = b.z().square();
  193|  35.4k|   const auto U1 = a.x() * Z2Z2;
  194|  35.4k|   const auto U2 = b.x() * Z1Z1;
  195|  35.4k|   const auto S1 = a.y() * b.z() * Z2Z2;
  196|  35.4k|   const auto S2 = b.y() * a.z() * Z1Z1;
  197|  35.4k|   const auto H = U2 - U1;
  198|  35.4k|   const auto r = S2 - S1;
  199|       |
  200|       |   /* Risky conditional
  201|       |   *
  202|       |   * This implementation uses projective coordinates, which do not have an efficient complete
  203|       |   * addition formula. We rely on the design of the multiplication algorithms to avoid doublings.
  204|       |   *
  205|       |   * This conditional only comes into play for the actual doubling case, not x + (-x) which
  206|       |   * is another exceptional case in some circumstances. Here if a == -b then H == 0 && r != 0,
  207|       |   * in which case at the end we'll set z to a.z * b.z * H = 0, resulting in the correct
  208|       |   * output (the identity element)
  209|       |   */
  210|  35.4k|   if((r.is_zero() && H.is_zero() && !(a_is_identity && b_is_identity)).as_bool()) {
  ------------------
  |  Branch (210:7): [True: 0, False: 35.4k]
  ------------------
  211|      0|      return a.dbl();
  212|      0|   }
  213|       |
  214|  35.4k|   const auto HH = H.square();
  215|  35.4k|   const auto HHH = H * HH;
  216|  35.4k|   const auto V = U1 * HH;
  217|  35.4k|   const auto t2 = r.square();
  218|  35.4k|   const auto t3 = V + V;
  219|  35.4k|   const auto t4 = t2 - HHH;
  220|  35.4k|   auto X3 = t4 - t3;
  221|  35.4k|   const auto t5 = V - X3;
  222|  35.4k|   const auto t6 = S1 * HHH;
  223|  35.4k|   const auto t7 = r * t5;
  224|  35.4k|   auto Y3 = t7 - t6;
  225|  35.4k|   const auto t8 = b.z() * H;
  226|  35.4k|   auto Z3 = a.z() * t8;
  227|       |
  228|       |   // if a is identity then return b
  229|  35.4k|   FieldElement::conditional_assign(X3, Y3, Z3, a_is_identity, b.x(), b.y(), b.z());
  230|       |
  231|       |   // if b is identity then return a
  232|  35.4k|   FieldElement::conditional_assign(X3, Y3, Z3, b_is_identity, a.x(), a.y(), a.z());
  233|       |
  234|  35.4k|   return ProjectivePoint(X3, Y3, Z3);
  235|  35.4k|}
pcurves_secp256k1.cpp:_ZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19secp256k15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEE:
  107|  1.28k|auto to_affine_batch(std::span<const typename C::ProjectivePoint> projective) {
  108|  1.28k|   using AffinePoint = typename C::AffinePoint;
  109|       |
  110|  1.28k|   const size_t N = projective.size();
  111|  1.28k|   std::vector<AffinePoint> affine;
  112|  1.28k|   affine.reserve(N);
  113|       |
  114|  1.28k|   CT::Choice any_identity = CT::Choice::no();
  115|       |
  116|  82.6k|   for(const auto& pt : projective) {
  ------------------
  |  Branch (116:23): [True: 82.6k, False: 1.28k]
  ------------------
  117|  82.6k|      any_identity = any_identity || pt.is_identity();
  118|  82.6k|   }
  119|       |
  120|       |   // Conditional acceptable: N is public. State of points is not necessarily
  121|       |   // public, but we don't leak which point was the identity. In practice with
  122|       |   // the algorithms currently in use, the only time an identity can occur is
  123|       |   // during mul2 where the two points g/h have a small relation (ie h = g*k for
  124|       |   // some k < 16)
  125|       |
  126|  1.28k|   if(N <= 2 || any_identity.as_bool()) {
  ------------------
  |  Branch (126:7): [True: 0, False: 1.28k]
  |  Branch (126:17): [True: 0, False: 1.28k]
  ------------------
  127|       |      // If there are identity elements, using the batch inversion gets
  128|       |      // tricky. It can be done, but this should be a rare situation so
  129|       |      // just punt to the serial conversion if it occurs
  130|      0|      for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (130:25): [True: 0, False: 0]
  ------------------
  131|      0|         affine.push_back(to_affine<C>(projective[i]));
  132|      0|      }
  133|  1.28k|   } else {
  134|  1.28k|      std::vector<typename C::FieldElement> c;
  135|  1.28k|      c.reserve(N);
  136|       |
  137|       |      /*
  138|       |      Batch projective->affine using Montgomery's trick
  139|       |
  140|       |      See Algorithm 2.26 in "Guide to Elliptic Curve Cryptography"
  141|       |      (Hankerson, Menezes, Vanstone)
  142|       |      */
  143|       |
  144|  1.28k|      c.push_back(projective[0].z());
  145|  82.6k|      for(size_t i = 1; i != N; ++i) {
  ------------------
  |  Branch (145:25): [True: 81.3k, False: 1.28k]
  ------------------
  146|  81.3k|         c.push_back(c[i - 1] * projective[i].z());
  147|  81.3k|      }
  148|       |
  149|  1.28k|      auto s_inv = [&]() {
  150|  1.28k|         if constexpr(VariableTime) {
  151|  1.28k|            return c[N - 1].invert_vartime();
  152|  1.28k|         } else {
  153|  1.28k|            return invert_field_element<C>(c[N - 1]);
  154|  1.28k|         }
  155|  1.28k|      }();
  156|       |
  157|  82.6k|      for(size_t i = N - 1; i > 0; --i) {
  ------------------
  |  Branch (157:29): [True: 81.3k, False: 1.28k]
  ------------------
  158|  81.3k|         const auto& p = projective[i];
  159|       |
  160|  81.3k|         const auto z_inv = s_inv * c[i - 1];
  161|  81.3k|         const auto z2_inv = z_inv.square();
  162|  81.3k|         const auto z3_inv = z_inv * z2_inv;
  163|       |
  164|  81.3k|         s_inv = s_inv * p.z();
  165|       |
  166|  81.3k|         affine.push_back(AffinePoint(p.x() * z2_inv, p.y() * z3_inv));
  167|  81.3k|      }
  168|       |
  169|  1.28k|      const auto z2_inv = s_inv.square();
  170|  1.28k|      const auto z3_inv = s_inv * z2_inv;
  171|  1.28k|      affine.push_back(AffinePoint(projective[0].x() * z2_inv, projective[0].y() * z3_inv));
  172|  1.28k|      std::reverse(affine.begin(), affine.end());
  173|  1.28k|      return affine;
  174|  1.28k|   }
  175|       |
  176|      0|   return affine;
  177|  1.28k|}
pcurves_secp256k1.cpp:_ZZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19secp256k15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEEENKUlvE_clEv:
  149|  1.28k|      auto s_inv = [&]() {
  150|  1.28k|         if constexpr(VariableTime) {
  151|  1.28k|            return c[N - 1].invert_vartime();
  152|       |         } else {
  153|       |            return invert_field_element<C>(c[N - 1]);
  154|       |         }
  155|  1.28k|      }();
pcurves_secp256k1.cpp:_ZN5Botan15point_add_mixedINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EENS_16AffineCurvePointISC_EESC_EET_RKSG_RKT0_RKT1_:
  240|   129k|                                                 const FieldElement& one) {
  241|   129k|   const auto a_is_identity = a.is_identity();
  242|   129k|   const auto b_is_identity = b.is_identity();
  243|       |
  244|       |   /*
  245|       |   https://hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html#addition-add-1998-cmo-2
  246|       |
  247|       |   Cost: 8M + 3S + 6add + 1*2
  248|       |   */
  249|       |
  250|   129k|   const auto Z1Z1 = a.z().square();
  251|   129k|   const auto U2 = b.x() * Z1Z1;
  252|   129k|   const auto S2 = b.y() * a.z() * Z1Z1;
  253|   129k|   const auto H = U2 - a.x();
  254|   129k|   const auto r = S2 - a.y();
  255|       |
  256|       |   /* Risky conditional
  257|       |   *
  258|       |   * This implementation uses projective coordinates, which do not have an efficient complete
  259|       |   * addition formula. We rely on the design of the multiplication algorithms to avoid doublings.
  260|       |   *
  261|       |   * This conditional only comes into play for the actual doubling case, not x + (-x) which
  262|       |   * is another exceptional case in some circumstances. Here if a == -b then H == 0 && r != 0,
  263|       |   * in which case at the end we'll set z to a.z * H = 0, resulting in the correct output
  264|       |   * (the identity element)
  265|       |   */
  266|   129k|   if((r.is_zero() && H.is_zero() && !(a_is_identity && b_is_identity)).as_bool()) {
  ------------------
  |  Branch (266:7): [True: 0, False: 129k]
  ------------------
  267|      0|      return a.dbl();
  268|      0|   }
  269|       |
  270|   129k|   const auto HH = H.square();
  271|   129k|   const auto HHH = H * HH;
  272|   129k|   const auto V = a.x() * HH;
  273|   129k|   const auto t2 = r.square();
  274|   129k|   const auto t3 = V + V;
  275|   129k|   const auto t4 = t2 - HHH;
  276|   129k|   auto X3 = t4 - t3;
  277|   129k|   const auto t5 = V - X3;
  278|   129k|   const auto t6 = a.y() * HHH;
  279|   129k|   const auto t7 = r * t5;
  280|   129k|   auto Y3 = t7 - t6;
  281|   129k|   auto Z3 = a.z() * H;
  282|       |
  283|       |   // if a is identity then return b
  284|   129k|   FieldElement::conditional_assign(X3, Y3, Z3, a_is_identity, b.x(), b.y(), one);
  285|       |
  286|       |   // if b is identity then return a
  287|   129k|   FieldElement::conditional_assign(X3, Y3, Z3, b_is_identity, a.x(), a.y(), a.z());
  288|       |
  289|   129k|   return ProjectivePoint(X3, Y3, Z3);
  290|   129k|}
pcurves_secp256k1.cpp:_ZN5Botan12dbl_n_a_zeroINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EEEET_RKSE_m:
  457|   107k|inline constexpr ProjectivePoint dbl_n_a_zero(const ProjectivePoint& pt, size_t n) {
  458|   107k|   auto nx = pt.x();
  459|   107k|   auto ny = pt.y().mul2();
  460|   107k|   auto nz = pt.z();
  461|       |
  462|       |   // Conditional ok: loop iteration count is public
  463|   428k|   while(n > 0) {
  ------------------
  |  Branch (463:10): [True: 321k, False: 107k]
  ------------------
  464|   321k|      const auto ny2 = ny.square();
  465|   321k|      const auto ny4 = ny2.square();
  466|   321k|      const auto t1 = nx.square().mul3();
  467|   321k|      const auto t2 = nx * ny2;
  468|   321k|      nx = t1.square() - t2.mul2();
  469|   321k|      nz *= ny;
  470|   321k|      ny = t1 * (t2 - nx).mul2() - ny4;
  471|   321k|      n--;
  472|   321k|   }
  473|   107k|   return ProjectivePoint(nx, ny.div2(), nz);
  474|   107k|}
pcurves_secp256r1.cpp:_ZN5Botan13dbl_a_minus_3INS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS4_9secp256r16ParamsES5_E11FieldParamsEEEEES8_EEEET_RKSE_:
  362|  75.2k|inline constexpr ProjectivePoint dbl_a_minus_3(const ProjectivePoint& pt) {
  363|       |   /*
  364|       |   if a == -3 then
  365|       |   3*x^2 + a*z^4 == 3*x^2 - 3*z^4 == 3*(x^2-z^4) == 3*(x-z^2)*(x+z^2)
  366|       |   */
  367|  75.2k|   const auto z2 = pt.z().square();
  368|  75.2k|   const auto m = (pt.x() - z2).mul3() * (pt.x() + z2);
  369|       |
  370|       |   // Remaining cost: 3M + 3S + 3A + 2*2 + 1*4 + 1*8
  371|  75.2k|   const auto y2 = pt.y().square();
  372|  75.2k|   const auto s = pt.x().mul4() * y2;
  373|  75.2k|   const auto nx = m.square() - s.mul2();
  374|  75.2k|   const auto ny = m * (s - nx) - y2.square().mul8();
  375|  75.2k|   const auto nz = pt.y().mul2() * pt.z();
  376|       |
  377|  75.2k|   return ProjectivePoint(nx, ny, nz);
  378|  75.2k|}
pcurves_secp256r1.cpp:_ZN5Botan9point_addINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS4_9secp256r16ParamsES5_E11FieldParamsEEEEES8_EESC_EET_RKSE_SG_:
  187|   134k|inline constexpr ProjectivePoint point_add(const ProjectivePoint& a, const ProjectivePoint& b) {
  188|   134k|   const auto a_is_identity = a.is_identity();
  189|   134k|   const auto b_is_identity = b.is_identity();
  190|       |
  191|   134k|   const auto Z1Z1 = a.z().square();
  192|   134k|   const auto Z2Z2 = b.z().square();
  193|   134k|   const auto U1 = a.x() * Z2Z2;
  194|   134k|   const auto U2 = b.x() * Z1Z1;
  195|   134k|   const auto S1 = a.y() * b.z() * Z2Z2;
  196|   134k|   const auto S2 = b.y() * a.z() * Z1Z1;
  197|   134k|   const auto H = U2 - U1;
  198|   134k|   const auto r = S2 - S1;
  199|       |
  200|       |   /* Risky conditional
  201|       |   *
  202|       |   * This implementation uses projective coordinates, which do not have an efficient complete
  203|       |   * addition formula. We rely on the design of the multiplication algorithms to avoid doublings.
  204|       |   *
  205|       |   * This conditional only comes into play for the actual doubling case, not x + (-x) which
  206|       |   * is another exceptional case in some circumstances. Here if a == -b then H == 0 && r != 0,
  207|       |   * in which case at the end we'll set z to a.z * b.z * H = 0, resulting in the correct
  208|       |   * output (the identity element)
  209|       |   */
  210|   134k|   if((r.is_zero() && H.is_zero() && !(a_is_identity && b_is_identity)).as_bool()) {
  ------------------
  |  Branch (210:7): [True: 0, False: 134k]
  ------------------
  211|      0|      return a.dbl();
  212|      0|   }
  213|       |
  214|   134k|   const auto HH = H.square();
  215|   134k|   const auto HHH = H * HH;
  216|   134k|   const auto V = U1 * HH;
  217|   134k|   const auto t2 = r.square();
  218|   134k|   const auto t3 = V + V;
  219|   134k|   const auto t4 = t2 - HHH;
  220|   134k|   auto X3 = t4 - t3;
  221|   134k|   const auto t5 = V - X3;
  222|   134k|   const auto t6 = S1 * HHH;
  223|   134k|   const auto t7 = r * t5;
  224|   134k|   auto Y3 = t7 - t6;
  225|   134k|   const auto t8 = b.z() * H;
  226|   134k|   auto Z3 = a.z() * t8;
  227|       |
  228|       |   // if a is identity then return b
  229|   134k|   FieldElement::conditional_assign(X3, Y3, Z3, a_is_identity, b.x(), b.y(), b.z());
  230|       |
  231|       |   // if b is identity then return a
  232|   134k|   FieldElement::conditional_assign(X3, Y3, Z3, b_is_identity, a.x(), a.y(), a.z());
  233|       |
  234|   134k|   return ProjectivePoint(X3, Y3, Z3);
  235|   134k|}
pcurves_secp256r1.cpp:_ZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19secp256r15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEE:
  107|  4.96k|auto to_affine_batch(std::span<const typename C::ProjectivePoint> projective) {
  108|  4.96k|   using AffinePoint = typename C::AffinePoint;
  109|       |
  110|  4.96k|   const size_t N = projective.size();
  111|  4.96k|   std::vector<AffinePoint> affine;
  112|  4.96k|   affine.reserve(N);
  113|       |
  114|  4.96k|   CT::Choice any_identity = CT::Choice::no();
  115|       |
  116|   314k|   for(const auto& pt : projective) {
  ------------------
  |  Branch (116:23): [True: 314k, False: 4.96k]
  ------------------
  117|   314k|      any_identity = any_identity || pt.is_identity();
  118|   314k|   }
  119|       |
  120|       |   // Conditional acceptable: N is public. State of points is not necessarily
  121|       |   // public, but we don't leak which point was the identity. In practice with
  122|       |   // the algorithms currently in use, the only time an identity can occur is
  123|       |   // during mul2 where the two points g/h have a small relation (ie h = g*k for
  124|       |   // some k < 16)
  125|       |
  126|  4.96k|   if(N <= 2 || any_identity.as_bool()) {
  ------------------
  |  Branch (126:7): [True: 0, False: 4.96k]
  |  Branch (126:17): [True: 0, False: 4.96k]
  ------------------
  127|       |      // If there are identity elements, using the batch inversion gets
  128|       |      // tricky. It can be done, but this should be a rare situation so
  129|       |      // just punt to the serial conversion if it occurs
  130|      0|      for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (130:25): [True: 0, False: 0]
  ------------------
  131|      0|         affine.push_back(to_affine<C>(projective[i]));
  132|      0|      }
  133|  4.96k|   } else {
  134|  4.96k|      std::vector<typename C::FieldElement> c;
  135|  4.96k|      c.reserve(N);
  136|       |
  137|       |      /*
  138|       |      Batch projective->affine using Montgomery's trick
  139|       |
  140|       |      See Algorithm 2.26 in "Guide to Elliptic Curve Cryptography"
  141|       |      (Hankerson, Menezes, Vanstone)
  142|       |      */
  143|       |
  144|  4.96k|      c.push_back(projective[0].z());
  145|   314k|      for(size_t i = 1; i != N; ++i) {
  ------------------
  |  Branch (145:25): [True: 309k, False: 4.96k]
  ------------------
  146|   309k|         c.push_back(c[i - 1] * projective[i].z());
  147|   309k|      }
  148|       |
  149|  4.96k|      auto s_inv = [&]() {
  150|  4.96k|         if constexpr(VariableTime) {
  151|  4.96k|            return c[N - 1].invert_vartime();
  152|  4.96k|         } else {
  153|  4.96k|            return invert_field_element<C>(c[N - 1]);
  154|  4.96k|         }
  155|  4.96k|      }();
  156|       |
  157|   314k|      for(size_t i = N - 1; i > 0; --i) {
  ------------------
  |  Branch (157:29): [True: 309k, False: 4.96k]
  ------------------
  158|   309k|         const auto& p = projective[i];
  159|       |
  160|   309k|         const auto z_inv = s_inv * c[i - 1];
  161|   309k|         const auto z2_inv = z_inv.square();
  162|   309k|         const auto z3_inv = z_inv * z2_inv;
  163|       |
  164|   309k|         s_inv = s_inv * p.z();
  165|       |
  166|   309k|         affine.push_back(AffinePoint(p.x() * z2_inv, p.y() * z3_inv));
  167|   309k|      }
  168|       |
  169|  4.96k|      const auto z2_inv = s_inv.square();
  170|  4.96k|      const auto z3_inv = s_inv * z2_inv;
  171|  4.96k|      affine.push_back(AffinePoint(projective[0].x() * z2_inv, projective[0].y() * z3_inv));
  172|  4.96k|      std::reverse(affine.begin(), affine.end());
  173|  4.96k|      return affine;
  174|  4.96k|   }
  175|       |
  176|      0|   return affine;
  177|  4.96k|}
pcurves_secp256r1.cpp:_ZZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19secp256r15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEEENKUlvE_clEv:
  149|  4.96k|      auto s_inv = [&]() {
  150|  4.96k|         if constexpr(VariableTime) {
  151|  4.96k|            return c[N - 1].invert_vartime();
  152|       |         } else {
  153|       |            return invert_field_element<C>(c[N - 1]);
  154|       |         }
  155|  4.96k|      }();
pcurves_secp256r1.cpp:_ZN5Botan15point_add_mixedINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS4_9secp256r16ParamsES5_E11FieldParamsEEEEES8_EENS_16AffineCurvePointISC_EESC_EET_RKSG_RKT0_RKT1_:
  240|   503k|                                                 const FieldElement& one) {
  241|   503k|   const auto a_is_identity = a.is_identity();
  242|   503k|   const auto b_is_identity = b.is_identity();
  243|       |
  244|       |   /*
  245|       |   https://hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-3.html#addition-add-1998-cmo-2
  246|       |
  247|       |   Cost: 8M + 3S + 6add + 1*2
  248|       |   */
  249|       |
  250|   503k|   const auto Z1Z1 = a.z().square();
  251|   503k|   const auto U2 = b.x() * Z1Z1;
  252|   503k|   const auto S2 = b.y() * a.z() * Z1Z1;
  253|   503k|   const auto H = U2 - a.x();
  254|   503k|   const auto r = S2 - a.y();
  255|       |
  256|       |   /* Risky conditional
  257|       |   *
  258|       |   * This implementation uses projective coordinates, which do not have an efficient complete
  259|       |   * addition formula. We rely on the design of the multiplication algorithms to avoid doublings.
  260|       |   *
  261|       |   * This conditional only comes into play for the actual doubling case, not x + (-x) which
  262|       |   * is another exceptional case in some circumstances. Here if a == -b then H == 0 && r != 0,
  263|       |   * in which case at the end we'll set z to a.z * H = 0, resulting in the correct output
  264|       |   * (the identity element)
  265|       |   */
  266|   503k|   if((r.is_zero() && H.is_zero() && !(a_is_identity && b_is_identity)).as_bool()) {
  ------------------
  |  Branch (266:7): [True: 0, False: 503k]
  ------------------
  267|      0|      return a.dbl();
  268|      0|   }
  269|       |
  270|   503k|   const auto HH = H.square();
  271|   503k|   const auto HHH = H * HH;
  272|   503k|   const auto V = a.x() * HH;
  273|   503k|   const auto t2 = r.square();
  274|   503k|   const auto t3 = V + V;
  275|   503k|   const auto t4 = t2 - HHH;
  276|   503k|   auto X3 = t4 - t3;
  277|   503k|   const auto t5 = V - X3;
  278|   503k|   const auto t6 = a.y() * HHH;
  279|   503k|   const auto t7 = r * t5;
  280|   503k|   auto Y3 = t7 - t6;
  281|   503k|   auto Z3 = a.z() * H;
  282|       |
  283|       |   // if a is identity then return b
  284|   503k|   FieldElement::conditional_assign(X3, Y3, Z3, a_is_identity, b.x(), b.y(), one);
  285|       |
  286|       |   // if b is identity then return a
  287|   503k|   FieldElement::conditional_assign(X3, Y3, Z3, b_is_identity, a.x(), a.y(), a.z());
  288|       |
  289|   503k|   return ProjectivePoint(X3, Y3, Z3);
  290|   503k|}
pcurves_secp256r1.cpp:_ZN5Botan15dbl_n_a_minus_3INS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS4_9secp256r16ParamsES5_E11FieldParamsEEEEES8_EEEET_RKSE_m:
  432|   416k|inline constexpr ProjectivePoint dbl_n_a_minus_3(const ProjectivePoint& pt, size_t n) {
  433|   416k|   auto nx = pt.x();
  434|   416k|   auto ny = pt.y().mul2();
  435|   416k|   auto nz = pt.z();
  436|   416k|   auto w = nz.square().square();
  437|       |
  438|       |   // Conditional ok: loop iteration count is public
  439|  1.66M|   while(n > 0) {
  ------------------
  |  Branch (439:10): [True: 1.24M, False: 416k]
  ------------------
  440|  1.24M|      const auto ny2 = ny.square();
  441|  1.24M|      const auto ny4 = ny2.square();
  442|  1.24M|      const auto t1 = (nx.square() - w).mul3();
  443|  1.24M|      const auto t2 = nx * ny2;
  444|  1.24M|      nx = t1.square() - t2.mul2();
  445|  1.24M|      nz *= ny;
  446|  1.24M|      ny = t1 * (t2 - nx).mul2() - ny4;
  447|  1.24M|      n--;
  448|       |      // Conditional ok: loop iteration count is public
  449|  1.24M|      if(n > 0) {
  ------------------
  |  Branch (449:10): [True: 832k, False: 416k]
  ------------------
  450|   832k|         w *= ny4;
  451|   832k|      }
  452|  1.24M|   }
  453|   416k|   return ProjectivePoint(nx, ny.div2(), nz);
  454|   416k|}
pcurves_sm2p256v1.cpp:_ZN5Botan13dbl_a_minus_3INS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EEEET_RKSE_:
  362|    833|inline constexpr ProjectivePoint dbl_a_minus_3(const ProjectivePoint& pt) {
  363|       |   /*
  364|       |   if a == -3 then
  365|       |   3*x^2 + a*z^4 == 3*x^2 - 3*z^4 == 3*(x^2-z^4) == 3*(x-z^2)*(x+z^2)
  366|       |   */
  367|    833|   const auto z2 = pt.z().square();
  368|    833|   const auto m = (pt.x() - z2).mul3() * (pt.x() + z2);
  369|       |
  370|       |   // Remaining cost: 3M + 3S + 3A + 2*2 + 1*4 + 1*8
  371|    833|   const auto y2 = pt.y().square();
  372|    833|   const auto s = pt.x().mul4() * y2;
  373|    833|   const auto nx = m.square() - s.mul2();
  374|    833|   const auto ny = m * (s - nx) - y2.square().mul8();
  375|    833|   const auto nz = pt.y().mul2() * pt.z();
  376|       |
  377|    833|   return ProjectivePoint(nx, ny, nz);
  378|    833|}
pcurves_sm2p256v1.cpp:_ZN5Botan9point_addINS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS5_6ParamsES6_E11FieldParamsEEEEES8_EESC_EET_RKSE_SG_:
  187|    735|inline constexpr ProjectivePoint point_add(const ProjectivePoint& a, const ProjectivePoint& b) {
  188|    735|   const auto a_is_identity = a.is_identity();
  189|    735|   const auto b_is_identity = b.is_identity();
  190|       |
  191|    735|   const auto Z1Z1 = a.z().square();
  192|    735|   const auto Z2Z2 = b.z().square();
  193|    735|   const auto U1 = a.x() * Z2Z2;
  194|    735|   const auto U2 = b.x() * Z1Z1;
  195|    735|   const auto S1 = a.y() * b.z() * Z2Z2;
  196|    735|   const auto S2 = b.y() * a.z() * Z1Z1;
  197|    735|   const auto H = U2 - U1;
  198|    735|   const auto r = S2 - S1;
  199|       |
  200|       |   /* Risky conditional
  201|       |   *
  202|       |   * This implementation uses projective coordinates, which do not have an efficient complete
  203|       |   * addition formula. We rely on the design of the multiplication algorithms to avoid doublings.
  204|       |   *
  205|       |   * This conditional only comes into play for the actual doubling case, not x + (-x) which
  206|       |   * is another exceptional case in some circumstances. Here if a == -b then H == 0 && r != 0,
  207|       |   * in which case at the end we'll set z to a.z * b.z * H = 0, resulting in the correct
  208|       |   * output (the identity element)
  209|       |   */
  210|    735|   if((r.is_zero() && H.is_zero() && !(a_is_identity && b_is_identity)).as_bool()) {
  ------------------
  |  Branch (210:7): [True: 0, False: 735]
  ------------------
  211|      0|      return a.dbl();
  212|      0|   }
  213|       |
  214|    735|   const auto HH = H.square();
  215|    735|   const auto HHH = H * HH;
  216|    735|   const auto V = U1 * HH;
  217|    735|   const auto t2 = r.square();
  218|    735|   const auto t3 = V + V;
  219|    735|   const auto t4 = t2 - HHH;
  220|    735|   auto X3 = t4 - t3;
  221|    735|   const auto t5 = V - X3;
  222|    735|   const auto t6 = S1 * HHH;
  223|    735|   const auto t7 = r * t5;
  224|    735|   auto Y3 = t7 - t6;
  225|    735|   const auto t8 = b.z() * H;
  226|    735|   auto Z3 = a.z() * t8;
  227|       |
  228|       |   // if a is identity then return b
  229|    735|   FieldElement::conditional_assign(X3, Y3, Z3, a_is_identity, b.x(), b.y(), b.z());
  230|       |
  231|       |   // if b is identity then return a
  232|    735|   FieldElement::conditional_assign(X3, Y3, Z3, b_is_identity, a.x(), a.y(), a.z());
  233|       |
  234|    735|   return ProjectivePoint(X3, Y3, Z3);
  235|    735|}
pcurves_sm2p256v1.cpp:_ZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19sm2p256v15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEE:
  107|      1|auto to_affine_batch(std::span<const typename C::ProjectivePoint> projective) {
  108|      1|   using AffinePoint = typename C::AffinePoint;
  109|       |
  110|      1|   const size_t N = projective.size();
  111|      1|   std::vector<AffinePoint> affine;
  112|      1|   affine.reserve(N);
  113|       |
  114|      1|   CT::Choice any_identity = CT::Choice::no();
  115|       |
  116|  1.56k|   for(const auto& pt : projective) {
  ------------------
  |  Branch (116:23): [True: 1.56k, False: 1]
  ------------------
  117|  1.56k|      any_identity = any_identity || pt.is_identity();
  118|  1.56k|   }
  119|       |
  120|       |   // Conditional acceptable: N is public. State of points is not necessarily
  121|       |   // public, but we don't leak which point was the identity. In practice with
  122|       |   // the algorithms currently in use, the only time an identity can occur is
  123|       |   // during mul2 where the two points g/h have a small relation (ie h = g*k for
  124|       |   // some k < 16)
  125|       |
  126|      1|   if(N <= 2 || any_identity.as_bool()) {
  ------------------
  |  Branch (126:7): [True: 0, False: 1]
  |  Branch (126:17): [True: 0, False: 1]
  ------------------
  127|       |      // If there are identity elements, using the batch inversion gets
  128|       |      // tricky. It can be done, but this should be a rare situation so
  129|       |      // just punt to the serial conversion if it occurs
  130|      0|      for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (130:25): [True: 0, False: 0]
  ------------------
  131|      0|         affine.push_back(to_affine<C>(projective[i]));
  132|      0|      }
  133|      1|   } else {
  134|      1|      std::vector<typename C::FieldElement> c;
  135|      1|      c.reserve(N);
  136|       |
  137|       |      /*
  138|       |      Batch projective->affine using Montgomery's trick
  139|       |
  140|       |      See Algorithm 2.26 in "Guide to Elliptic Curve Cryptography"
  141|       |      (Hankerson, Menezes, Vanstone)
  142|       |      */
  143|       |
  144|      1|      c.push_back(projective[0].z());
  145|  1.56k|      for(size_t i = 1; i != N; ++i) {
  ------------------
  |  Branch (145:25): [True: 1.56k, False: 1]
  ------------------
  146|  1.56k|         c.push_back(c[i - 1] * projective[i].z());
  147|  1.56k|      }
  148|       |
  149|      1|      auto s_inv = [&]() {
  150|      1|         if constexpr(VariableTime) {
  151|      1|            return c[N - 1].invert_vartime();
  152|      1|         } else {
  153|      1|            return invert_field_element<C>(c[N - 1]);
  154|      1|         }
  155|      1|      }();
  156|       |
  157|  1.56k|      for(size_t i = N - 1; i > 0; --i) {
  ------------------
  |  Branch (157:29): [True: 1.56k, False: 1]
  ------------------
  158|  1.56k|         const auto& p = projective[i];
  159|       |
  160|  1.56k|         const auto z_inv = s_inv * c[i - 1];
  161|  1.56k|         const auto z2_inv = z_inv.square();
  162|  1.56k|         const auto z3_inv = z_inv * z2_inv;
  163|       |
  164|  1.56k|         s_inv = s_inv * p.z();
  165|       |
  166|  1.56k|         affine.push_back(AffinePoint(p.x() * z2_inv, p.y() * z3_inv));
  167|  1.56k|      }
  168|       |
  169|      1|      const auto z2_inv = s_inv.square();
  170|      1|      const auto z3_inv = s_inv * z2_inv;
  171|      1|      affine.push_back(AffinePoint(projective[0].x() * z2_inv, projective[0].y() * z3_inv));
  172|      1|      std::reverse(affine.begin(), affine.end());
  173|      1|      return affine;
  174|      1|   }
  175|       |
  176|      0|   return affine;
  177|      1|}
pcurves_sm2p256v1.cpp:_ZZN5Botan15to_affine_batchINS_6PCurve12_GLOBAL__N_19sm2p256v15CurveELb1EEEDaNSt3__14spanIKNT_15ProjectivePointELm18446744073709551615EEEENKUlvE_clEv:
  149|      1|      auto s_inv = [&]() {
  150|      1|         if constexpr(VariableTime) {
  151|      1|            return c[N - 1].invert_vartime();
  152|       |         } else {
  153|       |            return invert_field_element<C>(c[N - 1]);
  154|       |         }
  155|      1|      }();

pcurves_secp256k1.cpp:_ZN5Botan23PrecomputedBaseMulTableINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm6EEC2ERKNS_16AffineCurvePointINS_6IntModINS3_12Secp256k1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEE:
 1405|      1|            m_table(basemul_booth_setup<C, WindowBits>(p, BlindedScalar::Bits + 1)) {}
pcurves_secp256k1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E11from_affineERKNS_16AffineCurvePointISB_EE:
 1016|  3.83k|      static constexpr Self from_affine(const AffinePoint& pt) {
 1017|       |         /*
 1018|       |         * If the point is the identity element (x=0, y=0) then instead of
 1019|       |         * creating (x, y, 1) = (0, 0, 1) we want our projective identity
 1020|       |         * encoding of (0, 1, 0)
 1021|       |         *
 1022|       |         * Which we can achieve by a conditional swap of y and z if the
 1023|       |         * affine point is the identity.
 1024|       |         */
 1025|       |
 1026|  3.83k|         auto x = pt.x();
 1027|  3.83k|         auto y = pt.y();
 1028|  3.83k|         auto z = FieldElement::one();
 1029|       |
 1030|  3.83k|         FieldElement::conditional_swap(pt.is_identity(), y, z);
 1031|       |
 1032|  3.83k|         return ProjectiveCurvePoint(x, y, z);
 1033|  3.83k|      }
pcurves_secp256k1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE1xEv:
  971|   406k|      constexpr const FieldElement& x() const { return m_x; }
pcurves_secp256k1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE1yEv:
  976|   406k|      constexpr const FieldElement& y() const { return m_y; }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE3oneEv:
  200|   133k|      static constexpr Self one() { return Self(Rep::one()); }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEC2ENSt3__15arrayImLm4EEE:
  898|  8.88M|      explicit constexpr IntMod(std::array<W, N> v) : m_val(v) {}
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE16conditional_swapENS_2CT6ChoiceERSA_SD_:
  410|  3.83k|      static constexpr void conditional_swap(CT::Choice cond, Self& x, Self& y) {
  411|  3.83k|         const W mask = cond.into_bitmask<W>();
  412|       |
  413|  19.1k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (413:28): [True: 15.3k, False: 3.83k]
  ------------------
  414|  15.3k|            auto nx = Botan::choose(mask, y.m_val[i], x.m_val[i]);
  415|  15.3k|            auto ny = Botan::choose(mask, x.m_val[i], y.m_val[i]);
  416|  15.3k|            x.m_val[i] = nx;
  417|  15.3k|            y.m_val[i] = ny;
  418|  15.3k|         }
  419|  3.83k|      }
pcurves_secp256k1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE11is_identityEv:
  928|   138k|      constexpr CT::Choice is_identity() const { return x().is_zero() && y().is_zero(); }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE7is_zeroEv:
  225|   894k|      constexpr CT::Choice is_zero() const { return CT::all_zeros(m_val.data(), m_val.size()).as_choice(); }
pcurves_secp256k1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EC2ERKSB_SE_SE_:
 1056|   296k|            m_x(x), m_y(y), m_z(z) {}
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E3dblEv:
 1121|  20.1k|      constexpr Self dbl() const {
 1122|       |         if constexpr(Self::A_is_minus_3) {
 1123|       |            return dbl_a_minus_3(*this);
 1124|  20.1k|         } else if constexpr(Self::A_is_zero) {
 1125|  20.1k|            return dbl_a_zero(*this);
 1126|       |         } else {
 1127|       |            return dbl_generic(*this, A);
 1128|       |         }
 1129|  20.1k|      }
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1xEv:
 1162|   762k|      constexpr const FieldElement& x() const { return m_x; }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE6squareEv:
  426|  1.98M|      constexpr BOTAN_FORCE_INLINE Self square() const {
  427|  1.98M|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  428|  1.98M|         comba_sqr<N>(z.data(), this->data());
  429|  1.98M|         return Self(Rep::redc(z));
  430|  1.98M|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4dataEv:
  896|  8.63M|      constexpr const W* data() const { return m_val.data(); }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul3Ev:
  335|   341k|      constexpr inline Self mul3() const { return mul2() + (*this); }
pcurves_secp256k1.cpp:_ZN5BotanplERKNS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  265|   732k|      friend constexpr BOTAN_FORCE_INLINE Self operator+(const Self& a, const Self& b) {
  266|   732k|         std::array<W, N> t;  // NOLINT(*-member-init)
  267|       |
  268|   732k|         W carry = 0;
  269|  3.66M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (269:28): [True: 2.92M, False: 732k]
  ------------------
  270|  2.92M|            t[i] = word_add(a.m_val[i], b.m_val[i], &carry);
  271|  2.92M|         }
  272|       |
  273|   732k|         std::array<W, N> r;  // NOLINT(*-member-init)
  274|   732k|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  275|   732k|         return Self(r);
  276|   732k|      }
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1yEv:
 1167|   761k|      constexpr const FieldElement& y() const { return m_y; }
pcurves_secp256k1.cpp:_ZN5BotanmlERKNS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  346|  2.66M|      friend constexpr BOTAN_FORCE_INLINE Self operator*(const Self& a, const Self& b) {
  347|  2.66M|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  348|  2.66M|         comba_mul<N>(z.data(), a.data(), b.data());
  349|  2.66M|         return Self(Rep::redc(z));
  350|  2.66M|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul4Ev:
  338|  20.1k|      constexpr inline Self mul4() const { return mul2().mul2(); }
pcurves_secp256k1.cpp:_ZN5BotanmiERKNS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  281|  2.01M|      friend constexpr BOTAN_FORCE_INLINE Self operator-(const Self& a, const Self& b) {
  282|  2.01M|         std::array<W, N> r;  // NOLINT(*-member-init)
  283|  2.01M|         W carry = 0;
  284|  10.0M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (284:28): [True: 8.06M, False: 2.01M]
  ------------------
  285|  8.06M|            r[i] = word_sub(a.m_val[i], b.m_val[i], &carry);
  286|  8.06M|         }
  287|       |
  288|  2.01M|         const auto mask = CT::Mask<W>::expand(carry).value();
  289|       |
  290|  2.01M|         carry = 0;
  291|       |
  292|  10.0M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (292:28): [True: 8.06M, False: 2.01M]
  ------------------
  293|  8.06M|            r[i] = word_add(r[i], P[i] & mask, &carry);
  294|  8.06M|         }
  295|       |
  296|  2.01M|         return Self(r);
  297|  2.01M|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul2Ev:
  325|  1.23M|      constexpr BOTAN_FORCE_INLINE Self mul2() const {
  326|  1.23M|         std::array<W, N> t = value();
  327|  1.23M|         const W carry = shift_left<1>(t);
  328|       |
  329|  1.23M|         std::array<W, N> r;  // NOLINT(*-member-init)
  330|  1.23M|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  331|  1.23M|         return Self(r);
  332|  1.23M|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE5valueEv:
  894|  1.33M|      constexpr const std::array<W, N>& value() const { return m_val; }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul8Ev:
  341|  20.1k|      constexpr inline Self mul8() const { return mul2().mul2().mul2(); }
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1zEv:
 1172|  1.38M|      constexpr const FieldElement& z() const { return m_z; }
pcurves_secp256k1.cpp:_ZN5BotanplERKNS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EESE_:
 1064|  35.4k|      friend constexpr Self operator+(const Self& a, const Self& b) { return Self::add(a, b); }
pcurves_secp256k1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E3addERKSC_SE_:
 1103|  35.4k|      constexpr static Self add(const Self& a, const Self& b) { return point_add<Self, FieldElement>(a, b); }
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E11is_identityEv:
 1082|   284k|      constexpr CT::Choice is_identity() const { return z().is_zero(); }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE18conditional_assignERSA_SB_SB_NS_2CT6ChoiceERKSA_SF_SF_:
  395|   330k|         Self& x, Self& y, Self& z, CT::Choice cond, const Self& nx, const Self& ny, const Self& nz) {
  396|   330k|         const W mask = cond.into_bitmask<W>();
  397|       |
  398|  1.65M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (398:28): [True: 1.32M, False: 330k]
  ------------------
  399|  1.32M|            x.m_val[i] = Botan::choose(mask, nx.m_val[i], x.m_val[i]);
  400|  1.32M|            y.m_val[i] = Botan::choose(mask, ny.m_val[i], y.m_val[i]);
  401|  1.32M|            z.m_val[i] = Botan::choose(mask, nz.m_val[i], z.m_val[i]);
  402|  1.32M|         }
  403|   330k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEmLERKSA_:
  355|   321k|      constexpr BOTAN_FORCE_INLINE Self& operator*=(const Self& other) {
  356|   321k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  357|   321k|         comba_mul<N>(z.data(), data(), other.data());
  358|   321k|         m_val = Rep::redc(z);
  359|   321k|         return (*this);
  360|   321k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE14invert_vartimeEv:
  598|  1.28k|      constexpr Self invert_vartime() const {
  599|       |         // Conditional ok: this function is variable time
  600|  1.28k|         if(this->is_zero().as_bool()) {
  ------------------
  |  Branch (600:13): [True: 0, False: 1.28k]
  ------------------
  601|      0|            return Self::zero();
  602|      0|         }
  603|       |
  604|  1.28k|         auto x = Self(std::array<W, N>{1});  // 1 in standard domain
  605|  1.28k|         auto b = Self(this->to_words());     // *this in standard domain
  606|       |
  607|       |         // First loop iteration
  608|  1.28k|         Self::_invert_vartime_div2_helper(b, x);
  609|       |
  610|  1.28k|         auto a = b.negate();
  611|       |         // y += x but y is zero at the outset
  612|  1.28k|         auto y = x;
  613|       |
  614|       |         // First half of second loop iteration
  615|  1.28k|         Self::_invert_vartime_div2_helper(a, y);
  616|       |
  617|   224k|         for(;;) {
  618|       |            // Conditional ok: this function is variable time
  619|   224k|            if(a.m_val == b.m_val) {
  ------------------
  |  Branch (619:16): [True: 1.28k, False: 222k]
  ------------------
  620|       |               // At this point it should be that a == b == 1
  621|  1.28k|               auto r = y.negate();
  622|       |
  623|       |               // Convert back to Montgomery if required
  624|  1.28k|               r.m_val = Rep::to_rep(r.m_val);
  625|  1.28k|               return r;
  626|  1.28k|            }
  627|       |
  628|   222k|            auto nx = x + y;
  629|       |
  630|       |            /*
  631|       |            * Otherwise either b > a or a > b
  632|       |            *
  633|       |            * If b > a we want to set b to b - a
  634|       |            * Otherwise we want to set a to a - b
  635|       |            *
  636|       |            * Compute r = b - a and check if it underflowed
  637|       |            * If it did not then we are in the b > a path
  638|       |            */
  639|   222k|            std::array<W, N> r;  // NOLINT(*-member-init)
  640|   222k|            const word carry = bigint_sub3(r.data(), b.data(), N, a.data(), N);
  641|       |
  642|       |            // Conditional ok: this function is variable time
  643|   222k|            if(carry == 0) {
  ------------------
  |  Branch (643:16): [True: 106k, False: 115k]
  ------------------
  644|       |               // b > a
  645|   106k|               b.m_val = r;
  646|   106k|               x = nx;
  647|   106k|               Self::_invert_vartime_div2_helper(b, x);
  648|   115k|            } else {
  649|       |               // We know this can't underflow because a > b
  650|   115k|               bigint_sub3(r.data(), a.data(), N, b.data(), N);
  651|   115k|               a.m_val = r;
  652|   115k|               y = nx;
  653|   115k|               Self::_invert_vartime_div2_helper(a, y);
  654|   115k|            }
  655|   222k|         }
  656|  1.28k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE8to_wordsEv:
  734|  3.68k|      constexpr std::array<W, Self::N> to_words() const { return Rep::from_rep(m_val); }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE27_invert_vartime_div2_helperERSA_SB_:
  547|   225k|      static constexpr void _invert_vartime_div2_helper(Self& a, Self& x) {
  548|   225k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  549|       |
  550|       |         // Conditional ok: this function is variable time
  551|   677k|         while((a.m_val[0] & 1) != 1) {
  ------------------
  |  Branch (551:16): [True: 452k, False: 225k]
  ------------------
  552|   452k|            shift_right<1>(a.m_val);
  553|       |
  554|   452k|            const W borrow = shift_right<1>(x.m_val);
  555|       |
  556|       |            // Conditional ok: this function is variable time
  557|   452k|            if(borrow) {
  ------------------
  |  Branch (557:16): [True: 227k, False: 224k]
  ------------------
  558|   227k|               bigint_add2(x.m_val.data(), N, INV_2.data(), N);
  559|   227k|            }
  560|   452k|         }
  561|   225k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE6negateEv:
  452|  3.77k|      constexpr Self negate() const {
  453|  3.77k|         const W x_is_zero = ~CT::all_zeros(this->data(), N).value();
  454|       |
  455|  3.77k|         std::array<W, N> r;  // NOLINT(*-member-init)
  456|  3.77k|         W carry = 0;
  457|  18.8k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (457:28): [True: 15.0k, False: 3.77k]
  ------------------
  458|  15.0k|            r[i] = word_sub(P[i] & x_is_zero, m_val[i], &carry);
  459|  15.0k|         }
  460|       |
  461|  3.77k|         return Self(r);
  462|  3.77k|      }
pcurves_secp256k1.cpp:_ZN5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEEC2ERKSB_SE_:
  917|  90.3k|      constexpr AffineCurvePoint(const FieldElement& x, const FieldElement& y) : m_x(x), m_y(y) {}
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE11stash_valueILm9EEENSt3__15arrayImXT_EEEv:
  759|  2.57k|      std::array<W, L> stash_value() const {
  760|  2.57k|         static_assert(L >= N);
  761|  2.57k|         std::array<W, L> stash = {};
  762|  12.8k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (762:28): [True: 10.2k, False: 2.57k]
  ------------------
  763|  10.2k|            stash[i] = m_val[i];
  764|  10.2k|         }
  765|  2.57k|         return stash;
  766|  2.57k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE8to_wordsEv:
  734|  1.26k|      constexpr std::array<W, Self::N> to_words() const { return Rep::from_rep(m_val); }
pcurves_secp256k1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS4_12Secp256k1RepEE12ScalarParamsEE8from_repERKNSt3__15arrayImLm4EEE:
  137|  5.05k|      constexpr static std::array<W, N> from_rep(const std::array<W, N>& z) {
  138|  5.05k|         std::array<W, 2 * N> ze = {};
  139|  5.05k|         copy_mem(std::span{ze}.template first<N>(), z);
  140|  5.05k|         return Self::redc(ze);
  141|  5.05k|      }
pcurves_secp256k1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS4_12Secp256k1RepEE12ScalarParamsEE4redcERKNSt3__15arrayImLm8EEE:
  104|  13.9k|      constexpr static std::array<W, N> redc(const std::array<W, 2 * N>& z) {
  105|       |         if constexpr(P_dash == 1) {
  106|       |            return monty_redc_pdash1(z, P);
  107|  13.9k|         } else {
  108|  13.9k|            return monty_redc(z, P, P_dash);
  109|  13.9k|         }
  110|  13.9k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE12serialize_toENSt3__14spanIhLm32EEE:
  739|  3.79k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  740|  3.79k|         auto v = Rep::from_rep(m_val);
  741|  3.79k|         std::reverse(v.begin(), v.end());
  742|       |
  743|  3.79k|         if constexpr(Self::BYTES == N * WordInfo<W>::bytes) {
  744|  3.79k|            store_be(bytes, v);
  745|       |         } else {
  746|       |            // Remove leading zero bytes
  747|       |            const auto padded_bytes = store_be(v);
  748|       |            constexpr size_t extra = N * WordInfo<W>::bytes - Self::BYTES;
  749|       |            copy_mem(bytes, std::span{padded_bytes}.template subspan<extra, Self::BYTES>());
  750|       |         }
  751|  3.79k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE11deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  792|  3.87k|      static std::optional<Self> deserialize(std::span<const uint8_t> bytes) {
  793|       |         // Conditional ok: input length is public
  794|  3.87k|         if(bytes.size() != Self::BYTES) {
  ------------------
  |  Branch (794:13): [True: 0, False: 3.87k]
  ------------------
  795|      0|            return {};
  796|      0|         }
  797|       |
  798|  3.87k|         const auto words = bytes_to_words<W, N, BYTES>(bytes.first<Self::BYTES>());
  799|       |
  800|       |         // Conditional acceptable: std::optional is implicitly not constant time
  801|  3.87k|         if(!bigint_ct_is_lt(words.data(), N, P.data(), N).as_bool()) {
  ------------------
  |  Branch (801:13): [True: 0, False: 3.87k]
  ------------------
  802|      0|            return {};
  803|      0|         }
  804|       |
  805|       |         // Safe because we checked above that words is an integer < P
  806|  3.87k|         return Self::from_words(words);
  807|  3.87k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE10from_wordsILm4EEESA_NSt3__15arrayImXT_EEE:
  211|  5.07k|      static constexpr Self from_words(std::array<W, L> w) {
  212|  5.07k|         if constexpr(L == N) {
  213|  5.07k|            return Self(Rep::to_rep(w));
  214|       |         } else {
  215|       |            static_assert(L < N);
  216|       |            std::array<W, N> ew = {};
  217|       |            copy_mem(std::span{ew}.template first<L>(), w);
  218|       |            return Self(Rep::to_rep(ew));
  219|       |         }
  220|  5.07k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE10from_stashILm9EEESB_RKNSt3__15arrayImXT_EEE:
  774|  12.6k|      static Self from_stash(const std::array<W, L>& stash) {
  775|  12.6k|         static_assert(L >= N);
  776|  12.6k|         std::array<W, N> val = {};
  777|  63.2k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (777:28): [True: 50.5k, False: 12.6k]
  ------------------
  778|  50.5k|            val[i] = stash[i];
  779|  50.5k|         }
  780|  12.6k|         return Self(val);
  781|  12.6k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEEC2ENSt3__15arrayImLm4EEE:
  898|   250k|      explicit constexpr IntMod(std::array<W, N> v) : m_val(v) {}
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE12serialize_toENSt3__14spanIhLm32EEE:
  739|  5.14k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  740|  5.14k|         auto v = Rep::from_rep(m_val);
  741|  5.14k|         std::reverse(v.begin(), v.end());
  742|       |
  743|  5.14k|         if constexpr(Self::BYTES == N * WordInfo<W>::bytes) {
  744|  5.14k|            store_be(bytes, v);
  745|       |         } else {
  746|       |            // Remove leading zero bytes
  747|       |            const auto padded_bytes = store_be(v);
  748|       |            constexpr size_t extra = N * WordInfo<W>::bytes - Self::BYTES;
  749|       |            copy_mem(bytes, std::span{padded_bytes}.template subspan<extra, Self::BYTES>());
  750|       |         }
  751|  5.14k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE11stash_valueILm9EEENSt3__15arrayImXT_EEEv:
  759|  7.60k|      std::array<W, L> stash_value() const {
  760|  7.60k|         static_assert(L >= N);
  761|  7.60k|         std::array<W, L> stash = {};
  762|  38.0k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (762:28): [True: 30.4k, False: 7.60k]
  ------------------
  763|  30.4k|            stash[i] = m_val[i];
  764|  30.4k|         }
  765|  7.60k|         return stash;
  766|  7.60k|      }
pcurves_secp256k1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS4_12Secp256k1RepEE12ScalarParamsEE11wide_to_repERKNSt3__15arrayImLm8EEE:
  127|  1.26k|      constexpr static std::array<W, N> wide_to_rep(const std::array<W, 2 * N>& x) {
  128|  1.26k|         auto redc_x = Self::redc(x);
  129|  1.26k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  130|  1.26k|         comba_mul<N>(z.data(), redc_x.data(), R3.data());
  131|  1.26k|         return Self::redc(z);
  132|  1.26k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE10from_stashILm9EEESA_RKNSt3__15arrayImXT_EEE:
  774|  12.8k|      static Self from_stash(const std::array<W, L>& stash) {
  775|  12.8k|         static_assert(L >= N);
  776|  12.8k|         std::array<W, N> val = {};
  777|  64.3k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (777:28): [True: 51.4k, False: 12.8k]
  ------------------
  778|  51.4k|            val[i] = stash[i];
  779|  51.4k|         }
  780|  12.8k|         return Self(val);
  781|  12.8k|      }
pcurves_secp256k1.cpp:_ZN5BotanplERKNS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EERKNS_16AffineCurvePointISB_EE:
 1066|   113k|      friend constexpr Self operator+(const Self& a, const AffinePoint& b) { return Self::add_mixed(a, b); }
pcurves_secp256k1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E9add_mixedERKSC_RKNS_16AffineCurvePointISB_EE:
 1091|   129k|      constexpr static Self add_mixed(const Self& a, const AffinePoint& b) {
 1092|   129k|         return point_add_mixed<Self, AffinePoint, FieldElement>(a, b, FieldElement::one());
 1093|   129k|      }
pcurves_secp256k1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E5dbl_nEm:
 1108|   107k|      constexpr Self dbl_n(size_t n) const {
 1109|       |         if constexpr(Self::A_is_minus_3) {
 1110|       |            return dbl_n_a_minus_3(*this, n);
 1111|   107k|         } else if constexpr(Self::A_is_zero) {
 1112|   107k|            return dbl_n_a_zero(*this, n);
 1113|       |         } else {
 1114|       |            return dbl_n_generic(*this, A, n);
 1115|       |         }
 1116|   107k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4div2Ev:
  302|   107k|      Self div2() const {
  303|       |         // The inverse of 2 modulo P is (P/2)+1; this avoids a constexpr time
  304|       |         // general inversion, which some compilers can't handle
  305|   107k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  306|       |
  307|       |         // We could multiply by INV_2 but there is a better way ...
  308|       |
  309|   107k|         std::array<W, N> t = value();
  310|   107k|         const W borrow = shift_right<1>(t);
  311|       |
  312|       |         // If value was odd, add (P/2)+1
  313|   107k|         const auto mask = CT::Mask<W>::expand(borrow).value();
  314|       |
  315|   107k|         W carry = 0;
  316|       |
  317|   535k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (317:28): [True: 428k, False: 107k]
  ------------------
  318|   428k|            t[i] = word_add(t[i], INV_2[i] & mask, &carry);
  319|   428k|         }
  320|       |
  321|   107k|         return Self(t);
  322|   107k|      }
pcurves_secp256k1.cpp:_ZN5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EEC2ERKNS_16AffineCurvePointINS_6IntModINS3_12Secp256k1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEESH_:
 1577|  1.28k|            m_table(to_affine_batch<C, true>(mul2_setup<C, W>(p, q))) {}
pcurves_secp256k1.cpp:_ZN5BotanplERKNS_16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEEERKNS_20ProjectiveCurvePointISB_S7_EE:
 1068|  16.7k|      friend constexpr Self operator+(const AffinePoint& a, const Self& b) { return Self::add_mixed(b, a); }
pcurves_secp256k1.cpp:_ZNK5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EE12mul2_vartimeERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS3_12Secp256k1RepEE12ScalarParamsEEEEESG_:
 1588|  1.26k|      ProjectivePoint mul2_vartime(const Scalar& s1, const Scalar& s2) const {
 1589|  1.26k|         constexpr size_t Windows = (Scalar::BITS + WindowBits - 1) / WindowBits;
 1590|       |
 1591|  1.26k|         const UnblindedScalarBits<C, W> bits1(s1);
 1592|  1.26k|         const UnblindedScalarBits<C, W> bits2(s2);
 1593|       |
 1594|  1.26k|         const bool s1_is_zero = s1.is_zero().as_bool();
 1595|  1.26k|         const bool s2_is_zero = s2.is_zero().as_bool();
 1596|       |
 1597|       |         // Conditional ok: this function is variable time
 1598|  1.26k|         if(s1_is_zero && s2_is_zero) {
  ------------------
  |  Branch (1598:13): [True: 0, False: 1.26k]
  |  Branch (1598:27): [True: 0, False: 0]
  ------------------
 1599|      0|            return ProjectivePoint::identity();
 1600|      0|         }
 1601|       |
 1602|  1.26k|         auto [w_0, first_nonempty_window] = [&]() {
 1603|  1.26k|            for(size_t i = 0; i != Windows; ++i) {
 1604|  1.26k|               const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1605|  1.26k|               const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1606|  1.26k|               const size_t window = w_1 + (w_2 << WindowBits);
 1607|       |               // Conditional ok: this function is variable time
 1608|  1.26k|               if(window > 0) {
 1609|  1.26k|                  return std::make_pair(window, i);
 1610|  1.26k|               }
 1611|  1.26k|            }
 1612|       |            // We checked for s1 == s2 == 0 above, so we must see a window eventually
 1613|  1.26k|            BOTAN_ASSERT_UNREACHABLE();
 1614|  1.26k|         }();
 1615|       |
 1616|  1.26k|         BOTAN_ASSERT_NOMSG(w_0 > 0);
  ------------------
  |  |   77|  1.26k|   do {                                                                     \
  |  |   78|  1.26k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.26k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.26k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.26k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.26k]
  |  |  ------------------
  ------------------
 1617|  1.26k|         auto accum = ProjectivePoint::from_affine(m_table[w_0 - 1]);
 1618|       |
 1619|   108k|         for(size_t i = first_nonempty_window + 1; i < Windows; ++i) {
  ------------------
  |  Branch (1619:52): [True: 107k, False: 1.26k]
  ------------------
 1620|   107k|            accum = accum.dbl_n(WindowBits);
 1621|       |
 1622|   107k|            const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1623|   107k|            const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1624|       |
 1625|   107k|            const size_t window = w_1 + (w_2 << WindowBits);
 1626|       |
 1627|       |            // Conditional ok: this function is variable time
 1628|   107k|            if(window > 0) {
  ------------------
  |  Branch (1628:16): [True: 105k, False: 1.65k]
  ------------------
 1629|   105k|               accum += m_table[window - 1];
 1630|   105k|            }
 1631|   107k|         }
 1632|       |
 1633|  1.26k|         return accum;
 1634|  1.26k|      }
pcurves_secp256k1.cpp:_ZN5Botan19UnblindedScalarBitsINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EEC2ERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS3_12Secp256k1RepEE12ScalarParamsEEEEE:
 1378|  2.52k|      explicit UnblindedScalarBits(const typename C::Scalar& scalar) { scalar.serialize_to(std::span{m_bytes}); }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE7is_zeroEv:
  225|  8.87k|      constexpr CT::Choice is_zero() const { return CT::all_zeros(m_val.data(), m_val.size()).as_choice(); }
pcurves_secp256k1.cpp:_ZZNK5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EE12mul2_vartimeERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS3_12Secp256k1RepEE12ScalarParamsEEEEESG_ENKUlvE_clEv:
 1602|  1.26k|         auto [w_0, first_nonempty_window] = [&]() {
 1603|  1.68k|            for(size_t i = 0; i != Windows; ++i) {
  ------------------
  |  Branch (1603:31): [True: 1.68k, False: 0]
  ------------------
 1604|  1.68k|               const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1605|  1.68k|               const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1606|  1.68k|               const size_t window = w_1 + (w_2 << WindowBits);
 1607|       |               // Conditional ok: this function is variable time
 1608|  1.68k|               if(window > 0) {
  ------------------
  |  Branch (1608:19): [True: 1.26k, False: 420]
  ------------------
 1609|  1.26k|                  return std::make_pair(window, i);
 1610|  1.26k|               }
 1611|  1.68k|            }
 1612|       |            // We checked for s1 == s2 == 0 above, so we must see a window eventually
 1613|      0|            BOTAN_ASSERT_UNREACHABLE();
  ------------------
  |  |  166|      0|#define BOTAN_ASSERT_UNREACHABLE() Botan::assert_unreachable(__FILE__, __LINE__)
  ------------------
 1614|      0|         }();
pcurves_secp256k1.cpp:_ZNK5Botan19UnblindedScalarBitsINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EE10get_windowEm:
 1380|   217k|      size_t get_window(size_t offset) const {
 1381|       |         // Extract a WindowBits sized window out of s, depending on offset.
 1382|   217k|         return read_window_bits<WindowBits>(std::span{m_bytes}, offset);
 1383|   217k|      }
pcurves_secp256k1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EpLERKNS_16AffineCurvePointISB_EE:
 1075|   105k|      constexpr Self& operator+=(const AffinePoint& other) {
 1076|   105k|         (*this) = (*this) + other;
 1077|   105k|         return (*this);
 1078|   105k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEeqERKSA_:
  722|  2.63k|      constexpr CT::Choice operator==(const Self& other) const {
  723|  2.63k|         return CT::is_equal(this->data(), other.data(), N).as_choice();
  724|  2.63k|      }
pcurves_secp256k1.cpp:_ZN5Botan13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS3_12Secp256k1RepEE7x3_ax_bERKNS_6IntModINS5_INS6_11FieldParamsEEEEE:
 1275|  1.30k|      static constexpr FieldElement x3_ax_b(const FieldElement& x) { return (x.square() + A) * x + B; }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE11deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  792|  2.57k|      static std::optional<Self> deserialize(std::span<const uint8_t> bytes) {
  793|       |         // Conditional ok: input length is public
  794|  2.57k|         if(bytes.size() != Self::BYTES) {
  ------------------
  |  Branch (794:13): [True: 0, False: 2.57k]
  ------------------
  795|      0|            return {};
  796|      0|         }
  797|       |
  798|  2.57k|         const auto words = bytes_to_words<W, N, BYTES>(bytes.first<Self::BYTES>());
  799|       |
  800|       |         // Conditional acceptable: std::optional is implicitly not constant time
  801|  2.57k|         if(!bigint_ct_is_lt(words.data(), N, P.data(), N).as_bool()) {
  ------------------
  |  Branch (801:13): [True: 22, False: 2.55k]
  ------------------
  802|     22|            return {};
  803|     22|         }
  804|       |
  805|       |         // Safe because we checked above that words is an integer < P
  806|  2.55k|         return Self::from_words(words);
  807|  2.57k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE10from_wordsILm4EEESB_NSt3__15arrayImXT_EEE:
  211|  2.55k|      static constexpr Self from_words(std::array<W, L> w) {
  212|  2.55k|         if constexpr(L == N) {
  213|  2.55k|            return Self(Rep::to_rep(w));
  214|       |         } else {
  215|       |            static_assert(L < N);
  216|       |            std::array<W, N> ew = {};
  217|       |            copy_mem(std::span{ew}.template first<L>(), w);
  218|       |            return Self(Rep::to_rep(ew));
  219|       |         }
  220|  2.55k|      }
pcurves_secp256k1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS4_12Secp256k1RepEE12ScalarParamsEE6to_repERKNSt3__15arrayImLm4EEE:
  115|  3.81k|      constexpr static std::array<W, N> to_rep(const std::array<W, N>& x) {
  116|  3.81k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  117|  3.81k|         comba_mul<N>(z.data(), x.data(), R2.data());
  118|  3.81k|         return Self::redc(z);
  119|  3.81k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE22from_wide_bytes_varlenENSt3__14spanIKhLm18446744073709551615EEE:
  829|  1.26k|      static constexpr std::optional<Self> from_wide_bytes_varlen(std::span<const uint8_t> bytes) {
  830|       |         // Conditional ok: input length is public
  831|  1.26k|         if(bytes.size() > 2 * Self::BYTES) {
  ------------------
  |  Branch (831:13): [True: 0, False: 1.26k]
  ------------------
  832|      0|            return {};
  833|      0|         }
  834|       |
  835|  1.26k|         std::array<uint8_t, 2 * Self::BYTES> padded_bytes = {};
  836|  1.26k|         copy_mem(std::span{padded_bytes}.last(bytes.size()), bytes);
  837|  1.26k|         return Self(Rep::wide_to_rep(bytes_to_words<W, 2 * N, 2 * BYTES>(std::span{padded_bytes})));
  838|  1.26k|      }
pcurves_secp256k1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE12serialize_toENSt3__14spanIhLm65EEE:
  941|  2.57k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  942|  2.57k|         BOTAN_STATE_CHECK(this->is_identity().as_bool() == false);
  ------------------
  |  |   51|  2.57k|   do {                                                         \
  |  |   52|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  2.57k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  943|  2.57k|         BufferStuffer pack(bytes);
  944|  2.57k|         pack.append(0x04);
  945|  2.57k|         x().serialize_to(pack.next<FieldElement::BYTES>());
  946|  2.57k|         y().serialize_to(pack.next<FieldElement::BYTES>());
  947|  2.57k|         BOTAN_DEBUG_ASSERT(pack.full());
  ------------------
  |  |  130|  2.57k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  2.57k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  948|  2.57k|      }
pcurves_secp256k1.cpp:_ZN5BotanplERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEEESD_:
  265|   226k|      friend constexpr BOTAN_FORCE_INLINE Self operator+(const Self& a, const Self& b) {
  266|   226k|         std::array<W, N> t;  // NOLINT(*-member-init)
  267|       |
  268|   226k|         W carry = 0;
  269|  1.13M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (269:28): [True: 904k, False: 226k]
  ------------------
  270|   904k|            t[i] = word_add(a.m_val[i], b.m_val[i], &carry);
  271|   904k|         }
  272|       |
  273|   226k|         std::array<W, N> r;  // NOLINT(*-member-init)
  274|   226k|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  275|   226k|         return Self(r);
  276|   226k|      }
pcurves_secp256k1.cpp:_ZN5BotanmlERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEEESD_:
  346|  2.52k|      friend constexpr BOTAN_FORCE_INLINE Self operator*(const Self& a, const Self& b) {
  347|  2.52k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  348|  2.52k|         comba_mul<N>(z.data(), a.data(), b.data());
  349|  2.52k|         return Self(Rep::redc(z));
  350|  2.52k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE4dataEv:
  896|   683k|      constexpr const W* data() const { return m_val.data(); }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE14invert_vartimeEv:
  598|  1.26k|      constexpr Self invert_vartime() const {
  599|       |         // Conditional ok: this function is variable time
  600|  1.26k|         if(this->is_zero().as_bool()) {
  ------------------
  |  Branch (600:13): [True: 0, False: 1.26k]
  ------------------
  601|      0|            return Self::zero();
  602|      0|         }
  603|       |
  604|  1.26k|         auto x = Self(std::array<W, N>{1});  // 1 in standard domain
  605|  1.26k|         auto b = Self(this->to_words());     // *this in standard domain
  606|       |
  607|       |         // First loop iteration
  608|  1.26k|         Self::_invert_vartime_div2_helper(b, x);
  609|       |
  610|  1.26k|         auto a = b.negate();
  611|       |         // y += x but y is zero at the outset
  612|  1.26k|         auto y = x;
  613|       |
  614|       |         // First half of second loop iteration
  615|  1.26k|         Self::_invert_vartime_div2_helper(a, y);
  616|       |
  617|   227k|         for(;;) {
  618|       |            // Conditional ok: this function is variable time
  619|   227k|            if(a.m_val == b.m_val) {
  ------------------
  |  Branch (619:16): [True: 1.26k, False: 226k]
  ------------------
  620|       |               // At this point it should be that a == b == 1
  621|  1.26k|               auto r = y.negate();
  622|       |
  623|       |               // Convert back to Montgomery if required
  624|  1.26k|               r.m_val = Rep::to_rep(r.m_val);
  625|  1.26k|               return r;
  626|  1.26k|            }
  627|       |
  628|   226k|            auto nx = x + y;
  629|       |
  630|       |            /*
  631|       |            * Otherwise either b > a or a > b
  632|       |            *
  633|       |            * If b > a we want to set b to b - a
  634|       |            * Otherwise we want to set a to a - b
  635|       |            *
  636|       |            * Compute r = b - a and check if it underflowed
  637|       |            * If it did not then we are in the b > a path
  638|       |            */
  639|   226k|            std::array<W, N> r;  // NOLINT(*-member-init)
  640|   226k|            const word carry = bigint_sub3(r.data(), b.data(), N, a.data(), N);
  641|       |
  642|       |            // Conditional ok: this function is variable time
  643|   226k|            if(carry == 0) {
  ------------------
  |  Branch (643:16): [True: 114k, False: 111k]
  ------------------
  644|       |               // b > a
  645|   114k|               b.m_val = r;
  646|   114k|               x = nx;
  647|   114k|               Self::_invert_vartime_div2_helper(b, x);
  648|   114k|            } else {
  649|       |               // We know this can't underflow because a > b
  650|   111k|               bigint_sub3(r.data(), a.data(), N, b.data(), N);
  651|   111k|               a.m_val = r;
  652|   111k|               y = nx;
  653|   111k|               Self::_invert_vartime_div2_helper(a, y);
  654|   111k|            }
  655|   226k|         }
  656|  1.26k|      }
pcurves_secp256k1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE27_invert_vartime_div2_helperERSB_SC_:
  547|   228k|      static constexpr void _invert_vartime_div2_helper(Self& a, Self& x) {
  548|   228k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  549|       |
  550|       |         // Conditional ok: this function is variable time
  551|   687k|         while((a.m_val[0] & 1) != 1) {
  ------------------
  |  Branch (551:16): [True: 458k, False: 228k]
  ------------------
  552|   458k|            shift_right<1>(a.m_val);
  553|       |
  554|   458k|            const W borrow = shift_right<1>(x.m_val);
  555|       |
  556|       |            // Conditional ok: this function is variable time
  557|   458k|            if(borrow) {
  ------------------
  |  Branch (557:16): [True: 233k, False: 225k]
  ------------------
  558|   233k|               bigint_add2(x.m_val.data(), N, INV_2.data(), N);
  559|   233k|            }
  560|   458k|         }
  561|   228k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256k16ParamsENS5_12Secp256k1RepEE12ScalarParamsEEEE6negateEv:
  452|  2.52k|      constexpr Self negate() const {
  453|  2.52k|         const W x_is_zero = ~CT::all_zeros(this->data(), N).value();
  454|       |
  455|  2.52k|         std::array<W, N> r;  // NOLINT(*-member-init)
  456|  2.52k|         W carry = 0;
  457|  12.6k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (457:28): [True: 10.1k, False: 2.52k]
  ------------------
  458|  10.1k|            r[i] = word_sub(P[i] & x_is_zero, m_val[i], &carry);
  459|  10.1k|         }
  460|       |
  461|  2.52k|         return Self(r);
  462|  2.52k|      }
pcurves_secp256r1.cpp:_ZN5Botan23PrecomputedBaseMulTableINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm6EEC2ERKNS_16AffineCurvePointINS_6IntModINS2_12Secp256r1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEE:
 1405|      1|            m_table(basemul_booth_setup<C, WindowBits>(p, BlindedScalar::Bits + 1)) {}
pcurves_secp256r1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E11from_affineERKNS_16AffineCurvePointISB_EE:
 1016|  14.8k|      static constexpr Self from_affine(const AffinePoint& pt) {
 1017|       |         /*
 1018|       |         * If the point is the identity element (x=0, y=0) then instead of
 1019|       |         * creating (x, y, 1) = (0, 0, 1) we want our projective identity
 1020|       |         * encoding of (0, 1, 0)
 1021|       |         *
 1022|       |         * Which we can achieve by a conditional swap of y and z if the
 1023|       |         * affine point is the identity.
 1024|       |         */
 1025|       |
 1026|  14.8k|         auto x = pt.x();
 1027|  14.8k|         auto y = pt.y();
 1028|  14.8k|         auto z = FieldElement::one();
 1029|       |
 1030|  14.8k|         FieldElement::conditional_swap(pt.is_identity(), y, z);
 1031|       |
 1032|  14.8k|         return ProjectiveCurvePoint(x, y, z);
 1033|  14.8k|      }
pcurves_secp256r1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEE1xEv:
  971|  1.57M|      constexpr const FieldElement& x() const { return m_x; }
pcurves_secp256r1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEE1yEv:
  976|  1.57M|      constexpr const FieldElement& y() const { return m_y; }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE3oneEv:
  200|   518k|      static constexpr Self one() { return Self(Rep::one()); }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEC2ENSt3__15arrayImLm4EEE:
  898|  36.6M|      explicit constexpr IntMod(std::array<W, N> v) : m_val(v) {}
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE16conditional_swapENS_2CT6ChoiceERSA_SD_:
  410|  14.8k|      static constexpr void conditional_swap(CT::Choice cond, Self& x, Self& y) {
  411|  14.8k|         const W mask = cond.into_bitmask<W>();
  412|       |
  413|  74.2k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (413:28): [True: 59.3k, False: 14.8k]
  ------------------
  414|  59.3k|            auto nx = Botan::choose(mask, y.m_val[i], x.m_val[i]);
  415|  59.3k|            auto ny = Botan::choose(mask, x.m_val[i], y.m_val[i]);
  416|  59.3k|            x.m_val[i] = nx;
  417|  59.3k|            y.m_val[i] = ny;
  418|  59.3k|         }
  419|  14.8k|      }
pcurves_secp256r1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEE11is_identityEv:
  928|   538k|      constexpr CT::Choice is_identity() const { return x().is_zero() && y().is_zero(); }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE7is_zeroEv:
  225|  3.45M|      constexpr CT::Choice is_zero() const { return CT::all_zeros(m_val.data(), m_val.size()).as_choice(); }
pcurves_secp256r1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_EC2ERKSB_SE_SE_:
 1056|  1.14M|            m_x(x), m_y(y), m_z(z) {}
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E3dblEv:
 1121|  75.2k|      constexpr Self dbl() const {
 1122|  75.2k|         if constexpr(Self::A_is_minus_3) {
 1123|  75.2k|            return dbl_a_minus_3(*this);
 1124|       |         } else if constexpr(Self::A_is_zero) {
 1125|       |            return dbl_a_zero(*this);
 1126|       |         } else {
 1127|       |            return dbl_generic(*this, A);
 1128|       |         }
 1129|  75.2k|      }
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E1zEv:
 1172|  5.38M|      constexpr const FieldElement& z() const { return m_z; }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE6squareEv:
  426|  8.50M|      constexpr BOTAN_FORCE_INLINE Self square() const {
  427|  8.50M|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  428|  8.50M|         comba_sqr<N>(z.data(), this->data());
  429|  8.50M|         return Self(Rep::redc(z));
  430|  8.50M|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4dataEv:
  896|  35.8M|      constexpr const W* data() const { return m_val.data(); }
pcurves_secp256r1.cpp:_ZN5BotanmlERKNS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEESC_:
  346|  10.3M|      friend constexpr BOTAN_FORCE_INLINE Self operator*(const Self& a, const Self& b) {
  347|  10.3M|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  348|  10.3M|         comba_mul<N>(z.data(), a.data(), b.data());
  349|  10.3M|         return Self(Rep::redc(z));
  350|  10.3M|      }
pcurves_secp256r1.cpp:_ZN5BotanmiERKNS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEESC_:
  281|  9.12M|      friend constexpr BOTAN_FORCE_INLINE Self operator-(const Self& a, const Self& b) {
  282|  9.12M|         std::array<W, N> r;  // NOLINT(*-member-init)
  283|  9.12M|         W carry = 0;
  284|  45.6M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (284:28): [True: 36.4M, False: 9.12M]
  ------------------
  285|  36.4M|            r[i] = word_sub(a.m_val[i], b.m_val[i], &carry);
  286|  36.4M|         }
  287|       |
  288|  9.12M|         const auto mask = CT::Mask<W>::expand(carry).value();
  289|       |
  290|  9.12M|         carry = 0;
  291|       |
  292|  45.6M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (292:28): [True: 36.4M, False: 9.12M]
  ------------------
  293|  36.4M|            r[i] = word_add(r[i], P[i] & mask, &carry);
  294|  36.4M|         }
  295|       |
  296|  9.12M|         return Self(r);
  297|  9.12M|      }
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E1xEv:
 1162|  3.01M|      constexpr const FieldElement& x() const { return m_x; }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4mul3Ev:
  335|  1.32M|      constexpr inline Self mul3() const { return mul2() + (*this); }
pcurves_secp256r1.cpp:_ZN5BotanplERKNS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEESC_:
  265|  2.90M|      friend constexpr BOTAN_FORCE_INLINE Self operator+(const Self& a, const Self& b) {
  266|  2.90M|         std::array<W, N> t;  // NOLINT(*-member-init)
  267|       |
  268|  2.90M|         W carry = 0;
  269|  14.5M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (269:28): [True: 11.6M, False: 2.90M]
  ------------------
  270|  11.6M|            t[i] = word_add(a.m_val[i], b.m_val[i], &carry);
  271|  11.6M|         }
  272|       |
  273|  2.90M|         std::array<W, N> r;  // NOLINT(*-member-init)
  274|  2.90M|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  275|  2.90M|         return Self(r);
  276|  2.90M|      }
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E1yEv:
 1167|  2.93M|      constexpr const FieldElement& y() const { return m_y; }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4mul4Ev:
  338|  75.2k|      constexpr inline Self mul4() const { return mul2().mul2(); }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4mul2Ev:
  325|  4.76M|      constexpr BOTAN_FORCE_INLINE Self mul2() const {
  326|  4.76M|         std::array<W, N> t = value();
  327|  4.76M|         const W carry = shift_left<1>(t);
  328|       |
  329|  4.76M|         std::array<W, N> r;  // NOLINT(*-member-init)
  330|  4.76M|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  331|  4.76M|         return Self(r);
  332|  4.76M|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE5valueEv:
  894|  5.17M|      constexpr const std::array<W, N>& value() const { return m_val; }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4mul8Ev:
  341|  75.2k|      constexpr inline Self mul8() const { return mul2().mul2().mul2(); }
pcurves_secp256r1.cpp:_ZN5BotanplERKNS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_EESE_:
 1064|   134k|      friend constexpr Self operator+(const Self& a, const Self& b) { return Self::add(a, b); }
pcurves_secp256r1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E3addERKSC_SE_:
 1103|   134k|      constexpr static Self add(const Self& a, const Self& b) { return point_add<Self, FieldElement>(a, b); }
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E11is_identityEv:
 1082|  1.09M|      constexpr CT::Choice is_identity() const { return z().is_zero(); }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE18conditional_assignERSA_SB_SB_NS_2CT6ChoiceERKSA_SF_SF_:
  395|  1.27M|         Self& x, Self& y, Self& z, CT::Choice cond, const Self& nx, const Self& ny, const Self& nz) {
  396|  1.27M|         const W mask = cond.into_bitmask<W>();
  397|       |
  398|  6.38M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (398:28): [True: 5.10M, False: 1.27M]
  ------------------
  399|  5.10M|            x.m_val[i] = Botan::choose(mask, nx.m_val[i], x.m_val[i]);
  400|  5.10M|            y.m_val[i] = Botan::choose(mask, ny.m_val[i], y.m_val[i]);
  401|  5.10M|            z.m_val[i] = Botan::choose(mask, nz.m_val[i], z.m_val[i]);
  402|  5.10M|         }
  403|  1.27M|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEmLERKSA_:
  355|  2.08M|      constexpr BOTAN_FORCE_INLINE Self& operator*=(const Self& other) {
  356|  2.08M|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  357|  2.08M|         comba_mul<N>(z.data(), data(), other.data());
  358|  2.08M|         m_val = Rep::redc(z);
  359|  2.08M|         return (*this);
  360|  2.08M|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE14invert_vartimeEv:
  598|  4.96k|      constexpr Self invert_vartime() const {
  599|       |         // Conditional ok: this function is variable time
  600|  4.96k|         if(this->is_zero().as_bool()) {
  ------------------
  |  Branch (600:13): [True: 0, False: 4.96k]
  ------------------
  601|      0|            return Self::zero();
  602|      0|         }
  603|       |
  604|  4.96k|         auto x = Self(std::array<W, N>{1});  // 1 in standard domain
  605|  4.96k|         auto b = Self(this->to_words());     // *this in standard domain
  606|       |
  607|       |         // First loop iteration
  608|  4.96k|         Self::_invert_vartime_div2_helper(b, x);
  609|       |
  610|  4.96k|         auto a = b.negate();
  611|       |         // y += x but y is zero at the outset
  612|  4.96k|         auto y = x;
  613|       |
  614|       |         // First half of second loop iteration
  615|  4.96k|         Self::_invert_vartime_div2_helper(a, y);
  616|       |
  617|   863k|         for(;;) {
  618|       |            // Conditional ok: this function is variable time
  619|   863k|            if(a.m_val == b.m_val) {
  ------------------
  |  Branch (619:16): [True: 4.96k, False: 858k]
  ------------------
  620|       |               // At this point it should be that a == b == 1
  621|  4.96k|               auto r = y.negate();
  622|       |
  623|       |               // Convert back to Montgomery if required
  624|  4.96k|               r.m_val = Rep::to_rep(r.m_val);
  625|  4.96k|               return r;
  626|  4.96k|            }
  627|       |
  628|   858k|            auto nx = x + y;
  629|       |
  630|       |            /*
  631|       |            * Otherwise either b > a or a > b
  632|       |            *
  633|       |            * If b > a we want to set b to b - a
  634|       |            * Otherwise we want to set a to a - b
  635|       |            *
  636|       |            * Compute r = b - a and check if it underflowed
  637|       |            * If it did not then we are in the b > a path
  638|       |            */
  639|   858k|            std::array<W, N> r;  // NOLINT(*-member-init)
  640|   858k|            const word carry = bigint_sub3(r.data(), b.data(), N, a.data(), N);
  641|       |
  642|       |            // Conditional ok: this function is variable time
  643|   858k|            if(carry == 0) {
  ------------------
  |  Branch (643:16): [True: 446k, False: 412k]
  ------------------
  644|       |               // b > a
  645|   446k|               b.m_val = r;
  646|   446k|               x = nx;
  647|   446k|               Self::_invert_vartime_div2_helper(b, x);
  648|   446k|            } else {
  649|       |               // We know this can't underflow because a > b
  650|   412k|               bigint_sub3(r.data(), a.data(), N, b.data(), N);
  651|   412k|               a.m_val = r;
  652|   412k|               y = nx;
  653|   412k|               Self::_invert_vartime_div2_helper(a, y);
  654|   412k|            }
  655|   858k|         }
  656|  4.96k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE8to_wordsEv:
  734|  14.7k|      constexpr std::array<W, Self::N> to_words() const { return Rep::from_rep(m_val); }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE27_invert_vartime_div2_helperERSA_SB_:
  547|   868k|      static constexpr void _invert_vartime_div2_helper(Self& a, Self& x) {
  548|   868k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  549|       |
  550|       |         // Conditional ok: this function is variable time
  551|  2.67M|         while((a.m_val[0] & 1) != 1) {
  ------------------
  |  Branch (551:16): [True: 1.80M, False: 868k]
  ------------------
  552|  1.80M|            shift_right<1>(a.m_val);
  553|       |
  554|  1.80M|            const W borrow = shift_right<1>(x.m_val);
  555|       |
  556|       |            // Conditional ok: this function is variable time
  557|  1.80M|            if(borrow) {
  ------------------
  |  Branch (557:16): [True: 630k, False: 1.17M]
  ------------------
  558|   630k|               bigint_add2(x.m_val.data(), N, INV_2.data(), N);
  559|   630k|            }
  560|  1.80M|         }
  561|   868k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE6negateEv:
  452|  14.8k|      constexpr Self negate() const {
  453|  14.8k|         const W x_is_zero = ~CT::all_zeros(this->data(), N).value();
  454|       |
  455|  14.8k|         std::array<W, N> r;  // NOLINT(*-member-init)
  456|  14.8k|         W carry = 0;
  457|  74.2k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (457:28): [True: 59.3k, False: 14.8k]
  ------------------
  458|  59.3k|            r[i] = word_sub(P[i] & x_is_zero, m_val[i], &carry);
  459|  59.3k|         }
  460|       |
  461|  14.8k|         return Self(r);
  462|  14.8k|      }
pcurves_secp256r1.cpp:_ZN5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEEC2ERKSB_SE_:
  917|   344k|      constexpr AffineCurvePoint(const FieldElement& x, const FieldElement& y) : m_x(x), m_y(y) {}
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE11stash_valueILm9EEENSt3__15arrayImXT_EEEv:
  759|  9.92k|      std::array<W, L> stash_value() const {
  760|  9.92k|         static_assert(L >= N);
  761|  9.92k|         std::array<W, L> stash = {};
  762|  49.6k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (762:28): [True: 39.7k, False: 9.92k]
  ------------------
  763|  39.7k|            stash[i] = m_val[i];
  764|  39.7k|         }
  765|  9.92k|         return stash;
  766|  9.92k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE8to_wordsEv:
  734|  4.91k|      constexpr std::array<W, Self::N> to_words() const { return Rep::from_rep(m_val); }
pcurves_secp256r1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS3_12Secp256r1RepEE12ScalarParamsEE8from_repERKNSt3__15arrayImLm4EEE:
  137|  19.6k|      constexpr static std::array<W, N> from_rep(const std::array<W, N>& z) {
  138|  19.6k|         std::array<W, 2 * N> ze = {};
  139|  19.6k|         copy_mem(std::span{ze}.template first<N>(), z);
  140|  19.6k|         return Self::redc(ze);
  141|  19.6k|      }
pcurves_secp256r1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS3_12Secp256r1RepEE12ScalarParamsEE4redcERKNSt3__15arrayImLm8EEE:
  104|  54.1k|      constexpr static std::array<W, N> redc(const std::array<W, 2 * N>& z) {
  105|       |         if constexpr(P_dash == 1) {
  106|       |            return monty_redc_pdash1(z, P);
  107|  54.1k|         } else {
  108|  54.1k|            return monty_redc(z, P, P_dash);
  109|  54.1k|         }
  110|  54.1k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE12serialize_toENSt3__14spanIhLm32EEE:
  739|  14.7k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  740|  14.7k|         auto v = Rep::from_rep(m_val);
  741|  14.7k|         std::reverse(v.begin(), v.end());
  742|       |
  743|  14.7k|         if constexpr(Self::BYTES == N * WordInfo<W>::bytes) {
  744|  14.7k|            store_be(bytes, v);
  745|       |         } else {
  746|       |            // Remove leading zero bytes
  747|       |            const auto padded_bytes = store_be(v);
  748|       |            constexpr size_t extra = N * WordInfo<W>::bytes - Self::BYTES;
  749|       |            copy_mem(bytes, std::span{padded_bytes}.template subspan<extra, Self::BYTES>());
  750|       |         }
  751|  14.7k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE11deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  792|  14.8k|      static std::optional<Self> deserialize(std::span<const uint8_t> bytes) {
  793|       |         // Conditional ok: input length is public
  794|  14.8k|         if(bytes.size() != Self::BYTES) {
  ------------------
  |  Branch (794:13): [True: 0, False: 14.8k]
  ------------------
  795|      0|            return {};
  796|      0|         }
  797|       |
  798|  14.8k|         const auto words = bytes_to_words<W, N, BYTES>(bytes.first<Self::BYTES>());
  799|       |
  800|       |         // Conditional acceptable: std::optional is implicitly not constant time
  801|  14.8k|         if(!bigint_ct_is_lt(words.data(), N, P.data(), N).as_bool()) {
  ------------------
  |  Branch (801:13): [True: 0, False: 14.8k]
  ------------------
  802|      0|            return {};
  803|      0|         }
  804|       |
  805|       |         // Safe because we checked above that words is an integer < P
  806|  14.8k|         return Self::from_words(words);
  807|  14.8k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE10from_wordsILm4EEESA_NSt3__15arrayImXT_EEE:
  211|  19.8k|      static constexpr Self from_words(std::array<W, L> w) {
  212|  19.8k|         if constexpr(L == N) {
  213|  19.8k|            return Self(Rep::to_rep(w));
  214|       |         } else {
  215|       |            static_assert(L < N);
  216|       |            std::array<W, N> ew = {};
  217|       |            copy_mem(std::span{ew}.template first<L>(), w);
  218|       |            return Self(Rep::to_rep(ew));
  219|       |         }
  220|  19.8k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE10from_stashILm9EEESB_RKNSt3__15arrayImXT_EEE:
  774|  49.1k|      static Self from_stash(const std::array<W, L>& stash) {
  775|  49.1k|         static_assert(L >= N);
  776|  49.1k|         std::array<W, N> val = {};
  777|   245k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (777:28): [True: 196k, False: 49.1k]
  ------------------
  778|   196k|            val[i] = stash[i];
  779|   196k|         }
  780|  49.1k|         return Self(val);
  781|  49.1k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEEC2ENSt3__15arrayImLm4EEE:
  898|   986k|      explicit constexpr IntMod(std::array<W, N> v) : m_val(v) {}
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE12serialize_toENSt3__14spanIhLm32EEE:
  739|  19.8k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  740|  19.8k|         auto v = Rep::from_rep(m_val);
  741|  19.8k|         std::reverse(v.begin(), v.end());
  742|       |
  743|  19.8k|         if constexpr(Self::BYTES == N * WordInfo<W>::bytes) {
  744|  19.8k|            store_be(bytes, v);
  745|       |         } else {
  746|       |            // Remove leading zero bytes
  747|       |            const auto padded_bytes = store_be(v);
  748|       |            constexpr size_t extra = N * WordInfo<W>::bytes - Self::BYTES;
  749|       |            copy_mem(bytes, std::span{padded_bytes}.template subspan<extra, Self::BYTES>());
  750|       |         }
  751|  19.8k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE11stash_valueILm9EEENSt3__15arrayImXT_EEEv:
  759|  29.5k|      std::array<W, L> stash_value() const {
  760|  29.5k|         static_assert(L >= N);
  761|  29.5k|         std::array<W, L> stash = {};
  762|   147k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (762:28): [True: 118k, False: 29.5k]
  ------------------
  763|   118k|            stash[i] = m_val[i];
  764|   118k|         }
  765|  29.5k|         return stash;
  766|  29.5k|      }
pcurves_secp256r1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS3_12Secp256r1RepEE12ScalarParamsEE11wide_to_repERKNSt3__15arrayImLm8EEE:
  127|  4.91k|      constexpr static std::array<W, N> wide_to_rep(const std::array<W, 2 * N>& x) {
  128|  4.91k|         auto redc_x = Self::redc(x);
  129|  4.91k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  130|  4.91k|         comba_mul<N>(z.data(), redc_x.data(), R3.data());
  131|  4.91k|         return Self::redc(z);
  132|  4.91k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE10from_stashILm9EEESA_RKNSt3__15arrayImXT_EEE:
  774|  49.6k|      static Self from_stash(const std::array<W, L>& stash) {
  775|  49.6k|         static_assert(L >= N);
  776|  49.6k|         std::array<W, N> val = {};
  777|   248k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (777:28): [True: 198k, False: 49.6k]
  ------------------
  778|   198k|            val[i] = stash[i];
  779|   198k|         }
  780|  49.6k|         return Self(val);
  781|  49.6k|      }
pcurves_secp256r1.cpp:_ZN5BotanplERKNS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_EERKNS_16AffineCurvePointISB_EE:
 1066|   439k|      friend constexpr Self operator+(const Self& a, const AffinePoint& b) { return Self::add_mixed(a, b); }
pcurves_secp256r1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E9add_mixedERKSC_RKNS_16AffineCurvePointISB_EE:
 1091|   503k|      constexpr static Self add_mixed(const Self& a, const AffinePoint& b) {
 1092|   503k|         return point_add_mixed<Self, AffinePoint, FieldElement>(a, b, FieldElement::one());
 1093|   503k|      }
pcurves_secp256r1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_E5dbl_nEm:
 1108|   416k|      constexpr Self dbl_n(size_t n) const {
 1109|   416k|         if constexpr(Self::A_is_minus_3) {
 1110|   416k|            return dbl_n_a_minus_3(*this, n);
 1111|       |         } else if constexpr(Self::A_is_zero) {
 1112|       |            return dbl_n_a_zero(*this, n);
 1113|       |         } else {
 1114|       |            return dbl_n_generic(*this, A, n);
 1115|       |         }
 1116|   416k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEE4div2Ev:
  302|   416k|      Self div2() const {
  303|       |         // The inverse of 2 modulo P is (P/2)+1; this avoids a constexpr time
  304|       |         // general inversion, which some compilers can't handle
  305|   416k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  306|       |
  307|       |         // We could multiply by INV_2 but there is a better way ...
  308|       |
  309|   416k|         std::array<W, N> t = value();
  310|   416k|         const W borrow = shift_right<1>(t);
  311|       |
  312|       |         // If value was odd, add (P/2)+1
  313|   416k|         const auto mask = CT::Mask<W>::expand(borrow).value();
  314|       |
  315|   416k|         W carry = 0;
  316|       |
  317|  2.08M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (317:28): [True: 1.66M, False: 416k]
  ------------------
  318|  1.66M|            t[i] = word_add(t[i], INV_2[i] & mask, &carry);
  319|  1.66M|         }
  320|       |
  321|   416k|         return Self(t);
  322|   416k|      }
pcurves_secp256r1.cpp:_ZN5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EEC2ERKNS_16AffineCurvePointINS_6IntModINS2_12Secp256r1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEESH_:
 1577|  4.96k|            m_table(to_affine_batch<C, true>(mul2_setup<C, W>(p, q))) {}
pcurves_secp256r1.cpp:_ZN5BotanplERKNS_16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEEERKNS_20ProjectiveCurvePointISB_S7_EE:
 1068|  64.5k|      friend constexpr Self operator+(const AffinePoint& a, const Self& b) { return Self::add_mixed(b, a); }
pcurves_secp256r1.cpp:_ZNK5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EE12mul2_vartimeERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS2_12Secp256r1RepEE12ScalarParamsEEEEESG_:
 1588|  4.91k|      ProjectivePoint mul2_vartime(const Scalar& s1, const Scalar& s2) const {
 1589|  4.91k|         constexpr size_t Windows = (Scalar::BITS + WindowBits - 1) / WindowBits;
 1590|       |
 1591|  4.91k|         const UnblindedScalarBits<C, W> bits1(s1);
 1592|  4.91k|         const UnblindedScalarBits<C, W> bits2(s2);
 1593|       |
 1594|  4.91k|         const bool s1_is_zero = s1.is_zero().as_bool();
 1595|  4.91k|         const bool s2_is_zero = s2.is_zero().as_bool();
 1596|       |
 1597|       |         // Conditional ok: this function is variable time
 1598|  4.91k|         if(s1_is_zero && s2_is_zero) {
  ------------------
  |  Branch (1598:13): [True: 0, False: 4.91k]
  |  Branch (1598:27): [True: 0, False: 0]
  ------------------
 1599|      0|            return ProjectivePoint::identity();
 1600|      0|         }
 1601|       |
 1602|  4.91k|         auto [w_0, first_nonempty_window] = [&]() {
 1603|  4.91k|            for(size_t i = 0; i != Windows; ++i) {
 1604|  4.91k|               const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1605|  4.91k|               const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1606|  4.91k|               const size_t window = w_1 + (w_2 << WindowBits);
 1607|       |               // Conditional ok: this function is variable time
 1608|  4.91k|               if(window > 0) {
 1609|  4.91k|                  return std::make_pair(window, i);
 1610|  4.91k|               }
 1611|  4.91k|            }
 1612|       |            // We checked for s1 == s2 == 0 above, so we must see a window eventually
 1613|  4.91k|            BOTAN_ASSERT_UNREACHABLE();
 1614|  4.91k|         }();
 1615|       |
 1616|  4.91k|         BOTAN_ASSERT_NOMSG(w_0 > 0);
  ------------------
  |  |   77|  4.91k|   do {                                                                     \
  |  |   78|  4.91k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.91k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.91k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.91k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.91k]
  |  |  ------------------
  ------------------
 1617|  4.91k|         auto accum = ProjectivePoint::from_affine(m_table[w_0 - 1]);
 1618|       |
 1619|   420k|         for(size_t i = first_nonempty_window + 1; i < Windows; ++i) {
  ------------------
  |  Branch (1619:52): [True: 416k, False: 4.91k]
  ------------------
 1620|   416k|            accum = accum.dbl_n(WindowBits);
 1621|       |
 1622|   416k|            const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1623|   416k|            const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1624|       |
 1625|   416k|            const size_t window = w_1 + (w_2 << WindowBits);
 1626|       |
 1627|       |            // Conditional ok: this function is variable time
 1628|   416k|            if(window > 0) {
  ------------------
  |  Branch (1628:16): [True: 409k, False: 6.71k]
  ------------------
 1629|   409k|               accum += m_table[window - 1];
 1630|   409k|            }
 1631|   416k|         }
 1632|       |
 1633|  4.91k|         return accum;
 1634|  4.91k|      }
pcurves_secp256r1.cpp:_ZN5Botan19UnblindedScalarBitsINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EEC2ERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS2_12Secp256r1RepEE12ScalarParamsEEEEE:
 1378|  9.83k|      explicit UnblindedScalarBits(const typename C::Scalar& scalar) { scalar.serialize_to(std::span{m_bytes}); }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE7is_zeroEv:
  225|  34.4k|      constexpr CT::Choice is_zero() const { return CT::all_zeros(m_val.data(), m_val.size()).as_choice(); }
pcurves_secp256r1.cpp:_ZZNK5Botan16VartimeMul2TableINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EE12mul2_vartimeERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS2_12Secp256r1RepEE12ScalarParamsEEEEESG_ENKUlvE_clEv:
 1602|  4.91k|         auto [w_0, first_nonempty_window] = [&]() {
 1603|  6.75k|            for(size_t i = 0; i != Windows; ++i) {
  ------------------
  |  Branch (1603:31): [True: 6.75k, False: 0]
  ------------------
 1604|  6.75k|               const size_t w_1 = bits1.get_window((Windows - i - 1) * WindowBits);
 1605|  6.75k|               const size_t w_2 = bits2.get_window((Windows - i - 1) * WindowBits);
 1606|  6.75k|               const size_t window = w_1 + (w_2 << WindowBits);
 1607|       |               // Conditional ok: this function is variable time
 1608|  6.75k|               if(window > 0) {
  ------------------
  |  Branch (1608:19): [True: 4.91k, False: 1.83k]
  ------------------
 1609|  4.91k|                  return std::make_pair(window, i);
 1610|  4.91k|               }
 1611|  6.75k|            }
 1612|       |            // We checked for s1 == s2 == 0 above, so we must see a window eventually
 1613|      0|            BOTAN_ASSERT_UNREACHABLE();
  ------------------
  |  |  166|      0|#define BOTAN_ASSERT_UNREACHABLE() Botan::assert_unreachable(__FILE__, __LINE__)
  ------------------
 1614|      0|         }();
pcurves_secp256r1.cpp:_ZNK5Botan19UnblindedScalarBitsINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EE10get_windowEm:
 1380|   845k|      size_t get_window(size_t offset) const {
 1381|       |         // Extract a WindowBits sized window out of s, depending on offset.
 1382|   845k|         return read_window_bits<WindowBits>(std::span{m_bytes}, offset);
 1383|   845k|      }
pcurves_secp256r1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEES7_EpLERKNS_16AffineCurvePointISB_EE:
 1075|   409k|      constexpr Self& operator+=(const AffinePoint& other) {
 1076|   409k|         (*this) = (*this) + other;
 1077|   409k|         return (*this);
 1078|   409k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS2_9secp256r16ParamsES3_E11FieldParamsEEEEeqERKSA_:
  722|  9.99k|      constexpr CT::Choice operator==(const Self& other) const {
  723|  9.99k|         return CT::is_equal(this->data(), other.data(), N).as_choice();
  724|  9.99k|      }
pcurves_secp256r1.cpp:_ZN5Botan13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS2_12Secp256r1RepEE7x3_ax_bERKNS_6IntModINS5_INS6_11FieldParamsEEEEE:
 1275|  4.98k|      static constexpr FieldElement x3_ax_b(const FieldElement& x) { return (x.square() + A) * x + B; }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE11deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  792|  9.92k|      static std::optional<Self> deserialize(std::span<const uint8_t> bytes) {
  793|       |         // Conditional ok: input length is public
  794|  9.92k|         if(bytes.size() != Self::BYTES) {
  ------------------
  |  Branch (794:13): [True: 0, False: 9.92k]
  ------------------
  795|      0|            return {};
  796|      0|         }
  797|       |
  798|  9.92k|         const auto words = bytes_to_words<W, N, BYTES>(bytes.first<Self::BYTES>());
  799|       |
  800|       |         // Conditional acceptable: std::optional is implicitly not constant time
  801|  9.92k|         if(!bigint_ct_is_lt(words.data(), N, P.data(), N).as_bool()) {
  ------------------
  |  Branch (801:13): [True: 49, False: 9.87k]
  ------------------
  802|     49|            return {};
  803|     49|         }
  804|       |
  805|       |         // Safe because we checked above that words is an integer < P
  806|  9.87k|         return Self::from_words(words);
  807|  9.92k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE10from_wordsILm4EEESB_NSt3__15arrayImXT_EEE:
  211|  9.87k|      static constexpr Self from_words(std::array<W, L> w) {
  212|  9.87k|         if constexpr(L == N) {
  213|  9.87k|            return Self(Rep::to_rep(w));
  214|       |         } else {
  215|       |            static_assert(L < N);
  216|       |            std::array<W, N> ew = {};
  217|       |            copy_mem(std::span{ew}.template first<L>(), w);
  218|       |            return Self(Rep::to_rep(ew));
  219|       |         }
  220|  9.87k|      }
pcurves_secp256r1.cpp:_ZN5Botan13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS3_12Secp256r1RepEE12ScalarParamsEE6to_repERKNSt3__15arrayImLm4EEE:
  115|  14.7k|      constexpr static std::array<W, N> to_rep(const std::array<W, N>& x) {
  116|  14.7k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  117|  14.7k|         comba_mul<N>(z.data(), x.data(), R2.data());
  118|  14.7k|         return Self::redc(z);
  119|  14.7k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE22from_wide_bytes_varlenENSt3__14spanIKhLm18446744073709551615EEE:
  829|  4.91k|      static constexpr std::optional<Self> from_wide_bytes_varlen(std::span<const uint8_t> bytes) {
  830|       |         // Conditional ok: input length is public
  831|  4.91k|         if(bytes.size() > 2 * Self::BYTES) {
  ------------------
  |  Branch (831:13): [True: 0, False: 4.91k]
  ------------------
  832|      0|            return {};
  833|      0|         }
  834|       |
  835|  4.91k|         std::array<uint8_t, 2 * Self::BYTES> padded_bytes = {};
  836|  4.91k|         copy_mem(std::span{padded_bytes}.last(bytes.size()), bytes);
  837|  4.91k|         return Self(Rep::wide_to_rep(bytes_to_words<W, 2 * N, 2 * BYTES>(std::span{padded_bytes})));
  838|  4.91k|      }
pcurves_secp256r1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS3_9secp256r16ParamsES4_E11FieldParamsEEEEEE12serialize_toENSt3__14spanIhLm65EEE:
  941|  9.92k|      constexpr void serialize_to(std::span<uint8_t, Self::BYTES> bytes) const {
  942|  9.92k|         BOTAN_STATE_CHECK(this->is_identity().as_bool() == false);
  ------------------
  |  |   51|  9.92k|   do {                                                         \
  |  |   52|  9.92k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  9.92k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 9.92k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  9.92k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 9.92k]
  |  |  ------------------
  ------------------
  943|  9.92k|         BufferStuffer pack(bytes);
  944|  9.92k|         pack.append(0x04);
  945|  9.92k|         x().serialize_to(pack.next<FieldElement::BYTES>());
  946|  9.92k|         y().serialize_to(pack.next<FieldElement::BYTES>());
  947|  9.92k|         BOTAN_DEBUG_ASSERT(pack.full());
  ------------------
  |  |  130|  9.92k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  9.92k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 9.92k]
  |  |  ------------------
  ------------------
  948|  9.92k|      }
pcurves_secp256r1.cpp:_ZN5BotanplERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEEESD_:
  265|   893k|      friend constexpr BOTAN_FORCE_INLINE Self operator+(const Self& a, const Self& b) {
  266|   893k|         std::array<W, N> t;  // NOLINT(*-member-init)
  267|       |
  268|   893k|         W carry = 0;
  269|  4.46M|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (269:28): [True: 3.57M, False: 893k]
  ------------------
  270|  3.57M|            t[i] = word_add(a.m_val[i], b.m_val[i], &carry);
  271|  3.57M|         }
  272|       |
  273|   893k|         std::array<W, N> r;  // NOLINT(*-member-init)
  274|   893k|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  275|   893k|         return Self(r);
  276|   893k|      }
pcurves_secp256r1.cpp:_ZN5BotanmlERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEEESD_:
  346|  9.83k|      friend constexpr BOTAN_FORCE_INLINE Self operator*(const Self& a, const Self& b) {
  347|  9.83k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  348|  9.83k|         comba_mul<N>(z.data(), a.data(), b.data());
  349|  9.83k|         return Self(Rep::redc(z));
  350|  9.83k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE4dataEv:
  896|  2.69M|      constexpr const W* data() const { return m_val.data(); }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE14invert_vartimeEv:
  598|  4.91k|      constexpr Self invert_vartime() const {
  599|       |         // Conditional ok: this function is variable time
  600|  4.91k|         if(this->is_zero().as_bool()) {
  ------------------
  |  Branch (600:13): [True: 0, False: 4.91k]
  ------------------
  601|      0|            return Self::zero();
  602|      0|         }
  603|       |
  604|  4.91k|         auto x = Self(std::array<W, N>{1});  // 1 in standard domain
  605|  4.91k|         auto b = Self(this->to_words());     // *this in standard domain
  606|       |
  607|       |         // First loop iteration
  608|  4.91k|         Self::_invert_vartime_div2_helper(b, x);
  609|       |
  610|  4.91k|         auto a = b.negate();
  611|       |         // y += x but y is zero at the outset
  612|  4.91k|         auto y = x;
  613|       |
  614|       |         // First half of second loop iteration
  615|  4.91k|         Self::_invert_vartime_div2_helper(a, y);
  616|       |
  617|   897k|         for(;;) {
  618|       |            // Conditional ok: this function is variable time
  619|   897k|            if(a.m_val == b.m_val) {
  ------------------
  |  Branch (619:16): [True: 4.91k, False: 893k]
  ------------------
  620|       |               // At this point it should be that a == b == 1
  621|  4.91k|               auto r = y.negate();
  622|       |
  623|       |               // Convert back to Montgomery if required
  624|  4.91k|               r.m_val = Rep::to_rep(r.m_val);
  625|  4.91k|               return r;
  626|  4.91k|            }
  627|       |
  628|   893k|            auto nx = x + y;
  629|       |
  630|       |            /*
  631|       |            * Otherwise either b > a or a > b
  632|       |            *
  633|       |            * If b > a we want to set b to b - a
  634|       |            * Otherwise we want to set a to a - b
  635|       |            *
  636|       |            * Compute r = b - a and check if it underflowed
  637|       |            * If it did not then we are in the b > a path
  638|       |            */
  639|   893k|            std::array<W, N> r;  // NOLINT(*-member-init)
  640|   893k|            const word carry = bigint_sub3(r.data(), b.data(), N, a.data(), N);
  641|       |
  642|       |            // Conditional ok: this function is variable time
  643|   893k|            if(carry == 0) {
  ------------------
  |  Branch (643:16): [True: 454k, False: 438k]
  ------------------
  644|       |               // b > a
  645|   454k|               b.m_val = r;
  646|   454k|               x = nx;
  647|   454k|               Self::_invert_vartime_div2_helper(b, x);
  648|   454k|            } else {
  649|       |               // We know this can't underflow because a > b
  650|   438k|               bigint_sub3(r.data(), a.data(), N, b.data(), N);
  651|   438k|               a.m_val = r;
  652|   438k|               y = nx;
  653|   438k|               Self::_invert_vartime_div2_helper(a, y);
  654|   438k|            }
  655|   893k|         }
  656|  4.91k|      }
pcurves_secp256r1.cpp:_ZN5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE27_invert_vartime_div2_helperERSB_SC_:
  547|   902k|      static constexpr void _invert_vartime_div2_helper(Self& a, Self& x) {
  548|   902k|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  549|       |
  550|       |         // Conditional ok: this function is variable time
  551|  2.69M|         while((a.m_val[0] & 1) != 1) {
  ------------------
  |  Branch (551:16): [True: 1.79M, False: 902k]
  ------------------
  552|  1.79M|            shift_right<1>(a.m_val);
  553|       |
  554|  1.79M|            const W borrow = shift_right<1>(x.m_val);
  555|       |
  556|       |            // Conditional ok: this function is variable time
  557|  1.79M|            if(borrow) {
  ------------------
  |  Branch (557:16): [True: 916k, False: 873k]
  ------------------
  558|   916k|               bigint_add2(x.m_val.data(), N, INV_2.data(), N);
  559|   916k|            }
  560|  1.79M|         }
  561|   902k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6IntModINS_13MontgomeryRepINS_13EllipticCurveINS_6PCurve12_GLOBAL__N_19secp256r16ParamsENS4_12Secp256r1RepEE12ScalarParamsEEEE6negateEv:
  452|  9.83k|      constexpr Self negate() const {
  453|  9.83k|         const W x_is_zero = ~CT::all_zeros(this->data(), N).value();
  454|       |
  455|  9.83k|         std::array<W, N> r;  // NOLINT(*-member-init)
  456|  9.83k|         W carry = 0;
  457|  49.1k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (457:28): [True: 39.3k, False: 9.83k]
  ------------------
  458|  39.3k|            r[i] = word_sub(P[i] & x_is_zero, m_val[i], &carry);
  459|  39.3k|         }
  460|       |
  461|  9.83k|         return Self(r);
  462|  9.83k|      }
pcurves_sm2p256v1.cpp:_ZN5Botan23PrecomputedBaseMulTableINS_6PCurve12_GLOBAL__N_19sm2p256v15CurveELm6EEC2ERKNS_16AffineCurvePointINS_6IntModINS3_12Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEE:
 1405|      1|            m_table(basemul_booth_setup<C, WindowBits>(p, BlindedScalar::Bits + 1)) {}
pcurves_sm2p256v1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E11from_affineERKNS_16AffineCurvePointISB_EE:
 1016|      1|      static constexpr Self from_affine(const AffinePoint& pt) {
 1017|       |         /*
 1018|       |         * If the point is the identity element (x=0, y=0) then instead of
 1019|       |         * creating (x, y, 1) = (0, 0, 1) we want our projective identity
 1020|       |         * encoding of (0, 1, 0)
 1021|       |         *
 1022|       |         * Which we can achieve by a conditional swap of y and z if the
 1023|       |         * affine point is the identity.
 1024|       |         */
 1025|       |
 1026|      1|         auto x = pt.x();
 1027|      1|         auto y = pt.y();
 1028|      1|         auto z = FieldElement::one();
 1029|       |
 1030|      1|         FieldElement::conditional_swap(pt.is_identity(), y, z);
 1031|       |
 1032|      1|         return ProjectiveCurvePoint(x, y, z);
 1033|      1|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE1xEv:
  971|      2|      constexpr const FieldElement& x() const { return m_x; }
pcurves_sm2p256v1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE1yEv:
  976|      2|      constexpr const FieldElement& y() const { return m_y; }
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE3oneEv:
  200|      1|      static constexpr Self one() { return Self(Rep::one()); }
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEC2ENSt3__15arrayImLm4EEE:
  898|  46.4k|      explicit constexpr IntMod(std::array<W, N> v) : m_val(v) {}
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE16conditional_swapENS_2CT6ChoiceERSA_SD_:
  410|      1|      static constexpr void conditional_swap(CT::Choice cond, Self& x, Self& y) {
  411|      1|         const W mask = cond.into_bitmask<W>();
  412|       |
  413|      5|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (413:28): [True: 4, False: 1]
  ------------------
  414|      4|            auto nx = Botan::choose(mask, y.m_val[i], x.m_val[i]);
  415|      4|            auto ny = Botan::choose(mask, x.m_val[i], y.m_val[i]);
  416|      4|            x.m_val[i] = nx;
  417|      4|            y.m_val[i] = ny;
  418|      4|         }
  419|      1|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEE11is_identityEv:
  928|      1|      constexpr CT::Choice is_identity() const { return x().is_zero() && y().is_zero(); }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE7is_zeroEv:
  225|  4.51k|      constexpr CT::Choice is_zero() const { return CT::all_zeros(m_val.data(), m_val.size()).as_choice(); }
pcurves_sm2p256v1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EC2ERKSB_SE_SE_:
 1056|  1.56k|            m_x(x), m_y(y), m_z(z) {}
pcurves_sm2p256v1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E3dblEv:
 1121|    833|      constexpr Self dbl() const {
 1122|    833|         if constexpr(Self::A_is_minus_3) {
 1123|    833|            return dbl_a_minus_3(*this);
 1124|       |         } else if constexpr(Self::A_is_zero) {
 1125|       |            return dbl_a_zero(*this);
 1126|       |         } else {
 1127|       |            return dbl_generic(*this, A);
 1128|       |         }
 1129|    833|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1zEv:
 1172|  13.7k|      constexpr const FieldElement& z() const { return m_z; }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE6squareEv:
  426|  7.84k|      constexpr BOTAN_FORCE_INLINE Self square() const {
  427|  7.84k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  428|  7.84k|         comba_sqr<N>(z.data(), this->data());
  429|  7.84k|         return Self(Rep::redc(z));
  430|  7.84k|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4dataEv:
  896|  51.5k|      constexpr const W* data() const { return m_val.data(); }
pcurves_sm2p256v1.cpp:_ZN5BotanmlERKNS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  346|  21.5k|      friend constexpr BOTAN_FORCE_INLINE Self operator*(const Self& a, const Self& b) {
  347|  21.5k|         std::array<W, 2 * N> z;  // NOLINT(*-member-init)
  348|  21.5k|         comba_mul<N>(z.data(), a.data(), b.data());
  349|  21.5k|         return Self(Rep::redc(z));
  350|  21.5k|      }
pcurves_sm2p256v1.cpp:_ZN5BotanmiERKNS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  281|  7.74k|      friend constexpr BOTAN_FORCE_INLINE Self operator-(const Self& a, const Self& b) {
  282|  7.74k|         std::array<W, N> r;  // NOLINT(*-member-init)
  283|  7.74k|         W carry = 0;
  284|  38.7k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (284:28): [True: 30.9k, False: 7.74k]
  ------------------
  285|  30.9k|            r[i] = word_sub(a.m_val[i], b.m_val[i], &carry);
  286|  30.9k|         }
  287|       |
  288|  7.74k|         const auto mask = CT::Mask<W>::expand(carry).value();
  289|       |
  290|  7.74k|         carry = 0;
  291|       |
  292|  38.7k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (292:28): [True: 30.9k, False: 7.74k]
  ------------------
  293|  30.9k|            r[i] = word_add(r[i], P[i] & mask, &carry);
  294|  30.9k|         }
  295|       |
  296|  7.74k|         return Self(r);
  297|  7.74k|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1xEv:
 1162|  7.00k|      constexpr const FieldElement& x() const { return m_x; }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul3Ev:
  335|    833|      constexpr inline Self mul3() const { return mul2() + (*this); }
pcurves_sm2p256v1.cpp:_ZN5BotanplERKNS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEESC_:
  265|  2.58k|      friend constexpr BOTAN_FORCE_INLINE Self operator+(const Self& a, const Self& b) {
  266|  2.58k|         std::array<W, N> t;  // NOLINT(*-member-init)
  267|       |
  268|  2.58k|         W carry = 0;
  269|  12.9k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (269:28): [True: 10.3k, False: 2.58k]
  ------------------
  270|  10.3k|            t[i] = word_add(a.m_val[i], b.m_val[i], &carry);
  271|  10.3k|         }
  272|       |
  273|  2.58k|         std::array<W, N> r;  // NOLINT(*-member-init)
  274|  2.58k|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  275|  2.58k|         return Self(r);
  276|  2.58k|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E1yEv:
 1167|  6.17k|      constexpr const FieldElement& y() const { return m_y; }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul4Ev:
  338|    833|      constexpr inline Self mul4() const { return mul2().mul2(); }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul2Ev:
  325|  6.66k|      constexpr BOTAN_FORCE_INLINE Self mul2() const {
  326|  6.66k|         std::array<W, N> t = value();
  327|  6.66k|         const W carry = shift_left<1>(t);
  328|       |
  329|  6.66k|         std::array<W, N> r;  // NOLINT(*-member-init)
  330|  6.66k|         bigint_monty_maybe_sub<N>(r.data(), carry, t.data(), P.data());
  331|  6.66k|         return Self(r);
  332|  6.66k|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE5valueEv:
  894|  6.66k|      constexpr const std::array<W, N>& value() const { return m_val; }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE4mul8Ev:
  341|    833|      constexpr inline Self mul8() const { return mul2().mul2().mul2(); }
pcurves_sm2p256v1.cpp:_ZN5BotanplERKNS_20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_EESE_:
 1064|    735|      friend constexpr Self operator+(const Self& a, const Self& b) { return Self::add(a, b); }
pcurves_sm2p256v1.cpp:_ZN5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E3addERKSC_SE_:
 1103|    735|      constexpr static Self add(const Self& a, const Self& b) { return point_add<Self, FieldElement>(a, b); }
pcurves_sm2p256v1.cpp:_ZNK5Botan20ProjectiveCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEES7_E11is_identityEv:
 1082|  3.03k|      constexpr CT::Choice is_identity() const { return z().is_zero(); }
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE18conditional_assignERSA_SB_SB_NS_2CT6ChoiceERKSA_SF_SF_:
  395|  1.47k|         Self& x, Self& y, Self& z, CT::Choice cond, const Self& nx, const Self& ny, const Self& nz) {
  396|  1.47k|         const W mask = cond.into_bitmask<W>();
  397|       |
  398|  7.35k|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (398:28): [True: 5.88k, False: 1.47k]
  ------------------
  399|  5.88k|            x.m_val[i] = Botan::choose(mask, nx.m_val[i], x.m_val[i]);
  400|  5.88k|            y.m_val[i] = Botan::choose(mask, ny.m_val[i], y.m_val[i]);
  401|  5.88k|            z.m_val[i] = Botan::choose(mask, nz.m_val[i], z.m_val[i]);
  402|  5.88k|         }
  403|  1.47k|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE14invert_vartimeEv:
  598|      1|      constexpr Self invert_vartime() const {
  599|       |         // Conditional ok: this function is variable time
  600|      1|         if(this->is_zero().as_bool()) {
  ------------------
  |  Branch (600:13): [True: 0, False: 1]
  ------------------
  601|      0|            return Self::zero();
  602|      0|         }
  603|       |
  604|      1|         auto x = Self(std::array<W, N>{1});  // 1 in standard domain
  605|      1|         auto b = Self(this->to_words());     // *this in standard domain
  606|       |
  607|       |         // First loop iteration
  608|      1|         Self::_invert_vartime_div2_helper(b, x);
  609|       |
  610|      1|         auto a = b.negate();
  611|       |         // y += x but y is zero at the outset
  612|      1|         auto y = x;
  613|       |
  614|       |         // First half of second loop iteration
  615|      1|         Self::_invert_vartime_div2_helper(a, y);
  616|       |
  617|    184|         for(;;) {
  618|       |            // Conditional ok: this function is variable time
  619|    184|            if(a.m_val == b.m_val) {
  ------------------
  |  Branch (619:16): [True: 1, False: 183]
  ------------------
  620|       |               // At this point it should be that a == b == 1
  621|      1|               auto r = y.negate();
  622|       |
  623|       |               // Convert back to Montgomery if required
  624|      1|               r.m_val = Rep::to_rep(r.m_val);
  625|      1|               return r;
  626|      1|            }
  627|       |
  628|    183|            auto nx = x + y;
  629|       |
  630|       |            /*
  631|       |            * Otherwise either b > a or a > b
  632|       |            *
  633|       |            * If b > a we want to set b to b - a
  634|       |            * Otherwise we want to set a to a - b
  635|       |            *
  636|       |            * Compute r = b - a and check if it underflowed
  637|       |            * If it did not then we are in the b > a path
  638|       |            */
  639|    183|            std::array<W, N> r;  // NOLINT(*-member-init)
  640|    183|            const word carry = bigint_sub3(r.data(), b.data(), N, a.data(), N);
  641|       |
  642|       |            // Conditional ok: this function is variable time
  643|    183|            if(carry == 0) {
  ------------------
  |  Branch (643:16): [True: 87, False: 96]
  ------------------
  644|       |               // b > a
  645|     87|               b.m_val = r;
  646|     87|               x = nx;
  647|     87|               Self::_invert_vartime_div2_helper(b, x);
  648|     96|            } else {
  649|       |               // We know this can't underflow because a > b
  650|     96|               bigint_sub3(r.data(), a.data(), N, b.data(), N);
  651|     96|               a.m_val = r;
  652|     96|               y = nx;
  653|     96|               Self::_invert_vartime_div2_helper(a, y);
  654|     96|            }
  655|    183|         }
  656|      1|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE8to_wordsEv:
  734|      1|      constexpr std::array<W, Self::N> to_words() const { return Rep::from_rep(m_val); }
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE27_invert_vartime_div2_helperERSA_SB_:
  547|    185|      static constexpr void _invert_vartime_div2_helper(Self& a, Self& x) {
  548|    185|         constexpr auto INV_2 = p_div_2_plus_1(Rep::P);
  549|       |
  550|       |         // Conditional ok: this function is variable time
  551|    545|         while((a.m_val[0] & 1) != 1) {
  ------------------
  |  Branch (551:16): [True: 360, False: 185]
  ------------------
  552|    360|            shift_right<1>(a.m_val);
  553|       |
  554|    360|            const W borrow = shift_right<1>(x.m_val);
  555|       |
  556|       |            // Conditional ok: this function is variable time
  557|    360|            if(borrow) {
  ------------------
  |  Branch (557:16): [True: 162, False: 198]
  ------------------
  558|    162|               bigint_add2(x.m_val.data(), N, INV_2.data(), N);
  559|    162|            }
  560|    360|         }
  561|    185|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE6negateEv:
  452|      2|      constexpr Self negate() const {
  453|      2|         const W x_is_zero = ~CT::all_zeros(this->data(), N).value();
  454|       |
  455|      2|         std::array<W, N> r;  // NOLINT(*-member-init)
  456|      2|         W carry = 0;
  457|     10|         for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (457:28): [True: 8, False: 2]
  ------------------
  458|      8|            r[i] = word_sub(P[i] & x_is_zero, m_val[i], &carry);
  459|      8|         }
  460|       |
  461|      2|         return Self(r);
  462|      2|      }
pcurves_sm2p256v1.cpp:_ZN5Botan16AffineCurvePointINS_6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS4_6ParamsES5_E11FieldParamsEEEEEEC2ERKSB_SE_:
  917|  1.56k|      constexpr AffineCurvePoint(const FieldElement& x, const FieldElement& y) : m_x(x), m_y(y) {}
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE11deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  792|      4|      static std::optional<Self> deserialize(std::span<const uint8_t> bytes) {
  793|       |         // Conditional ok: input length is public
  794|      4|         if(bytes.size() != Self::BYTES) {
  ------------------
  |  Branch (794:13): [True: 0, False: 4]
  ------------------
  795|      0|            return {};
  796|      0|         }
  797|       |
  798|      4|         const auto words = bytes_to_words<W, N, BYTES>(bytes.first<Self::BYTES>());
  799|       |
  800|       |         // Conditional acceptable: std::optional is implicitly not constant time
  801|      4|         if(!bigint_ct_is_lt(words.data(), N, P.data(), N).as_bool()) {
  ------------------
  |  Branch (801:13): [True: 0, False: 4]
  ------------------
  802|      0|            return {};
  803|      0|         }
  804|       |
  805|       |         // Safe because we checked above that words is an integer < P
  806|      4|         return Self::from_words(words);
  807|      4|      }
pcurves_sm2p256v1.cpp:_ZN5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEE10from_wordsILm4EEESA_NSt3__15arrayImXT_EEE:
  211|      4|      static constexpr Self from_words(std::array<W, L> w) {
  212|      4|         if constexpr(L == N) {
  213|      4|            return Self(Rep::to_rep(w));
  214|       |         } else {
  215|       |            static_assert(L < N);
  216|       |            std::array<W, N> ew = {};
  217|       |            copy_mem(std::span{ew}.template first<L>(), w);
  218|       |            return Self(Rep::to_rep(ew));
  219|       |         }
  220|      4|      }
pcurves_sm2p256v1.cpp:_ZNK5Botan6IntModINS_6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS3_6ParamsES4_E11FieldParamsEEEEeqERKSA_:
  722|      2|      constexpr CT::Choice operator==(const Self& other) const {
  723|      2|         return CT::is_equal(this->data(), other.data(), N).as_choice();
  724|      2|      }
pcurves_sm2p256v1.cpp:_ZN5Botan13EllipticCurveINS_6PCurve12_GLOBAL__N_19sm2p256v16ParamsENS3_12Sm2p256v1RepEE7x3_ax_bERKNS_6IntModINS5_INS6_11FieldParamsEEEEE:
 1275|      2|      static constexpr FieldElement x3_ax_b(const FieldElement& x) { return (x.square() + A) * x + B; }

pcurves_secp256k1.cpp:_ZN5Botan19basemul_booth_setupINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm6EEENSt3__16vectorINT_11AffinePointENS5_9allocatorIS8_EEEERKS8_m:
  254|      1|std::vector<typename C::AffinePoint> basemul_booth_setup(const typename C::AffinePoint& p, size_t max_scalar_bits) {
  255|      1|   static_assert(WindowBits >= 1 && WindowBits <= 8);
  256|       |
  257|       |   // 2^(W-1) elements per window [1*base .. 2^(W-1)*base]
  258|      1|   constexpr size_t WindowElements = 1 << (WindowBits - 1);
  259|       |
  260|      1|   const size_t Windows = (max_scalar_bits + WindowBits - 1) / WindowBits;
  261|       |
  262|      1|   const size_t TableSize = Windows * WindowElements;
  263|       |
  264|      1|   std::vector<typename C::ProjectivePoint> table;
  265|      1|   table.reserve(TableSize);
  266|       |
  267|      1|   auto accum = C::ProjectivePoint::from_affine(p);
  268|       |
  269|     50|   for(size_t i = 0; i != TableSize; i += WindowElements) {
  ------------------
  |  Branch (269:22): [True: 49, False: 1]
  ------------------
  270|     49|      table.push_back(accum);
  271|       |
  272|  1.56k|      for(size_t j = 1; j != WindowElements; ++j) {
  ------------------
  |  Branch (272:25): [True: 1.51k, False: 49]
  ------------------
  273|       |         // Conditional ok: loop iteration count is public
  274|  1.51k|         if(j % 2 == 1) {
  ------------------
  |  Branch (274:13): [True: 784, False: 735]
  ------------------
  275|    784|            table.emplace_back(table[i + j / 2].dbl());
  276|    784|         } else {
  277|    735|            table.emplace_back(table[i + j - 1] + table[i]);
  278|    735|         }
  279|  1.51k|      }
  280|       |
  281|       |      // Advance to next window's base: 2^W * current_base
  282|       |      // The last entry is 2^(W-1) * base, so doubling gives 2^W * base
  283|     49|      accum = table[i + WindowElements - 1].dbl();
  284|     49|   }
  285|       |
  286|       |   // Variable time batch conversion is fine since generator is public
  287|      1|   return to_affine_batch<C, true>(table);
  288|      1|}
pcurves_secp256k1.cpp:_ZN5Botan10mul2_setupINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EEENSt3__16vectorINT_15ProjectivePointENS5_9allocatorIS8_EEEERKNS7_11AffinePointESE_:
  449|  1.28k|                                                    const typename C::AffinePoint& q) {
  450|  1.28k|   static_assert(WindowBits >= 1 && WindowBits <= 4);
  451|       |
  452|       |   // 2^(2*W) elements, less the identity element
  453|  1.28k|   constexpr size_t TableSize = (1 << (2 * WindowBits)) - 1;
  454|  1.28k|   constexpr size_t WindowSize = (1 << WindowBits);
  455|       |
  456|  1.28k|   std::vector<typename C::ProjectivePoint> table;
  457|  1.28k|   table.reserve(TableSize);
  458|       |
  459|  82.3k|   for(size_t i = 0; i != TableSize; ++i) {
  ------------------
  |  Branch (459:22): [True: 81.0k, False: 1.28k]
  ------------------
  460|  81.0k|      const size_t t_i = (i + 1);
  461|  81.0k|      const size_t p_i = t_i % WindowSize;
  462|  81.0k|      const size_t q_i = (t_i >> WindowBits) % WindowSize;
  463|       |
  464|       |      // Conditionals ok: all based on t_i/p_i/q_i which in turn are derived from public i
  465|       |
  466|       |      // Returns x_i * x + y_i * y
  467|  81.0k|      auto next_tbl_e = [&]() {
  468|  81.0k|         if(p_i % 2 == 0 && q_i % 2 == 0) {
  469|       |            // Where possible using doubling (eg indices 1, 7, 9 in
  470|       |            // the table above)
  471|  81.0k|            return table[(t_i / 2) - 1].dbl();
  472|  81.0k|         } else if(p_i > 0 && q_i > 0) {
  473|       |            // A combination of p and q
  474|  81.0k|            if(p_i == 1) {
  475|  81.0k|               return p + table[(q_i << WindowBits) - 1];
  476|  81.0k|            } else if(q_i == 1) {
  477|  81.0k|               return table[p_i - 1] + q;
  478|  81.0k|            } else {
  479|  81.0k|               return table[p_i - 1] + table[(q_i << WindowBits) - 1];
  480|  81.0k|            }
  481|  81.0k|         } else if(p_i > 0 && q_i == 0) {
  482|       |            // A multiple of p without a q component
  483|  81.0k|            if(p_i == 1) {
  484|       |               // Just p
  485|  81.0k|               return C::ProjectivePoint::from_affine(p);
  486|  81.0k|            } else {
  487|       |               // p * p_{i-1}
  488|  81.0k|               return p + table[p_i - 1 - 1];
  489|  81.0k|            }
  490|  81.0k|         } else if(p_i == 0 && q_i > 0) {
  491|  81.0k|            if(q_i == 1) {
  492|       |               // Just q
  493|  81.0k|               return C::ProjectivePoint::from_affine(q);
  494|  81.0k|            } else {
  495|       |               // q * q_{i-1}
  496|  81.0k|               return q + table[((q_i - 1) << WindowBits) - 1];
  497|  81.0k|            }
  498|  81.0k|         } else {
  499|  81.0k|            BOTAN_ASSERT_UNREACHABLE();
  500|  81.0k|         }
  501|  81.0k|      };
  502|       |
  503|  81.0k|      table.emplace_back(next_tbl_e());
  504|  81.0k|   }
  505|       |
  506|  1.28k|   return table;
  507|  1.28k|}
pcurves_secp256k1.cpp:_ZZN5Botan10mul2_setupINS_6PCurve12_GLOBAL__N_19secp256k15CurveELm3EEENSt3__16vectorINT_15ProjectivePointENS5_9allocatorIS8_EEEERKNS7_11AffinePointESE_ENKUlvE_clEv:
  467|  81.0k|      auto next_tbl_e = [&]() {
  468|  81.0k|         if(p_i % 2 == 0 && q_i % 2 == 0) {
  ------------------
  |  Branch (468:13): [True: 39.8k, False: 41.1k]
  |  Branch (468:29): [True: 19.3k, False: 20.5k]
  ------------------
  469|       |            // Where possible using doubling (eg indices 1, 7, 9 in
  470|       |            // the table above)
  471|  19.3k|            return table[(t_i / 2) - 1].dbl();
  472|  61.7k|         } else if(p_i > 0 && q_i > 0) {
  ------------------
  |  Branch (472:20): [True: 56.6k, False: 5.14k]
  |  Branch (472:31): [True: 51.4k, False: 5.14k]
  ------------------
  473|       |            // A combination of p and q
  474|  51.4k|            if(p_i == 1) {
  ------------------
  |  Branch (474:16): [True: 9.00k, False: 42.4k]
  ------------------
  475|  9.00k|               return p + table[(q_i << WindowBits) - 1];
  476|  42.4k|            } else if(q_i == 1) {
  ------------------
  |  Branch (476:23): [True: 7.72k, False: 34.7k]
  ------------------
  477|  7.72k|               return table[p_i - 1] + q;
  478|  34.7k|            } else {
  479|  34.7k|               return table[p_i - 1] + table[(q_i << WindowBits) - 1];
  480|  34.7k|            }
  481|  51.4k|         } else if(p_i > 0 && q_i == 0) {
  ------------------
  |  Branch (481:20): [True: 5.14k, False: 5.14k]
  |  Branch (481:31): [True: 5.14k, False: 0]
  ------------------
  482|       |            // A multiple of p without a q component
  483|  5.14k|            if(p_i == 1) {
  ------------------
  |  Branch (483:16): [True: 1.28k, False: 3.86k]
  ------------------
  484|       |               // Just p
  485|  1.28k|               return C::ProjectivePoint::from_affine(p);
  486|  3.86k|            } else {
  487|       |               // p * p_{i-1}
  488|  3.86k|               return p + table[p_i - 1 - 1];
  489|  3.86k|            }
  490|  5.14k|         } else if(p_i == 0 && q_i > 0) {
  ------------------
  |  Branch (490:20): [True: 5.14k, False: 0]
  |  Branch (490:32): [True: 5.14k, False: 0]
  ------------------
  491|  5.14k|            if(q_i == 1) {
  ------------------
  |  Branch (491:16): [True: 1.28k, False: 3.86k]
  ------------------
  492|       |               // Just q
  493|  1.28k|               return C::ProjectivePoint::from_affine(q);
  494|  3.86k|            } else {
  495|       |               // q * q_{i-1}
  496|  3.86k|               return q + table[((q_i - 1) << WindowBits) - 1];
  497|  3.86k|            }
  498|  5.14k|         } else {
  499|      0|            BOTAN_ASSERT_UNREACHABLE();
  ------------------
  |  |  166|      0|#define BOTAN_ASSERT_UNREACHABLE() Botan::assert_unreachable(__FILE__, __LINE__)
  ------------------
  500|      0|         }
  501|  81.0k|      };
pcurves_secp256r1.cpp:_ZN5Botan19basemul_booth_setupINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm6EEENSt3__16vectorINT_11AffinePointENS5_9allocatorIS8_EEEERKS8_m:
  254|      1|std::vector<typename C::AffinePoint> basemul_booth_setup(const typename C::AffinePoint& p, size_t max_scalar_bits) {
  255|      1|   static_assert(WindowBits >= 1 && WindowBits <= 8);
  256|       |
  257|       |   // 2^(W-1) elements per window [1*base .. 2^(W-1)*base]
  258|      1|   constexpr size_t WindowElements = 1 << (WindowBits - 1);
  259|       |
  260|      1|   const size_t Windows = (max_scalar_bits + WindowBits - 1) / WindowBits;
  261|       |
  262|      1|   const size_t TableSize = Windows * WindowElements;
  263|       |
  264|      1|   std::vector<typename C::ProjectivePoint> table;
  265|      1|   table.reserve(TableSize);
  266|       |
  267|      1|   auto accum = C::ProjectivePoint::from_affine(p);
  268|       |
  269|     50|   for(size_t i = 0; i != TableSize; i += WindowElements) {
  ------------------
  |  Branch (269:22): [True: 49, False: 1]
  ------------------
  270|     49|      table.push_back(accum);
  271|       |
  272|  1.56k|      for(size_t j = 1; j != WindowElements; ++j) {
  ------------------
  |  Branch (272:25): [True: 1.51k, False: 49]
  ------------------
  273|       |         // Conditional ok: loop iteration count is public
  274|  1.51k|         if(j % 2 == 1) {
  ------------------
  |  Branch (274:13): [True: 784, False: 735]
  ------------------
  275|    784|            table.emplace_back(table[i + j / 2].dbl());
  276|    784|         } else {
  277|    735|            table.emplace_back(table[i + j - 1] + table[i]);
  278|    735|         }
  279|  1.51k|      }
  280|       |
  281|       |      // Advance to next window's base: 2^W * current_base
  282|       |      // The last entry is 2^(W-1) * base, so doubling gives 2^W * base
  283|     49|      accum = table[i + WindowElements - 1].dbl();
  284|     49|   }
  285|       |
  286|       |   // Variable time batch conversion is fine since generator is public
  287|      1|   return to_affine_batch<C, true>(table);
  288|      1|}
pcurves_secp256r1.cpp:_ZN5Botan10mul2_setupINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EEENSt3__16vectorINT_15ProjectivePointENS5_9allocatorIS8_EEEERKNS7_11AffinePointESE_:
  449|  4.96k|                                                    const typename C::AffinePoint& q) {
  450|  4.96k|   static_assert(WindowBits >= 1 && WindowBits <= 4);
  451|       |
  452|       |   // 2^(2*W) elements, less the identity element
  453|  4.96k|   constexpr size_t TableSize = (1 << (2 * WindowBits)) - 1;
  454|  4.96k|   constexpr size_t WindowSize = (1 << WindowBits);
  455|       |
  456|  4.96k|   std::vector<typename C::ProjectivePoint> table;
  457|  4.96k|   table.reserve(TableSize);
  458|       |
  459|   317k|   for(size_t i = 0; i != TableSize; ++i) {
  ------------------
  |  Branch (459:22): [True: 312k, False: 4.96k]
  ------------------
  460|   312k|      const size_t t_i = (i + 1);
  461|   312k|      const size_t p_i = t_i % WindowSize;
  462|   312k|      const size_t q_i = (t_i >> WindowBits) % WindowSize;
  463|       |
  464|       |      // Conditionals ok: all based on t_i/p_i/q_i which in turn are derived from public i
  465|       |
  466|       |      // Returns x_i * x + y_i * y
  467|   312k|      auto next_tbl_e = [&]() {
  468|   312k|         if(p_i % 2 == 0 && q_i % 2 == 0) {
  469|       |            // Where possible using doubling (eg indices 1, 7, 9 in
  470|       |            // the table above)
  471|   312k|            return table[(t_i / 2) - 1].dbl();
  472|   312k|         } else if(p_i > 0 && q_i > 0) {
  473|       |            // A combination of p and q
  474|   312k|            if(p_i == 1) {
  475|   312k|               return p + table[(q_i << WindowBits) - 1];
  476|   312k|            } else if(q_i == 1) {
  477|   312k|               return table[p_i - 1] + q;
  478|   312k|            } else {
  479|   312k|               return table[p_i - 1] + table[(q_i << WindowBits) - 1];
  480|   312k|            }
  481|   312k|         } else if(p_i > 0 && q_i == 0) {
  482|       |            // A multiple of p without a q component
  483|   312k|            if(p_i == 1) {
  484|       |               // Just p
  485|   312k|               return C::ProjectivePoint::from_affine(p);
  486|   312k|            } else {
  487|       |               // p * p_{i-1}
  488|   312k|               return p + table[p_i - 1 - 1];
  489|   312k|            }
  490|   312k|         } else if(p_i == 0 && q_i > 0) {
  491|   312k|            if(q_i == 1) {
  492|       |               // Just q
  493|   312k|               return C::ProjectivePoint::from_affine(q);
  494|   312k|            } else {
  495|       |               // q * q_{i-1}
  496|   312k|               return q + table[((q_i - 1) << WindowBits) - 1];
  497|   312k|            }
  498|   312k|         } else {
  499|   312k|            BOTAN_ASSERT_UNREACHABLE();
  500|   312k|         }
  501|   312k|      };
  502|       |
  503|   312k|      table.emplace_back(next_tbl_e());
  504|   312k|   }
  505|       |
  506|  4.96k|   return table;
  507|  4.96k|}
pcurves_secp256r1.cpp:_ZZN5Botan10mul2_setupINS_6PCurve12_GLOBAL__N_19secp256r15CurveELm3EEENSt3__16vectorINT_15ProjectivePointENS5_9allocatorIS8_EEEERKNS7_11AffinePointESE_ENKUlvE_clEv:
  467|   312k|      auto next_tbl_e = [&]() {
  468|   312k|         if(p_i % 2 == 0 && q_i % 2 == 0) {
  ------------------
  |  Branch (468:13): [True: 153k, False: 158k]
  |  Branch (468:29): [True: 74.4k, False: 79.4k]
  ------------------
  469|       |            // Where possible using doubling (eg indices 1, 7, 9 in
  470|       |            // the table above)
  471|  74.4k|            return table[(t_i / 2) - 1].dbl();
  472|   238k|         } else if(p_i > 0 && q_i > 0) {
  ------------------
  |  Branch (472:20): [True: 218k, False: 19.8k]
  |  Branch (472:31): [True: 198k, False: 19.8k]
  ------------------
  473|       |            // A combination of p and q
  474|   198k|            if(p_i == 1) {
  ------------------
  |  Branch (474:16): [True: 34.7k, False: 163k]
  ------------------
  475|  34.7k|               return p + table[(q_i << WindowBits) - 1];
  476|   163k|            } else if(q_i == 1) {
  ------------------
  |  Branch (476:23): [True: 29.7k, False: 134k]
  ------------------
  477|  29.7k|               return table[p_i - 1] + q;
  478|   134k|            } else {
  479|   134k|               return table[p_i - 1] + table[(q_i << WindowBits) - 1];
  480|   134k|            }
  481|   198k|         } else if(p_i > 0 && q_i == 0) {
  ------------------
  |  Branch (481:20): [True: 19.8k, False: 19.8k]
  |  Branch (481:31): [True: 19.8k, False: 0]
  ------------------
  482|       |            // A multiple of p without a q component
  483|  19.8k|            if(p_i == 1) {
  ------------------
  |  Branch (483:16): [True: 4.96k, False: 14.8k]
  ------------------
  484|       |               // Just p
  485|  4.96k|               return C::ProjectivePoint::from_affine(p);
  486|  14.8k|            } else {
  487|       |               // p * p_{i-1}
  488|  14.8k|               return p + table[p_i - 1 - 1];
  489|  14.8k|            }
  490|  19.8k|         } else if(p_i == 0 && q_i > 0) {
  ------------------
  |  Branch (490:20): [True: 19.8k, False: 0]
  |  Branch (490:32): [True: 19.8k, False: 0]
  ------------------
  491|  19.8k|            if(q_i == 1) {
  ------------------
  |  Branch (491:16): [True: 4.96k, False: 14.8k]
  ------------------
  492|       |               // Just q
  493|  4.96k|               return C::ProjectivePoint::from_affine(q);
  494|  14.8k|            } else {
  495|       |               // q * q_{i-1}
  496|  14.8k|               return q + table[((q_i - 1) << WindowBits) - 1];
  497|  14.8k|            }
  498|  19.8k|         } else {
  499|      0|            BOTAN_ASSERT_UNREACHABLE();
  ------------------
  |  |  166|      0|#define BOTAN_ASSERT_UNREACHABLE() Botan::assert_unreachable(__FILE__, __LINE__)
  ------------------
  500|      0|         }
  501|   312k|      };
pcurves_sm2p256v1.cpp:_ZN5Botan19basemul_booth_setupINS_6PCurve12_GLOBAL__N_19sm2p256v15CurveELm6EEENSt3__16vectorINT_11AffinePointENS5_9allocatorIS8_EEEERKS8_m:
  254|      1|std::vector<typename C::AffinePoint> basemul_booth_setup(const typename C::AffinePoint& p, size_t max_scalar_bits) {
  255|      1|   static_assert(WindowBits >= 1 && WindowBits <= 8);
  256|       |
  257|       |   // 2^(W-1) elements per window [1*base .. 2^(W-1)*base]
  258|      1|   constexpr size_t WindowElements = 1 << (WindowBits - 1);
  259|       |
  260|      1|   const size_t Windows = (max_scalar_bits + WindowBits - 1) / WindowBits;
  261|       |
  262|      1|   const size_t TableSize = Windows * WindowElements;
  263|       |
  264|      1|   std::vector<typename C::ProjectivePoint> table;
  265|      1|   table.reserve(TableSize);
  266|       |
  267|      1|   auto accum = C::ProjectivePoint::from_affine(p);
  268|       |
  269|     50|   for(size_t i = 0; i != TableSize; i += WindowElements) {
  ------------------
  |  Branch (269:22): [True: 49, False: 1]
  ------------------
  270|     49|      table.push_back(accum);
  271|       |
  272|  1.56k|      for(size_t j = 1; j != WindowElements; ++j) {
  ------------------
  |  Branch (272:25): [True: 1.51k, False: 49]
  ------------------
  273|       |         // Conditional ok: loop iteration count is public
  274|  1.51k|         if(j % 2 == 1) {
  ------------------
  |  Branch (274:13): [True: 784, False: 735]
  ------------------
  275|    784|            table.emplace_back(table[i + j / 2].dbl());
  276|    784|         } else {
  277|    735|            table.emplace_back(table[i + j - 1] + table[i]);
  278|    735|         }
  279|  1.51k|      }
  280|       |
  281|       |      // Advance to next window's base: 2^W * current_base
  282|       |      // The last entry is 2^(W-1) * base, so doubling gives 2^W * base
  283|     49|      accum = table[i + WindowElements - 1].dbl();
  284|     49|   }
  285|       |
  286|       |   // Variable time batch conversion is fine since generator is public
  287|      1|   return to_affine_batch<C, true>(table);
  288|      1|}

_ZN5Botan10get_uint32ITkNS_8WordTypeEmEEjPKT_m:
   33|   335M|constexpr uint32_t get_uint32(const W xw[], size_t i) {
   34|   335M|   static_assert(WordInfo<W>::bits == 32 || WordInfo<W>::bits == 64);
   35|       |
   36|       |   if constexpr(WordInfo<W>::bits == 32) {
   37|       |      return xw[i];
   38|   335M|   } else {
   39|   335M|      return static_cast<uint32_t>(xw[i / 2] >> ((i % 2) * 32));
   40|   335M|   }
   41|   335M|}
_ZN5Botan12SolinasAccumImLm4EEC2ERNSt3__15arrayImLm4EEE:
   50|  20.9M|      constexpr explicit SolinasAccum(std::array<W, N>& r) : m_r(r) {}
_ZN5Botan12SolinasAccumImLm4EE5accumEl:
   52|   167M|      constexpr void accum(int64_t v) {
   53|   167M|         BOTAN_DEBUG_ASSERT(m_idx < N32);
  ------------------
  |  |  130|   167M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|   167M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 167M]
  |  |  ------------------
  ------------------
   54|       |
   55|   167M|         m_S += v;
   56|   167M|         const uint32_t r = static_cast<uint32_t>(m_S);
   57|   167M|         m_S >>= 32;
   58|       |
   59|       |         if constexpr(WordInfo<W>::bits == 32) {
   60|       |            m_r[m_idx] = r;
   61|   167M|         } else {
   62|   167M|            m_r[m_idx / 2] |= static_cast<uint64_t>(r) << (32 * (m_idx % 2));
   63|   167M|         }
   64|       |
   65|   167M|         m_idx += 1;
   66|   167M|      }
_ZN5Botan12SolinasAccumImLm4EE11final_carryEl:
   68|  20.9M|      constexpr W final_carry(int64_t C) {
   69|  20.9M|         m_S += C;
   70|  20.9M|         BOTAN_DEBUG_ASSERT(m_S >= 0);
  ------------------
  |  |  130|  20.9M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  20.9M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 20.9M]
  |  |  ------------------
  ------------------
   71|  20.9M|         return static_cast<W>(m_S);
   72|  20.9M|      }
_ZN5Botan20solinas_correct_redcILm4ETkNS_8WordTypeEmEEvRNSt3__15arrayIT0_XT_EEERKS4_S7_:
   84|  20.9M|constexpr inline void solinas_correct_redc(std::array<W, N>& r, const std::array<W, N>& P, const std::array<W, N>& C) {
   85|  20.9M|   W borrow = 0;
   86|   104M|   for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (86:22): [True: 83.7M, False: 20.9M]
  ------------------
   87|  83.7M|      r[i] = word_sub(r[i], C[i], &borrow);
   88|  83.7M|   }
   89|       |
   90|       |   // borrow is either 0 or 1, perfect for setting up a mask without extra work
   91|  20.9M|   const W mask = CT::value_barrier<W>(0 - borrow);
   92|       |
   93|  20.9M|   W carry = 0;
   94|       |
   95|   104M|   for(size_t i = 0; i != N; ++i) {
  ------------------
  |  Branch (95:22): [True: 83.7M, False: 20.9M]
  ------------------
   96|  83.7M|      r[i] = word_add(r[i], P[i] & mask, &carry);
   97|  83.7M|   }
   98|  20.9M|}

_ZN5Botan10monty_redcITkNS_8WordTypeEmLm4EEENSt3__15arrayIT_XT0_EEERKNS2_IS3_XmlLi2ET0_EEERKS4_S3_:
  110|  68.0k|   -> std::array<W, N> {
  111|  68.0k|   static_assert(N >= 1);
  112|       |
  113|  68.0k|   std::array<W, N> ws;  // NOLINT(*-member-init)
  114|  68.0k|   std::array<W, N> r;   // NOLINT(*-member-init)
  115|       |
  116|       |   // Conditional ok: the parameter size is public
  117|  68.0k|   if(!std::is_constant_evaluated()) {
  ------------------
  |  Branch (117:7): [True: 68.0k, Folded]
  ------------------
  118|       |      // This range ensures we cover fields of 256, 384 and 512 bits for both 32 and 64 bit words
  119|  68.0k|      if constexpr(N == 4) {
  120|  68.0k|         bigint_monty_redc_4(r.data(), z.data(), p.data(), p_dash, ws.data());
  121|  68.0k|         return r;
  122|       |      } else if constexpr(N == 6) {
  123|       |         bigint_monty_redc_6(r.data(), z.data(), p.data(), p_dash, ws.data());
  124|       |         return r;
  125|       |      } else if constexpr(N == 8) {
  126|       |         bigint_monty_redc_8(r.data(), z.data(), p.data(), p_dash, ws.data());
  127|       |         return r;
  128|       |      } else if constexpr(N == 12) {
  129|       |         bigint_monty_redc_12(r.data(), z.data(), p.data(), p_dash, ws.data());
  130|       |         return r;
  131|       |      } else if constexpr(N == 16) {
  132|       |         bigint_monty_redc_16(r.data(), z.data(), p.data(), p_dash, ws.data());
  133|       |         return r;
  134|       |      }
  135|  68.0k|   }
  136|       |
  137|      0|   word3<W> accum;
  138|       |
  139|  68.0k|   accum.add(z[0]);
  140|       |
  141|  68.0k|   ws[0] = accum.monty_step(p[0], p_dash);
  142|       |
  143|  68.0k|   for(size_t i = 1; i != N; ++i) {
  ------------------
  |  Branch (143:22): [True: 0, False: 68.0k]
  ------------------
  144|      0|      for(size_t j = 0; j < i; ++j) {
  ------------------
  |  Branch (144:25): [True: 0, False: 0]
  ------------------
  145|      0|         accum.mul(ws[j], p[i - j]);
  146|      0|      }
  147|       |
  148|      0|      accum.add(z[i]);
  149|       |
  150|      0|      ws[i] = accum.monty_step(p[0], p_dash);
  151|      0|   }
  152|       |
  153|  68.0k|   for(size_t i = 0; i != N - 1; ++i) {
  ------------------
  |  Branch (153:22): [True: 0, False: 68.0k]
  ------------------
  154|      0|      for(size_t j = i + 1; j != N; ++j) {
  ------------------
  |  Branch (154:29): [True: 0, False: 0]
  ------------------
  155|      0|         accum.mul(ws[j], p[N + i - j]);
  156|      0|      }
  157|       |
  158|      0|      accum.add(z[N + i]);
  159|       |
  160|      0|      ws[i] = accum.extract();
  161|      0|   }
  162|       |
  163|  68.0k|   accum.add(z[2 * N - 1]);
  164|       |
  165|  68.0k|   ws[N - 1] = accum.extract();
  166|       |   // w1 is the final part, which is not stored in the workspace
  167|  68.0k|   const W w1 = accum.extract();
  168|       |
  169|  68.0k|   bigint_monty_maybe_sub<N>(r.data(), w1, ws.data(), p.data());
  170|       |
  171|  68.0k|   return r;
  172|  68.0k|}
_ZN5Botan14bytes_to_wordsITkNS_8WordTypeEmLm4ELm32EEEDaNSt3__14spanIKhXT1_EEE:
  287|  31.2k|inline constexpr auto bytes_to_words(std::span<const uint8_t, L> bytes) {
  288|  31.2k|   static_assert(L <= WordInfo<W>::bytes * N);
  289|       |
  290|  31.2k|   std::array<W, N> r = {};
  291|       |
  292|  31.2k|   constexpr size_t full_words = L / WordInfo<W>::bytes;
  293|  31.2k|   constexpr size_t extra_bytes = L % WordInfo<W>::bytes;
  294|       |
  295|  31.2k|   static_assert(full_words + (extra_bytes ? 1 : 0) <= N);
  296|       |
  297|   156k|   for(size_t i = 0; i != full_words; ++i) {
  ------------------
  |  Branch (297:22): [True: 125k, False: 31.2k]
  ------------------
  298|   125k|      r[i] = load_be<W>(bytes.data(), full_words - 1 - i);
  299|   125k|   }
  300|       |
  301|       |   if constexpr(extra_bytes > 0) {
  302|       |      constexpr size_t shift = extra_bytes * 8;
  303|       |      shift_left<shift>(r);
  304|       |
  305|       |      for(size_t i = 0; i != extra_bytes; ++i) {
  306|       |         const W b0 = bytes[WordInfo<W>::bytes * full_words + i];
  307|       |         r[0] |= (b0 << (8 * (extra_bytes - 1 - i)));
  308|       |      }
  309|       |   }
  310|       |
  311|  31.2k|   return r;
  312|  31.2k|}
_ZN5Botan14bytes_to_wordsITkNS_8WordTypeEmLm8ELm64EEEDaNSt3__14spanIKhXT1_EEE:
  287|  6.18k|inline constexpr auto bytes_to_words(std::span<const uint8_t, L> bytes) {
  288|  6.18k|   static_assert(L <= WordInfo<W>::bytes * N);
  289|       |
  290|  6.18k|   std::array<W, N> r = {};
  291|       |
  292|  6.18k|   constexpr size_t full_words = L / WordInfo<W>::bytes;
  293|  6.18k|   constexpr size_t extra_bytes = L % WordInfo<W>::bytes;
  294|       |
  295|  6.18k|   static_assert(full_words + (extra_bytes ? 1 : 0) <= N);
  296|       |
  297|  55.6k|   for(size_t i = 0; i != full_words; ++i) {
  ------------------
  |  Branch (297:22): [True: 49.4k, False: 6.18k]
  ------------------
  298|  49.4k|      r[i] = load_be<W>(bytes.data(), full_words - 1 - i);
  299|  49.4k|   }
  300|       |
  301|       |   if constexpr(extra_bytes > 0) {
  302|       |      constexpr size_t shift = extra_bytes * 8;
  303|       |      shift_left<shift>(r);
  304|       |
  305|       |      for(size_t i = 0; i != extra_bytes; ++i) {
  306|       |         const W b0 = bytes[WordInfo<W>::bytes * full_words + i];
  307|       |         r[0] |= (b0 << (8 * (extra_bytes - 1 - i)));
  308|       |      }
  309|       |   }
  310|       |
  311|  6.18k|   return r;
  312|  6.18k|}

pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE8instanceEv:
  344|  27.9k|      static std::shared_ptr<const PrimeOrderCurve> instance() {
  345|  27.9k|         static auto g_curve = std::make_shared<const PrimeOrderCurveImpl<C>>();
  346|  27.9k|         return g_curve;
  347|  27.9k|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEEC2Ev:
  342|      1|      PrimeOrderCurveImpl() : m_mul_by_g(C::G) {}
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE19field_element_bytesEv:
   36|  3.86k|      size_t field_element_bytes() const override { return C::FieldElement::BYTES; }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE10from_stashERKNS0_15PrimeOrderCurve6ScalarE:
  354|  12.6k|      static typename C::Scalar from_stash(const Scalar& s) {
  355|  12.6k|         if(s._curve() != instance()) {
  ------------------
  |  Branch (355:13): [True: 0, False: 12.6k]
  ------------------
  356|      0|            throw Invalid_Argument("Curve mismatch");
  357|      0|         }
  358|  12.6k|         return C::Scalar::from_stash(s._value());
  359|  12.6k|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE5stashERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS3_12Secp256k1RepEE12ScalarParamsEEEEE:
  350|  7.60k|      static Scalar stash(const typename C::Scalar& s) {
  351|  7.60k|         return Scalar::_create(instance(), s.template stash_value<StorageWords>());
  352|  7.60k|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE10from_stashERKNS0_15PrimeOrderCurve11AffinePointE:
  367|  6.43k|      static typename C::AffinePoint from_stash(const AffinePoint& pt) {
  368|  6.43k|         if(pt._curve() != instance()) {
  ------------------
  |  Branch (368:13): [True: 0, False: 6.43k]
  ------------------
  369|      0|            throw Invalid_Argument("Curve mismatch");
  370|      0|         }
  371|  6.43k|         auto x = C::FieldElement::from_stash(pt._x());
  372|  6.43k|         auto y = C::FieldElement::from_stash(pt._y());
  373|  6.43k|         return typename C::AffinePoint(x, y);
  374|  6.43k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE12mul2_setup_gERKNS0_15PrimeOrderCurve11AffinePointE:
   70|  1.28k|      std::unique_ptr<const PrecomputedMul2Table> mul2_setup_g(const AffinePoint& q) const override {
   71|  1.28k|         return std::make_unique<PrecomputedMul2TableC>(C::G, from_stash(q));
   72|  1.28k|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE21PrecomputedMul2TableCC2ERKNS_16AffineCurvePointINS_6IntModINS3_12Secp256k1RepINS_13EllipticCurveINS3_6ParamsES9_E11FieldParamsEEEEEEESI_:
   64|  1.28k|                  m_table(x, y) {}
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE21PrecomputedMul2TableC5tableEv:
   61|  1.26k|            const auto& table() const { return m_table; }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE27mul2_vartime_x_mod_order_eqERKNS0_15PrimeOrderCurve20PrecomputedMul2TableERKNS6_6ScalarESC_SC_:
  107|  1.26k|                                       const Scalar& y) const override {
  108|  1.26k|         try {
  109|  1.26k|            const auto& table = dynamic_cast<const PrecomputedMul2TableC&>(tableb);
  110|  1.26k|            const auto pt = table.table().mul2_vartime(from_stash(x), from_stash(y));
  111|       |            // Variable time here, so the early return is fine
  112|  1.26k|            if(pt.is_identity().as_bool()) {
  ------------------
  |  Branch (112:16): [True: 0, False: 1.26k]
  ------------------
  113|      0|               return false;
  114|      0|            }
  115|       |
  116|       |            /*
  117|       |            * Avoid the inversion by instead projecting v.
  118|       |            *
  119|       |            * Given (x*z2) and v we want to know if x % n == v
  120|       |            *
  121|       |            * Inverting z2 to extract x is expensive. Instead compute (v*z2) and
  122|       |            * compare it with (x*z2).
  123|       |            *
  124|       |            * With overwhelming probability, this conversion is correct. The
  125|       |            * only time it is not is in the extremely unlikely case where the
  126|       |            * signer actually reduced the x coordinate modulo the group order.
  127|       |            * That is handled separately in a second step.
  128|       |            */
  129|  1.26k|            const auto z2 = pt.z().square();
  130|       |
  131|  1.26k|            std::array<uint8_t, C::Scalar::BYTES> v_bytes{};
  132|  1.26k|            from_stash(v).serialize_to(v_bytes);
  133|       |
  134|  1.26k|            if(const auto fe_v = C::FieldElement::deserialize(v_bytes)) {
  ------------------
  |  Branch (134:27): [True: 1.26k, False: 0]
  ------------------
  135|  1.26k|               if((*fe_v * z2 == pt.x()).as_bool()) {
  ------------------
  |  Branch (135:19): [True: 68, False: 1.19k]
  ------------------
  136|     68|                  return true;
  137|     68|               }
  138|       |
  139|       |               /*
  140|       |               * Possibly (if cryptographically unlikely) the signer
  141|       |               * reduced the value modulo the group order.
  142|       |               *
  143|       |               * If so we must check v + n similarly as before. However here
  144|       |               * we must be careful to not overflow since otherwise that
  145|       |               * would lead to us accepting an incorrect signature.
  146|       |               *
  147|       |               * If the order is > p then the reduction modulo p would not have
  148|       |               * had any effect and we don't need to consider the possibility
  149|       |               */
  150|  1.19k|               if constexpr(C::OrderIsLessThanField) {
  151|       |                  /*
  152|       |                  * We have to be careful to avoid overflow since this would
  153|       |                  * lead to a forgery
  154|       |                  *
  155|       |                  * v < (p)-n => v + n < p
  156|       |                  *
  157|       |                  * The values n and neg_n could be precomputed but they are
  158|       |                  * fast to compute and this codepath will ~never be taken
  159|       |                  * unless when verifying an invalid signature. In any case
  160|       |                  * it is many times cheaper than performing the modular inversion
  161|       |                  * which this approach avoids.
  162|       |                  */
  163|       |
  164|       |                  // Create the group order as a field element, safe because n < p
  165|  1.19k|                  const auto n = C::FieldElement::from_words(C::NW);
  166|  1.19k|                  const auto neg_n = n.negate().to_words();
  167|       |
  168|  1.19k|                  const auto vw = fe_v->to_words();
  169|  1.19k|                  if(bigint_ct_is_lt(vw.data(), vw.size(), neg_n.data(), neg_n.size()).as_bool()) {
  ------------------
  |  Branch (169:22): [True: 66, False: 1.13k]
  ------------------
  170|     66|                     return (((*fe_v + n) * z2) == pt.x()).as_bool();
  171|     66|                  }
  172|  1.19k|               }
  173|  1.19k|            }
  174|       |
  175|  1.19k|            return false;
  176|  1.26k|         } catch(std::bad_cast&) {
  177|      0|            throw Invalid_Argument("Curve mismatch");
  178|      0|         }
  179|  1.26k|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE5stashERKNS_16AffineCurvePointINS_6IntModINS3_12Secp256k1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEE:
  361|  1.28k|      static AffinePoint stash(const typename C::AffinePoint& pt) {
  362|  1.28k|         auto x_w = pt.x().template stash_value<StorageWords>();
  363|  1.28k|         auto y_w = pt.y().template stash_value<StorageWords>();
  364|  1.28k|         return AffinePoint::_create(instance(), x_w, y_w);
  365|  1.28k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE30deserialize_point_uncompressedENSt3__14spanIKhLm18446744073709551615EEE:
  244|  1.30k|      std::optional<AffinePoint> deserialize_point_uncompressed(std::span<const uint8_t> bytes) const override {
  245|  1.30k|         constexpr size_t FieldElementBytes = C::FieldElement::BYTES;
  246|  1.30k|         constexpr size_t UncompressedBytes = 2 * C::FieldElement::BYTES + 1;
  247|       |
  248|  1.30k|         if(bytes.size() == UncompressedBytes && bytes[0] == 0x04) {
  ------------------
  |  Branch (248:13): [True: 1.30k, False: 0]
  |  Branch (248:50): [True: 1.30k, False: 0]
  ------------------
  249|  1.30k|            const auto encoded_point = bytes.subspan(1);
  250|  1.30k|            auto x = C::FieldElement::deserialize(encoded_point.first(FieldElementBytes));
  251|  1.30k|            auto y = C::FieldElement::deserialize(encoded_point.last(FieldElementBytes));
  252|       |
  253|  1.30k|            if(x && y) {
  ------------------
  |  Branch (253:16): [True: 1.30k, False: 0]
  |  Branch (253:21): [True: 1.30k, False: 0]
  ------------------
  254|       |               // Check that y^2 = x^3 + ax + b
  255|  1.30k|               const auto lhs = (*y).square();
  256|  1.30k|               const auto rhs = C::x3_ax_b(*x);
  257|  1.30k|               const auto valid = (lhs == rhs);
  258|  1.30k|               if(valid.as_bool()) {
  ------------------
  |  Branch (258:19): [True: 1.28k, False: 18]
  ------------------
  259|  1.28k|                  return stash(typename C::AffinePoint(*x, *y));
  260|  1.28k|               }
  261|  1.30k|            }
  262|  1.30k|         }
  263|       |
  264|     18|         return {};
  265|  1.30k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE18deserialize_scalarENSt3__14spanIKhLm18446744073709551615EEE:
  224|  2.57k|      std::optional<Scalar> deserialize_scalar(std::span<const uint8_t> bytes) const override {
  225|  2.57k|         if(auto scalar = C::Scalar::deserialize(bytes)) {
  ------------------
  |  Branch (225:18): [True: 2.55k, False: 22]
  ------------------
  226|  2.55k|            if(!scalar->is_zero().as_bool()) {
  ------------------
  |  Branch (226:16): [True: 2.55k, False: 1]
  ------------------
  227|  2.55k|               return stash(*scalar);
  228|  2.55k|            }
  229|  2.55k|         }
  230|       |
  231|     23|         return {};
  232|  2.57k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE22scalar_from_wide_bytesENSt3__14spanIKhLm18446744073709551615EEE:
  234|  1.26k|      std::optional<Scalar> scalar_from_wide_bytes(std::span<const uint8_t> bytes) const override {
  235|  1.26k|         if(auto s = C::Scalar::from_wide_bytes_varlen(bytes)) {
  ------------------
  |  Branch (235:18): [True: 1.26k, False: 0]
  ------------------
  236|  1.26k|            return stash(*s);
  237|  1.26k|         } else {
  238|      0|            return {};
  239|      0|         }
  240|  1.26k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE24affine_point_is_identityERKNS0_15PrimeOrderCurve11AffinePointE:
  210|  2.57k|      bool affine_point_is_identity(const AffinePoint& pt) const override {
  211|  2.57k|         return from_stash(pt).is_identity().as_bool();
  212|  2.57k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE15serialize_pointENSt3__14spanIhLm18446744073709551615EEERKNS0_15PrimeOrderCurve11AffinePointE:
  214|  2.57k|      void serialize_point(std::span<uint8_t> bytes, const AffinePoint& pt) const override {
  215|  2.57k|         BOTAN_ARG_CHECK(bytes.size() == C::AffinePoint::BYTES, "Invalid length for serialize_point");
  ------------------
  |  |   35|  2.57k|   do {                                                          \
  |  |   36|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.57k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  216|  2.57k|         from_stash(pt).serialize_to(bytes.subspan<0, C::AffinePoint::BYTES>());
  217|  2.57k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE10scalar_mulERKNS0_15PrimeOrderCurve6ScalarES9_:
  310|  2.52k|      Scalar scalar_mul(const Scalar& a, const Scalar& b) const override {
  311|  2.52k|         return stash(from_stash(a) * from_stash(b));
  312|  2.52k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE21scalar_invert_vartimeERKNS0_15PrimeOrderCurve6ScalarE:
  325|  1.26k|      Scalar scalar_invert_vartime(const Scalar& ss) const override {
  326|  1.26k|         auto s = from_stash(ss);
  327|  1.26k|         return stash(s.invert_vartime());
  328|  1.26k|      }
pcurves_secp256k1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256k15CurveEE14scalar_is_zeroERKNS0_15PrimeOrderCurve6ScalarE:
  332|  2.52k|      bool scalar_is_zero(const Scalar& s) const override { return from_stash(s).is_zero().as_bool(); }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE8instanceEv:
  344|   108k|      static std::shared_ptr<const PrimeOrderCurve> instance() {
  345|   108k|         static auto g_curve = std::make_shared<const PrimeOrderCurveImpl<C>>();
  346|   108k|         return g_curve;
  347|   108k|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEEC2Ev:
  342|      1|      PrimeOrderCurveImpl() : m_mul_by_g(C::G) {}
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE19field_element_bytesEv:
   36|  14.8k|      size_t field_element_bytes() const override { return C::FieldElement::BYTES; }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE10from_stashERKNS0_15PrimeOrderCurve6ScalarE:
  354|  49.1k|      static typename C::Scalar from_stash(const Scalar& s) {
  355|  49.1k|         if(s._curve() != instance()) {
  ------------------
  |  Branch (355:13): [True: 0, False: 49.1k]
  ------------------
  356|      0|            throw Invalid_Argument("Curve mismatch");
  357|      0|         }
  358|  49.1k|         return C::Scalar::from_stash(s._value());
  359|  49.1k|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE5stashERKNS_6IntModINS_13MontgomeryRepINS_13EllipticCurveINS3_6ParamsENS2_12Secp256r1RepEE12ScalarParamsEEEEE:
  350|  29.5k|      static Scalar stash(const typename C::Scalar& s) {
  351|  29.5k|         return Scalar::_create(instance(), s.template stash_value<StorageWords>());
  352|  29.5k|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE10from_stashERKNS0_15PrimeOrderCurve11AffinePointE:
  367|  24.8k|      static typename C::AffinePoint from_stash(const AffinePoint& pt) {
  368|  24.8k|         if(pt._curve() != instance()) {
  ------------------
  |  Branch (368:13): [True: 0, False: 24.8k]
  ------------------
  369|      0|            throw Invalid_Argument("Curve mismatch");
  370|      0|         }
  371|  24.8k|         auto x = C::FieldElement::from_stash(pt._x());
  372|  24.8k|         auto y = C::FieldElement::from_stash(pt._y());
  373|  24.8k|         return typename C::AffinePoint(x, y);
  374|  24.8k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE12mul2_setup_gERKNS0_15PrimeOrderCurve11AffinePointE:
   70|  4.96k|      std::unique_ptr<const PrecomputedMul2Table> mul2_setup_g(const AffinePoint& q) const override {
   71|  4.96k|         return std::make_unique<PrecomputedMul2TableC>(C::G, from_stash(q));
   72|  4.96k|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE21PrecomputedMul2TableCC2ERKNS_16AffineCurvePointINS_6IntModINS2_12Secp256r1RepINS_13EllipticCurveINS3_6ParamsES9_E11FieldParamsEEEEEEESI_:
   64|  4.96k|                  m_table(x, y) {}
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE21PrecomputedMul2TableC5tableEv:
   61|  4.91k|            const auto& table() const { return m_table; }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE27mul2_vartime_x_mod_order_eqERKNS0_15PrimeOrderCurve20PrecomputedMul2TableERKNS6_6ScalarESC_SC_:
  107|  4.91k|                                       const Scalar& y) const override {
  108|  4.91k|         try {
  109|  4.91k|            const auto& table = dynamic_cast<const PrecomputedMul2TableC&>(tableb);
  110|  4.91k|            const auto pt = table.table().mul2_vartime(from_stash(x), from_stash(y));
  111|       |            // Variable time here, so the early return is fine
  112|  4.91k|            if(pt.is_identity().as_bool()) {
  ------------------
  |  Branch (112:16): [True: 0, False: 4.91k]
  ------------------
  113|      0|               return false;
  114|      0|            }
  115|       |
  116|       |            /*
  117|       |            * Avoid the inversion by instead projecting v.
  118|       |            *
  119|       |            * Given (x*z2) and v we want to know if x % n == v
  120|       |            *
  121|       |            * Inverting z2 to extract x is expensive. Instead compute (v*z2) and
  122|       |            * compare it with (x*z2).
  123|       |            *
  124|       |            * With overwhelming probability, this conversion is correct. The
  125|       |            * only time it is not is in the extremely unlikely case where the
  126|       |            * signer actually reduced the x coordinate modulo the group order.
  127|       |            * That is handled separately in a second step.
  128|       |            */
  129|  4.91k|            const auto z2 = pt.z().square();
  130|       |
  131|  4.91k|            std::array<uint8_t, C::Scalar::BYTES> v_bytes{};
  132|  4.91k|            from_stash(v).serialize_to(v_bytes);
  133|       |
  134|  4.91k|            if(const auto fe_v = C::FieldElement::deserialize(v_bytes)) {
  ------------------
  |  Branch (134:27): [True: 4.91k, False: 0]
  ------------------
  135|  4.91k|               if((*fe_v * z2 == pt.x()).as_bool()) {
  ------------------
  |  Branch (135:19): [True: 0, False: 4.91k]
  ------------------
  136|      0|                  return true;
  137|      0|               }
  138|       |
  139|       |               /*
  140|       |               * Possibly (if cryptographically unlikely) the signer
  141|       |               * reduced the value modulo the group order.
  142|       |               *
  143|       |               * If so we must check v + n similarly as before. However here
  144|       |               * we must be careful to not overflow since otherwise that
  145|       |               * would lead to us accepting an incorrect signature.
  146|       |               *
  147|       |               * If the order is > p then the reduction modulo p would not have
  148|       |               * had any effect and we don't need to consider the possibility
  149|       |               */
  150|  4.91k|               if constexpr(C::OrderIsLessThanField) {
  151|       |                  /*
  152|       |                  * We have to be careful to avoid overflow since this would
  153|       |                  * lead to a forgery
  154|       |                  *
  155|       |                  * v < (p)-n => v + n < p
  156|       |                  *
  157|       |                  * The values n and neg_n could be precomputed but they are
  158|       |                  * fast to compute and this codepath will ~never be taken
  159|       |                  * unless when verifying an invalid signature. In any case
  160|       |                  * it is many times cheaper than performing the modular inversion
  161|       |                  * which this approach avoids.
  162|       |                  */
  163|       |
  164|       |                  // Create the group order as a field element, safe because n < p
  165|  4.91k|                  const auto n = C::FieldElement::from_words(C::NW);
  166|  4.91k|                  const auto neg_n = n.negate().to_words();
  167|       |
  168|  4.91k|                  const auto vw = fe_v->to_words();
  169|  4.91k|                  if(bigint_ct_is_lt(vw.data(), vw.size(), neg_n.data(), neg_n.size()).as_bool()) {
  ------------------
  |  Branch (169:22): [True: 90, False: 4.82k]
  ------------------
  170|     90|                     return (((*fe_v + n) * z2) == pt.x()).as_bool();
  171|     90|                  }
  172|  4.91k|               }
  173|  4.91k|            }
  174|       |
  175|  4.91k|            return false;
  176|  4.91k|         } catch(std::bad_cast&) {
  177|      0|            throw Invalid_Argument("Curve mismatch");
  178|      0|         }
  179|  4.91k|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE5stashERKNS_16AffineCurvePointINS_6IntModINS2_12Secp256r1RepINS_13EllipticCurveINS3_6ParamsES8_E11FieldParamsEEEEEEE:
  361|  4.96k|      static AffinePoint stash(const typename C::AffinePoint& pt) {
  362|  4.96k|         auto x_w = pt.x().template stash_value<StorageWords>();
  363|  4.96k|         auto y_w = pt.y().template stash_value<StorageWords>();
  364|  4.96k|         return AffinePoint::_create(instance(), x_w, y_w);
  365|  4.96k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE30deserialize_point_uncompressedENSt3__14spanIKhLm18446744073709551615EEE:
  244|  4.98k|      std::optional<AffinePoint> deserialize_point_uncompressed(std::span<const uint8_t> bytes) const override {
  245|  4.98k|         constexpr size_t FieldElementBytes = C::FieldElement::BYTES;
  246|  4.98k|         constexpr size_t UncompressedBytes = 2 * C::FieldElement::BYTES + 1;
  247|       |
  248|  4.98k|         if(bytes.size() == UncompressedBytes && bytes[0] == 0x04) {
  ------------------
  |  Branch (248:13): [True: 4.98k, False: 0]
  |  Branch (248:50): [True: 4.98k, False: 0]
  ------------------
  249|  4.98k|            const auto encoded_point = bytes.subspan(1);
  250|  4.98k|            auto x = C::FieldElement::deserialize(encoded_point.first(FieldElementBytes));
  251|  4.98k|            auto y = C::FieldElement::deserialize(encoded_point.last(FieldElementBytes));
  252|       |
  253|  4.98k|            if(x && y) {
  ------------------
  |  Branch (253:16): [True: 4.98k, False: 0]
  |  Branch (253:21): [True: 4.98k, False: 0]
  ------------------
  254|       |               // Check that y^2 = x^3 + ax + b
  255|  4.98k|               const auto lhs = (*y).square();
  256|  4.98k|               const auto rhs = C::x3_ax_b(*x);
  257|  4.98k|               const auto valid = (lhs == rhs);
  258|  4.98k|               if(valid.as_bool()) {
  ------------------
  |  Branch (258:19): [True: 4.96k, False: 21]
  ------------------
  259|  4.96k|                  return stash(typename C::AffinePoint(*x, *y));
  260|  4.96k|               }
  261|  4.98k|            }
  262|  4.98k|         }
  263|       |
  264|     21|         return {};
  265|  4.98k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE18deserialize_scalarENSt3__14spanIKhLm18446744073709551615EEE:
  224|  9.92k|      std::optional<Scalar> deserialize_scalar(std::span<const uint8_t> bytes) const override {
  225|  9.92k|         if(auto scalar = C::Scalar::deserialize(bytes)) {
  ------------------
  |  Branch (225:18): [True: 9.87k, False: 49]
  ------------------
  226|  9.87k|            if(!scalar->is_zero().as_bool()) {
  ------------------
  |  Branch (226:16): [True: 9.87k, False: 1]
  ------------------
  227|  9.87k|               return stash(*scalar);
  228|  9.87k|            }
  229|  9.87k|         }
  230|       |
  231|     50|         return {};
  232|  9.92k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE22scalar_from_wide_bytesENSt3__14spanIKhLm18446744073709551615EEE:
  234|  4.91k|      std::optional<Scalar> scalar_from_wide_bytes(std::span<const uint8_t> bytes) const override {
  235|  4.91k|         if(auto s = C::Scalar::from_wide_bytes_varlen(bytes)) {
  ------------------
  |  Branch (235:18): [True: 4.91k, False: 0]
  ------------------
  236|  4.91k|            return stash(*s);
  237|  4.91k|         } else {
  238|      0|            return {};
  239|      0|         }
  240|  4.91k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE24affine_point_is_identityERKNS0_15PrimeOrderCurve11AffinePointE:
  210|  9.92k|      bool affine_point_is_identity(const AffinePoint& pt) const override {
  211|  9.92k|         return from_stash(pt).is_identity().as_bool();
  212|  9.92k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE15serialize_pointENSt3__14spanIhLm18446744073709551615EEERKNS0_15PrimeOrderCurve11AffinePointE:
  214|  9.92k|      void serialize_point(std::span<uint8_t> bytes, const AffinePoint& pt) const override {
  215|  9.92k|         BOTAN_ARG_CHECK(bytes.size() == C::AffinePoint::BYTES, "Invalid length for serialize_point");
  ------------------
  |  |   35|  9.92k|   do {                                                          \
  |  |   36|  9.92k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  9.92k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 9.92k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  9.92k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 9.92k]
  |  |  ------------------
  ------------------
  216|  9.92k|         from_stash(pt).serialize_to(bytes.subspan<0, C::AffinePoint::BYTES>());
  217|  9.92k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE10scalar_mulERKNS0_15PrimeOrderCurve6ScalarES9_:
  310|  9.83k|      Scalar scalar_mul(const Scalar& a, const Scalar& b) const override {
  311|  9.83k|         return stash(from_stash(a) * from_stash(b));
  312|  9.83k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE21scalar_invert_vartimeERKNS0_15PrimeOrderCurve6ScalarE:
  325|  4.91k|      Scalar scalar_invert_vartime(const Scalar& ss) const override {
  326|  4.91k|         auto s = from_stash(ss);
  327|  4.91k|         return stash(s.invert_vartime());
  328|  4.91k|      }
pcurves_secp256r1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19secp256r15CurveEE14scalar_is_zeroERKNS0_15PrimeOrderCurve6ScalarE:
  332|  9.83k|      bool scalar_is_zero(const Scalar& s) const override { return from_stash(s).is_zero().as_bool(); }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19sm2p256v15CurveEE8instanceEv:
  344|      1|      static std::shared_ptr<const PrimeOrderCurve> instance() {
  345|      1|         static auto g_curve = std::make_shared<const PrimeOrderCurveImpl<C>>();
  346|      1|         return g_curve;
  347|      1|      }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19sm2p256v15CurveEEC2Ev:
  342|      1|      PrimeOrderCurveImpl() : m_mul_by_g(C::G) {}
pcurves_sm2p256v1.cpp:_ZNK5Botan6PCurve19PrimeOrderCurveImplINS0_12_GLOBAL__N_19sm2p256v15CurveEE30deserialize_point_uncompressedENSt3__14spanIKhLm18446744073709551615EEE:
  244|      2|      std::optional<AffinePoint> deserialize_point_uncompressed(std::span<const uint8_t> bytes) const override {
  245|      2|         constexpr size_t FieldElementBytes = C::FieldElement::BYTES;
  246|      2|         constexpr size_t UncompressedBytes = 2 * C::FieldElement::BYTES + 1;
  247|       |
  248|      2|         if(bytes.size() == UncompressedBytes && bytes[0] == 0x04) {
  ------------------
  |  Branch (248:13): [True: 2, False: 0]
  |  Branch (248:50): [True: 2, False: 0]
  ------------------
  249|      2|            const auto encoded_point = bytes.subspan(1);
  250|      2|            auto x = C::FieldElement::deserialize(encoded_point.first(FieldElementBytes));
  251|      2|            auto y = C::FieldElement::deserialize(encoded_point.last(FieldElementBytes));
  252|       |
  253|      2|            if(x && y) {
  ------------------
  |  Branch (253:16): [True: 2, False: 0]
  |  Branch (253:21): [True: 2, False: 0]
  ------------------
  254|       |               // Check that y^2 = x^3 + ax + b
  255|      2|               const auto lhs = (*y).square();
  256|      2|               const auto rhs = C::x3_ax_b(*x);
  257|      2|               const auto valid = (lhs == rhs);
  258|      2|               if(valid.as_bool()) {
  ------------------
  |  Branch (258:19): [True: 0, False: 2]
  ------------------
  259|      0|                  return stash(typename C::AffinePoint(*x, *y));
  260|      0|               }
  261|      2|            }
  262|      2|         }
  263|       |
  264|      2|         return {};
  265|      2|      }

_ZN5Botan13poly_double_nEPhm:
   26|  4.86k|inline void poly_double_n(uint8_t buf[], size_t n) {
   27|  4.86k|   return poly_double_n(buf, buf, n);
   28|  4.86k|}
_ZN5Botan26poly_double_supported_sizeEm:
   22|  4.86k|inline bool poly_double_supported_size(size_t n) {
   23|  4.86k|   return (n == 8 || n == 16 || n == 24 || n == 32 || n == 64 || n == 128);
  ------------------
  |  Branch (23:12): [True: 992, False: 3.87k]
  |  Branch (23:22): [True: 3.87k, False: 0]
  |  Branch (23:33): [True: 0, False: 0]
  |  Branch (23:44): [True: 0, False: 0]
  |  Branch (23:55): [True: 0, False: 0]
  |  Branch (23:66): [True: 0, False: 0]
  ------------------
   24|  4.86k|}

_ZN5Botan15prefetch_arraysITkNSt3__117unsigned_integralEKhJLm256ELm256ELm256ELm256EEEET_DpRAT0__S3_:
   34|  5.70M|T prefetch_arrays(T (&... arr)[Ns]) noexcept {
   35|  5.70M|   return (static_cast<T>(prefetch_array_raw(sizeof(T) * Ns, arr)) & ...);
   36|  5.70M|}
_ZN5Botan15prefetch_arraysITkNSt3__117unsigned_integralEKhJLm256EEEET_DpRAT0__S3_:
   34|  10.1k|T prefetch_arrays(T (&... arr)[Ns]) noexcept {
   35|  10.1k|   return (static_cast<T>(prefetch_array_raw(sizeof(T) * Ns, arr)) & ...);
   36|  10.1k|}

_ZN5Botan15RawHashFunctionC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEm:
   28|  7.33k|      RawHashFunction(std::string_view name, size_t output_length) : m_name(name), m_output_length(output_length) {}
_ZN5Botan15RawHashFunctionC2ENSt3__110unique_ptrINS_12HashFunctionENS1_14default_deleteIS3_EEEE:
   26|  6.25k|            RawHashFunction(hash->name(), hash->output_length()) {}

_ZNK5Botan10RIPEMD_1604nameEv:
   32|     24|      std::string name() const override { return "RIPEMD-160"; }
_ZNK5Botan10RIPEMD_16013output_lengthEv:
   34|  7.39k|      size_t output_length() const override { return output_bytes; }

_ZN5Botan4rotrILm8ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   827M|{
   38|   827M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   827M|}
_ZN5Botan4rotrILm16ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   879M|{
   38|   879M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   879M|}
_ZN5Botan4rotrILm24ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   827M|{
   38|   827M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   827M|}
_ZN5Botan4rotlILm8ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  16.4M|{
   26|  16.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  16.4M|}
_ZN5Botan4rotlILm1ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  1.58G|{
   26|  1.58G|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  1.58G|}
_ZN5Botan4rotlILm1ETkNSt3__117unsigned_integralEhEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|   242k|{
   26|   242k|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|   242k|}
_ZN5Botan4rotlILm7ETkNSt3__117unsigned_integralEhEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|   121k|{
   26|   121k|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|   121k|}
_ZN5Botan8rotl_varITkNSt3__117unsigned_integralEjEET_S2_m:
   64|  9.05M|BOTAN_FORCE_INLINE constexpr T rotl_var(T input, size_t rot) {
   65|  9.05M|   return rot ? static_cast<T>((input << rot) | (input >> (sizeof(T) * 8 - rot))) : input;
  ------------------
  |  Branch (65:11): [True: 8.72M, False: 339k]
  ------------------
   66|  9.05M|}
_ZN5Botan4rotlILm2ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.7M|{
   26|  14.7M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.7M|}
_ZN5Botan4rotlILm10ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|   193M|{
   26|   193M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|   193M|}
_ZN5Botan4rotlILm18ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.7M|{
   26|  14.7M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.7M|}
_ZN5Botan4rotlILm24ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.7M|{
   26|  14.7M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.7M|}
_ZN5Botan4rotlILm13ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  16.3M|{
   26|  16.3M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  16.3M|}
_ZN5Botan4rotlILm23ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  18.9M|{
   26|  18.9M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  18.9M|}
_ZN5Botan4rotrILm1ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|  27.5M|{
   38|  27.5M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|  27.5M|}
_ZN5Botan4rotlILm9ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  40.6M|{
   26|  40.6M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  40.6M|}
_ZN5Botan4rotrILm32ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|  2.76G|{
   38|  2.76G|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|  2.76G|}
_ZN5Botan4rotrILm24ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|  2.76G|{
   38|  2.76G|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|  2.76G|}
_ZN5Botan4rotrILm16ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|  2.76G|{
   38|  2.76G|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|  2.76G|}
_ZN5Botan4rotrILm63ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|  2.76G|{
   38|  2.76G|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|  2.76G|}
_ZN5Botan4rotlILm7ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  39.7M|{
   26|  39.7M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  39.7M|}
_ZN5Botan4rotlILm12ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  36.0M|{
   26|  36.0M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  36.0M|}
_ZN5Botan4rotlILm17ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  19.7M|{
   26|  19.7M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  19.7M|}
_ZN5Botan4rotlILm22ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  15.2M|{
   26|  15.2M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  15.2M|}
_ZN5Botan4rotlILm5ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  1.90G|{
   26|  1.90G|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  1.90G|}
_ZN5Botan4rotlILm14ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  31.5M|{
   26|  31.5M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  31.5M|}
_ZN5Botan4rotlILm20ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  15.2M|{
   26|  15.2M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  15.2M|}
_ZN5Botan4rotlILm4ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  15.2M|{
   26|  15.2M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  15.2M|}
_ZN5Botan4rotlILm11ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  31.5M|{
   26|  31.5M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  31.5M|}
_ZN5Botan4rotlILm16ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  15.2M|{
   26|  15.2M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  15.2M|}
_ZN5Botan4rotlILm6ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  31.5M|{
   26|  31.5M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  31.5M|}
_ZN5Botan4rotlILm15ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  38.9M|{
   26|  38.9M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  38.9M|}
_ZN5Botan4rotlILm21ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  15.2M|{
   26|  15.2M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  15.2M|}
_ZN5Botan4rotlILm30ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  1.87G|{
   26|  1.87G|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  1.87G|}
_ZN5Botan3rhoILm6ELm11ELm25ETkNSt3__117unsigned_integralEjEET2_S2_:
   53|   412M|BOTAN_FORCE_INLINE constexpr T rho(T x) {
   54|   412M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ rotr<R3>(x);
   55|   412M|}
_ZN5Botan4rotrILm6ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm11ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm25ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan3rhoILm2ELm13ELm22ETkNSt3__117unsigned_integralEjEET2_S2_:
   53|   412M|BOTAN_FORCE_INLINE constexpr T rho(T x) {
   54|   412M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ rotr<R3>(x);
   55|   412M|}
_ZN5Botan4rotrILm2ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm13ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm22ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan5sigmaILm17ELm19ELm10ETkNSt3__117unsigned_integralEjEET2_S2_:
   45|   412M|BOTAN_FORCE_INLINE constexpr T sigma(T x) {
   46|   412M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ (x >> S);
   47|   412M|}
_ZN5Botan4rotrILm17ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm19ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan5sigmaILm7ELm18ELm3ETkNSt3__117unsigned_integralEjEET2_S2_:
   45|   412M|BOTAN_FORCE_INLINE constexpr T sigma(T x) {
   46|   412M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ (x >> S);
   47|   412M|}
_ZN5Botan4rotrILm7ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan4rotrILm18ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   412M|{
   38|   412M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   412M|}
_ZN5Botan3rhoILm14ELm18ELm41ETkNSt3__117unsigned_integralEmEET2_S2_:
   53|   737M|BOTAN_FORCE_INLINE constexpr T rho(T x) {
   54|   737M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ rotr<R3>(x);
   55|   737M|}
_ZN5Botan4rotrILm14ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm18ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm41ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan3rhoILm28ELm34ELm39ETkNSt3__117unsigned_integralEmEET2_S2_:
   53|   737M|BOTAN_FORCE_INLINE constexpr T rho(T x) {
   54|   737M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ rotr<R3>(x);
   55|   737M|}
_ZN5Botan4rotrILm28ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm34ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm39ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan5sigmaILm19ELm61ELm6ETkNSt3__117unsigned_integralEmEET2_S2_:
   45|   737M|BOTAN_FORCE_INLINE constexpr T sigma(T x) {
   46|   737M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ (x >> S);
   47|   737M|}
_ZN5Botan4rotrILm19ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm61ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan5sigmaILm1ELm8ELm7ETkNSt3__117unsigned_integralEmEET2_S2_:
   45|   737M|BOTAN_FORCE_INLINE constexpr T sigma(T x) {
   46|   737M|   return rotr<R1>(x) ^ rotr<R2>(x) ^ (x >> S);
   47|   737M|}
_ZN5Botan4rotrILm1ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotrILm8ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   37|   737M|{
   38|   737M|   return static_cast<T>((input >> ROT) | (input << (8 * sizeof(T) - ROT)));
   39|   737M|}
_ZN5Botan4rotlILm19ETkNSt3__117unsigned_integralEjEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  4.54M|{
   26|  4.54M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  4.54M|}
_ZN5Botan4rotlILm1ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  86.5M|{
   26|  86.5M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  86.5M|}
_ZN5Botan4rotlILm44ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm43ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm21ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm14ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm28ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm20ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm3ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm45ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm61ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm6ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm25ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm8ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm18ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm27ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm36ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm10ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm15ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm56ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm62ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm55ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm39ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm41ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}
_ZN5Botan4rotlILm2ETkNSt3__117unsigned_integralEmEET0_S2_QaagtT_Li0EltT_mlLi8EstS2_:
   25|  14.4M|{
   26|  14.4M|   return static_cast<T>((input << ROT) | (input >> (8 * sizeof(T) - ROT)));
   27|  14.4M|}

_ZN5Botan8round_upEmm:
   26|  49.8k|constexpr inline size_t round_up(size_t n, size_t align_to) {
   27|       |   // Arguably returning n in this case would also be sensible
   28|  49.8k|   BOTAN_ARG_CHECK(align_to != 0, "align_to must not be 0");
  ------------------
  |  |   35|  49.8k|   do {                                                          \
  |  |   36|  49.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  49.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 49.8k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  49.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 49.8k]
  |  |  ------------------
  ------------------
   29|       |
   30|  49.8k|   if(n % align_to > 0) {
  ------------------
  |  Branch (30:7): [True: 38.4k, False: 11.4k]
  ------------------
   31|  38.4k|      const size_t adj = align_to - (n % align_to);
   32|  38.4k|      BOTAN_ARG_CHECK(n + adj >= n, "Integer overflow during rounding");
  ------------------
  |  |   35|  38.4k|   do {                                                          \
  |  |   36|  38.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  38.4k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 38.4k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  38.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 38.4k]
  |  |  ------------------
  ------------------
   33|  38.4k|      n += adj;
   34|  38.4k|   }
   35|  49.8k|   return n;
   36|  49.8k|}

_ZNK5Botan9SCAN_Name9algo_nameEv:
   38|   253k|      const std::string& algo_name() const { return m_alg_name; }
_ZNK5Botan9SCAN_Name9arg_countEv:
   43|   167k|      size_t arg_count() const { return m_args.size(); }

ffi_cipher.cpp:_ZN5Botan14scoped_cleanupIZZ19botan_cipher_updateENK3$_0clEvEUlvE_EC2ES2_:
   26|   727k|      explicit scoped_cleanup(FunT cleanup) : m_cleanup(std::move(cleanup)) {}
ffi_cipher.cpp:_ZN5Botan14scoped_cleanupIZZ19botan_cipher_updateENK3$_0clEvEUlvE_ED2Ev:
   34|   727k|      ~scoped_cleanup() {
   35|   727k|         if(m_cleanup.has_value()) {
  ------------------
  |  Branch (35:13): [True: 727k, False: 0]
  ------------------
   36|   727k|            (*m_cleanup)();  // NOLINT(bugprone-exception-escape) clang-tidy bug
   37|   727k|         }
   38|   727k|      }
_ZN5Botan14scoped_cleanupIZNS_2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS6_EEEDaDpRKS6_EUlvE_EC2ESA_:
   26|   545k|      explicit scoped_cleanup(FunT cleanup) : m_cleanup(std::move(cleanup)) {}
_ZN5Botan14scoped_cleanupIZNS_2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS6_EEEDaDpRKS6_EUlvE_EC2EOSB_:
   32|   545k|      scoped_cleanup(scoped_cleanup&& other) noexcept : m_cleanup(std::move(other.m_cleanup)) { other.disengage(); }
_ZN5Botan14scoped_cleanupIZNS_2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS6_EEEDaDpRKS6_EUlvE_E9disengageEv:
   43|   545k|      void disengage() noexcept { m_cleanup.reset(); }
_ZN5Botan14scoped_cleanupIZNS_2CT13scoped_poisonIJNSt3__14spanIhLm16EEEEQaaaagtsZT_Li0Efraa10poisonableIT_Efraa12unpoisonableIS6_EEEDaDpRKS6_EUlvE_ED2Ev:
   34|  1.09M|      ~scoped_cleanup() {
   35|  1.09M|         if(m_cleanup.has_value()) {
  ------------------
  |  Branch (35:13): [True: 545k, False: 545k]
  ------------------
   36|   545k|            (*m_cleanup)();  // NOLINT(bugprone-exception-escape) clang-tidy bug
   37|   545k|         }
   38|  1.09M|      }

_ZNK5Botan5SHA_14nameEv:
   32|    337|      std::string name() const override { return "SHA-1"; }
_ZNK5Botan5SHA_113output_lengthEv:
   34|  6.43k|      size_t output_length() const override { return 20; }

_ZN5Botan6SHA1_F2F1EjRjjjS1_j:
   21|   469M|inline void F1(uint32_t A, uint32_t& B, uint32_t C, uint32_t D, uint32_t& E, uint32_t M) {
   22|   469M|   E += choose(B, C, D) + M + rotl<5>(A);
   23|   469M|   B = rotl<30>(B);
   24|   469M|}
_ZN5Botan6SHA1_F2F2EjRjjjS1_j:
   26|   469M|inline void F2(uint32_t A, uint32_t& B, uint32_t C, uint32_t D, uint32_t& E, uint32_t M) {
   27|   469M|   E += (B ^ C ^ D) + M + rotl<5>(A);
   28|   469M|   B = rotl<30>(B);
   29|   469M|}
_ZN5Botan6SHA1_F2F3EjRjjjS1_j:
   31|   469M|inline void F3(uint32_t A, uint32_t& B, uint32_t C, uint32_t D, uint32_t& E, uint32_t M) {
   32|   469M|   E += majority(B, C, D) + M + rotl<5>(A);
   33|   469M|   B = rotl<30>(B);
   34|   469M|}
_ZN5Botan6SHA1_F2F4EjRjjjS1_j:
   37|   469M|inline void F4(uint32_t A, uint32_t& B, uint32_t C, uint32_t D, uint32_t& E, uint32_t M) {
   38|   469M|   E += (B ^ C ^ D) + M + rotl<5>(A);
   39|   469M|   B = rotl<30>(B);
   40|   469M|}

_ZNK5Botan7SHA_2244nameEv:
   33|     44|      std::string name() const override { return "SHA-224"; }
_ZNK5Botan7SHA_22413output_lengthEv:
   35|  1.36k|      size_t output_length() const override { return output_bytes; }
_ZNK5Botan7SHA_2564nameEv:
   73|  5.41k|      std::string name() const override { return "SHA-256"; }
_ZNK5Botan7SHA_25613output_lengthEv:
   75|   113k|      size_t output_length() const override { return output_bytes; }
_ZNK5Botan7SHA_25615hash_block_sizeEv:
   77|  20.3k|      size_t hash_block_size() const override { return block_bytes; }
_ZN5Botan7SHA_2565clearEv:
   83|  13.5k|      void clear() override { m_md.clear(); }

_ZN5Botan9SHA2_32_FEjjjRjjjjS0_S0_jjjj:
   31|   412M|                                  uint32_t magic) {
   32|   412M|   H += magic + rho<6, 11, 25>(E) + choose(E, F, G) + M1;
   33|   412M|   D += H;
   34|   412M|   H += rho<2, 13, 22>(A) + majority(A, B, C);
   35|   412M|   M1 += sigma<17, 19, 10>(M2) + M3 + sigma<7, 18, 3>(M4);
   36|   412M|}

_ZNK5Botan7SHA_3844nameEv:
   32|     30|      std::string name() const override { return "SHA-384"; }
_ZNK5Botan7SHA_38413output_lengthEv:
   34|  3.80k|      size_t output_length() const override { return output_bytes; }
_ZNK5Botan7SHA_5124nameEv:
   72|    143|      std::string name() const override { return "SHA-512"; }
_ZNK5Botan7SHA_51213output_lengthEv:
   74|  4.60M|      size_t output_length() const override { return output_bytes; }
_ZNK5Botan7SHA_51215hash_block_sizeEv:
   76|  12.7k|      size_t hash_block_size() const override { return block_bytes; }
_ZN5Botan7SHA_5125clearEv:
   84|   173k|      void clear() override { m_md.clear(); }

_ZN5Botan9SHA2_64_FEmmmRmmmmS0_S0_mmmm:
   31|   737M|                                  uint64_t magic) {
   32|   737M|   H += magic + rho<14, 18, 41>(E) + choose(E, F, G) + M1;
   33|   737M|   D += H;
   34|   737M|   H += rho<28, 34, 39>(A) + majority(A, B, C);
   35|   737M|   M1 += sigma<19, 61, 6>(M2) + M3 + sigma<1, 8, 7>(M4);
   36|   737M|}

_ZNK5Botan5SHA_313output_lengthEv:
   31|  9.91k|      size_t output_length() const override { return m_output_length; }

_ZN5Botan22SignaturePaddingSchemeD2Ev:
   27|    348|      virtual ~SignaturePaddingScheme() = default;

_ZNK5Botan3SM34nameEv:
   32|      5|      std::string name() const override { return "SM3"; }
_ZNK5Botan3SM313output_lengthEv:
   36|    371|      size_t output_length() const override { return output_bytes; }

_ZN5Botan2R1EjRjjS0_jS0_jS0_jjj:
   31|  1.13M|               uint32_t Wj) {
   32|  1.13M|   const uint32_t A12 = rotl<12>(A);
   33|  1.13M|   const uint32_t SS1 = rotl<7>(A12 + E + TJ);
   34|  1.13M|   const uint32_t TT1 = (A ^ B ^ C) + D + (SS1 ^ A12) + (Wi ^ Wj);
   35|  1.13M|   const uint32_t TT2 = (E ^ F ^ G) + H + SS1 + Wi;
   36|       |
   37|  1.13M|   B = rotl<9>(B);
   38|  1.13M|   D = TT1;
   39|  1.13M|   F = rotl<19>(F);
   40|  1.13M|   H = P0(TT2);
   41|  1.13M|}
_ZN5Botan2P0Ej:
   17|  4.54M|inline uint32_t P0(uint32_t X) {
   18|  4.54M|   return X ^ rotl<9>(X) ^ rotl<17>(X);
   19|  4.54M|}
_ZN5Botan5SM3_EEjjjjj:
   69|  3.69M|inline uint32_t SM3_E(uint32_t W0, uint32_t W7, uint32_t W13, uint32_t W3, uint32_t W10) {
   70|  3.69M|   return P1(W0 ^ W7 ^ rotl<15>(W13)) ^ rotl<7>(W3) ^ W10;
   71|  3.69M|}
_ZN5Botan2P1Ej:
   65|  3.69M|inline uint32_t P1(uint32_t X) {
   66|  3.69M|   return X ^ rotl<15>(X) ^ rotl<23>(X);
   67|  3.69M|}
_ZN5Botan2R2EjRjjS0_jS0_jS0_jjj:
   53|  3.40M|               uint32_t Wj) {
   54|  3.40M|   const uint32_t A12 = rotl<12>(A);
   55|  3.40M|   const uint32_t SS1 = rotl<7>(A12 + E + TJ);
   56|  3.40M|   const uint32_t TT1 = majority(A, B, C) + D + (SS1 ^ A12) + (Wi ^ Wj);
   57|  3.40M|   const uint32_t TT2 = choose(E, F, G) + H + SS1 + Wi;
   58|       |
   59|  3.40M|   B = rotl<9>(B);
   60|  3.40M|   D = TT1;
   61|  3.40M|   F = rotl<19>(F);
   62|  3.40M|   H = P0(TT2);
   63|  3.40M|}

_ZNK5Botan3SM44nameEv:
   26|    366|      std::string name() const override { return "SM4"; }
_ZNK5Botan3SM410new_objectEv:
   28|    692|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<SM4>(); }

_ZN5Botan6SpongeILm25EmE11state_bytesEv:
   43|  9.53k|      constexpr static size_t state_bytes() { return sizeof(state_t); }
_ZN5Botan6SpongeILm25EmE10state_bitsEv:
   45|  9.53k|      constexpr static size_t state_bits() { return state_bytes() * 8; }
_ZNK5Botan6SpongeILm25EmE9byte_rateEv:
   49|  4.37M|      constexpr size_t byte_rate() const { return m_bit_rate / 8; }
_ZN5Botan6SpongeILm25EmEC2ENS1_6ConfigE:
   39|  9.53k|      constexpr explicit Sponge(Config config) : m_S(config.initial_state), m_S_cursor(0), m_bit_rate(config.bit_rate) {
   40|  9.53k|         BOTAN_ARG_CHECK(m_bit_rate % word_bits == 0 && m_bit_rate < words * word_bits, "Invalid sponge bit rate");
  ------------------
  |  |   35|  9.53k|   do {                                                          \
  |  |   36|  9.53k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  19.0k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 9.53k, False: 0]
  |  |  |  Branch (37:12): [True: 9.53k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  9.53k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 9.53k]
  |  |  ------------------
  ------------------
   41|  9.53k|      }
_ZN5Botan6SpongeILm25EmE5stateEv:
   55|  18.7M|      constexpr auto& state() { return m_S; }
_ZN5Botan6SpongeILm25EmE12reset_cursorEv:
   62|  8.96k|      void reset_cursor() { m_S_cursor = 0; }
_ZN5Botan6SpongeILm25EmE7_cursorEv:
   59|  4.36M|      size_t& _cursor() { return m_S_cursor; }
_ZNK5Botan6SpongeILm25EmE6cursorEv:
   57|  8.96k|      size_t cursor() const { return m_S_cursor; }

_ZN5Botan18absorb_into_spongeITkNS_6detail28SpongeLikeWithTrivialPermuteENS_18Keccak_PermutationEEEvRT_NSt3__14spanIKhLm18446744073709551615EEE:
  233|  4.36M|inline void absorb_into_sponge(detail::SpongeLikeWithTrivialPermute auto& sponge, std::span<const uint8_t> input) {
  234|  4.36M|   absorb_into_sponge(sponge, input, [&sponge] { sponge.permute(); });
  235|  4.36M|}
_ZN5Botan18absorb_into_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_18absorb_into_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIKhLm18446744073709551615EEEEUlvE_EEvS5_S9_RKT0_:
  223|  4.36M|                               const detail::PermutationFn auto& permutation_fn) {
  224|  4.36M|   using word_t = typename SpongeT::word_t;
  225|       |
  226|  4.36M|   BufferSlicer input_slicer(input);
  227|  4.36M|   process_bytes_in_sponge(sponge, input.size(), permutation_fn, [&](word_t state_word, auto bounds) {
  228|  4.36M|      return state_word ^ bounds.read_from(input_slicer);
  229|  4.36M|   });
  230|  4.36M|   BOTAN_ASSERT_NOMSG(input_slicer.empty());
  ------------------
  |  |   77|  4.36M|   do {                                                                     \
  |  |   78|  4.36M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.36M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.36M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.36M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.36M]
  |  |  ------------------
  ------------------
  231|  4.36M|}
_ZN5Botan23process_bytes_in_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_18absorb_into_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIKhLm18446744073709551615EEEEUlvE_TkNS1_10ModifierFnIS4_EEZNS_18absorb_into_spongeITkNS1_10SpongeLikeES2_TkNS1_13PermutationFnESA_EEvS5_S9_RKT0_EUlmS4_E_EEvS5_mSF_RKT1_:
  139|  4.36M|                                                const detail::ModifierFn<SpongeT> auto& modifier_fn) {
  140|  4.36M|   if(bytes_to_process == 0) {
  ------------------
  |  Branch (140:7): [True: 4.10k, False: 4.36M]
  ------------------
  141|  4.10k|      return;
  142|  4.10k|   }
  143|       |
  144|  4.36M|   constexpr auto word_bytes = SpongeT::word_bytes;
  145|  4.36M|   const auto byte_rate = sponge.byte_rate();
  146|  4.36M|   auto& S = sponge.state();
  147|  4.36M|   auto& cursor = sponge._cursor();
  148|       |
  149|       |   // If necessary, try to get aligned with the sponge state's words array
  150|  4.36M|   const auto bytes_out_of_word_alignment = static_cast<size_t>(cursor % word_bytes);
  151|  4.36M|   if(bytes_out_of_word_alignment > 0) {
  ------------------
  |  Branch (151:7): [True: 1.65M, False: 2.70M]
  ------------------
  152|  1.65M|      const auto bytes_until_word_alignment = word_bytes - bytes_out_of_word_alignment;
  153|  1.65M|      const auto bytes_from_input = std::min(bytes_to_process, bytes_until_word_alignment);
  154|  1.65M|      BOTAN_DEBUG_ASSERT(bytes_from_input < word_bytes);
  ------------------
  |  |  130|  1.65M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  1.65M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 1.65M]
  |  |  ------------------
  ------------------
  155|       |
  156|  1.65M|      S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes],
  157|  1.65M|                                           detail::PartialWordBounds<SpongeT>{
  158|  1.65M|                                              .offset = bytes_out_of_word_alignment,
  159|  1.65M|                                              .length = bytes_from_input,
  160|  1.65M|                                           });
  161|  1.65M|      cursor += bytes_from_input;
  162|  1.65M|      bytes_to_process -= bytes_from_input;
  163|       |
  164|  1.65M|      if(cursor == byte_rate) {
  ------------------
  |  Branch (164:10): [True: 142k, False: 1.51M]
  ------------------
  165|   142k|         permutation_fn();
  166|   142k|         cursor = 0;
  167|   142k|      }
  168|  1.65M|   }
  169|       |
  170|       |   // If we didn't exhaust the bytes to process for this invocation, we should
  171|       |   // be word-aligned with the sponge state now
  172|  4.36M|   BOTAN_DEBUG_ASSERT(bytes_to_process == 0 || cursor % word_bytes == 0);
  ------------------
  |  |  130|  4.36M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.36M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.36M]
  |  |  ------------------
  ------------------
  173|       |
  174|       |   // Block-wise incorporation of the input data into the sponge state until
  175|       |   // all input bytes are processed
  176|  8.44M|   while(bytes_to_process >= word_bytes) {
  ------------------
  |  Branch (176:10): [True: 4.07M, False: 4.36M]
  ------------------
  177|       |      // Process full words until we either run out of data or reach the
  178|       |      // end of the current sponge state block
  179|  10.9M|      while(bytes_to_process >= word_bytes && cursor < byte_rate) {
  ------------------
  |  Branch (179:13): [True: 7.07M, False: 3.90M]
  |  Branch (179:47): [True: 6.89M, False: 177k]
  ------------------
  180|  6.89M|         S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes], detail::FullWordBounds<SpongeT>{});
  181|  6.89M|         cursor += word_bytes;
  182|  6.89M|         bytes_to_process -= word_bytes;
  183|  6.89M|      }
  184|       |
  185|  4.07M|      if(cursor == byte_rate) {
  ------------------
  |  Branch (185:10): [True: 454k, False: 3.62M]
  ------------------
  186|   454k|         permutation_fn();
  187|   454k|         cursor = 0;
  188|   454k|      }
  189|  4.07M|   }
  190|       |
  191|       |   // Process the remaining bytes that don't fill an entire word.
  192|       |   // Therefore, leaving the sponge state in an unaligned state that won't
  193|       |   // need another permutation until the next call to process().
  194|  4.36M|   BOTAN_DEBUG_ASSERT(bytes_to_process < word_bytes && cursor < byte_rate);
  ------------------
  |  |  130|  4.36M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.36M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.36M]
  |  |  ------------------
  ------------------
  195|  4.36M|   if(bytes_to_process > 0) {
  ------------------
  |  Branch (195:7): [True: 1.65M, False: 2.71M]
  ------------------
  196|  1.65M|      S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes],
  197|  1.65M|                                           detail::PartialWordBounds<SpongeT>{
  198|  1.65M|                                              .offset = 0,
  199|  1.65M|                                              .length = bytes_to_process,
  200|  1.65M|                                           });
  201|  1.65M|      cursor += bytes_to_process;
  202|  1.65M|   }
  203|  4.36M|}
_ZZN5Botan18absorb_into_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_18absorb_into_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIKhLm18446744073709551615EEEEUlvE_EEvS5_S9_RKT0_ENKUlmS4_E_clINS1_17PartialWordBoundsIS2_EEEEDamS4_:
  227|  3.30M|   process_bytes_in_sponge(sponge, input.size(), permutation_fn, [&](word_t state_word, auto bounds) {
  228|  3.30M|      return state_word ^ bounds.read_from(input_slicer);
  229|  3.30M|   });
_ZNK5Botan6detail17PartialWordBoundsINS_18Keccak_PermutationEE9read_fromERNS_12BufferSlicerE:
   59|  3.30M|      word_t read_from(BufferSlicer& slicer) const {
   60|  3.30M|         std::array<uint8_t, word_bytes> partial_word_bytes{};
   61|  3.30M|         slicer.copy_into(std::span{partial_word_bytes}.subspan(offset, length));
   62|  3.30M|         return load_le(partial_word_bytes);
   63|  3.30M|      }
_ZZN5Botan18absorb_into_spongeITkNS_6detail28SpongeLikeWithTrivialPermuteENS_18Keccak_PermutationEEEvRT_NSt3__14spanIKhLm18446744073709551615EEEENKUlvE_clEv:
  234|   596k|   absorb_into_sponge(sponge, input, [&sponge] { sponge.permute(); });
_ZZN5Botan18absorb_into_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_18absorb_into_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIKhLm18446744073709551615EEEEUlvE_EEvS5_S9_RKT0_ENKUlmS4_E_clINS1_14FullWordBoundsIS2_EEEEDamS4_:
  227|  6.89M|   process_bytes_in_sponge(sponge, input.size(), permutation_fn, [&](word_t state_word, auto bounds) {
  228|  6.89M|      return state_word ^ bounds.read_from(input_slicer);
  229|  6.89M|   });
_ZNK5Botan6detail14FullWordBoundsINS_18Keccak_PermutationEE9read_fromERNS_12BufferSlicerE:
   97|  6.89M|      word_t read_from(BufferSlicer& slicer) const { return load_le(slicer.take<word_bytes>()); }
_ZN5Botan19squeeze_from_spongeITkNS_6detail28SpongeLikeWithTrivialPermuteENS_18Keccak_PermutationEEEvRT_NSt3__14spanIhLm18446744073709551615EEE:
  258|  4.48k|inline void squeeze_from_sponge(detail::SpongeLikeWithTrivialPermute auto& sponge, std::span<uint8_t> output) {
  259|  4.48k|   squeeze_from_sponge(sponge, output, [&sponge] { sponge.permute(); });
  260|  4.48k|}
_ZN5Botan19squeeze_from_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_19squeeze_from_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIhLm18446744073709551615EEEEUlvE_EEvS5_S8_RKT0_:
  247|  4.48k|                                const detail::PermutationFn auto& permutation_fn) {
  248|  4.48k|   using word_t = typename SpongeT::word_t;
  249|       |
  250|  4.48k|   BufferStuffer output_stuffer(output);
  251|  4.48k|   process_bytes_in_sponge(sponge, output.size(), permutation_fn, [&](word_t state_word, auto bounds) {
  252|  4.48k|      bounds.write_into(output_stuffer, state_word);
  253|  4.48k|      return state_word;
  254|  4.48k|   });
  255|  4.48k|   BOTAN_ASSERT_NOMSG(output_stuffer.full());
  ------------------
  |  |   77|  4.48k|   do {                                                                     \
  |  |   78|  4.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.48k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.48k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.48k]
  |  |  ------------------
  ------------------
  256|  4.48k|}
_ZN5Botan23process_bytes_in_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_19squeeze_from_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIhLm18446744073709551615EEEEUlvE_TkNS1_10ModifierFnIS4_EEZNS_19squeeze_from_spongeITkNS1_10SpongeLikeES2_TkNS1_13PermutationFnES9_EEvS5_S8_RKT0_EUlmS4_E_EEvS5_mSE_RKT1_:
  139|  4.48k|                                                const detail::ModifierFn<SpongeT> auto& modifier_fn) {
  140|  4.48k|   if(bytes_to_process == 0) {
  ------------------
  |  Branch (140:7): [True: 0, False: 4.48k]
  ------------------
  141|      0|      return;
  142|      0|   }
  143|       |
  144|  4.48k|   constexpr auto word_bytes = SpongeT::word_bytes;
  145|  4.48k|   const auto byte_rate = sponge.byte_rate();
  146|  4.48k|   auto& S = sponge.state();
  147|  4.48k|   auto& cursor = sponge._cursor();
  148|       |
  149|       |   // If necessary, try to get aligned with the sponge state's words array
  150|  4.48k|   const auto bytes_out_of_word_alignment = static_cast<size_t>(cursor % word_bytes);
  151|  4.48k|   if(bytes_out_of_word_alignment > 0) {
  ------------------
  |  Branch (151:7): [True: 0, False: 4.48k]
  ------------------
  152|      0|      const auto bytes_until_word_alignment = word_bytes - bytes_out_of_word_alignment;
  153|      0|      const auto bytes_from_input = std::min(bytes_to_process, bytes_until_word_alignment);
  154|      0|      BOTAN_DEBUG_ASSERT(bytes_from_input < word_bytes);
  ------------------
  |  |  130|      0|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|      0|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 0]
  |  |  ------------------
  ------------------
  155|       |
  156|      0|      S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes],
  157|      0|                                           detail::PartialWordBounds<SpongeT>{
  158|      0|                                              .offset = bytes_out_of_word_alignment,
  159|      0|                                              .length = bytes_from_input,
  160|      0|                                           });
  161|      0|      cursor += bytes_from_input;
  162|      0|      bytes_to_process -= bytes_from_input;
  163|       |
  164|      0|      if(cursor == byte_rate) {
  ------------------
  |  Branch (164:10): [True: 0, False: 0]
  ------------------
  165|      0|         permutation_fn();
  166|      0|         cursor = 0;
  167|      0|      }
  168|      0|   }
  169|       |
  170|       |   // If we didn't exhaust the bytes to process for this invocation, we should
  171|       |   // be word-aligned with the sponge state now
  172|  4.48k|   BOTAN_DEBUG_ASSERT(bytes_to_process == 0 || cursor % word_bytes == 0);
  ------------------
  |  |  130|  4.48k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.48k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.48k]
  |  |  ------------------
  ------------------
  173|       |
  174|       |   // Block-wise incorporation of the input data into the sponge state until
  175|       |   // all input bytes are processed
  176|  8.96k|   while(bytes_to_process >= word_bytes) {
  ------------------
  |  Branch (176:10): [True: 4.48k, False: 4.48k]
  ------------------
  177|       |      // Process full words until we either run out of data or reach the
  178|       |      // end of the current sponge state block
  179|  28.3k|      while(bytes_to_process >= word_bytes && cursor < byte_rate) {
  ------------------
  |  Branch (179:13): [True: 23.8k, False: 4.48k]
  |  Branch (179:47): [True: 23.8k, False: 0]
  ------------------
  180|  23.8k|         S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes], detail::FullWordBounds<SpongeT>{});
  181|  23.8k|         cursor += word_bytes;
  182|  23.8k|         bytes_to_process -= word_bytes;
  183|  23.8k|      }
  184|       |
  185|  4.48k|      if(cursor == byte_rate) {
  ------------------
  |  Branch (185:10): [True: 0, False: 4.48k]
  ------------------
  186|      0|         permutation_fn();
  187|      0|         cursor = 0;
  188|      0|      }
  189|  4.48k|   }
  190|       |
  191|       |   // Process the remaining bytes that don't fill an entire word.
  192|       |   // Therefore, leaving the sponge state in an unaligned state that won't
  193|       |   // need another permutation until the next call to process().
  194|  4.48k|   BOTAN_DEBUG_ASSERT(bytes_to_process < word_bytes && cursor < byte_rate);
  ------------------
  |  |  130|  4.48k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.48k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.48k]
  |  |  ------------------
  ------------------
  195|  4.48k|   if(bytes_to_process > 0) {
  ------------------
  |  Branch (195:7): [True: 0, False: 4.48k]
  ------------------
  196|      0|      S[cursor / word_bytes] = modifier_fn(S[cursor / word_bytes],
  197|      0|                                           detail::PartialWordBounds<SpongeT>{
  198|      0|                                              .offset = 0,
  199|      0|                                              .length = bytes_to_process,
  200|      0|                                           });
  201|      0|      cursor += bytes_to_process;
  202|      0|   }
  203|  4.48k|}
_ZZN5Botan19squeeze_from_spongeITkNS_6detail10SpongeLikeENS_18Keccak_PermutationETkNS1_13PermutationFnEZNS_19squeeze_from_spongeITkNS1_28SpongeLikeWithTrivialPermuteES2_EEvRT_NSt3__14spanIhLm18446744073709551615EEEEUlvE_EEvS5_S8_RKT0_ENKUlmS4_E_clINS1_14FullWordBoundsIS2_EEEEDamS4_:
  251|  23.8k|   process_bytes_in_sponge(sponge, output.size(), permutation_fn, [&](word_t state_word, auto bounds) {
  252|  23.8k|      bounds.write_into(output_stuffer, state_word);
  253|  23.8k|      return state_word;
  254|  23.8k|   });
_ZNK5Botan6detail14FullWordBoundsINS_18Keccak_PermutationEE10write_intoERNS_13BufferStufferEm:
   99|  23.8k|      void write_into(BufferStuffer& stuffer, word_t full_word) const { stuffer.append(store_le(full_word)); }

_ZNK5Botan7Twofish4nameEv:
   27|    187|      std::string name() const override { return "Twofish"; }
_ZNK5Botan7Twofish10new_objectEv:
   29|    776|      std::unique_ptr<BlockCipher> new_object() const override { return std::make_unique<Twofish>(); }

_ZN5Botan2CT13value_barrierITkNSt3__117unsigned_integralEjQntsr3stdE7same_asIbT_EEES3_S3_:
   43|  43.2M|constexpr inline T value_barrier(T x) {
   44|  43.2M|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (44:7): [Folded, False: 43.2M]
  ------------------
   45|      0|      return x;
   46|  43.2M|   } else {
   47|  43.2M|#if defined(BOTAN_CT_VALUE_BARRIER_USE_ASM)
   48|       |      /*
   49|       |      * We may want a "stronger" statement such as
   50|       |      *     asm volatile("" : "+r,m"(x) : : "memory);
   51|       |      * (see https://theunixzoo.co.uk/blog/2021-10-14-preventing-optimisations.html)
   52|       |      * however the current approach seems sufficient with current compilers,
   53|       |      * and is minimally damaging with regards to degrading code generation.
   54|       |      */
   55|  43.2M|      asm("" : "+r"(x) : /* no input */);  // NOLINT(*-no-assembler)
   56|  43.2M|      return x;
   57|       |#elif defined(BOTAN_CT_VALUE_BARRIER_USE_VOLATILE)
   58|       |      volatile T vx = x;
   59|       |      return vx;
   60|       |#else
   61|       |      return x;
   62|       |#endif
   63|  43.2M|   }
   64|  43.2M|}
_ZN5Botan2CT13value_barrierITkNSt3__117unsigned_integralEmQntsr3stdE7same_asIbT_EEES3_S3_:
   43|  1.14G|constexpr inline T value_barrier(T x) {
   44|  1.14G|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (44:7): [Folded, False: 1.14G]
  ------------------
   45|      0|      return x;
   46|  1.14G|   } else {
   47|  1.14G|#if defined(BOTAN_CT_VALUE_BARRIER_USE_ASM)
   48|       |      /*
   49|       |      * We may want a "stronger" statement such as
   50|       |      *     asm volatile("" : "+r,m"(x) : : "memory);
   51|       |      * (see https://theunixzoo.co.uk/blog/2021-10-14-preventing-optimisations.html)
   52|       |      * however the current approach seems sufficient with current compilers,
   53|       |      * and is minimally damaging with regards to degrading code generation.
   54|       |      */
   55|  1.14G|      asm("" : "+r"(x) : /* no input */);  // NOLINT(*-no-assembler)
   56|  1.14G|      return x;
   57|       |#elif defined(BOTAN_CT_VALUE_BARRIER_USE_VOLATILE)
   58|       |      volatile T vx = x;
   59|       |      return vx;
   60|       |#else
   61|       |      return x;
   62|       |#endif
   63|  1.14G|   }
   64|  1.14G|}
_ZN5Botan2CT13value_barrierITkNSt3__117unsigned_integralEhQntsr3stdE7same_asIbT_EEES3_S3_:
   43|   341M|constexpr inline T value_barrier(T x) {
   44|   341M|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (44:7): [Folded, False: 341M]
  ------------------
   45|      0|      return x;
   46|   341M|   } else {
   47|   341M|#if defined(BOTAN_CT_VALUE_BARRIER_USE_ASM)
   48|       |      /*
   49|       |      * We may want a "stronger" statement such as
   50|       |      *     asm volatile("" : "+r,m"(x) : : "memory);
   51|       |      * (see https://theunixzoo.co.uk/blog/2021-10-14-preventing-optimisations.html)
   52|       |      * however the current approach seems sufficient with current compilers,
   53|       |      * and is minimally damaging with regards to degrading code generation.
   54|       |      */
   55|   341M|      asm("" : "+r"(x) : /* no input */);  // NOLINT(*-no-assembler)
   56|   341M|      return x;
   57|       |#elif defined(BOTAN_CT_VALUE_BARRIER_USE_VOLATILE)
   58|       |      volatile T vx = x;
   59|       |      return vx;
   60|       |#else
   61|       |      return x;
   62|       |#endif
   63|   341M|   }
   64|   341M|}

_ZN5Botan9AEAD_Mode19set_associated_dataEPKhm:
   69|   721k|      void set_associated_data(const uint8_t ad[], size_t ad_len) { set_associated_data(std::span(ad, ad_len)); }
_ZN5Botan9AEAD_Mode19set_associated_dataENSt3__14spanIKhLm18446744073709551615EEE:
   59|   721k|      void set_associated_data(std::span<const uint8_t> ad) { set_associated_data_n(0, ad); }

_ZN5Botan21Allocator_InitializerC2Ev:
   57|      1|      Allocator_Initializer() { initialize_allocator(); }

_ZN5Botan11ASN1_ObjectC2Ev:
  146|  6.36k|      ASN1_Object() = default;
_ZN5Botan11ASN1_ObjectC2ERKS0_:
  151|  6.31k|      ASN1_Object(const ASN1_Object&) = default;
_ZN5Botan11ASN1_ObjectD2Ev:
  168|  25.2k|      virtual ~ASN1_Object() = default;
_ZNK5Botan3OIDeqERKS0_:
  510|  7.64k|      bool operator==(const OID& other) const { return m_id == other.m_id; }
_ZNK5Botan3OID5emptyEv:
  468|  12.5k|      bool empty() const { return m_id.empty(); }
_ZNK5Botan3OID9has_valueEv:
  474|  6.29k|      bool has_value() const { return !empty(); }
_ZN5BotanneERKNS_3OIDES2_:
  561|      3|inline bool operator!=(const OID& a, const OID& b) {
  562|      3|   return !(a == b);
  563|      3|}
_ZNKSt3__14hashIN5Botan3OIDEEclERKS2_:
  761|      4|      size_t operator()(const Botan::OID& oid) const noexcept { return static_cast<size_t>(oid.hash_code()); }
_ZN5Botan11ASN1_ObjectC2EOS0_:
  161|  12.6k|      ASN1_Object(ASN1_Object&&) = default;

_ZN5Botan13ignore_paramsIJPKjmEEEvDpRKT_:
  142|  15.8M|constexpr void ignore_params([[maybe_unused]] const T&... args) {}
_ZN5Botan13ignore_paramsIJPKhmEEEvDpRKT_:
  142|  4.30M|constexpr void ignore_params([[maybe_unused]] const T&... args) {}
_ZN5Botan13ignore_paramsIJNS_9SCAN_NameEEEEvDpRKT_:
  142|  16.2k|constexpr void ignore_params([[maybe_unused]] const T&... args) {}
_ZN5Botan13ignore_paramsIJNSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEEEEvDpRKT_:
  142|  47.9k|constexpr void ignore_params([[maybe_unused]] const T&... args) {}
_ZN5Botan13ignore_paramsIJPKtmEEEvDpRKT_:
  142|  1.46M|constexpr void ignore_params([[maybe_unused]] const T&... args) {}
_ZN5Botan13ignore_paramsIJPKmmEEEvDpRKT_:
  142|  4.98M|constexpr void ignore_params([[maybe_unused]] const T&... args) {}

_ZN5Botan6BigIntC2Ev:
   45|   121k|      BigInt() = default;
_ZN5Botan6BigIntD2Ev:
  185|   161k|      ~BigInt() { _const_time_unpoison(); }
_ZN5Botan6BigInt4zeroEv:
   50|  3.59k|      static BigInt zero() { return BigInt(); }
_ZN5Botan6BigIntC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   98|     18|      explicit BigInt(std::string_view str) { *this = BigInt::from_string(str); }
_ZN5Botan6BigIntC2EPKhm:
  133|    348|      BigInt(const uint8_t buf[], size_t length) { assign_from_bytes(std::span{buf, length}); }
_ZN5Botan6BigIntC2ENSt3__14spanIKhLm18446744073709551615EEE:
  139|  2.21k|      explicit BigInt(std::span<const uint8_t> bytes) { assign_from_bytes(bytes); }
_ZN5Botan6BigIntC2EOS0_:
  183|  17.9k|      BigInt(BigInt&& other) noexcept { this->swap(other); }
_ZN5Botan6BigIntaSEOS0_:
  190|  6.51k|      BigInt& operator=(BigInt&& other) noexcept {
  191|  6.51k|         if(this != &other) {
  ------------------
  |  Branch (191:13): [True: 6.51k, False: 0]
  ------------------
  192|  6.51k|            this->swap(other);
  193|  6.51k|         }
  194|       |
  195|  6.51k|         return (*this);
  196|  6.51k|      }
_ZN5Botan6BigInt4swapERS0_:
  207|  43.2k|      void swap(BigInt& other) noexcept {
  208|  43.2k|         m_data.swap(other.m_data);
  209|  43.2k|         std::swap(m_signedness, other.m_signedness);
  210|  43.2k|      }
_ZN5Botan6BigInt8swap_regERNSt3__16vectorImNS_16secure_allocatorImEEEE:
  218|  1.02k|      BOTAN_DEPRECATED("Deprecated no replacement") void swap_reg(secure_vector<word>& reg) {
  219|  1.02k|         m_data.swap(reg);
  220|       |         // sign left unchanged
  221|  1.02k|      }
_ZN5Botan6BigInt3subEPKmmNS0_4SignE:
  358|  45.2k|      BigInt& sub(const word y[], size_t y_words, Sign sign) {
  359|  45.2k|         return add(y, y_words, sign == Positive ? Negative : Positive);
  ------------------
  |  Branch (359:33): [True: 45.2k, False: 0]
  ------------------
  360|  45.2k|      }
_ZN5Botan6BigInt5clearEv:
  441|  34.0k|      void clear() {
  442|  34.0k|         m_data.set_to_zero();
  443|  34.0k|         m_signedness = Positive;
  444|  34.0k|      }
_ZNK5Botan6BigInt7is_evenEv:
  481|  4.39k|      bool is_even() const { return !get_bit(0); }
_ZNK5Botan6BigInt6is_oddEv:
  487|  2.05k|      bool is_odd() const { return get_bit(0); }
_ZNK5Botan6BigInt6signumEv:
  493|   292k|      int signum() const {
  494|   292k|         if(sig_words() == 0) {
  ------------------
  |  Branch (494:13): [True: 80, False: 292k]
  ------------------
  495|     80|            return 0;
  496|     80|         }
  497|   292k|         return (sign() == Negative) ? -1 : 1;
  ------------------
  |  Branch (497:17): [True: 0, False: 292k]
  ------------------
  498|   292k|      }
_ZNK5Botan6BigInt7is_zeroEv:
  510|  7.77k|      bool is_zero() const { return sig_words() == 0; }
_ZN5Botan6BigInt7set_bitEm:
  516|  4.05k|      void set_bit(size_t n) { conditionally_set_bit(n, true); }
_ZN5Botan6BigInt21conditionally_set_bitEmb:
  526|  4.05k|      void conditionally_set_bit(size_t n, bool set_it) {
  527|  4.05k|         const size_t which = n / (sizeof(word) * 8);
  528|  4.05k|         const word mask = static_cast<word>(set_it) << (n % (sizeof(word) * 8));
  529|  4.05k|         m_data.set_word_at(which, word_at(which) | mask);
  530|  4.05k|      }
_ZNK5Botan6BigInt7get_bitEm:
  549|  6.44k|      bool get_bit(size_t n) const { return ((word_at(n / (sizeof(word) * 8)) >> (n % (sizeof(word) * 8))) & 1) == 1; }
_ZNK5Botan6BigInt7word_atEm:
  601|   439k|      word word_at(size_t n) const { return m_data.get_word_at(n); }
_ZNK5Botan6BigInt4signEv:
  641|   435k|      Sign sign() const { return (m_signedness); }
_ZN5Botan6BigInt8set_signENS0_4SignE:
  663|  50.0k|      void set_sign(Sign sign) {
  664|  50.0k|         if(sign == Negative && is_zero()) {
  ------------------
  |  Branch (664:13): [True: 0, False: 50.0k]
  |  Branch (664:33): [True: 0, False: 0]
  ------------------
  665|      0|            sign = Positive;
  666|      0|         }
  667|       |
  668|  50.0k|         m_signedness = sign;
  669|  50.0k|      }
_ZNK5Botan6BigInt4sizeEv:
  681|   198k|      size_t size() const { return m_data.size(); }
_ZNK5Botan6BigInt9sig_wordsEv:
  687|   608k|      size_t sig_words() const { return m_data.sig_words(); }
_ZN5Botan6BigInt12mutable_dataEv:
  712|   108k|      BOTAN_DEPRECATED("Deprecated no replacement") word* mutable_data() { return m_data.mutable_data(); }
_ZNK5Botan6BigInt4dataEv:
  718|      6|      BOTAN_DEPRECATED("Deprecated no replacement") const word* data() const { return m_data.const_data(); }
_ZNK5Botan6BigInt7grow_toEm:
  738|   102k|      BOTAN_DEPRECATED("Deprecated no replacement") void grow_to(size_t n) const { m_data.grow_to(n); }
_ZN5Botan6BigInt10power_of_2Em:
  906|  1.47k|      static BigInt power_of_2(size_t n) {
  907|  1.47k|         BigInt b;
  908|  1.47k|         b.set_bit(n);
  909|  1.47k|         return b;
  910|  1.47k|      }
_ZNK5Botan6BigInt8_as_spanEv:
 1023|  11.1k|      std::span<const word> _as_span() const { return m_data.const_span(); }
_ZNK5Botan6BigInt5_dataEv:
 1033|  1.03M|      const word* _data() const { return m_data.const_data(); }
_ZN5Botan6BigInt18_assign_from_bytesENSt3__14spanIKhLm18446744073709551615EEE:
 1044|  17.9k|      void _assign_from_bytes(std::span<const uint8_t> bytes) { assign_from_bytes(bytes); }
_ZN5Botan6BigInt11_from_wordsERNSt3__16vectorImNS_16secure_allocatorImEEEE:
 1052|  7.98k|      static BigInt _from_words(secure_vector<word>& words) {
 1053|  7.98k|         BigInt bn;
 1054|  7.98k|         bn.m_data.swap(words);
 1055|  7.98k|         return bn;
 1056|  7.98k|      }
_ZN5Botan6BigInt4Data12mutable_dataEv:
 1083|   157k|            word* mutable_data() {
 1084|   157k|               invalidate_sig_words();
 1085|   157k|               return m_reg.data();
 1086|   157k|            }
_ZNK5Botan6BigInt4Data10const_dataEv:
 1088|  1.19M|            const word* const_data() const { return m_reg.data(); }
_ZNK5Botan6BigInt4Data10const_spanEv:
 1090|  11.1k|            std::span<const word> const_span() const { return std::span{m_reg}; }
_ZNK5Botan6BigInt4Data11get_word_atEm:
 1099|   439k|            word get_word_at(size_t n) const {
 1100|   439k|               if(n < m_reg.size()) {
  ------------------
  |  Branch (1100:19): [True: 435k, False: 4.13k]
  ------------------
 1101|   435k|                  return m_reg[n];
 1102|   435k|               }
 1103|  4.13k|               return 0;
 1104|   439k|            }
_ZN5Botan6BigInt4Data11set_word_atEmm:
 1106|  4.05k|            void set_word_at(size_t i, word w) {
 1107|  4.05k|               invalidate_sig_words();
 1108|  4.05k|               if(i >= m_reg.size()) {
  ------------------
  |  Branch (1108:19): [True: 4.05k, False: 0]
  ------------------
 1109|  4.05k|                  if(w == 0) {
  ------------------
  |  Branch (1109:22): [True: 0, False: 4.05k]
  ------------------
 1110|      0|                     return;
 1111|      0|                  }
 1112|  4.05k|                  grow_to(i + 1);
 1113|  4.05k|               }
 1114|  4.05k|               m_reg[i] = w;
 1115|  4.05k|            }
_ZNK5Botan6BigInt4Data7grow_toEm:
 1126|   109k|            void grow_to(size_t n) const {
 1127|   109k|               if(n > size()) {
  ------------------
  |  Branch (1127:19): [True: 59.6k, False: 49.8k]
  ------------------
 1128|  59.6k|                  if(n <= m_reg.capacity()) {
  ------------------
  |  Branch (1128:22): [True: 0, False: 59.6k]
  ------------------
 1129|      0|                     m_reg.resize(n);
 1130|  59.6k|                  } else {
 1131|  59.6k|                     m_reg.resize(n + (8 - (n % 8)));
 1132|  59.6k|                  }
 1133|  59.6k|               }
 1134|   109k|            }
_ZNK5Botan6BigInt4Data4sizeEv:
 1136|   515k|            size_t size() const { return m_reg.size(); }
_ZN5Botan6BigInt4Data4swapERS1_:
 1151|  43.2k|            void swap(Data& other) noexcept {
 1152|  43.2k|               m_reg.swap(other.m_reg);
 1153|  43.2k|               std::swap(m_sig_words, other.m_sig_words);
 1154|  43.2k|            }
_ZN5Botan6BigInt4Data4swapERNSt3__16vectorImNS_16secure_allocatorImEEEE:
 1156|  43.0k|            void swap(secure_vector<word>& reg) noexcept {
 1157|  43.0k|               m_reg.swap(reg);
 1158|  43.0k|               invalidate_sig_words();
 1159|  43.0k|            }
_ZNK5Botan6BigInt4Data20invalidate_sig_wordsEv:
 1161|   204k|            void invalidate_sig_words() const noexcept { m_sig_words = sig_words_npos; }
_ZNK5Botan6BigInt4Data9sig_wordsEv:
 1163|   608k|            size_t sig_words() const {
 1164|   608k|               if(m_sig_words == sig_words_npos) {
  ------------------
  |  Branch (1164:19): [True: 189k, False: 419k]
  ------------------
 1165|   189k|                  m_sig_words = calc_sig_words();
 1166|   189k|               }
 1167|   608k|               return m_sig_words;
 1168|   608k|            }
_ZN5BotanplERKNS_6BigIntES2_:
 1189|      6|inline BigInt operator+(const BigInt& x, const BigInt& y) {
 1190|      6|   return BigInt::add2(x, y._data(), y.sig_words(), y.sign());
 1191|      6|}
_ZN5BotanmiERKNS_6BigIntEm:
 1229|      3|inline BigInt operator-(const BigInt& x, word y) {
 1230|      3|   return BigInt::add2(x, &y, 1, BigInt::Negative);
 1231|      3|}
_ZN5BotanmlEmRKNS_6BigIntE:
 1255|  43.2k|inline BigInt operator*(word x, const BigInt& y) {
 1256|  43.2k|   return y * x;
 1257|  43.2k|}
_ZN5BotaneqERKNS_6BigIntES2_:
 1313|  1.03k|inline bool operator==(const BigInt& a, const BigInt& b) {
 1314|  1.03k|   return a.is_equal(b);
 1315|  1.03k|}
_ZN5BotanneERKNS_6BigIntES2_:
 1323|      3|inline bool operator!=(const BigInt& a, const BigInt& b) {
 1324|      3|   return !a.is_equal(b);
 1325|      3|}
_ZN5BotangeERKNS_6BigIntES2_:
 1343|  30.1k|inline bool operator>=(const BigInt& a, const BigInt& b) {
 1344|  30.1k|   return (a.cmp(b) >= 0);
 1345|  30.1k|}
_ZN5BotanltERKNS_6BigIntES2_:
 1353|  11.7k|inline bool operator<(const BigInt& a, const BigInt& b) {
 1354|  11.7k|   return a.is_less_than(b);
 1355|  11.7k|}
_ZN5BotaneqERKNS_6BigIntEm:
 1373|  2.18k|inline bool operator==(const BigInt& a, word b) {
 1374|  2.18k|   return (a.cmp_word(b) == 0);
 1375|  2.18k|}
_ZN5BotanneERKNS_6BigIntEm:
 1383|      3|inline bool operator!=(const BigInt& a, word b) {
 1384|      3|   return (a.cmp_word(b) != 0);
 1385|      3|}
_ZN5BotanleERKNS_6BigIntEm:
 1393|    348|inline bool operator<=(const BigInt& a, word b) {
 1394|    348|   return (a.cmp_word(b) <= 0);
 1395|    348|}
_ZN5BotangeERKNS_6BigIntEm:
 1403|  1.02k|inline bool operator>=(const BigInt& a, word b) {
 1404|  1.02k|   return (a.cmp_word(b) >= 0);
 1405|  1.02k|}
_ZN5BotanltERKNS_6BigIntEm:
 1413|  15.1k|inline bool operator<(const BigInt& a, word b) {
 1414|  15.1k|   return (a.cmp_word(b) < 0);
 1415|  15.1k|}
_ZN5BotangtERKNS_6BigIntEm:
 1423|  2.15k|inline bool operator>(const BigInt& a, word b) {
 1424|  2.15k|   return (a.cmp_word(b) > 0);
 1425|  2.15k|}
_ZNK5Botan6BigInt9serializeINSt3__16vectorIhNS2_9allocatorIhEEEEEET_m:
  790|    329|      T serialize(size_t len) const {
  791|       |         // TODO this supports std::vector and secure_vector
  792|       |         // it would be nice if this also could work with std::array as in
  793|       |         //   bn.serialize_to<std::array<uint8_t, 32>>(32);
  794|    329|         T out(len);
  795|    329|         this->serialize_to(out);
  796|    329|         return out;
  797|    329|      }
_ZN5Botan6BigIntC2ERKS0_:
   88|  18.8k|      BigInt(const BigInt& other) = default;
_ZNK5Botan6BigInt9serializeINSt3__16vectorIhNS2_9allocatorIhEEEEEET_v:
  803|    329|      T serialize() const {
  804|    329|         return serialize<T>(this->bytes());
  805|    329|      }
_ZN5Botan6BigIntaSERKS0_:
  201|  3.53k|      BigInt& operator=(const BigInt&) = default;

_ZNK5Botan11BlockCipher11parallelismEv:
   65|  1.14k|      virtual size_t parallelism() const { return 1; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm16ELm0ELm1ENS_11BlockCipherEE8key_specEv:
  246|  23.5k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm16ELm0ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|  3.75M|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm24ELm0ELm1ENS_11BlockCipherEE8key_specEv:
  246|  12.2k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm24ELm0ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|  3.00M|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm32ELm0ELm1ENS_11BlockCipherEE8key_specEv:
  246|  15.4k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm32ELm0ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|  4.42M|      size_t block_size() const final { return BS; }
_ZNK5Botan11BlockCipher14parallel_bytesEv:
   71|  48.6k|      size_t parallel_bytes() const { return parallelism() * block_size() * BlockCipher::ParallelismMult; }
_ZNK5Botan11BlockCipher7encryptENSt3__14spanIhLm18446744073709551615EEE:
  118|  8.93M|      void encrypt(std::span<uint8_t> block) const {
  119|  8.93M|         return encrypt_n(block.data(), block.data(), block.size() / block_size());
  120|  8.93M|      }
_ZNK5Botan11BlockCipher7encryptENSt3__14spanIKhLm18446744073709551615EEENS2_IhLm18446744073709551615EEE:
  135|  3.61k|      void encrypt(std::span<const uint8_t> in, std::span<uint8_t> out) const {
  136|  3.61k|         return encrypt_n(in.data(), out.data(), in.size() / block_size());
  137|  3.61k|      }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm1ELm72ELm1ENS_11BlockCipherEE8key_specEv:
  246|    314|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm1ELm72ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|   568k|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm11ELm16ELm1ENS_11BlockCipherEE8key_specEv:
  246|  1.11k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm11ELm16ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|   285k|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm16ELm24ELm8ENS_11BlockCipherEE8key_specEv:
  246|    619|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm16ELm24ELm8ENS_11BlockCipherEE10block_sizeEv:
  240|   528k|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm16ELm0ELm1ENS_11BlockCipherEE8key_specEv:
  246|  3.76k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm8ELm16ELm0ELm1ENS_11BlockCipherEE10block_sizeEv:
  240|   593k|      size_t block_size() const final { return BS; }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm16ELm32ELm8ENS_11BlockCipherEE8key_specEv:
  246|  4.18k|      Key_Length_Specification key_spec() const final { return Key_Length_Specification(KMIN, KMAX, KMOD); }
_ZNK5Botan25Block_Cipher_Fixed_ParamsILm16ELm16ELm32ELm8ENS_11BlockCipherEE10block_sizeEv:
  240|   547k|      size_t block_size() const final { return BS; }

_ZN5Botan20Buffered_Computation6updateEPKhm:
   35|   190M|      void update(const uint8_t in[], size_t length) { add_data({in, length}); }
_ZN5Botan20Buffered_Computation6updateENSt3__14spanIKhLm18446744073709551615EEE:
   41|  6.53M|      void update(std::span<const uint8_t> in) { add_data(in); }
_ZN5Botan20Buffered_Computation6updateEh:
   90|  11.6M|      void update(uint8_t in) { add_data({&in, 1}); }
_ZN5Botan20Buffered_Computation5finalEPh:
   97|   482k|      void final(uint8_t out[]) { final_result({out, output_length()}); }
_ZN5Botan20Buffered_Computation12final_stdvecEv:
  114|  7.33k|      std::vector<uint8_t> final_stdvec() { return final<std::vector<uint8_t>>(); }
_ZN5Botan20Buffered_Computation5finalITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS3_9allocatorIhEEEEEET_v:
  104|  7.33k|      T final() {
  105|  7.33k|         T output(output_length());
  106|  7.33k|         final_result(output);
  107|  7.33k|         return output;
  108|  7.33k|      }
_ZN5Botan20Buffered_Computation5finalITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS_16secure_allocatorIhEEEEEET_v:
  104|   968k|      T final() {
  105|   968k|         T output(output_length());
  106|   968k|         final_result(output);
  107|   968k|         return output;
  108|   968k|      }
_ZN5Botan20Buffered_ComputationD2Ev:
  169|   168k|      virtual ~Buffered_Computation() = default;
_ZN5Botan20Buffered_Computation5finalITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS_16secure_allocatorIhEEEEEEvRT_:
  127|  1.14M|      void final(T& out) {
  128|  1.14M|         out.resize(output_length());
  129|  1.14M|         final_result(out);
  130|  1.14M|      }

_ZN5Botan11Cipher_Mode5startEPKhm:
  105|   721k|      void start(const uint8_t nonce[], size_t nonce_len) { start_msg(nonce, nonce_len); }
_ZN5Botan11Cipher_Mode6finishERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  185|   720k|      void finish(secure_vector<uint8_t>& final_block, size_t offset = 0) { finish_msg(final_block, offset); }
_ZN5Botan11Cipher_Mode7processENSt3__14spanIhLm18446744073709551615EEE:
  132|  1.84M|      size_t process(std::span<uint8_t> msg) { return this->process_msg(msg.data(), msg.size()); }
_ZNK5Botan11Cipher_Mode23requires_entire_messageEv:
  239|  14.3k|      virtual bool requires_entire_message() const { return false; }
_ZN5Botan11Cipher_Mode6updateITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS_16secure_allocatorIhEEEEEEvRT_m:
  155|   163k|      void update(T& buffer, size_t offset = 0) {
  156|   163k|         const size_t written = process(std::span(buffer).subspan(offset));
  157|   163k|         buffer.resize(offset + written);
  158|   163k|      }

_ZN5Botan8CurveGFp4swapERS0_:
   82|  6.25k|      void swap(CurveGFp& other) noexcept { std::swap(m_group, other.m_group); }
_ZN5Botan8CurveGFpC2Ev:
   75|  6.25k|      CurveGFp() = default;

_ZN5Botan11DER_Encoder10add_objectENS_9ASN1_TypeENS_10ASN1_ClassENSt3__14spanIKhLm18446744073709551615EEE:
  410|      3|      DER_Encoder& add_object(ASN1_Type type_tag, ASN1_Class class_tag, std::span<const uint8_t> rep) {
  411|      3|         return add_object(type_tag, class_tag, rep.data(), rep.size());
  412|      3|      }
_ZN5Botan11DER_Encoder10add_objectENS_9ASN1_TypeENS_10ASN1_ClassERKNSt3__16vectorIhNS3_9allocatorIhEEEE:
  421|      3|      DER_Encoder& add_object(ASN1_Type type_tag, ASN1_Class class_tag, const std::vector<uint8_t>& rep) {
  422|      3|         return add_object(type_tag, class_tag, std::span{rep});
  423|      3|      }

_ZNK5Botan14EC_AffinePoint6_innerEv:
  337|  6.25k|      const EC_AffinePoint_Data& _inner() const { return inner(); }
_ZNK5Botan14EC_AffinePoint5innerEv:
  354|  25.0k|      const EC_AffinePoint_Data& inner() const { return *m_point; }

_ZN5Botan8EC_GroupC2EOS0_:
  238|  6.25k|      EC_Group(EC_Group&&) = default;
_ZNK5Botan8EC_Group5_dataEv:
  545|  24.9k|      const std::shared_ptr<EC_Group_Data>& _data() const { return m_data; }

_ZN5Botan8EC_PointaSEOS0_:
   75|  6.25k|      EC_Point& operator=(EC_Point&& other) noexcept {
   76|  6.25k|         if(this != &other) {
  ------------------
  |  Branch (76:13): [True: 6.25k, False: 0]
  ------------------
   77|  6.25k|            this->swap(other);
   78|  6.25k|         }
   79|  6.25k|         return (*this);
   80|  6.25k|      }
_ZN5Botan8EC_PointD2Ev:
   82|  12.5k|      ~EC_Point() = default;
_ZN5Botan8EC_PointC2Ev:
   49|  6.25k|      EC_Point() = default;

_ZNK5Botan9EC_Scalar10is_nonzeroEv:
  170|  12.3k|      bool is_nonzero() const { return !is_zero(); }
_ZN5BotanmlERKNS_9EC_ScalarES2_:
  241|  12.3k|      friend EC_Scalar operator*(const EC_Scalar& x, const EC_Scalar& y) { return x.mul(y); }
_ZNK5Botan9EC_Scalar6_innerEv:
  277|  18.5k|      const EC_Scalar_Data& _inner() const { return inner(); }
_ZNK5Botan9EC_Scalar5innerEv:
  291|  98.8k|      const EC_Scalar_Data& inner() const { return *m_scalar; }

_ZN5Botan12EC_PublicKeyD2Ev:
   42|  6.25k|      ~EC_PublicKey() override = default;

_ZN5Botan15ECDSA_PublicKeyC1ERKNS_8EC_GroupERKNS_14EC_AffinePointE:
   27|  6.25k|      ECDSA_PublicKey(const EC_Group& group, const EC_AffinePoint& public_key) : EC_PublicKey(group, public_key) {}

_ZN5Botan17Ed25519_PublicKeyC1ENSt3__14spanIKhLm18446744073709551615EEE:
   52|  3.08k|            Ed25519_PublicKey(pub.data(), pub.size()) {}

_ZNK5Botan9Exception4whatEv:
   94|    481|      const char* what() const noexcept override { return m_msg.c_str(); }
_ZNK5Botan16Invalid_Argument10error_typeEv:
  158|    400|      ErrorType error_type() const noexcept override { return ErrorType::InvalidArgument; }
_ZNK5Botan14Decoding_Error10error_typeEv:
  271|     81|      ErrorType error_type() const noexcept override { return ErrorType::DecodingFailure; }

_ZNK5Botan9HMAC_DRBG31max_number_of_bytes_per_requestEv:
  151|  43.2k|      size_t max_number_of_bytes_per_request() const override { return m_max_number_of_bytes_per_request; }

_ZNK5Botan3KDF3kdfEPhmPKhmS3_mS3_m:
   76|  6.79k|               size_t label_len) const {
   77|  6.79k|         derive_key({key, key_len}, {secret, secret_len}, {salt, salt_len}, {label, label_len});
   78|  6.79k|      }
_ZNK5Botan3KDF10derive_keyENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEES5_S5_:
  129|  20.3k|                      std::span<const uint8_t> label) const {
  130|  20.3k|         perform_kdf(key, secret, salt, label);
  131|  20.3k|      }
_ZN5Botan3KDFD2Ev:
   27|  20.3k|      virtual ~KDF() = default;

_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayImLm4EEETkNS1_16contiguous_rangeENS2_4spanIhLm32EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS8_IXsr21__is_primary_templateINS9_Iu14__remove_cvrefIDTclL_ZNSB_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSH_ISP_EESQ_E4type10value_typeEEEEvOSM_RKSC_:
  176|  10.2M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  10.2M|   ranges::assert_equal_byte_lengths(out, in);
  178|  10.2M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  10.2M|}
_ZN5Botan13typecast_copyINSt3__15arrayImLm4EEETkNS_6ranges16contiguous_rangeENS1_4spanIhLm32EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS7_Esr3stdE23is_trivially_copyable_vINS1_11conditionalIXsr21__is_primary_templateINS1_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS1_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS1_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEEES7_RKSC_:
  210|  10.2M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|  10.2M|   ToT dst;  // NOLINT(*-member-init)
  212|  10.2M|   typecast_copy(dst, src);
  213|  10.2M|   return dst;
  214|  10.2M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayImLm4EEETkNS1_16contiguous_rangeENS2_4spanIKhLm32EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEEEvOSN_RKSD_:
  176|  17.1M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  17.1M|   ranges::assert_equal_byte_lengths(out, in);
  178|  17.1M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  17.1M|}
_ZN5Botan13typecast_copyINSt3__15arrayImLm4EEETkNS_6ranges16contiguous_rangeENS1_4spanIKhLm32EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS8_Esr3stdE23is_trivially_copyable_vINS1_11conditionalIXsr21__is_primary_templateINS1_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS1_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS1_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEEES8_RKSD_:
  210|  17.1M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|  17.1M|   ToT dst;  // NOLINT(*-member-init)
  212|  17.1M|   typecast_copy(dst, src);
  213|  17.1M|   return dst;
  214|  17.1M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeENSt3__14spanIhLm32EEETkNS1_16contiguous_rangeENS2_5arrayImLm4EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEEEvOSL_RKSB_:
  176|  13.7M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  13.7M|   ranges::assert_equal_byte_lengths(out, in);
  178|  13.7M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  13.7M|}
_ZN5Botan7xor_bufITkNS_6ranges23contiguous_output_rangeIhEENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeIhEENS4_IKhLm18446744073709551615EEEEEvOT_OT0_:
  404|  20.7M|                              ranges::contiguous_range<uint8_t> auto&& in) {
  405|  20.7M|   ranges::assert_equal_byte_lengths(out, in);
  406|       |
  407|  20.7M|   std::span<uint8_t> o(out);
  408|  20.7M|   std::span<const uint8_t> i(in);
  409|       |
  410|  31.0M|   for(; o.size_bytes() >= 32; o = o.subspan(32), i = i.subspan(32)) {
  ------------------
  |  Branch (410:10): [True: 10.2M, False: 20.7M]
  ------------------
  411|  10.2M|      auto x = typecast_copy<std::array<uint64_t, 4>>(o.template first<32>());
  412|  10.2M|      const auto y = typecast_copy<std::array<uint64_t, 4>>(i.template first<32>());
  413|       |
  414|  10.2M|      x[0] ^= y[0];
  415|  10.2M|      x[1] ^= y[1];
  416|  10.2M|      x[2] ^= y[2];
  417|  10.2M|      x[3] ^= y[3];
  418|       |
  419|  10.2M|      typecast_copy(o.template first<32>(), x);
  420|  10.2M|   }
  421|       |
  422|   251M|   for(size_t off = 0; off != o.size_bytes(); ++off) {
  ------------------
  |  Branch (422:24): [True: 230M, False: 20.7M]
  ------------------
  423|   230M|      o[off] ^= i[off];
  424|   230M|   }
  425|  20.7M|}
_ZN5Botan7xor_bufITkNS_6ranges23contiguous_output_rangeIhEENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeIhEENS4_IKhLm18446744073709551615EEETkNS6_IhEES8_EEvOT_OT0_OT1_:
  435|  5.32M|                              ranges::contiguous_range<uint8_t> auto&& in2) {
  436|  5.32M|   ranges::assert_equal_byte_lengths(out, in1, in2);
  437|       |
  438|  5.32M|   std::span o{out};
  439|  5.32M|   std::span i1{in1};
  440|  5.32M|   std::span i2{in2};
  441|       |
  442|  8.77M|   for(; o.size_bytes() >= 32; o = o.subspan(32), i1 = i1.subspan(32), i2 = i2.subspan(32)) {
  ------------------
  |  Branch (442:10): [True: 3.45M, False: 5.32M]
  ------------------
  443|  3.45M|      auto x = typecast_copy<std::array<uint64_t, 4>>(i1.template first<32>());
  444|  3.45M|      const auto y = typecast_copy<std::array<uint64_t, 4>>(i2.template first<32>());
  445|       |
  446|  3.45M|      x[0] ^= y[0];
  447|  3.45M|      x[1] ^= y[1];
  448|  3.45M|      x[2] ^= y[2];
  449|  3.45M|      x[3] ^= y[3];
  450|       |
  451|  3.45M|      typecast_copy(o.template first<32>(), x);
  452|  3.45M|   }
  453|       |
  454|  67.4M|   for(size_t off = 0; off != o.size_bytes(); ++off) {
  ------------------
  |  Branch (454:24): [True: 62.0M, False: 5.32M]
  ------------------
  455|  62.0M|      o[off] = i1[off] ^ i2[off];
  456|  62.0M|   }
  457|  5.32M|}
_ZN5Botan11clear_bytesEPvm:
  101|  1.08M|inline constexpr void clear_bytes(void* ptr, size_t bytes) {
  102|  1.08M|   if(bytes > 0) {
  ------------------
  |  Branch (102:7): [True: 1.04M, False: 34.0k]
  ------------------
  103|  1.04M|      std::memset(ptr, 0, bytes);
  104|  1.04M|   }
  105|  1.08M|}
_ZN5Botan7xor_bufEPhPKhm:
  465|  11.6M|inline void xor_buf(uint8_t out[], const uint8_t in[], size_t length) {
  466|       |   // simply assumes that *out and *in point to "length" allocated bytes at least
  467|  11.6M|   xor_buf(std::span{out, length}, std::span{in, length});
  468|  11.6M|}
_ZN5Botan7xor_bufEPhPKhS2_m:
  477|  5.32M|inline void xor_buf(uint8_t out[], const uint8_t in[], const uint8_t in2[], size_t length) {
  478|       |   // simply assumes that *out, *in, and *in2 point to "length" allocated bytes at least
  479|  5.32M|   xor_buf(std::span{out, length}, std::span{in, length}, std::span{in2, length});
  480|  5.32M|}
_ZN5Botan7xor_bufENSt3__14spanIhLm18446744073709551615EEENS1_IKhLm18446744073709551615EEEm:
  489|  9.06M|inline void xor_buf(std::span<uint8_t> out, std::span<const uint8_t> in, size_t n) {
  490|  9.06M|   BOTAN_ARG_CHECK(out.size() >= n, "output span is too small");
  ------------------
  |  |   35|  9.06M|   do {                                                          \
  |  |   36|  9.06M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  9.06M|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 9.06M]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  9.06M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 9.06M]
  |  |  ------------------
  ------------------
  491|  9.06M|   BOTAN_ARG_CHECK(in.size() >= n, "input span is too small");
  ------------------
  |  |   35|  9.06M|   do {                                                          \
  |  |   36|  9.06M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  9.06M|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 9.06M]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  9.06M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 9.06M]
  |  |  ------------------
  ------------------
  492|  9.06M|   xor_buf(out.first(n), in.first(n));
  493|  9.06M|}
_ZN5Botan8copy_memIhQsr3stdE12is_trivial_vIu7__decayIT_EEEEvPS1_PKS1_m:
  144|  22.4M|inline constexpr void copy_mem(T* out, const T* in, size_t n) {
  145|  22.4M|   BOTAN_ASSERT_IMPLICATION(n > 0, in != nullptr && out != nullptr, "If n > 0 then args are not null");
  ------------------
  |  |  103|  22.4M|   do {                                                                                          \
  |  |  104|  22.4M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                              \
  |  |  105|  42.2M|      if((expr1) && !(expr2)) {                                                                  \
  |  |  ------------------
  |  |  |  Branch (105:10): [True: 21.1M, False: 1.36M]
  |  |  |  Branch (105:23): [True: 21.1M, False: 0]
  |  |  |  Branch (105:23): [True: 21.1M, False: 0]
  |  |  ------------------
  |  |  106|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                                     \
  |  |  107|      0|         Botan::assertion_failure(#expr1 " implies " #expr2, msg, __func__, __FILE__, __LINE__); \
  |  |  108|      0|      }                                                                                          \
  |  |  109|  22.4M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (109:12): [Folded, False: 22.4M]
  |  |  ------------------
  ------------------
  146|       |
  147|  22.4M|   if(in != nullptr && out != nullptr && n > 0) {
  ------------------
  |  Branch (147:7): [True: 22.4M, False: 8.17k]
  |  Branch (147:24): [True: 22.4M, False: 0]
  |  Branch (147:42): [True: 21.1M, False: 1.35M]
  ------------------
  148|  21.1M|      std::memmove(out, in, sizeof(T) * n);
  149|  21.1M|   }
  150|  22.4M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm2EEEtQaaaasr3stdE23is_trivially_copyable_vIT0_Entsr3std6rangesE5rangeIS7_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEEEvOSC_RKS7_:
  199|  4.65M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromT& in) {
  200|  4.65M|   typecast_copy(out, std::span<const FromT, 1>(&in, 1));
  201|  4.65M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm2EEETkNS1_16contiguous_rangeENS3_IKtLm1EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEEEvOSN_RKSD_:
  176|  4.65M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  4.65M|   ranges::assert_equal_byte_lengths(out, in);
  178|  4.65M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  4.65M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm4EEEjQaaaasr3stdE23is_trivially_copyable_vIT0_Entsr3std6rangesE5rangeIS7_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEEEvOSC_RKS7_:
  199|  63.8M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromT& in) {
  200|  63.8M|   typecast_copy(out, std::span<const FromT, 1>(&in, 1));
  201|  63.8M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm4EEETkNS1_16contiguous_rangeENS3_IKjLm1EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEEEvOSN_RKSD_:
  176|  63.8M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  63.8M|   ranges::assert_equal_byte_lengths(out, in);
  178|  63.8M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  63.8M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm8EEEmQaaaasr3stdE23is_trivially_copyable_vIT0_Entsr3std6rangesE5rangeIS7_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEEEvOSC_RKS7_:
  199|  56.0M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromT& in) {
  200|  56.0M|   typecast_copy(out, std::span<const FromT, 1>(&in, 1));
  201|  56.0M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERKNSt3__14spanIhLm8EEETkNS1_16contiguous_rangeENS3_IKmLm1EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEEEvOSN_RKSD_:
  176|  56.0M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  56.0M|   ranges::assert_equal_byte_lengths(out, in);
  178|  56.0M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  56.0M|}
_ZN5Botan13typecast_copyIjTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm4EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS6_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEEES6_RKSB_:
  210|   541M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|   541M|   ToT dst;  // NOLINT(*-member-init)
  212|   541M|   typecast_copy(dst, src);
  213|   541M|   return dst;
  214|   541M|}
_ZN5Botan13typecast_copyIjTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm4EEEQaaaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIT_Entsr3std6rangesE5rangeISK_EEEvRSK_RKSA_:
  188|   541M|inline constexpr void typecast_copy(ToT& out, const FromR& in) {
  189|   541M|   typecast_copy(std::span<ToT, 1>(&out, 1), in);
  190|   541M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeENSt3__14spanIjLm1EEETkNS1_16contiguous_rangeENS3_IKhLm4EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEEEvOSL_RKSB_:
  176|   541M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|   541M|   ranges::assert_equal_byte_lengths(out, in);
  178|   541M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|   541M|}
_ZN5Botan8copy_memIjQsr3stdE12is_trivial_vIu7__decayIT_EEEEvPS1_PKS1_m:
  144|    334|inline constexpr void copy_mem(T* out, const T* in, size_t n) {
  145|    334|   BOTAN_ASSERT_IMPLICATION(n > 0, in != nullptr && out != nullptr, "If n > 0 then args are not null");
  ------------------
  |  |  103|    334|   do {                                                                                          \
  |  |  104|    334|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                              \
  |  |  105|    668|      if((expr1) && !(expr2)) {                                                                  \
  |  |  ------------------
  |  |  |  Branch (105:10): [True: 334, False: 0]
  |  |  |  Branch (105:23): [True: 334, False: 0]
  |  |  |  Branch (105:23): [True: 334, False: 0]
  |  |  ------------------
  |  |  106|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                                     \
  |  |  107|      0|         Botan::assertion_failure(#expr1 " implies " #expr2, msg, __func__, __FILE__, __LINE__); \
  |  |  108|      0|      }                                                                                          \
  |  |  109|    334|   } while(0)
  |  |  ------------------
  |  |  |  Branch (109:12): [Folded, False: 334]
  |  |  ------------------
  ------------------
  146|       |
  147|    334|   if(in != nullptr && out != nullptr && n > 0) {
  ------------------
  |  Branch (147:7): [True: 334, False: 0]
  |  Branch (147:24): [True: 334, False: 0]
  |  Branch (147:42): [True: 334, False: 0]
  ------------------
  148|    334|      std::memmove(out, in, sizeof(T) * n);
  149|    334|   }
  150|    334|}
_ZN5Botan13typecast_copyImTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm8EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS6_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEEES6_RKSB_:
  210|   185M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|   185M|   ToT dst;  // NOLINT(*-member-init)
  212|   185M|   typecast_copy(dst, src);
  213|   185M|   return dst;
  214|   185M|}
_ZN5Botan13typecast_copyImTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm8EEEQaaaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIT_Entsr3std6rangesE5rangeISK_EEEvRSK_RKSA_:
  188|   185M|inline constexpr void typecast_copy(ToT& out, const FromR& in) {
  189|   185M|   typecast_copy(std::span<ToT, 1>(&out, 1), in);
  190|   185M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeENSt3__14spanImLm1EEETkNS1_16contiguous_rangeENS3_IKhLm8EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEEEvOSL_RKSB_:
  176|   185M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|   185M|   ranges::assert_equal_byte_lengths(out, in);
  178|   185M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|   185M|}
_ZN5Botan13typecast_copyItTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm2EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS6_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEEES6_RKSB_:
  210|  4.65M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|  4.65M|   ToT dst;  // NOLINT(*-member-init)
  212|  4.65M|   typecast_copy(dst, src);
  213|  4.65M|   return dst;
  214|  4.65M|}
_ZN5Botan13typecast_copyItTkNS_6ranges16contiguous_rangeENSt3__14spanIKhLm2EEEQaaaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIT_Entsr3std6rangesE5rangeISK_EEEvRSK_RKSA_:
  188|  4.65M|inline constexpr void typecast_copy(ToT& out, const FromR& in) {
  189|  4.65M|   typecast_copy(std::span<ToT, 1>(&out, 1), in);
  190|  4.65M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeENSt3__14spanItLm1EEETkNS1_16contiguous_rangeENS3_IKhLm2EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEEEvOSL_RKSB_:
  176|  4.65M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  4.65M|   ranges::assert_equal_byte_lengths(out, in);
  178|  4.65M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  4.65M|}
_ZN5Botan9clear_memIhEEvPT_m:
  118|   990k|inline constexpr void clear_mem(T* ptr, size_t n) {
  119|   990k|   clear_bytes(ptr, sizeof(T) * n);
  120|   990k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeERNSt3__16vectorIhNS_16secure_allocatorIhEEEETkNS1_16contiguous_rangeENS2_4spanIKhLm18446744073709551615EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISI_EESJ_E4type10value_typeENSB_IXsr21__is_primary_templateINSC_Iu14__remove_cvrefIDTclL_ZNSE_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSK_ISS_EEST_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISX_EEEvOSF_RKSP_:
  160|  2.39M|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|  2.39M|   ranges::assert_equal_byte_lengths(out, in);
  162|  2.39M|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 2.39M]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|  2.39M|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 2.39M, False: 5.55k]
  ------------------
  165|  2.39M|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|  2.39M|   }
  167|  2.39M|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeENS2_6vectorIhNS_16secure_allocatorIhEEEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeENS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISV_EEEvOSD_RKSN_:
  160|   719k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|   719k|   ranges::assert_equal_byte_lengths(out, in);
  162|   719k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 719k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|   719k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 715k, False: 3.21k]
  ------------------
  165|   715k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|   715k|   }
  167|   719k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeES4_Qaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISC_EESD_E4type10value_typeENS5_IXsr21__is_primary_templateINS6_Iu14__remove_cvrefIDTclL_ZNS8_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSE_ISM_EESN_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISR_EEEvOS9_RKSJ_:
  160|  1.67M|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|  1.67M|   ranges::assert_equal_byte_lengths(out, in);
  162|  1.67M|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 1.67M]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|  1.67M|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 1.67M, False: 0]
  ------------------
  165|  1.67M|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|  1.67M|   }
  167|  1.67M|}
_ZN5Botan8copy_memImQsr3stdE12is_trivial_vIu7__decayIT_EEEEvPS1_PKS1_m:
  144|  21.7M|inline constexpr void copy_mem(T* out, const T* in, size_t n) {
  145|  21.7M|   BOTAN_ASSERT_IMPLICATION(n > 0, in != nullptr && out != nullptr, "If n > 0 then args are not null");
  ------------------
  |  |  103|  21.7M|   do {                                                                                          \
  |  |  104|  21.7M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                              \
  |  |  105|  43.4M|      if((expr1) && !(expr2)) {                                                                  \
  |  |  ------------------
  |  |  |  Branch (105:10): [True: 21.7M, False: 0]
  |  |  |  Branch (105:23): [True: 21.7M, False: 0]
  |  |  |  Branch (105:23): [True: 21.7M, False: 0]
  |  |  ------------------
  |  |  106|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                                     \
  |  |  107|      0|         Botan::assertion_failure(#expr1 " implies " #expr2, msg, __func__, __FILE__, __LINE__); \
  |  |  108|      0|      }                                                                                          \
  |  |  109|  21.7M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (109:12): [Folded, False: 21.7M]
  |  |  ------------------
  ------------------
  146|       |
  147|  21.7M|   if(in != nullptr && out != nullptr && n > 0) {
  ------------------
  |  Branch (147:7): [True: 21.7M, False: 0]
  |  Branch (147:24): [True: 21.7M, False: 0]
  |  Branch (147:42): [True: 21.7M, False: 0]
  ------------------
  148|  21.7M|      std::memmove(out, in, sizeof(T) * n);
  149|  21.7M|   }
  150|  21.7M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__14spanImLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKhLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS8_IXsr21__is_primary_templateINS9_Iu14__remove_cvrefIDTclL_ZNSB_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSH_ISP_EESQ_E4type10value_typeEEEEvOSM_RKSC_:
  176|   852k|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|   852k|   ranges::assert_equal_byte_lengths(out, in);
  178|   852k|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|   852k|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKmLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS8_IXsr21__is_primary_templateINS9_Iu14__remove_cvrefIDTclL_ZNSB_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSH_ISP_EESQ_E4type10value_typeEEEEvOSM_RKSC_:
  176|   425k|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|   425k|   ranges::assert_equal_byte_lengths(out, in);
  178|   425k|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|   425k|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__14spanIjLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKhLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS8_IXsr21__is_primary_templateINS9_Iu14__remove_cvrefIDTclL_ZNSB_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSH_ISP_EESQ_E4type10value_typeEEEEvOSM_RKSC_:
  176|  7.22M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  7.22M|   ranges::assert_equal_byte_lengths(out, in);
  178|  7.22M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  7.22M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayIjLm16EEETkNS1_16contiguous_rangeENS2_4spanIKhLm64EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEEEvOSN_RKSD_:
  176|  4.82M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  4.82M|   ranges::assert_equal_byte_lengths(out, in);
  178|  4.82M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  4.82M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKjLm18446744073709551615EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISF_EESG_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS8_IXsr21__is_primary_templateINS9_Iu14__remove_cvrefIDTclL_ZNSB_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSH_ISP_EESQ_E4type10value_typeEEEEvOSM_RKSC_:
  176|  20.5k|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  20.5k|   ranges::assert_equal_byte_lengths(out, in);
  178|  20.5k|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  20.5k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKhLm18446744073709551615EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeENS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIST_EEEvOSB_RKSL_:
  160|   218k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|   218k|   ranges::assert_equal_byte_lengths(out, in);
  162|   218k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 218k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|   218k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 218k, False: 0]
  ------------------
  165|   218k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|   218k|   }
  167|   218k|}
_ZN5Botan9clear_memImEEvPT_m:
  118|  84.4k|inline constexpr void clear_mem(T* ptr, size_t n) {
  119|  84.4k|   clear_bytes(ptr, sizeof(T) * n);
  120|  84.4k|}
_ZN5Botan13typecast_copyImTkNS_6ranges16contiguous_rangeENSt3__14spanIhLm8EEEQaaaasr3stdE26is_default_constructible_vIT_Esr3stdE23is_trivially_copyable_vIS5_Esr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEEES5_RKSA_:
  210|  3.31M|inline constexpr ToT typecast_copy(const FromR& src) {
  211|  3.31M|   ToT dst;  // NOLINT(*-member-init)
  212|  3.31M|   typecast_copy(dst, src);
  213|  3.31M|   return dst;
  214|  3.31M|}
_ZN5Botan13typecast_copyImTkNS_6ranges16contiguous_rangeENSt3__14spanIhLm8EEEQaaaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISC_EESD_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIT_Entsr3std6rangesE5rangeISJ_EEEvRSJ_RKS9_:
  188|  3.31M|inline constexpr void typecast_copy(ToT& out, const FromR& in) {
  189|  3.31M|   typecast_copy(std::span<ToT, 1>(&out, 1), in);
  190|  3.31M|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeENSt3__14spanImLm1EEETkNS1_16contiguous_rangeENS3_IhLm8EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS6_IXsr21__is_primary_templateINS7_Iu14__remove_cvrefIDTclL_ZNS9_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSF_ISN_EESO_E4type10value_typeEEEEvOSK_RKSA_:
  176|  3.31M|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  3.31M|   ranges::assert_equal_byte_lengths(out, in);
  178|  3.31M|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  3.31M|}
_ZN5Botan9clear_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanImLm18446744073709551615EEEEEvOT_Qsr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRS5_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEE:
  132|  6.54k|{
  133|  6.54k|   clear_bytes(std::ranges::data(mem), ranges::size_bytes(mem));
  134|  6.54k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanImLm18446744073709551615EEETkNS1_16contiguous_rangeENS3_IKmLm18446744073709551615EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeENS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIST_EEEvOSB_RKSL_:
  160|  6.07k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|  6.07k|   ranges::assert_equal_byte_lengths(out, in);
  162|  6.07k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 6.07k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|  6.07k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 6.07k, False: 0]
  ------------------
  165|  6.07k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|  6.07k|   }
  167|  6.07k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeERNSt3__16vectorImNS_16secure_allocatorImEEEETkNS1_16contiguous_rangeENS2_4spanImLm18446744073709551615EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISH_EESI_E4type10value_typeENSA_IXsr21__is_primary_templateINSB_Iu14__remove_cvrefIDTclL_ZNSD_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSJ_ISR_EESS_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISW_EEEvOSE_RKSO_:
  160|   362k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|   362k|   ranges::assert_equal_byte_lengths(out, in);
  162|   362k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 362k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|   362k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 362k, False: 0]
  ------------------
  165|   362k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|   362k|   }
  167|   362k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanImLm4EEETkNS1_16contiguous_rangeENS2_5arrayImLm4EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeENS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEsr3stdE23is_trivially_copyable_vIST_EEEvOSB_RKSL_:
  160|  24.7k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|  24.7k|   ranges::assert_equal_byte_lengths(out, in);
  162|  24.7k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 24.7k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|  24.7k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 24.7k, False: 0]
  ------------------
  165|  24.7k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|  24.7k|   }
  167|  24.7k|}
_ZN5Botan9clear_memITkNS_6ranges23contiguous_output_rangeENSt3__14spanIhLm18446744073709551615EEEEEvOT_Qsr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRS5_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeEE:
  132|  1.03k|{
  133|  1.03k|   clear_bytes(std::ranges::data(mem), ranges::size_bytes(mem));
  134|  1.03k|}
_ZN5BotaneOINS_16secure_allocatorIhEES2_EERNSt3__16vectorIhT_EES7_RKNS4_IhT0_EE:
  532|  1.38M|std::vector<uint8_t, Alloc>& operator^=(std::vector<uint8_t, Alloc>& out, const std::vector<uint8_t, Alloc2>& in) {
  533|  1.38M|   if(out.size() < in.size()) {
  ------------------
  |  Branch (533:7): [True: 0, False: 1.38M]
  ------------------
  534|      0|      out.resize(in.size());
  535|      0|   }
  536|       |
  537|  1.38M|   xor_buf(std::span{out}.first(in.size()), in);
  538|  1.38M|   return out;
  539|  1.38M|}
_ZN5Botan7xor_bufITkNS_6ranges23contiguous_output_rangeIhEENSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeIhEERKNS3_6vectorIhNS_16secure_allocatorIhEEEEEEvOT_OT0_:
  404|  1.38M|                              ranges::contiguous_range<uint8_t> auto&& in) {
  405|  1.38M|   ranges::assert_equal_byte_lengths(out, in);
  406|       |
  407|  1.38M|   std::span<uint8_t> o(out);
  408|  1.38M|   std::span<const uint8_t> i(in);
  409|       |
  410|  1.38M|   for(; o.size_bytes() >= 32; o = o.subspan(32), i = i.subspan(32)) {
  ------------------
  |  Branch (410:10): [True: 0, False: 1.38M]
  ------------------
  411|      0|      auto x = typecast_copy<std::array<uint64_t, 4>>(o.template first<32>());
  412|      0|      const auto y = typecast_copy<std::array<uint64_t, 4>>(i.template first<32>());
  413|       |
  414|      0|      x[0] ^= y[0];
  415|      0|      x[1] ^= y[1];
  416|      0|      x[2] ^= y[2];
  417|      0|      x[3] ^= y[3];
  418|       |
  419|      0|      typecast_copy(o.template first<32>(), x);
  420|      0|   }
  421|       |
  422|  23.5M|   for(size_t off = 0; off != o.size_bytes(); ++off) {
  ------------------
  |  Branch (422:24): [True: 22.1M, False: 1.38M]
  ------------------
  423|  22.1M|      o[off] ^= i[off];
  424|  22.1M|   }
  425|  1.38M|}
_ZN5Botan19secure_scrub_memoryITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayIhLm16EEEEEvOT_:
   59|   310k|void secure_scrub_memory(ranges::contiguous_output_range auto&& data) {
   60|   310k|   secure_scrub_memory(std::ranges::data(data), ranges::size_bytes(data));
   61|   310k|}
_ZN5Botan13typecast_copyITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayIhLm8EEETkNS1_16contiguous_rangeENS3_ImLm1EEEQaasr3stdE23is_trivially_copyable_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISE_EESF_E4type10value_typeEEsr3stdE23is_trivially_copyable_vINS7_IXsr21__is_primary_templateINS8_Iu14__remove_cvrefIDTclL_ZNSA_5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENSG_ISO_EESP_E4type10value_typeEEEEvOSL_RKSB_:
  176|  23.8k|inline constexpr void typecast_copy(ToR&& out /* NOLINT(*-std-forward) */, const FromR& in) {
  177|  23.8k|   ranges::assert_equal_byte_lengths(out, in);
  178|  23.8k|   std::memcpy(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  179|  23.8k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayIhLm16EEETkNS1_16contiguous_rangeENS2_4spanIKhLm18446744073709551615EEEQaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISG_EESH_E4type10value_typeENS9_IXsr21__is_primary_templateINSA_Iu14__remove_cvrefIDTclL_ZNSC_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSI_ISQ_EESR_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISV_EEEvOSD_RKSN_:
  160|   102k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|   102k|   ranges::assert_equal_byte_lengths(out, in);
  162|   102k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 102k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|   102k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 102k, False: 0]
  ------------------
  165|   102k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|   102k|   }
  167|   102k|}
_ZN5Botan8copy_memITkNS_6ranges23contiguous_output_rangeERNSt3__15arrayIhLm16EEETkNS1_16contiguous_rangeES4_Qaasr3stdE9is_same_vINS2_11conditionalIXsr21__is_primary_templateINS2_15iterator_traitsIu14__remove_cvrefIDTclL_ZNS2_6ranges5__cpo5beginEEclsr3stdE7declvalIRT_EEEEEEEEE5valueENS2_26indirectly_readable_traitsISD_EESE_E4type10value_typeENS6_IXsr21__is_primary_templateINS7_Iu14__remove_cvrefIDTclL_ZNS9_5beginEEclsr3stdE7declvalIRT0_EEEEEEEEE5valueENSF_ISN_EESO_E4type10value_typeEEsr3stdE23is_trivially_copyable_vISS_EEEvOSA_RKSK_:
  160|   102k|inline constexpr void copy_mem(OutR&& out /* NOLINT(*-std-forward) */, const InR& in) {
  161|   102k|   ranges::assert_equal_byte_lengths(out, in);
  162|   102k|   if(std::is_constant_evaluated()) {
  ------------------
  |  Branch (162:7): [Folded, False: 102k]
  ------------------
  163|      0|      std::copy(std::ranges::begin(in), std::ranges::end(in), std::ranges::begin(out));
  164|   102k|   } else if(ranges::size_bytes(out) > 0) {
  ------------------
  |  Branch (164:14): [True: 102k, False: 0]
  ------------------
  165|   102k|      std::memmove(std::ranges::data(out), std::ranges::data(in), ranges::size_bytes(out));
  166|   102k|   }
  167|   102k|}
_ZN5Botan7xor_bufITkNS_6ranges23contiguous_output_rangeIhEERNSt3__14spanIhLm18446744073709551615EEETkNS1_16contiguous_rangeIhEES5_TkNS7_IhEES5_EEvOT_OT0_OT1_:
  435|   102k|                              ranges::contiguous_range<uint8_t> auto&& in2) {
  436|   102k|   ranges::assert_equal_byte_lengths(out, in1, in2);
  437|       |
  438|   102k|   std::span o{out};
  439|   102k|   std::span i1{in1};
  440|   102k|   std::span i2{in2};
  441|       |
  442|   102k|   for(; o.size_bytes() >= 32; o = o.subspan(32), i1 = i1.subspan(32), i2 = i2.subspan(32)) {
  ------------------
  |  Branch (442:10): [True: 0, False: 102k]
  ------------------
  443|      0|      auto x = typecast_copy<std::array<uint64_t, 4>>(i1.template first<32>());
  444|      0|      const auto y = typecast_copy<std::array<uint64_t, 4>>(i2.template first<32>());
  445|       |
  446|      0|      x[0] ^= y[0];
  447|      0|      x[1] ^= y[1];
  448|      0|      x[2] ^= y[2];
  449|      0|      x[3] ^= y[3];
  450|       |
  451|      0|      typecast_copy(o.template first<32>(), x);
  452|      0|   }
  453|       |
  454|  1.73M|   for(size_t off = 0; off != o.size_bytes(); ++off) {
  ------------------
  |  Branch (454:24): [True: 1.63M, False: 102k]
  ------------------
  455|  1.63M|      o[off] = i1[off] ^ i2[off];
  456|  1.63M|   }
  457|   102k|}

_ZN5Botan18RFC4880_S2K_FamilyC2ENSt3__110unique_ptrINS_12HashFunctionENS1_14default_deleteIS3_EEEE:
  106|  19.9k|      BOTAN_FUTURE_EXPLICIT RFC4880_S2K_Family(std::unique_ptr<HashFunction> hash) : m_hash(std::move(hash)) {}

_ZNK5Botan14Asymmetric_Key40_signature_element_size_for_DER_encodingEv:
  144|  3.43k|      virtual std::optional<size_t> _signature_element_size_for_DER_encoding() const { return {}; }
_ZN5Botan14Asymmetric_KeyD2Ev:
   62|  10.8k|      virtual ~Asymmetric_Key() = default;

_ZN5Botan6PK_Ops12VerificationD2Ev:
  102|  10.7k|      virtual ~Verification() = default;
_ZN5Botan6PK_Ops10EncryptionD2Ev:
   59|     41|      virtual ~Encryption() = default;

_ZNK5Botan12PK_Encryptor7encryptEPKhmRNS_21RandomNumberGeneratorE:
   36|     41|      std::vector<uint8_t> encrypt(const uint8_t in[], size_t length, RandomNumberGenerator& rng) const {
   37|     41|         return enc(in, length, rng);
   38|     41|      }
_ZN5Botan12PK_EncryptorC2Ev:
   61|     41|      PK_Encryptor() = default;
_ZN5Botan12PK_EncryptorD2Ev:
   62|     41|      virtual ~PK_Encryptor() = default;

_ZN5Botan12PasswordHashD2Ev:
   31|  20.2k|      virtual ~PasswordHash() = default;
_ZN5Botan18PasswordHashFamilyD2Ev:
  213|  20.2k|      virtual ~PasswordHashFamily() = default;

_ZN5Botan6ranges24assert_exact_byte_lengthILm32ETkNS0_14spanable_rangeENSt3__14spanIhLm32EEEEEvRKT0_:
   77|  11.5M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  11.5M|   const std::span s{r};
   79|  11.5M|   if constexpr(statically_spanable_range<R>) {
   80|  11.5M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  11.5M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayImLm4EEETpTkNS0_14spanable_rangeEJNS2_4spanIhLm32EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  10.2M|{
  101|  10.2M|   const std::span s0{r0};
  102|       |
  103|  10.2M|   if constexpr(statically_spanable_range<R0>) {
  104|  10.2M|      constexpr size_t expected_size = s0.size_bytes();
  105|  10.2M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  10.2M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__15arrayImLm4EEEEEmRKT_:
   59|  27.4M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  27.4M|   return std::span{r}.size_bytes();
   61|  27.4M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm32ETkNS0_14spanable_rangeENSt3__14spanIKhLm32EEEEEvRKT0_:
   77|  17.7M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  17.7M|   const std::span s{r};
   79|  17.7M|   if constexpr(statically_spanable_range<R>) {
   80|  17.7M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  17.7M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayImLm4EEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm32EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  17.1M|{
  101|  17.1M|   const std::span s0{r0};
  102|       |
  103|  17.1M|   if constexpr(statically_spanable_range<R0>) {
  104|  17.1M|      constexpr size_t expected_size = s0.size_bytes();
  105|  17.1M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  17.1M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm32ETkNS0_14spanable_rangeENSt3__15arrayImLm4EEEEEvRKT0_:
   77|  13.8M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  13.8M|   const std::span s{r};
   79|  13.8M|   if constexpr(statically_spanable_range<R>) {
   80|  13.8M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  13.8M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm32EEETpTkNS0_14spanable_rangeEJNS2_5arrayImLm4EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  13.7M|{
  101|  13.7M|   const std::span s0{r0};
  102|       |
  103|  13.7M|   if constexpr(statically_spanable_range<R0>) {
  104|  13.7M|      constexpr size_t expected_size = s0.size_bytes();
  105|  13.7M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  13.7M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIhLm32EEEEEmRKT_:
   59|  13.7M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  13.7M|   return std::span{r}.size_bytes();
   61|  13.7M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKhLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  20.9M|{
  101|  20.9M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  20.9M|   } else {
  107|  20.9M|      const size_t expected_size = s0.size_bytes();
  108|  20.9M|      const bool correct_size =
  109|  20.9M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  20.9M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 20.9M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  20.9M|   }
  115|  20.9M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKhLm18446744073709551615EEES6_EEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  5.32M|{
  101|  5.32M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  5.32M|   } else {
  107|  5.32M|      const size_t expected_size = s0.size_bytes();
  108|  5.32M|      const bool correct_size =
  109|  10.6M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  ------------------
  |  Branch (109:11): [True: 5.32M, False: 0]
  |  Branch (109:11): [True: 5.32M, False: 0]
  ------------------
  110|       |
  111|  5.32M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 5.32M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  5.32M|   }
  115|  5.32M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm2ETkNS0_14spanable_rangeENSt3__14spanIhLm2EEEEEvRKT0_:
   77|  4.65M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  4.65M|   const std::span s{r};
   79|  4.65M|   if constexpr(statically_spanable_range<R>) {
   80|  4.65M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  4.65M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm2EEETpTkNS0_14spanable_rangeEJNS3_IKtLm1EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  4.65M|{
  101|  4.65M|   const std::span s0{r0};
  102|       |
  103|  4.65M|   if constexpr(statically_spanable_range<R0>) {
  104|  4.65M|      constexpr size_t expected_size = s0.size_bytes();
  105|  4.65M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  4.65M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm2ETkNS0_14spanable_rangeENSt3__14spanIKtLm1EEEEEvRKT0_:
   77|  4.65M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  4.65M|   const std::span s{r};
   79|  4.65M|   if constexpr(statically_spanable_range<R>) {
   80|  4.65M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  4.65M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIhLm2EEEEEmRKT_:
   59|  4.65M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  4.65M|   return std::span{r}.size_bytes();
   61|  4.65M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm4ETkNS0_14spanable_rangeENSt3__14spanIhLm4EEEEEvRKT0_:
   77|   107M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|   107M|   const std::span s{r};
   79|   107M|   if constexpr(statically_spanable_range<R>) {
   80|   107M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|   107M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm4EEETpTkNS0_14spanable_rangeEJNS3_IKjLm1EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  63.8M|{
  101|  63.8M|   const std::span s0{r0};
  102|       |
  103|  63.8M|   if constexpr(statically_spanable_range<R0>) {
  104|  63.8M|      constexpr size_t expected_size = s0.size_bytes();
  105|  63.8M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  63.8M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm4ETkNS0_14spanable_rangeENSt3__14spanIKjLm1EEEEEvRKT0_:
   77|  63.8M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  63.8M|   const std::span s{r};
   79|  63.8M|   if constexpr(statically_spanable_range<R>) {
   80|  63.8M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  63.8M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIhLm4EEEEEmRKT_:
   59|  63.8M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  63.8M|   return std::span{r}.size_bytes();
   61|  63.8M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm8ETkNS0_14spanable_rangeENSt3__14spanIhLm8EEEEEvRKT0_:
   77|  82.4M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  82.4M|   const std::span s{r};
   79|  82.4M|   if constexpr(statically_spanable_range<R>) {
   80|  82.4M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  82.4M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm8EEETpTkNS0_14spanable_rangeEJNS3_IKmLm1EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  56.0M|{
  101|  56.0M|   const std::span s0{r0};
  102|       |
  103|  56.0M|   if constexpr(statically_spanable_range<R0>) {
  104|  56.0M|      constexpr size_t expected_size = s0.size_bytes();
  105|  56.0M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  56.0M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm8ETkNS0_14spanable_rangeENSt3__14spanIKmLm1EEEEEvRKT0_:
   77|  56.0M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  56.0M|   const std::span s{r};
   79|  56.0M|   if constexpr(statically_spanable_range<R>) {
   80|  56.0M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  56.0M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIhLm8EEEEEmRKT_:
   59|  56.0M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  56.0M|   return std::span{r}.size_bytes();
   61|  56.0M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIjLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKhLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  22.3M|{
  101|  22.3M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  22.3M|   } else {
  107|  22.3M|      const size_t expected_size = s0.size_bytes();
  108|  22.3M|      const bool correct_size =
  109|  22.3M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  22.3M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 22.3M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  22.3M|   }
  115|  22.3M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm4ETkNS0_14spanable_rangeENSt3__14spanIKhLm4EEEEEvRKT0_:
   77|  1.08G|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  1.08G|   const std::span s{r};
   79|  1.08G|   if constexpr(statically_spanable_range<R>) {
   80|  1.08G|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  1.08G|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIjLm1EEETpTkNS0_14spanable_rangeEJNS3_IKhLm4EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   541M|{
  101|   541M|   const std::span s0{r0};
  102|       |
  103|   541M|   if constexpr(statically_spanable_range<R0>) {
  104|   541M|      constexpr size_t expected_size = s0.size_bytes();
  105|   541M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   541M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIjLm1EEEEEmRKT_:
   59|   541M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|   541M|   return std::span{r}.size_bytes();
   61|   541M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKjLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  8.00M|{
  101|  8.00M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  8.00M|   } else {
  107|  8.00M|      const size_t expected_size = s0.size_bytes();
  108|  8.00M|      const bool correct_size =
  109|  8.00M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  8.00M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 8.00M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  8.00M|   }
  115|  8.00M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm8ETkNS0_14spanable_rangeENSt3__14spanIKhLm8EEEEEvRKT0_:
   77|   373M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|   373M|   const std::span s{r};
   79|   373M|   if constexpr(statically_spanable_range<R>) {
   80|   373M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|   373M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanImLm1EEETpTkNS0_14spanable_rangeEJNS3_IKhLm8EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   185M|{
  101|   185M|   const std::span s0{r0};
  102|       |
  103|   185M|   if constexpr(statically_spanable_range<R0>) {
  104|   185M|      constexpr size_t expected_size = s0.size_bytes();
  105|   185M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   185M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanImLm1EEEEEmRKT_:
   59|   189M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|   189M|   return std::span{r}.size_bytes();
   61|   189M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm16ETkNS0_14spanable_rangeENSt3__14spanIhLm16EEEEEvRKT0_:
   77|  13.1M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  13.1M|   const std::span s{r};
   79|  13.1M|   if constexpr(statically_spanable_range<R>) {
   80|  13.1M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  13.1M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm16ETkNS0_14spanable_rangeENSt3__14spanIKhLm16EEEEEvRKT0_:
   77|  3.14M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  3.14M|   const std::span s{r};
   79|  3.14M|   if constexpr(statically_spanable_range<R>) {
   80|  3.14M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  3.14M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanImLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKhLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  2.32M|{
  101|  2.32M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  2.32M|   } else {
  107|  2.32M|      const size_t expected_size = s0.size_bytes();
  108|  2.32M|      const bool correct_size =
  109|  2.32M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  2.32M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 2.32M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  2.32M|   }
  115|  2.32M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm2ETkNS0_14spanable_rangeENSt3__14spanIKhLm2EEEEEvRKT0_:
   77|  9.30M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  9.30M|   const std::span s{r};
   79|  9.30M|   if constexpr(statically_spanable_range<R>) {
   80|  9.30M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  9.30M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanItLm1EEETpTkNS0_14spanable_rangeEJNS3_IKhLm2EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  4.65M|{
  101|  4.65M|   const std::span s0{r0};
  102|       |
  103|  4.65M|   if constexpr(statically_spanable_range<R0>) {
  104|  4.65M|      constexpr size_t expected_size = s0.size_bytes();
  105|  4.65M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  4.65M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanItLm1EEEEEmRKT_:
   59|  4.65M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  4.65M|   return std::span{r}.size_bytes();
   61|  4.65M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__16vectorIhNS_16secure_allocatorIhEEEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  2.39M|{
  101|  2.39M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  2.39M|   } else {
  107|  2.39M|      const size_t expected_size = s0.size_bytes();
  108|  2.39M|      const bool correct_size =
  109|  2.39M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  2.39M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 2.39M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  2.39M|   }
  115|  2.39M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__16vectorIhNS_16secure_allocatorIhEEEEEEmRKT_:
   59|  4.79M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  4.79M|   return std::span{r}.size_bytes();
   61|  4.79M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS2_6vectorIhNS_16secure_allocatorIhEEEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  2.10M|{
  101|  2.10M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  2.10M|   } else {
  107|  2.10M|      const size_t expected_size = s0.size_bytes();
  108|  2.10M|      const bool correct_size =
  109|  2.10M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  2.10M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 2.10M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  2.10M|   }
  115|  2.10M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEEEEmRKT_:
   59|  5.67M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  5.67M|   return std::span{r}.size_bytes();
   61|  5.67M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJS4_EEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  1.67M|{
  101|  1.67M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  1.67M|   } else {
  107|  1.67M|      const size_t expected_size = s0.size_bytes();
  108|  1.67M|      const bool correct_size =
  109|  1.67M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  1.67M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 1.67M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  1.67M|   }
  115|  1.67M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanImLm18446744073709551615EEEEEmRKT_:
   59|   871k|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|   871k|   return std::span{r}.size_bytes();
   61|   871k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKmLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  3.22M|{
  101|  3.22M|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  3.22M|   } else {
  107|  3.22M|      const size_t expected_size = s0.size_bytes();
  108|  3.22M|      const bool correct_size =
  109|  3.22M|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  3.22M|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 3.22M]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  3.22M|   }
  115|  3.22M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanIjLm18446744073709551615EEEEEmRKT_:
   59|  7.22M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  7.22M|   return std::span{r}.size_bytes();
   61|  7.22M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayIjLm16EEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm64EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  16.1M|{
  101|  16.1M|   const std::span s0{r0};
  102|       |
  103|  16.1M|   if constexpr(statically_spanable_range<R0>) {
  104|  16.1M|      constexpr size_t expected_size = s0.size_bytes();
  105|  16.1M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  16.1M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm64ETkNS0_14spanable_rangeENSt3__14spanIKhLm64EEEEEvRKT0_:
   77|  39.6M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  39.6M|   const std::span s{r};
   79|  39.6M|   if constexpr(statically_spanable_range<R>) {
   80|  39.6M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  39.6M|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__15arrayIjLm16EEEEEmRKT_:
   59|  4.82M|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  4.82M|   return std::span{r}.size_bytes();
   61|  4.82M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIjLm16EEETpTkNS0_14spanable_rangeEJNS3_IKhLm64EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  23.4M|{
  101|  23.4M|   const std::span s0{r0};
  102|       |
  103|  23.4M|   if constexpr(statically_spanable_range<R0>) {
  104|  23.4M|      constexpr size_t expected_size = s0.size_bytes();
  105|  23.4M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  23.4M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayImLm16EEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm128EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  9.21M|{
  101|  9.21M|   const std::span s0{r0};
  102|       |
  103|  9.21M|   if constexpr(statically_spanable_range<R0>) {
  104|  9.21M|      constexpr size_t expected_size = s0.size_bytes();
  105|  9.21M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  9.21M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm128ETkNS0_14spanable_rangeENSt3__14spanIKhLm128EEEEEvRKT0_:
   77|  9.21M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  9.21M|   const std::span s{r};
   79|  9.21M|   if constexpr(statically_spanable_range<R>) {
   80|  9.21M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  9.21M|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm8ETkNS0_14spanable_rangeENSt3__15arrayIhLm8EEEEEvRKT0_:
   77|  3.31M|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  3.31M|   const std::span s{r};
   79|  3.31M|   if constexpr(statically_spanable_range<R>) {
   80|  3.31M|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  3.31M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanImLm1EEETpTkNS0_14spanable_rangeEJNS3_IhLm8EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  3.31M|{
  101|  3.31M|   const std::span s0{r0};
  102|       |
  103|  3.31M|   if constexpr(statically_spanable_range<R0>) {
  104|  3.31M|      constexpr size_t expected_size = s0.size_bytes();
  105|  3.31M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  3.31M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanImLm18446744073709551615EEETpTkNS0_14spanable_rangeEJNS3_IKmLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  6.07k|{
  101|  6.07k|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|  6.07k|   } else {
  107|  6.07k|      const size_t expected_size = s0.size_bytes();
  108|  6.07k|      const bool correct_size =
  109|  6.07k|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|  6.07k|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 6.07k]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|  6.07k|   }
  115|  6.07k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEETpTkNS0_14spanable_rangeEJNS2_4spanImLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   362k|{
  101|   362k|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|   362k|   } else {
  107|   362k|      const size_t expected_size = s0.size_bytes();
  108|   362k|      const bool correct_size =
  109|   362k|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|   362k|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 362k]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|   362k|   }
  115|   362k|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__16vectorImNS_16secure_allocatorImEEEEEEmRKT_:
   59|   724k|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|   724k|   return std::span{r}.size_bytes();
   61|   724k|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm8ETkNS0_14spanable_rangeENSt3__15arrayImLm1EEEEEvRKT0_:
   77|  47.6k|inline constexpr void assert_exact_byte_length(const R& r) {
   78|  47.6k|   const std::span s{r};
   79|  47.6k|   if constexpr(statically_spanable_range<R>) {
   80|  47.6k|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|  47.6k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanImLm4EEETpTkNS0_14spanable_rangeEJNS2_5arrayImLm4EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  24.7k|{
  101|  24.7k|   const std::span s0{r0};
  102|       |
  103|  24.7k|   if constexpr(statically_spanable_range<R0>) {
  104|  24.7k|      constexpr size_t expected_size = s0.size_bytes();
  105|  24.7k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  24.7k|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__14spanImLm4EEEEEmRKT_:
   59|  49.4k|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  49.4k|   return std::span{r}.size_bytes();
   61|  49.4k|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__15arrayIhLm16EEEEEmRKT_:
   59|   720k|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|   720k|   return std::span{r}.size_bytes();
   61|   720k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayIhLm8EEETpTkNS0_14spanable_rangeEJNS3_ImLm1EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  47.6k|{
  101|  47.6k|   const std::span s0{r0};
  102|       |
  103|  47.6k|   if constexpr(statically_spanable_range<R0>) {
  104|  47.6k|      constexpr size_t expected_size = s0.size_bytes();
  105|  47.6k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  47.6k|}
_ZN5Botan6ranges10size_bytesITkNS0_14spanable_rangeENSt3__15arrayIhLm8EEEEEmRKT_:
   59|  23.8k|inline constexpr size_t size_bytes(const spanable_range auto& r) {
   60|  23.8k|   return std::span{r}.size_bytes();
   61|  23.8k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayIhLm16EEETpTkNS0_14spanable_rangeEJNS3_ImLm2EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   102k|{
  101|   102k|   const std::span s0{r0};
  102|       |
  103|   102k|   if constexpr(statically_spanable_range<R0>) {
  104|   102k|      constexpr size_t expected_size = s0.size_bytes();
  105|   102k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   102k|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm16ETkNS0_14spanable_rangeENSt3__15arrayImLm2EEEEEvRKT0_:
   77|   648k|inline constexpr void assert_exact_byte_length(const R& r) {
   78|   648k|   const std::span s{r};
   79|   648k|   if constexpr(statically_spanable_range<R>) {
   80|   648k|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|   648k|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm16ETkNS0_14spanable_rangeENSt3__15arrayIhLm16EEEEEvRKT0_:
   77|   102k|inline constexpr void assert_exact_byte_length(const R& r) {
   78|   102k|   const std::span s{r};
   79|   102k|   if constexpr(statically_spanable_range<R>) {
   80|   102k|      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|       |   } else {
   82|       |      if(s.size_bytes() != expected) {
   83|       |         memory_region_size_violation();
   84|       |      }
   85|       |   }
   86|   102k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayImLm2EEETpTkNS0_14spanable_rangeEJNS2_4spanIhLm16EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   545k|{
  101|   545k|   const std::span s0{r0};
  102|       |
  103|   545k|   if constexpr(statically_spanable_range<R0>) {
  104|   545k|      constexpr size_t expected_size = s0.size_bytes();
  105|   545k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   545k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayImLm2EEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm16EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|  2.30M|{
  101|  2.30M|   const std::span s0{r0};
  102|       |
  103|  2.30M|   if constexpr(statically_spanable_range<R0>) {
  104|  2.30M|      constexpr size_t expected_size = s0.size_bytes();
  105|  2.30M|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|  2.30M|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm16EEETpTkNS0_14spanable_rangeEJNS2_5arrayImLm2EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   545k|{
  101|   545k|   const std::span s0{r0};
  102|       |
  103|   545k|   if constexpr(statically_spanable_range<R0>) {
  104|   545k|      constexpr size_t expected_size = s0.size_bytes();
  105|   545k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   545k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayIhLm16EEETpTkNS0_14spanable_rangeEJNS2_4spanIKhLm18446744073709551615EEEEEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   102k|{
  101|   102k|   const std::span s0{r0};
  102|       |
  103|   102k|   if constexpr(statically_spanable_range<R0>) {
  104|   102k|      constexpr size_t expected_size = s0.size_bytes();
  105|   102k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   102k|}
_ZN5Botan6ranges24assert_exact_byte_lengthILm16ETkNS0_14spanable_rangeENSt3__14spanIKhLm18446744073709551615EEEEEvRKT0_:
   77|   102k|inline constexpr void assert_exact_byte_length(const R& r) {
   78|   102k|   const std::span s{r};
   79|       |   if constexpr(statically_spanable_range<R>) {
   80|       |      static_assert(s.size_bytes() == expected, "memory region does not have expected byte lengths");
   81|   102k|   } else {
   82|   102k|      if(s.size_bytes() != expected) {
  ------------------
  |  Branch (82:10): [True: 0, False: 102k]
  ------------------
   83|      0|         memory_region_size_violation();
   84|      0|      }
   85|   102k|   }
   86|   102k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__15arrayIhLm16EEETpTkNS0_14spanable_rangeEJS4_EEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   102k|{
  101|   102k|   const std::span s0{r0};
  102|       |
  103|   102k|   if constexpr(statically_spanable_range<R0>) {
  104|   102k|      constexpr size_t expected_size = s0.size_bytes();
  105|   102k|      (assert_exact_byte_length<expected_size>(rs), ...);
  106|       |   } else {
  107|       |      const size_t expected_size = s0.size_bytes();
  108|       |      const bool correct_size =
  109|       |         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  110|       |
  111|       |      if(!correct_size) {
  112|       |         memory_region_size_violation();
  113|       |      }
  114|       |   }
  115|   102k|}
_ZN5Botan6ranges25assert_equal_byte_lengthsITkNS0_14spanable_rangeENSt3__14spanIhLm18446744073709551615EEETpTkNS0_14spanable_rangeEJS4_S4_EEEvRKT_DpRKT0_QgtsZT0_Li0E:
  100|   102k|{
  101|   102k|   const std::span s0{r0};
  102|       |
  103|       |   if constexpr(statically_spanable_range<R0>) {
  104|       |      constexpr size_t expected_size = s0.size_bytes();
  105|       |      (assert_exact_byte_length<expected_size>(rs), ...);
  106|   102k|   } else {
  107|   102k|      const size_t expected_size = s0.size_bytes();
  108|   102k|      const bool correct_size =
  109|   204k|         ((std::span<const std::ranges::range_value_t<Rs>>{rs}.size_bytes() == expected_size) && ...);
  ------------------
  |  Branch (109:11): [True: 102k, False: 0]
  |  Branch (109:11): [True: 102k, False: 0]
  ------------------
  110|       |
  111|   102k|      if(!correct_size) {
  ------------------
  |  Branch (111:10): [True: 0, False: 102k]
  ------------------
  112|      0|         memory_region_size_violation();
  113|      0|      }
  114|   102k|   }
  115|   102k|}

_ZN5Botan21RandomNumberGenerator10random_vecITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS_16secure_allocatorIhEEEEEEvRT_m:
  255|  12.7k|      void random_vec(T& v, size_t bytes) {
  256|  12.7k|         v.resize(bytes);
  257|  12.7k|         random_vec(v);
  258|  12.7k|      }
_ZN5Botan21RandomNumberGenerator10random_vecENSt3__14spanIhLm18446744073709551615EEE:
  244|  12.7k|      void random_vec(std::span<uint8_t> v) { this->randomize(v); }
_ZN5Botan21RandomNumberGenerator9randomizeENSt3__14spanIhLm18446744073709551615EEE:
   86|  69.6k|      void randomize(std::span<uint8_t> output) { this->fill_bytes_with_input(output, {}); }
_ZN5Botan21RandomNumberGenerator9randomizeEPhm:
   93|  26.4k|      void randomize(uint8_t output[], size_t length) { this->randomize(std::span(output, length)); }
_ZN5Botan21RandomNumberGenerator11add_entropyENSt3__14spanIKhLm18446744073709551615EEE:
  114|  12.7k|      void add_entropy(std::span<const uint8_t> input) { this->fill_bytes_with_input({}, input); }
_ZN5Botan21RandomNumberGenerator9next_byteEv:
  292|  16.7k|      uint8_t next_byte() {
  293|  16.7k|         uint8_t b = 0;
  294|  16.7k|         this->fill_bytes_with_input(std::span(&b, 1), {});
  295|  16.7k|         return b;
  296|  16.7k|      }
_ZN5Botan21RandomNumberGenerator17next_nonzero_byteEv:
  304|  3.97k|      uint8_t next_nonzero_byte() {
  305|  3.97k|         uint8_t b = this->next_byte();
  306|  3.98k|         while(b == 0) {
  ------------------
  |  Branch (306:16): [True: 17, False: 3.97k]
  ------------------
  307|     17|            b = this->next_byte();
  308|     17|         }
  309|  3.97k|         return b;
  310|  3.97k|      }
_ZN5Botan21RandomNumberGeneratorC2Ev:
   57|  25.4k|      RandomNumberGenerator() = default;
_ZN5Botan21RandomNumberGeneratorD2Ev:
   52|  25.4k|      virtual ~RandomNumberGenerator() = default;
_ZN5Botan21RandomNumberGenerator10random_vecITkNS_8concepts21resizable_byte_bufferENSt3__16vectorIhNS_16secure_allocatorIhEEEEQsr3stdE21default_initializableIT_EEES8_m:
  270|  12.7k|      T random_vec(size_t bytes) {
  271|  12.7k|         T result;
  272|  12.7k|         random_vec(result, bytes);
  273|  12.7k|         return result;
  274|  12.7k|      }

_ZN5Botan16secure_allocatorIhE10deallocateEPhm:
  102|  2.84M|      void deallocate(T* p, std::size_t n) { deallocate_memory(p, n, sizeof(T)); }
_ZN5Botan16secure_allocatorIhE8allocateEm:
   95|  2.84M|      T* allocate(std::size_t n) { return static_cast<T*>(allocate_memory(n, sizeof(T))); }
_ZN5Botan16secure_allocatorImE10deallocateEPmm:
  102|   250k|      void deallocate(T* p, std::size_t n) { deallocate_memory(p, n, sizeof(T)); }
_ZN5Botan16secure_allocatorImE8allocateEm:
   95|   250k|      T* allocate(std::size_t n) { return static_cast<T*>(allocate_memory(n, sizeof(T))); }
_ZN5BotanneIhhEEbRKNS_16secure_allocatorIT_EERKNS1_IT0_EE:
  123|   866k|inline bool operator!=(const secure_allocator<T>& /*a*/, const secure_allocator<U>& /*b*/) {
  124|   866k|   return false;
  125|   866k|}
_ZN5Botan7zeroiseIhNS_16secure_allocatorIhEEEEvRNSt3__16vectorIT_T0_EE:
  241|  4.98M|void zeroise(std::vector<T, Alloc>& vec) {
  242|   220M|   for(size_t i = 0; i != vec.size(); ++i) {
  ------------------
  |  Branch (242:22): [True: 215M, False: 4.98M]
  ------------------
  243|   215M|      vec[i] = static_cast<T>(0);
  244|   215M|   }
  245|  4.98M|}
_ZN5Botan16secure_allocatorIjE8allocateEm:
   95|   111k|      T* allocate(std::size_t n) { return static_cast<T*>(allocate_memory(n, sizeof(T))); }
_ZN5Botan16secure_allocatorIjE10deallocateEPjm:
  102|   111k|      void deallocate(T* p, std::size_t n) { deallocate_memory(p, n, sizeof(T)); }
_ZN5Botan3zapIjNS_16secure_allocatorIjEEEEvRNSt3__16vectorIT_T0_EE:
  261|  4.99k|void zap(std::vector<T, Alloc>& vec) {
  262|  4.99k|   zeroise(vec);
  263|  4.99k|   vec.clear();
  264|  4.99k|   vec.shrink_to_fit();
  265|  4.99k|}
_ZN5Botan7zeroiseIjNS_16secure_allocatorIjEEEEvRNSt3__16vectorIT_T0_EE:
  241|  4.99k|void zeroise(std::vector<T, Alloc>& vec) {
  242|  4.99k|   for(size_t i = 0; i != vec.size(); ++i) {
  ------------------
  |  Branch (242:22): [True: 0, False: 4.99k]
  ------------------
  243|      0|      vec[i] = static_cast<T>(0);
  244|      0|   }
  245|  4.99k|}
_ZN5Botan16secure_allocatorItE10deallocateEPtm:
  102|  3.28k|      void deallocate(T* p, std::size_t n) { deallocate_memory(p, n, sizeof(T)); }
_ZN5Botan3zapImNS_16secure_allocatorImEEEEvRNSt3__16vectorIT_T0_EE:
  261|  1.37k|void zap(std::vector<T, Alloc>& vec) {
  262|  1.37k|   zeroise(vec);
  263|  1.37k|   vec.clear();
  264|  1.37k|   vec.shrink_to_fit();
  265|  1.37k|}
_ZN5Botan7zeroiseImNS_16secure_allocatorImEEEEvRNSt3__16vectorIT_T0_EE:
  241|  1.37k|void zeroise(std::vector<T, Alloc>& vec) {
  242|  1.37k|   for(size_t i = 0; i != vec.size(); ++i) {
  ------------------
  |  Branch (242:22): [True: 0, False: 1.37k]
  ------------------
  243|      0|      vec[i] = static_cast<T>(0);
  244|      0|   }
  245|  1.37k|}
_ZN5Botan3zapIhNS_16secure_allocatorIhEEEEvRNSt3__16vectorIT_T0_EE:
  261|    540|void zap(std::vector<T, Alloc>& vec) {
  262|    540|   zeroise(vec);
  263|    540|   vec.clear();
  264|    540|   vec.shrink_to_fit();
  265|    540|}
_ZN5Botan16secure_allocatorItE8allocateEm:
   95|  3.28k|      T* allocate(std::size_t n) { return static_cast<T*>(allocate_memory(n, sizeof(T))); }
_ZN5Botan3zapItNS_16secure_allocatorItEEEEvRNSt3__16vectorIT_T0_EE:
  261|  1.41k|void zap(std::vector<T, Alloc>& vec) {
  262|  1.41k|   zeroise(vec);
  263|  1.41k|   vec.clear();
  264|  1.41k|   vec.shrink_to_fit();
  265|  1.41k|}
_ZN5Botan7zeroiseItNS_16secure_allocatorItEEEEvRNSt3__16vectorIT_T0_EE:
  241|  1.41k|void zeroise(std::vector<T, Alloc>& vec) {
  242|  1.41k|   for(size_t i = 0; i != vec.size(); ++i) {
  ------------------
  |  Branch (242:22): [True: 0, False: 1.41k]
  ------------------
  243|      0|      vec[i] = static_cast<T>(0);
  244|      0|   }
  245|  1.41k|}
_ZN5BotanpLIhNS_16secure_allocatorIhEEmEERNSt3__16vectorIT_T0_EES8_RKNS3_4pairIPS5_T1_EE:
  218|   458k|std::vector<T, Alloc>& operator+=(std::vector<T, Alloc>& out, const std::pair<T*, L>& in) {
  219|   458k|   if(in.second > 0) {
  ------------------
  |  Branch (219:7): [True: 458k, False: 0]
  ------------------
  220|   458k|      out.insert(out.end(), in.first, in.first + in.second);
  221|   458k|   }
  222|   458k|   return out;
  223|   458k|}
_ZN5BotanpLIhNSt3__19allocatorIhEEmEERNS1_6vectorIT_T0_EES8_RKNS1_4pairIPKS5_T1_EE:
  204|  7.33k|std::vector<T, Alloc>& operator+=(std::vector<T, Alloc>& out, const std::pair<const T*, L>& in) {
  205|  7.33k|   if(in.second > 0) {
  ------------------
  |  Branch (205:7): [True: 7.33k, False: 0]
  ------------------
  206|  7.33k|      out.insert(out.end(), in.first, in.first + in.second);
  207|  7.33k|   }
  208|  7.33k|   return out;
  209|  7.33k|}
_ZN5Botan7zeroiseIhNSt3__19allocatorIhEEEEvRNS1_6vectorIT_T0_EE:
  241|   353k|void zeroise(std::vector<T, Alloc>& vec) {
  242|  6.00M|   for(size_t i = 0; i != vec.size(); ++i) {
  ------------------
  |  Branch (242:22): [True: 5.64M, False: 353k]
  ------------------
  243|  5.64M|      vec[i] = static_cast<T>(0);
  244|  5.64M|   }
  245|   353k|}

_ZN5Botan12Stateful_RNGC2ERNS_21RandomNumberGeneratorEm:
   49|  12.7k|            m_underlying_rng(&rng), m_reseed_interval(reseed_interval) {}
_ZNK5Botan12Stateful_RNG13accepts_inputEv:
   91|  43.2k|      bool accepts_input() const final { return true; }

_ZN5Botan12StreamCipher6cipherEPKhPhm:
   61|  1.35M|      void cipher(const uint8_t in[], uint8_t out[], size_t len) { cipher_bytes(in, out, len); }
_ZN5Botan12StreamCipher8encipherENSt3__14spanIhLm18446744073709551615EEE:
  124|   105k|      void encipher(std::span<uint8_t> inout) { cipher(inout.data(), inout.data(), inout.size()); }
_ZN5Botan12StreamCipher6set_ivEPKhm:
  168|   350k|      void set_iv(const uint8_t iv[], size_t iv_len) { set_iv_bytes(iv, iv_len); }
_ZN5Botan12StreamCipher6set_ivENSt3__14spanIKhLm18446744073709551615EEE:
  175|  3.30k|      void set_iv(std::span<const uint8_t> iv) { set_iv_bytes(iv.data(), iv.size()); }

_ZN5Botan18unwrap_strong_typeIRtEEDcOT_:
  328|  4.65M|[[nodiscard]] constexpr decltype(auto) unwrap_strong_type(T&& t) {
  329|  4.65M|   if constexpr(!concepts::strong_type<std::remove_cvref_t<T>>) {
  330|       |      // If the parameter type isn't a strong type, return it as is.
  331|  4.65M|      return std::forward<T>(t);
  332|       |   } else {
  333|       |      // Unwrap the strong type and return the underlying value.
  334|       |      return std::forward<T>(t).get();
  335|       |   }
  336|  4.65M|}
_ZN5Botan18unwrap_strong_typeIRjEEDcOT_:
  328|  63.8M|[[nodiscard]] constexpr decltype(auto) unwrap_strong_type(T&& t) {
  329|  63.8M|   if constexpr(!concepts::strong_type<std::remove_cvref_t<T>>) {
  330|       |      // If the parameter type isn't a strong type, return it as is.
  331|  63.8M|      return std::forward<T>(t);
  332|       |   } else {
  333|       |      // Unwrap the strong type and return the underlying value.
  334|       |      return std::forward<T>(t).get();
  335|       |   }
  336|  63.8M|}
_ZN5Botan18unwrap_strong_typeIRmEEDcOT_:
  328|  56.0M|[[nodiscard]] constexpr decltype(auto) unwrap_strong_type(T&& t) {
  329|  56.0M|   if constexpr(!concepts::strong_type<std::remove_cvref_t<T>>) {
  330|       |      // If the parameter type isn't a strong type, return it as is.
  331|  56.0M|      return std::forward<T>(t);
  332|       |   } else {
  333|       |      // Unwrap the strong type and return the underlying value.
  334|       |      return std::forward<T>(t).get();
  335|       |   }
  336|  56.0M|}
_ZN5Botan16wrap_strong_typeIjRjQoosr3stdE18constructible_fromIT_T0_Eaasr8conceptsE11strong_typeIS2_Esr3stdE18constructible_fromINS2_12wrapped_typeES3_EEEDcOS3_:
  353|   541M|[[nodiscard]] constexpr decltype(auto) wrap_strong_type(ParamT&& t) {
  354|   541M|   if constexpr(std::same_as<std::remove_cvref_t<ParamT>, T>) {
  355|       |      // Noop, if the parameter type already is the desired return type.
  356|   541M|      return std::forward<ParamT>(t);
  357|       |   } else if constexpr(std::constructible_from<T, ParamT>) {
  358|       |      // Implicit conversion from the parameter type to the return type.
  359|       |      return T{std::forward<ParamT>(t)};
  360|       |   } else {
  361|       |      // Explicitly calling the wrapped type's constructor to support
  362|       |      // implicit conversions on types that mark their constructors as explicit.
  363|       |      static_assert(concepts::strong_type<T> && std::constructible_from<typename T::wrapped_type, ParamT>);
  364|       |      return T{typename T::wrapped_type{std::forward<ParamT>(t)}};
  365|       |   }
  366|   541M|}
_ZN5Botan16wrap_strong_typeImRmQoosr3stdE18constructible_fromIT_T0_Eaasr8conceptsE11strong_typeIS2_Esr3stdE18constructible_fromINS2_12wrapped_typeES3_EEEDcOS3_:
  353|   189M|[[nodiscard]] constexpr decltype(auto) wrap_strong_type(ParamT&& t) {
  354|   189M|   if constexpr(std::same_as<std::remove_cvref_t<ParamT>, T>) {
  355|       |      // Noop, if the parameter type already is the desired return type.
  356|   189M|      return std::forward<ParamT>(t);
  357|       |   } else if constexpr(std::constructible_from<T, ParamT>) {
  358|       |      // Implicit conversion from the parameter type to the return type.
  359|       |      return T{std::forward<ParamT>(t)};
  360|       |   } else {
  361|       |      // Explicitly calling the wrapped type's constructor to support
  362|       |      // implicit conversions on types that mark their constructors as explicit.
  363|       |      static_assert(concepts::strong_type<T> && std::constructible_from<typename T::wrapped_type, ParamT>);
  364|       |      return T{typename T::wrapped_type{std::forward<ParamT>(t)}};
  365|       |   }
  366|   189M|}
_ZN5Botan16wrap_strong_typeItRtQoosr3stdE18constructible_fromIT_T0_Eaasr8conceptsE11strong_typeIS2_Esr3stdE18constructible_fromINS2_12wrapped_typeES3_EEEDcOS3_:
  353|  4.65M|[[nodiscard]] constexpr decltype(auto) wrap_strong_type(ParamT&& t) {
  354|  4.65M|   if constexpr(std::same_as<std::remove_cvref_t<ParamT>, T>) {
  355|       |      // Noop, if the parameter type already is the desired return type.
  356|  4.65M|      return std::forward<ParamT>(t);
  357|       |   } else if constexpr(std::constructible_from<T, ParamT>) {
  358|       |      // Implicit conversion from the parameter type to the return type.
  359|       |      return T{std::forward<ParamT>(t)};
  360|       |   } else {
  361|       |      // Explicitly calling the wrapped type's constructor to support
  362|       |      // implicit conversions on types that mark their constructors as explicit.
  363|       |      static_assert(concepts::strong_type<T> && std::constructible_from<typename T::wrapped_type, ParamT>);
  364|       |      return T{typename T::wrapped_type{std::forward<ParamT>(t)}};
  365|       |   }
  366|  4.65M|}

_ZNK5Botan18SymmetricAlgorithm15valid_keylengthEm:
  143|   251k|      bool valid_keylength(size_t length) const { return key_spec().valid_keylength(length); }
_ZNK5Botan24Key_Length_Specification15valid_keylengthEm:
   44|   251k|      bool valid_keylength(size_t length) const {
   45|   251k|         return ((length >= m_min_keylen) && (length <= m_max_keylen) && (length % m_keylen_mod == 0));
  ------------------
  |  Branch (45:18): [True: 251k, False: 0]
  |  Branch (45:46): [True: 251k, False: 0]
  |  Branch (45:74): [True: 251k, False: 0]
  ------------------
   46|   251k|      }
_ZN5Botan24Key_Length_SpecificationC2Em:
   28|  3.30k|      explicit Key_Length_Specification(size_t keylen) : m_min_keylen(keylen), m_max_keylen(keylen), m_keylen_mod(1) {}
_ZN5Botan24Key_Length_SpecificationC2Emmm:
   37|   248k|            m_min_keylen(min_k), m_max_keylen(max_k > 0 ? max_k : min_k), m_keylen_mod(k_mod) {}
  ------------------
  |  Branch (37:47): [True: 193k, False: 55.0k]
  ------------------
_ZN5Botan18SymmetricAlgorithm7set_keyEPKhm:
  162|  27.8k|      void set_key(const uint8_t key[], size_t length) { set_key(std::span{key, length}); }
_ZNK5Botan18SymmetricAlgorithm23assert_key_material_setEv:
  180|  35.8M|      void assert_key_material_set() const { assert_key_material_set(has_keying_material()); }
_ZNK5Botan18SymmetricAlgorithm23assert_key_material_setEb:
  186|  35.8M|      void assert_key_material_set(bool predicate) const {
  187|  35.8M|         if(!predicate) {
  ------------------
  |  Branch (187:13): [True: 0, False: 35.8M]
  ------------------
  188|      0|            throw_key_not_set_error();
  189|      0|         }
  190|  35.8M|      }
_ZN5Botan18SymmetricAlgorithmD2Ev:
   90|   103k|      virtual ~SymmetricAlgorithm() = default;
_ZN5Botan18SymmetricAlgorithmC2Ev:
   88|   103k|      SymmetricAlgorithm() = default;

_ZN5Botan3OID9from_nameENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   66|  6.29k|std::optional<OID> OID::from_name(std::string_view name) {
   67|  6.29k|   if(name.empty()) {
  ------------------
  |  Branch (67:7): [True: 0, False: 6.29k]
  ------------------
   68|      0|      throw Invalid_Argument("OID::from_name argument must be non-empty");
   69|      0|   }
   70|       |
   71|  6.29k|   OID o = OID_Map::global_registry().str2oid(name);
   72|  6.29k|   if(o.has_value()) {
  ------------------
  |  Branch (72:7): [True: 6.29k, False: 0]
  ------------------
   73|  6.29k|      return std::optional(o);
   74|  6.29k|   }
   75|       |
   76|      0|   return std::nullopt;
   77|  6.29k|}
_ZN5Botan3OIDC2ESt16initializer_listIjE:
   98|  6.36k|OID::OID(std::initializer_list<uint32_t> init) : m_id(init) {
   99|  6.36k|   oid_valid_check(m_id);
  100|  6.36k|}
_ZNK5Botan3OID15registered_nameEv:
  149|      3|std::optional<std::string> OID::registered_name() const {
  150|      3|   return OID_Map::global_registry().oid2str(*this);
  151|      3|}
_ZNK5Botan3OID7matchesESt16initializer_listIjE:
  157|      3|bool OID::matches(std::initializer_list<uint32_t> other) const {
  158|       |   // TODO: once all target compilers support it, use std::ranges::equal
  159|      3|   return std::equal(m_id.begin(), m_id.end(), other.begin(), other.end());
  160|      3|}
_ZNK5Botan3OID9hash_codeEv:
  162|      7|uint64_t OID::hash_code() const {
  163|       |   // If this is changed also update gen_oids.py to match
  164|      7|   uint64_t hash = 0x621F302327D9A49A;
  165|     50|   for(auto id : m_id) {
  ------------------
  |  Branch (165:16): [True: 50, False: 7]
  ------------------
  166|     50|      hash *= 193;
  167|     50|      hash += id;
  168|     50|   }
  169|      7|   return hash;
  170|      7|}
_ZNK5Botan3OID11encode_intoERNS_11DER_EncoderE:
  185|      3|void OID::encode_into(DER_Encoder& der) const {
  186|      3|   if(m_id.size() < 2) {
  ------------------
  |  Branch (186:7): [True: 0, False: 3]
  ------------------
  187|      0|      throw Invalid_Argument("OID::encode_into: OID is invalid");
  188|      0|   }
  189|       |
  190|      3|   auto append = [](std::vector<uint8_t>& encoding, uint32_t z) {
  191|      3|      if(z <= 0x7F) {
  192|      3|         encoding.push_back(static_cast<uint8_t>(z));
  193|      3|      } else {
  194|      3|         const size_t z7 = (high_bit(z) + 7 - 1) / 7;
  195|       |
  196|      3|         for(size_t j = 0; j != z7; ++j) {
  197|      3|            uint8_t zp = static_cast<uint8_t>(z >> (7 * (z7 - j - 1)) & 0x7F);
  198|       |
  199|      3|            if(j != z7 - 1) {
  200|      3|               zp |= 0x80;
  201|      3|            }
  202|       |
  203|      3|            encoding.push_back(zp);
  204|      3|         }
  205|      3|      }
  206|      3|   };
  207|       |
  208|      3|   std::vector<uint8_t> encoding;
  209|       |
  210|       |   // We know 40 * root can't overflow because root is between 0 and 2
  211|      3|   auto first = checked_add(40 * m_id[0], m_id[1]);
  212|      3|   BOTAN_ASSERT_NOMSG(first.has_value());
  ------------------
  |  |   77|      3|   do {                                                                     \
  |  |   78|      3|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      3|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      3|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3]
  |  |  ------------------
  ------------------
  213|       |
  214|      3|   append(encoding, *first);
  215|       |
  216|     15|   for(size_t i = 2; i != m_id.size(); ++i) {
  ------------------
  |  Branch (216:22): [True: 12, False: 3]
  ------------------
  217|     12|      append(encoding, m_id[i]);
  218|     12|   }
  219|      3|   der.add_object(ASN1_Type::ObjectId, ASN1_Class::Universal, encoding);
  220|      3|}
asn1_oid.cpp:_ZN5Botan12_GLOBAL__N_115oid_valid_checkENSt3__14spanIKjLm18446744073709551615EEE:
   26|  6.36k|void oid_valid_check(std::span<const uint32_t> oid) {
   27|  6.36k|   BOTAN_ARG_CHECK(oid.size() >= 2, "OID too short to be valid");
  ------------------
  |  |   35|  6.36k|   do {                                                          \
  |  |   36|  6.36k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.36k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.36k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.36k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.36k]
  |  |  ------------------
  ------------------
   28|  6.36k|   BOTAN_ARG_CHECK(oid[0] <= 2, "OID root out of range");
  ------------------
  |  |   35|  6.36k|   do {                                                          \
  |  |   36|  6.36k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.36k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.36k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.36k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.36k]
  |  |  ------------------
  ------------------
   29|  6.36k|   BOTAN_ARG_CHECK(oid[1] <= 39 || oid[0] == 2, "OID second arc too large");
  ------------------
  |  |   35|  6.36k|   do {                                                          \
  |  |   36|  6.36k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.36k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 6.36k, False: 0]
  |  |  |  Branch (37:12): [True: 0, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.36k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.36k]
  |  |  ------------------
  ------------------
   30|       |   // This last is a limitation of using 32 bit integers when decoding
   31|       |   // not a limitation of ASN.1 object identifiers in general
   32|  6.36k|   BOTAN_ARG_CHECK(oid[1] <= 0xFFFFFFAF, "OID second arc too large");
  ------------------
  |  |   35|  6.36k|   do {                                                          \
  |  |   36|  6.36k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.36k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.36k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.36k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.36k]
  |  |  ------------------
  ------------------
   33|  6.36k|}
asn1_oid.cpp:_ZZNK5Botan3OID11encode_intoERNS_11DER_EncoderEENK3$_0clERNSt3__16vectorIhNS4_9allocatorIhEEEEj:
  190|     15|   auto append = [](std::vector<uint8_t>& encoding, uint32_t z) {
  191|     15|      if(z <= 0x7F) {
  ------------------
  |  Branch (191:10): [True: 9, False: 6]
  ------------------
  192|      9|         encoding.push_back(static_cast<uint8_t>(z));
  193|      9|      } else {
  194|      6|         const size_t z7 = (high_bit(z) + 7 - 1) / 7;
  195|       |
  196|     18|         for(size_t j = 0; j != z7; ++j) {
  ------------------
  |  Branch (196:28): [True: 12, False: 6]
  ------------------
  197|     12|            uint8_t zp = static_cast<uint8_t>(z >> (7 * (z7 - j - 1)) & 0x7F);
  198|       |
  199|     12|            if(j != z7 - 1) {
  ------------------
  |  Branch (199:16): [True: 6, False: 6]
  ------------------
  200|      6|               zp |= 0x80;
  201|      6|            }
  202|       |
  203|     12|            encoding.push_back(zp);
  204|     12|         }
  205|      6|      }
  206|     15|   };

_ZN5Botan11DER_EncoderC2ERNSt3__16vectorIhNS1_9allocatorIhEEEE:
   89|      3|DER_Encoder::DER_Encoder(std::vector<uint8_t>& vec) {
   90|      3|   m_append_output = [&vec](const uint8_t b[], size_t l) {
   91|      3|      if(l > 0) {
   92|      3|         vec.insert(vec.end(), b, b + l);
   93|      3|      }
   94|      3|   };
   95|      3|}
_ZN5Botan11DER_Encoder10add_objectENS_9ASN1_TypeENS_10ASN1_ClassEPKhm:
  285|      3|DER_Encoder& DER_Encoder::add_object(ASN1_Type type_tag, ASN1_Class class_tag, const uint8_t rep[], size_t length) {
  286|      3|   std::vector<uint8_t> hdr;
  287|      3|   encode_tag(hdr, type_tag, class_tag);
  288|      3|   encode_length(hdr, length);
  289|       |
  290|      3|   if(!m_subsequences.empty()) {
  ------------------
  |  Branch (290:7): [True: 0, False: 3]
  ------------------
  291|      0|      m_subsequences[m_subsequences.size() - 1].add_bytes(hdr.data(), hdr.size(), rep, length);
  292|      3|   } else if(m_append_output) {
  ------------------
  |  Branch (292:14): [True: 3, False: 0]
  ------------------
  293|      3|      m_append_output(hdr.data(), hdr.size());
  294|      3|      m_append_output(rep, length);
  295|      3|   } else {
  296|      0|      m_default_outbuf += hdr;
  297|      0|      m_default_outbuf += std::make_pair(rep, length);
  298|      0|   }
  299|       |
  300|      3|   return (*this);
  301|      3|}
_ZN5Botan11DER_Encoder6encodeERKNS_11ASN1_ObjectE:
  467|      3|DER_Encoder& DER_Encoder::encode(const ASN1_Object& obj) {
  468|      3|   obj.encode_into(*this);
  469|      3|   return (*this);
  470|      3|}
der_enc.cpp:_ZN5Botan12_GLOBAL__N_110encode_tagERNSt3__16vectorIhNS1_9allocatorIhEEEENS_9ASN1_TypeENS_10ASN1_ClassE:
   26|      3|void encode_tag(std::vector<uint8_t>& encoded_tag, ASN1_Type type_tag_e, ASN1_Class class_tag_e) {
   27|      3|   const uint32_t type_tag = static_cast<uint32_t>(type_tag_e);
   28|      3|   const uint32_t class_tag = static_cast<uint32_t>(class_tag_e);
   29|       |
   30|      3|   if((class_tag | 0xE0) != 0xE0) {
  ------------------
  |  Branch (30:7): [True: 0, False: 3]
  ------------------
   31|      0|      throw Encoding_Error(fmt("DER_Encoder: Invalid class tag {}", std::to_string(class_tag)));
   32|      0|   }
   33|       |
   34|      3|   if(type_tag <= 30) {
  ------------------
  |  Branch (34:7): [True: 3, False: 0]
  ------------------
   35|      3|      encoded_tag.push_back(static_cast<uint8_t>(type_tag | class_tag));
   36|      3|   } else {
   37|      0|      size_t blocks = high_bit(static_cast<uint32_t>(type_tag)) + 6;
   38|      0|      blocks = (blocks - (blocks % 7)) / 7;
   39|       |
   40|      0|      BOTAN_ASSERT_NOMSG(blocks > 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
   41|       |
   42|      0|      encoded_tag.push_back(static_cast<uint8_t>(class_tag | 0x1F));
   43|      0|      for(size_t i = 0; i != blocks - 1; ++i) {
  ------------------
  |  Branch (43:25): [True: 0, False: 0]
  ------------------
   44|      0|         encoded_tag.push_back(0x80 | ((type_tag >> 7 * (blocks - i - 1)) & 0x7F));
   45|      0|      }
   46|      0|      encoded_tag.push_back(type_tag & 0x7F);
   47|      0|   }
   48|      3|}
der_enc.cpp:_ZN5Botan12_GLOBAL__N_113encode_lengthERNSt3__16vectorIhNS1_9allocatorIhEEEEm:
   53|      3|void encode_length(std::vector<uint8_t>& encoded_length, size_t length) {
   54|      3|   if(length <= 127) {
  ------------------
  |  Branch (54:7): [True: 3, False: 0]
  ------------------
   55|      3|      encoded_length.push_back(static_cast<uint8_t>(length));
   56|      3|   } else {
   57|      0|      const size_t bytes_needed = significant_bytes(length);
   58|       |
   59|      0|      encoded_length.push_back(static_cast<uint8_t>(0x80 | bytes_needed));
   60|       |
   61|      0|      for(size_t i = sizeof(length) - bytes_needed; i < sizeof(length); ++i) {
  ------------------
  |  Branch (61:53): [True: 0, False: 0]
  ------------------
   62|      0|         encoded_length.push_back(get_byte_var(i, length));
   63|      0|      }
   64|      0|   }
   65|      3|}
der_enc.cpp:_ZZN5Botan11DER_EncoderC1ERNSt3__16vectorIhNS1_9allocatorIhEEEEENK3$_0clEPKhm:
   90|      6|   m_append_output = [&vec](const uint8_t b[], size_t l) {
   91|      6|      if(l > 0) {
  ------------------
  |  Branch (91:10): [True: 6, False: 0]
  ------------------
   92|      6|         vec.insert(vec.end(), b, b + l);
   93|      6|      }
   94|      6|   };

_ZN5Botan7OID_MapC2Ev:
   11|      1|OID_Map::OID_Map() {
   12|      1|   m_str2oid = OID_Map::load_str2oid_map();
   13|      1|   m_oid2str = OID_Map::load_oid2str_map();
   14|      1|}
_ZN5Botan7OID_Map15global_registryEv:
   16|  6.29k|OID_Map& OID_Map::global_registry() {
   17|  6.29k|   static OID_Map g_map;
   18|  6.29k|   return g_map;
   19|  6.29k|}
_ZN5Botan7OID_Map7oid2strERKNS_3OIDE:
   73|      3|std::optional<std::string> OID_Map::oid2str(const OID& oid) {
   74|      3|   if(auto name = lookup_static_oid(oid)) {
  ------------------
  |  Branch (74:12): [True: 3, False: 0]
  ------------------
   75|      3|      return std::string(*name);
   76|      3|   }
   77|       |
   78|      0|   const lock_guard_type<mutex_type> lock(m_mutex);
   79|       |
   80|      0|   auto i = m_oid2str.find(oid);
   81|      0|   if(i != m_oid2str.end()) {
  ------------------
  |  Branch (81:7): [True: 0, False: 0]
  ------------------
   82|      0|      return i->second;
   83|      0|   }
   84|       |
   85|      0|   return {};
   86|      0|}
_ZN5Botan7OID_Map7str2oidENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   88|  6.29k|OID OID_Map::str2oid(std::string_view str) {
   89|  6.29k|   if(auto oid = lookup_static_oid_name(str)) {
  ------------------
  |  Branch (89:12): [True: 6.29k, False: 0]
  ------------------
   90|  6.29k|      return std::move(*oid);
   91|  6.29k|   }
   92|       |
   93|      0|   const lock_guard_type<mutex_type> lock(m_mutex);
   94|      0|   auto i = m_str2oid.find(std::string(str));
   95|      0|   if(i != m_str2oid.end()) {
  ------------------
  |  Branch (95:7): [True: 0, False: 0]
  ------------------
   96|      0|      return i->second;
   97|      0|   }
   98|       |
   99|      0|   return OID();
  100|      0|}

_ZN5Botan7OID_Map17lookup_static_oidERKNS_3OIDE:
   48|      3|std::optional<std::string_view> OID_Map::lookup_static_oid(const OID& oid) {
   49|      3|   const uint32_t hc = static_cast<uint32_t>(oid.hash_code() % 858701);
   50|       |
   51|      3|   switch(hc) {
   52|      0|      case 0x01506:
  ------------------
  |  Branch (52:7): [True: 0, False: 3]
  ------------------
   53|      0|         return if_match(oid, {1, 2, 840, 10045, 4, 3, 1}, "ECDSA/SHA-224");
   54|      0|      case 0x01507:
  ------------------
  |  Branch (54:7): [True: 0, False: 3]
  ------------------
   55|      0|         return if_match(oid, {1, 2, 840, 10045, 4, 3, 2}, "ECDSA/SHA-256");
   56|      0|      case 0x01508:
  ------------------
  |  Branch (56:7): [True: 0, False: 3]
  ------------------
   57|      0|         return if_match(oid, {1, 2, 840, 10045, 4, 3, 3}, "ECDSA/SHA-384");
   58|      0|      case 0x01509:
  ------------------
  |  Branch (58:7): [True: 0, False: 3]
  ------------------
   59|      0|         return if_match(oid, {1, 2, 840, 10045, 4, 3, 4}, "ECDSA/SHA-512");
   60|      0|      case 0x04C1E:
  ------------------
  |  Branch (60:7): [True: 0, False: 3]
  ------------------
   61|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 3029, 1, 2, 1}, "ElGamal");
   62|      0|      case 0x04E61:
  ------------------
  |  Branch (62:7): [True: 0, False: 3]
  ------------------
   63|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 3029, 1, 5, 1}, "OpenPGP.Curve25519");
   64|      0|      case 0x0779B:
  ------------------
  |  Branch (64:7): [True: 0, False: 3]
  ------------------
   65|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 5}, "MD5");
   66|      0|      case 0x0779D:
  ------------------
  |  Branch (66:7): [True: 0, False: 3]
  ------------------
   67|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 7}, "HMAC(SHA-1)");
   68|      0|      case 0x0779E:
  ------------------
  |  Branch (68:7): [True: 0, False: 3]
  ------------------
   69|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 8}, "HMAC(SHA-224)");
   70|      0|      case 0x0779F:
  ------------------
  |  Branch (70:7): [True: 0, False: 3]
  ------------------
   71|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 9}, "HMAC(SHA-256)");
   72|      0|      case 0x077A0:
  ------------------
  |  Branch (72:7): [True: 0, False: 3]
  ------------------
   73|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 10}, "HMAC(SHA-384)");
   74|      0|      case 0x077A1:
  ------------------
  |  Branch (74:7): [True: 0, False: 3]
  ------------------
   75|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 11}, "HMAC(SHA-512)");
   76|      0|      case 0x077A3:
  ------------------
  |  Branch (76:7): [True: 0, False: 3]
  ------------------
   77|      0|         return if_match(oid, {1, 2, 840, 113549, 2, 13}, "HMAC(SHA-512-256)");
   78|      0|      case 0x0785E:
  ------------------
  |  Branch (78:7): [True: 0, False: 3]
  ------------------
   79|      0|         return if_match(oid, {1, 2, 840, 113549, 3, 7}, "TripleDES/CBC");
   80|      0|      case 0x0C904:
  ------------------
  |  Branch (80:7): [True: 0, False: 3]
  ------------------
   81|      0|         return if_match(oid, {1, 0, 14888, 3, 0, 5}, "ECKCDSA");
   82|      0|      case 0x11547:
  ------------------
  |  Branch (82:7): [True: 0, False: 3]
  ------------------
   83|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 1}, "SphincsPlus-shake-128s-r3.1");
   84|      0|      case 0x11548:
  ------------------
  |  Branch (84:7): [True: 0, False: 3]
  ------------------
   85|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 2}, "SphincsPlus-shake-128f-r3.1");
   86|      0|      case 0x11549:
  ------------------
  |  Branch (86:7): [True: 0, False: 3]
  ------------------
   87|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 3}, "SphincsPlus-shake-192s-r3.1");
   88|      0|      case 0x1154A:
  ------------------
  |  Branch (88:7): [True: 0, False: 3]
  ------------------
   89|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 4}, "SphincsPlus-shake-192f-r3.1");
   90|      0|      case 0x1154B:
  ------------------
  |  Branch (90:7): [True: 0, False: 3]
  ------------------
   91|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 5}, "SphincsPlus-shake-256s-r3.1");
   92|      0|      case 0x1154C:
  ------------------
  |  Branch (92:7): [True: 0, False: 3]
  ------------------
   93|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 6}, "SphincsPlus-shake-256f-r3.1");
   94|      0|      case 0x11608:
  ------------------
  |  Branch (94:7): [True: 0, False: 3]
  ------------------
   95|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 1}, "SphincsPlus-sha2-128s-r3.1");
   96|      0|      case 0x11609:
  ------------------
  |  Branch (96:7): [True: 0, False: 3]
  ------------------
   97|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 2}, "SphincsPlus-sha2-128f-r3.1");
   98|      0|      case 0x1160A:
  ------------------
  |  Branch (98:7): [True: 0, False: 3]
  ------------------
   99|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 3}, "SphincsPlus-sha2-192s-r3.1");
  100|      0|      case 0x1160B:
  ------------------
  |  Branch (100:7): [True: 0, False: 3]
  ------------------
  101|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 4}, "SphincsPlus-sha2-192f-r3.1");
  102|      0|      case 0x1160C:
  ------------------
  |  Branch (102:7): [True: 0, False: 3]
  ------------------
  103|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 5}, "SphincsPlus-sha2-256s-r3.1");
  104|      0|      case 0x1160D:
  ------------------
  |  Branch (104:7): [True: 0, False: 3]
  ------------------
  105|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 6}, "SphincsPlus-sha2-256f-r3.1");
  106|      0|      case 0x116C9:
  ------------------
  |  Branch (106:7): [True: 0, False: 3]
  ------------------
  107|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 1}, "SphincsPlus-haraka-128s-r3.1");
  108|      0|      case 0x116CA:
  ------------------
  |  Branch (108:7): [True: 0, False: 3]
  ------------------
  109|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 2}, "SphincsPlus-haraka-128f-r3.1");
  110|      0|      case 0x116CB:
  ------------------
  |  Branch (110:7): [True: 0, False: 3]
  ------------------
  111|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 3}, "SphincsPlus-haraka-192s-r3.1");
  112|      0|      case 0x116CC:
  ------------------
  |  Branch (112:7): [True: 0, False: 3]
  ------------------
  113|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 4}, "SphincsPlus-haraka-192f-r3.1");
  114|      0|      case 0x116CD:
  ------------------
  |  Branch (114:7): [True: 0, False: 3]
  ------------------
  115|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 5}, "SphincsPlus-haraka-256s-r3.1");
  116|      0|      case 0x116CE:
  ------------------
  |  Branch (116:7): [True: 0, False: 3]
  ------------------
  117|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 6}, "SphincsPlus-haraka-256f-r3.1");
  118|      0|      case 0x1533B:
  ------------------
  |  Branch (118:7): [True: 0, False: 3]
  ------------------
  119|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 104, 2}, "SM4/CBC");
  120|      0|      case 0x15341:
  ------------------
  |  Branch (120:7): [True: 0, False: 3]
  ------------------
  121|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 104, 8}, "SM4/GCM");
  122|      0|      case 0x1539D:
  ------------------
  |  Branch (122:7): [True: 0, False: 3]
  ------------------
  123|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 104, 100}, "SM4/OCB");
  124|      0|      case 0x187D7:
  ------------------
  |  Branch (124:7): [True: 0, False: 3]
  ------------------
  125|      0|         return if_match(oid, {1, 3, 14, 3, 2, 7}, "DES/CBC");
  126|      0|      case 0x187EA:
  ------------------
  |  Branch (126:7): [True: 0, False: 3]
  ------------------
  127|      0|         return if_match(oid, {1, 3, 14, 3, 2, 26}, "SHA-1");
  128|      0|      case 0x19933:
  ------------------
  |  Branch (128:7): [True: 0, False: 3]
  ------------------
  129|      0|         return if_match(oid, {1, 3, 132, 0, 8}, "secp160r1");
  130|      0|      case 0x19934:
  ------------------
  |  Branch (130:7): [True: 0, False: 3]
  ------------------
  131|      0|         return if_match(oid, {1, 3, 132, 0, 9}, "secp160k1");
  132|      1|      case 0x19935:
  ------------------
  |  Branch (132:7): [True: 1, False: 2]
  ------------------
  133|      1|         return if_match(oid, {1, 3, 132, 0, 10}, "secp256k1");
  134|      0|      case 0x19949:
  ------------------
  |  Branch (134:7): [True: 0, False: 3]
  ------------------
  135|      0|         return if_match(oid, {1, 3, 132, 0, 30}, "secp160r2");
  136|      0|      case 0x1994A:
  ------------------
  |  Branch (136:7): [True: 0, False: 3]
  ------------------
  137|      0|         return if_match(oid, {1, 3, 132, 0, 31}, "secp192k1");
  138|      0|      case 0x1994B:
  ------------------
  |  Branch (138:7): [True: 0, False: 3]
  ------------------
  139|      0|         return if_match(oid, {1, 3, 132, 0, 32}, "secp224k1");
  140|      0|      case 0x1994C:
  ------------------
  |  Branch (140:7): [True: 0, False: 3]
  ------------------
  141|      0|         return if_match(oid, {1, 3, 132, 0, 33}, "secp224r1");
  142|      0|      case 0x1994D:
  ------------------
  |  Branch (142:7): [True: 0, False: 3]
  ------------------
  143|      0|         return if_match(oid, {1, 3, 132, 0, 34}, "secp384r1");
  144|      0|      case 0x1994E:
  ------------------
  |  Branch (144:7): [True: 0, False: 3]
  ------------------
  145|      0|         return if_match(oid, {1, 3, 132, 0, 35}, "secp521r1");
  146|      0|      case 0x199F8:
  ------------------
  |  Branch (146:7): [True: 0, False: 3]
  ------------------
  147|      0|         return if_match(oid, {1, 3, 132, 1, 12}, "ECDH");
  148|      0|      case 0x1E7BF:
  ------------------
  |  Branch (148:7): [True: 0, False: 3]
  ------------------
  149|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 301, 1}, "SM2");
  150|      0|      case 0x1E7C0:
  ------------------
  |  Branch (150:7): [True: 0, False: 3]
  ------------------
  151|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 301, 2}, "SM2_Kex");
  152|      0|      case 0x1E7C1:
  ------------------
  |  Branch (152:7): [True: 0, False: 3]
  ------------------
  153|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 301, 3}, "SM2_Enc");
  154|      0|      case 0x21960:
  ------------------
  |  Branch (154:7): [True: 0, False: 3]
  ------------------
  155|      0|         return if_match(oid, {1, 3, 36, 3, 3, 1, 2}, "RSA/PKCS1v15(RIPEMD-160)");
  156|      0|      case 0x2198A:
  ------------------
  |  Branch (156:7): [True: 0, False: 3]
  ------------------
  157|      0|         return if_match(oid, {1, 2, 840, 113533, 7, 66, 10}, "CAST-128/CBC");
  158|      0|      case 0x2198F:
  ------------------
  |  Branch (158:7): [True: 0, False: 3]
  ------------------
  159|      0|         return if_match(oid, {1, 2, 840, 113533, 7, 66, 15}, "KeyWrap.CAST-128");
  160|      0|      case 0x227C0:
  ------------------
  |  Branch (160:7): [True: 0, False: 3]
  ------------------
  161|      0|         return if_match(oid, {1, 3, 101, 110}, "X25519");
  162|      0|      case 0x227C1:
  ------------------
  |  Branch (162:7): [True: 0, False: 3]
  ------------------
  163|      0|         return if_match(oid, {1, 3, 101, 111}, "X448");
  164|      0|      case 0x227C2:
  ------------------
  |  Branch (164:7): [True: 0, False: 3]
  ------------------
  165|      0|         return if_match(oid, {1, 3, 101, 112}, "Ed25519");
  166|      0|      case 0x227C3:
  ------------------
  |  Branch (166:7): [True: 0, False: 3]
  ------------------
  167|      0|         return if_match(oid, {1, 3, 101, 113}, "Ed448");
  168|      0|      case 0x27565:
  ------------------
  |  Branch (168:7): [True: 0, False: 3]
  ------------------
  169|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 48, 1, 1}, "PKIX.OCSP.BasicResponse");
  170|      0|      case 0x27566:
  ------------------
  |  Branch (170:7): [True: 0, False: 3]
  ------------------
  171|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 48, 1, 2}, "PKIX.OCSP.Nonce");
  172|      0|      case 0x27569:
  ------------------
  |  Branch (172:7): [True: 0, False: 3]
  ------------------
  173|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 48, 1, 5}, "PKIX.OCSP.NoCheck");
  174|      0|      case 0x29F7C:
  ------------------
  |  Branch (174:7): [True: 0, False: 3]
  ------------------
  175|      0|         return if_match(oid, {1, 2, 410, 200004, 1, 100, 4, 3}, "ECKCDSA/SHA-1");
  176|      0|      case 0x29F7D:
  ------------------
  |  Branch (176:7): [True: 0, False: 3]
  ------------------
  177|      0|         return if_match(oid, {1, 2, 410, 200004, 1, 100, 4, 4}, "ECKCDSA/SHA-224");
  178|      0|      case 0x29F7E:
  ------------------
  |  Branch (178:7): [True: 0, False: 3]
  ------------------
  179|      0|         return if_match(oid, {1, 2, 410, 200004, 1, 100, 4, 5}, "ECKCDSA/SHA-256");
  180|      0|      case 0x2AC3B:
  ------------------
  |  Branch (180:7): [True: 0, False: 3]
  ------------------
  181|      0|         return if_match(oid, {2, 5, 29, 32, 0}, "X509v3.AnyPolicy");
  182|      0|      case 0x2B000:
  ------------------
  |  Branch (182:7): [True: 0, False: 3]
  ------------------
  183|      0|         return if_match(oid, {2, 5, 29, 37, 0}, "X509v3.AnyExtendedKeyUsage");
  184|      0|      case 0x2B5C9:
  ------------------
  |  Branch (184:7): [True: 0, False: 3]
  ------------------
  185|      0|         return if_match(oid, {1, 2, 840, 10045, 2, 1}, "ECDSA");
  186|      0|      case 0x2B74B:
  ------------------
  |  Branch (186:7): [True: 0, False: 3]
  ------------------
  187|      0|         return if_match(oid, {1, 2, 840, 10045, 4, 1}, "ECDSA/SHA-1");
  188|      0|      case 0x3474A:
  ------------------
  |  Branch (188:7): [True: 0, False: 3]
  ------------------
  189|      0|         return if_match(oid, {1, 2, 840, 10046, 2, 1}, "DH");
  190|      0|      case 0x38D6D:
  ------------------
  |  Branch (190:7): [True: 0, False: 3]
  ------------------
  191|      0|         return if_match(oid, {1, 2, 643, 7, 1, 2, 1, 1, 1}, "gost_256A");
  192|      0|      case 0x38D6E:
  ------------------
  |  Branch (192:7): [True: 0, False: 3]
  ------------------
  193|      0|         return if_match(oid, {1, 2, 643, 7, 1, 2, 1, 1, 2}, "gost_256B");
  194|      0|      case 0x38E2E:
  ------------------
  |  Branch (194:7): [True: 0, False: 3]
  ------------------
  195|      0|         return if_match(oid, {1, 2, 643, 7, 1, 2, 1, 2, 1}, "gost_512A");
  196|      0|      case 0x38E2F:
  ------------------
  |  Branch (196:7): [True: 0, False: 3]
  ------------------
  197|      0|         return if_match(oid, {1, 2, 643, 7, 1, 2, 1, 2, 2}, "gost_512B");
  198|      0|      case 0x38F2C:
  ------------------
  |  Branch (198:7): [True: 0, False: 3]
  ------------------
  199|      0|         return if_match(oid, {1, 2, 643, 2, 2, 3}, "GOST-34.10/GOST-R-34.11-94");
  200|      0|      case 0x38F3C:
  ------------------
  |  Branch (200:7): [True: 0, False: 3]
  ------------------
  201|      0|         return if_match(oid, {1, 2, 643, 2, 2, 19}, "GOST-34.10");
  202|      0|      case 0x3D7B8:
  ------------------
  |  Branch (202:7): [True: 0, False: 3]
  ------------------
  203|      0|         return if_match(oid, {0, 3, 4401, 5, 3, 1, 9, 6}, "Camellia-128/GCM");
  204|      0|      case 0x3D7CC:
  ------------------
  |  Branch (204:7): [True: 0, False: 3]
  ------------------
  205|      0|         return if_match(oid, {0, 3, 4401, 5, 3, 1, 9, 26}, "Camellia-192/GCM");
  206|      0|      case 0x3D7E0:
  ------------------
  |  Branch (206:7): [True: 0, False: 3]
  ------------------
  207|      0|         return if_match(oid, {0, 3, 4401, 5, 3, 1, 9, 46}, "Camellia-256/GCM");
  208|      0|      case 0x3F20F:
  ------------------
  |  Branch (208:7): [True: 0, False: 3]
  ------------------
  209|      0|         return if_match(oid, {1, 3, 36, 3, 2, 1}, "RIPEMD-160");
  210|      0|      case 0x4266E:
  ------------------
  |  Branch (210:7): [True: 0, False: 3]
  ------------------
  211|      0|         return if_match(oid, {0, 4, 0, 127, 0, 15, 1, 1, 13, 0}, "XMSS");
  212|      0|      case 0x478C4:
  ------------------
  |  Branch (212:7): [True: 0, False: 3]
  ------------------
  213|      0|         return if_match(oid, {1, 2, 410, 200004, 1, 4}, "SEED/CBC");
  214|      1|      case 0x47D98:
  ------------------
  |  Branch (214:7): [True: 1, False: 2]
  ------------------
  215|      1|         return if_match(oid, {1, 2, 156, 10197, 1, 301}, "sm2p256v1");
  216|      0|      case 0x47DFC:
  ------------------
  |  Branch (216:7): [True: 0, False: 3]
  ------------------
  217|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 401}, "SM3");
  218|      0|      case 0x47E60:
  ------------------
  |  Branch (218:7): [True: 0, False: 3]
  ------------------
  219|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 501}, "SM2_Sig/SM3");
  220|      0|      case 0x47E63:
  ------------------
  |  Branch (220:7): [True: 0, False: 3]
  ------------------
  221|      0|         return if_match(oid, {1, 2, 156, 10197, 1, 504}, "RSA/PKCS1v15(SM3)");
  222|      0|      case 0x52B13:
  ------------------
  |  Branch (222:7): [True: 0, False: 3]
  ------------------
  223|      0|         return if_match(oid, {1, 2, 643, 3, 131, 1, 1}, "GOST.INN");
  224|      0|      case 0x635AE:
  ------------------
  |  Branch (224:7): [True: 0, False: 3]
  ------------------
  225|      0|         return if_match(oid, {1, 2, 250, 1, 223, 101, 256, 1}, "frp256v1");
  226|      0|      case 0x6A784:
  ------------------
  |  Branch (226:7): [True: 0, False: 3]
  ------------------
  227|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 1}, "PKCS12.KeyBag");
  228|      0|      case 0x6A785:
  ------------------
  |  Branch (228:7): [True: 0, False: 3]
  ------------------
  229|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 2}, "PKCS12.PKCS8ShroudedKeyBag");
  230|      0|      case 0x6A786:
  ------------------
  |  Branch (230:7): [True: 0, False: 3]
  ------------------
  231|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 3}, "PKCS12.CertBag");
  232|      0|      case 0x6A787:
  ------------------
  |  Branch (232:7): [True: 0, False: 3]
  ------------------
  233|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 4}, "PKCS12.CRLBag");
  234|      0|      case 0x6A788:
  ------------------
  |  Branch (234:7): [True: 0, False: 3]
  ------------------
  235|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 5}, "PKCS12.SecretBag");
  236|      0|      case 0x6A789:
  ------------------
  |  Branch (236:7): [True: 0, False: 3]
  ------------------
  237|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 10, 1, 6}, "PKCS12.SafeContentsBag");
  238|      0|      case 0x6EB86:
  ------------------
  |  Branch (238:7): [True: 0, False: 3]
  ------------------
  239|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 6, 1}, "GOST-34.10-2012-256/SHA-256");
  240|      0|      case 0x6EC47:
  ------------------
  |  Branch (240:7): [True: 0, False: 3]
  ------------------
  241|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 7, 1}, "Kyber-512-r3");
  242|      0|      case 0x6EC48:
  ------------------
  |  Branch (242:7): [True: 0, False: 3]
  ------------------
  243|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 7, 2}, "Kyber-768-r3");
  244|      0|      case 0x6EC49:
  ------------------
  |  Branch (244:7): [True: 0, False: 3]
  ------------------
  245|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 7, 3}, "Kyber-1024-r3");
  246|      0|      case 0x6EDC9:
  ------------------
  |  Branch (246:7): [True: 0, False: 3]
  ------------------
  247|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 9, 1}, "Dilithium-4x4-r3");
  248|      0|      case 0x6EDCA:
  ------------------
  |  Branch (248:7): [True: 0, False: 3]
  ------------------
  249|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 9, 2}, "Dilithium-6x5-r3");
  250|      0|      case 0x6EDCB:
  ------------------
  |  Branch (250:7): [True: 0, False: 3]
  ------------------
  251|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 9, 3}, "Dilithium-8x7-r3");
  252|      0|      case 0x6EE8A:
  ------------------
  |  Branch (252:7): [True: 0, False: 3]
  ------------------
  253|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 10, 1}, "Dilithium-4x4-AES-r3");
  254|      0|      case 0x6EE8B:
  ------------------
  |  Branch (254:7): [True: 0, False: 3]
  ------------------
  255|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 10, 2}, "Dilithium-6x5-AES-r3");
  256|      0|      case 0x6EE8C:
  ------------------
  |  Branch (256:7): [True: 0, False: 3]
  ------------------
  257|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 10, 3}, "Dilithium-8x7-AES-r3");
  258|      0|      case 0x6EF4B:
  ------------------
  |  Branch (258:7): [True: 0, False: 3]
  ------------------
  259|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 11, 1}, "Kyber-512-90s-r3");
  260|      0|      case 0x6EF4C:
  ------------------
  |  Branch (260:7): [True: 0, False: 3]
  ------------------
  261|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 11, 2}, "Kyber-768-90s-r3");
  262|      0|      case 0x6EF4D:
  ------------------
  |  Branch (262:7): [True: 0, False: 3]
  ------------------
  263|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 11, 3}, "Kyber-1024-90s-r3");
  264|      0|      case 0x6F18E:
  ------------------
  |  Branch (264:7): [True: 0, False: 3]
  ------------------
  265|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 14, 1}, "FrodoKEM-640-SHAKE");
  266|      0|      case 0x6F18F:
  ------------------
  |  Branch (266:7): [True: 0, False: 3]
  ------------------
  267|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 14, 2}, "FrodoKEM-976-SHAKE");
  268|      0|      case 0x6F190:
  ------------------
  |  Branch (268:7): [True: 0, False: 3]
  ------------------
  269|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 14, 3}, "FrodoKEM-1344-SHAKE");
  270|      0|      case 0x6F24F:
  ------------------
  |  Branch (270:7): [True: 0, False: 3]
  ------------------
  271|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 15, 1}, "FrodoKEM-640-AES");
  272|      0|      case 0x6F250:
  ------------------
  |  Branch (272:7): [True: 0, False: 3]
  ------------------
  273|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 15, 2}, "FrodoKEM-976-AES");
  274|      0|      case 0x6F251:
  ------------------
  |  Branch (274:7): [True: 0, False: 3]
  ------------------
  275|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 15, 3}, "FrodoKEM-1344-AES");
  276|      0|      case 0x6F310:
  ------------------
  |  Branch (276:7): [True: 0, False: 3]
  ------------------
  277|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 16, 1}, "eFrodoKEM-640-SHAKE");
  278|      0|      case 0x6F311:
  ------------------
  |  Branch (278:7): [True: 0, False: 3]
  ------------------
  279|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 16, 2}, "eFrodoKEM-976-SHAKE");
  280|      0|      case 0x6F312:
  ------------------
  |  Branch (280:7): [True: 0, False: 3]
  ------------------
  281|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 16, 3}, "eFrodoKEM-1344-SHAKE");
  282|      0|      case 0x6F3D1:
  ------------------
  |  Branch (282:7): [True: 0, False: 3]
  ------------------
  283|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 17, 1}, "eFrodoKEM-640-AES");
  284|      0|      case 0x6F3D2:
  ------------------
  |  Branch (284:7): [True: 0, False: 3]
  ------------------
  285|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 17, 2}, "eFrodoKEM-976-AES");
  286|      0|      case 0x6F3D3:
  ------------------
  |  Branch (286:7): [True: 0, False: 3]
  ------------------
  287|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 17, 3}, "eFrodoKEM-1344-AES");
  288|      0|      case 0x6F492:
  ------------------
  |  Branch (288:7): [True: 0, False: 3]
  ------------------
  289|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 1}, "ClassicMcEliece_6688128pc");
  290|      0|      case 0x6F493:
  ------------------
  |  Branch (290:7): [True: 0, False: 3]
  ------------------
  291|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 2}, "ClassicMcEliece_6688128pcf");
  292|      0|      case 0x6F494:
  ------------------
  |  Branch (292:7): [True: 0, False: 3]
  ------------------
  293|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 3}, "ClassicMcEliece_6960119pc");
  294|      0|      case 0x6F495:
  ------------------
  |  Branch (294:7): [True: 0, False: 3]
  ------------------
  295|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 4}, "ClassicMcEliece_6960119pcf");
  296|      0|      case 0x6F496:
  ------------------
  |  Branch (296:7): [True: 0, False: 3]
  ------------------
  297|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 5}, "ClassicMcEliece_8192128pc");
  298|      0|      case 0x6F497:
  ------------------
  |  Branch (298:7): [True: 0, False: 3]
  ------------------
  299|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 18, 6}, "ClassicMcEliece_8192128pcf");
  300|      0|      case 0x6F79D:
  ------------------
  |  Branch (300:7): [True: 0, False: 3]
  ------------------
  301|      0|         return if_match(oid, {2, 16, 840, 1, 113730, 1, 13}, "Certificate Comment");
  302|      0|      case 0x701A0:
  ------------------
  |  Branch (302:7): [True: 0, False: 3]
  ------------------
  303|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 2, 1}, "ECGDSA");
  304|      0|      case 0x70322:
  ------------------
  |  Branch (304:7): [True: 0, False: 3]
  ------------------
  305|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 1}, "ECGDSA/RIPEMD-160");
  306|      0|      case 0x70323:
  ------------------
  |  Branch (306:7): [True: 0, False: 3]
  ------------------
  307|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 2}, "ECGDSA/SHA-1");
  308|      0|      case 0x70324:
  ------------------
  |  Branch (308:7): [True: 0, False: 3]
  ------------------
  309|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 3}, "ECGDSA/SHA-224");
  310|      0|      case 0x70325:
  ------------------
  |  Branch (310:7): [True: 0, False: 3]
  ------------------
  311|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 4}, "ECGDSA/SHA-256");
  312|      0|      case 0x70326:
  ------------------
  |  Branch (312:7): [True: 0, False: 3]
  ------------------
  313|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 5}, "ECGDSA/SHA-384");
  314|      0|      case 0x70327:
  ------------------
  |  Branch (314:7): [True: 0, False: 3]
  ------------------
  315|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 5, 4, 6}, "ECGDSA/SHA-512");
  316|      0|      case 0x72B21:
  ------------------
  |  Branch (316:7): [True: 0, False: 3]
  ------------------
  317|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 1, 1}, "GOST-34.10-2012-256");
  318|      0|      case 0x72B22:
  ------------------
  |  Branch (318:7): [True: 0, False: 3]
  ------------------
  319|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 1, 2}, "GOST-34.10-2012-512");
  320|      0|      case 0x72BE3:
  ------------------
  |  Branch (320:7): [True: 0, False: 3]
  ------------------
  321|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 2, 2}, "Streebog-256");
  322|      0|      case 0x72BE4:
  ------------------
  |  Branch (322:7): [True: 0, False: 3]
  ------------------
  323|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 2, 3}, "Streebog-512");
  324|      0|      case 0x72CA4:
  ------------------
  |  Branch (324:7): [True: 0, False: 3]
  ------------------
  325|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 3, 2}, "GOST-34.10-2012-256/Streebog-256");
  326|      0|      case 0x72CA5:
  ------------------
  |  Branch (326:7): [True: 0, False: 3]
  ------------------
  327|      0|         return if_match(oid, {1, 2, 643, 7, 1, 1, 3, 3}, "GOST-34.10-2012-512/Streebog-512");
  328|      0|      case 0x7C7C7:
  ------------------
  |  Branch (328:7): [True: 0, False: 3]
  ------------------
  329|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 22, 1}, "PKCS9.X509Certificate");
  330|      0|      case 0x7C7C8:
  ------------------
  |  Branch (330:7): [True: 0, False: 3]
  ------------------
  331|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 22, 2}, "PKCS9.SDSICertificate");
  332|      0|      case 0x7C888:
  ------------------
  |  Branch (332:7): [True: 0, False: 3]
  ------------------
  333|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 23, 1}, "PKCS9.X509CRL");
  334|      0|      case 0x7E10F:
  ------------------
  |  Branch (334:7): [True: 0, False: 3]
  ------------------
  335|      0|         return if_match(oid, {2, 5, 4, 3}, "X520.CommonName");
  336|      0|      case 0x7E110:
  ------------------
  |  Branch (336:7): [True: 0, False: 3]
  ------------------
  337|      0|         return if_match(oid, {2, 5, 4, 4}, "X520.Surname");
  338|      0|      case 0x7E111:
  ------------------
  |  Branch (338:7): [True: 0, False: 3]
  ------------------
  339|      0|         return if_match(oid, {2, 5, 4, 5}, "X520.SerialNumber");
  340|      0|      case 0x7E112:
  ------------------
  |  Branch (340:7): [True: 0, False: 3]
  ------------------
  341|      0|         return if_match(oid, {2, 5, 4, 6}, "X520.Country");
  342|      0|      case 0x7E113:
  ------------------
  |  Branch (342:7): [True: 0, False: 3]
  ------------------
  343|      0|         return if_match(oid, {2, 5, 4, 7}, "X520.Locality");
  344|      0|      case 0x7E114:
  ------------------
  |  Branch (344:7): [True: 0, False: 3]
  ------------------
  345|      0|         return if_match(oid, {2, 5, 4, 8}, "X520.State");
  346|      0|      case 0x7E115:
  ------------------
  |  Branch (346:7): [True: 0, False: 3]
  ------------------
  347|      0|         return if_match(oid, {2, 5, 4, 9}, "X520.StreetAddress");
  348|      0|      case 0x7E116:
  ------------------
  |  Branch (348:7): [True: 0, False: 3]
  ------------------
  349|      0|         return if_match(oid, {2, 5, 4, 10}, "X520.Organization");
  350|      0|      case 0x7E117:
  ------------------
  |  Branch (350:7): [True: 0, False: 3]
  ------------------
  351|      0|         return if_match(oid, {2, 5, 4, 11}, "X520.OrganizationalUnit");
  352|      0|      case 0x7E118:
  ------------------
  |  Branch (352:7): [True: 0, False: 3]
  ------------------
  353|      0|         return if_match(oid, {2, 5, 4, 12}, "X520.Title");
  354|      0|      case 0x7E136:
  ------------------
  |  Branch (354:7): [True: 0, False: 3]
  ------------------
  355|      0|         return if_match(oid, {2, 5, 4, 42}, "X520.GivenName");
  356|      0|      case 0x7E137:
  ------------------
  |  Branch (356:7): [True: 0, False: 3]
  ------------------
  357|      0|         return if_match(oid, {2, 5, 4, 43}, "X520.Initials");
  358|      0|      case 0x7E138:
  ------------------
  |  Branch (358:7): [True: 0, False: 3]
  ------------------
  359|      0|         return if_match(oid, {2, 5, 4, 44}, "X520.GenerationalQualifier");
  360|      0|      case 0x7E13A:
  ------------------
  |  Branch (360:7): [True: 0, False: 3]
  ------------------
  361|      0|         return if_match(oid, {2, 5, 4, 46}, "X520.DNQualifier");
  362|      0|      case 0x7E14D:
  ------------------
  |  Branch (362:7): [True: 0, False: 3]
  ------------------
  363|      0|         return if_match(oid, {2, 5, 4, 65}, "X520.Pseudonym");
  364|      0|      case 0x7F3F3:
  ------------------
  |  Branch (364:7): [True: 0, False: 3]
  ------------------
  365|      0|         return if_match(oid, {2, 5, 29, 14}, "X509v3.SubjectKeyIdentifier");
  366|      0|      case 0x7F3F4:
  ------------------
  |  Branch (366:7): [True: 0, False: 3]
  ------------------
  367|      0|         return if_match(oid, {2, 5, 29, 15}, "X509v3.KeyUsage");
  368|      0|      case 0x7F3F5:
  ------------------
  |  Branch (368:7): [True: 0, False: 3]
  ------------------
  369|      0|         return if_match(oid, {2, 5, 29, 16}, "X509v3.PrivateKeyUsagePeriod");
  370|      0|      case 0x7F3F6:
  ------------------
  |  Branch (370:7): [True: 0, False: 3]
  ------------------
  371|      0|         return if_match(oid, {2, 5, 29, 17}, "X509v3.SubjectAlternativeName");
  372|      0|      case 0x7F3F7:
  ------------------
  |  Branch (372:7): [True: 0, False: 3]
  ------------------
  373|      0|         return if_match(oid, {2, 5, 29, 18}, "X509v3.IssuerAlternativeName");
  374|      0|      case 0x7F3F8:
  ------------------
  |  Branch (374:7): [True: 0, False: 3]
  ------------------
  375|      0|         return if_match(oid, {2, 5, 29, 19}, "X509v3.BasicConstraints");
  376|      0|      case 0x7F3F9:
  ------------------
  |  Branch (376:7): [True: 0, False: 3]
  ------------------
  377|      0|         return if_match(oid, {2, 5, 29, 20}, "X509v3.CRLNumber");
  378|      0|      case 0x7F3FA:
  ------------------
  |  Branch (378:7): [True: 0, False: 3]
  ------------------
  379|      0|         return if_match(oid, {2, 5, 29, 21}, "X509v3.ReasonCode");
  380|      0|      case 0x7F3FC:
  ------------------
  |  Branch (380:7): [True: 0, False: 3]
  ------------------
  381|      0|         return if_match(oid, {2, 5, 29, 23}, "X509v3.HoldInstructionCode");
  382|      0|      case 0x7F3FD:
  ------------------
  |  Branch (382:7): [True: 0, False: 3]
  ------------------
  383|      0|         return if_match(oid, {2, 5, 29, 24}, "X509v3.InvalidityDate");
  384|      0|      case 0x7F401:
  ------------------
  |  Branch (384:7): [True: 0, False: 3]
  ------------------
  385|      0|         return if_match(oid, {2, 5, 29, 28}, "X509v3.CRLIssuingDistributionPoint");
  386|      0|      case 0x7F403:
  ------------------
  |  Branch (386:7): [True: 0, False: 3]
  ------------------
  387|      0|         return if_match(oid, {2, 5, 29, 30}, "X509v3.NameConstraints");
  388|      0|      case 0x7F404:
  ------------------
  |  Branch (388:7): [True: 0, False: 3]
  ------------------
  389|      0|         return if_match(oid, {2, 5, 29, 31}, "X509v3.CRLDistributionPoints");
  390|      0|      case 0x7F405:
  ------------------
  |  Branch (390:7): [True: 0, False: 3]
  ------------------
  391|      0|         return if_match(oid, {2, 5, 29, 32}, "X509v3.CertificatePolicies");
  392|      0|      case 0x7F408:
  ------------------
  |  Branch (392:7): [True: 0, False: 3]
  ------------------
  393|      0|         return if_match(oid, {2, 5, 29, 35}, "X509v3.AuthorityKeyIdentifier");
  394|      0|      case 0x7F409:
  ------------------
  |  Branch (394:7): [True: 0, False: 3]
  ------------------
  395|      0|         return if_match(oid, {2, 5, 29, 36}, "X509v3.PolicyConstraints");
  396|      0|      case 0x7F40A:
  ------------------
  |  Branch (396:7): [True: 0, False: 3]
  ------------------
  397|      0|         return if_match(oid, {2, 5, 29, 37}, "X509v3.ExtendedKeyUsage");
  398|      0|      case 0x7F41D:
  ------------------
  |  Branch (398:7): [True: 0, False: 3]
  ------------------
  399|      0|         return if_match(oid, {2, 5, 29, 56}, "X509v3.NoRevocationAvailable");
  400|      0|      case 0x80B84:
  ------------------
  |  Branch (400:7): [True: 0, False: 3]
  ------------------
  401|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 1}, "AES-128/OCB");
  402|      0|      case 0x80B85:
  ------------------
  |  Branch (402:7): [True: 0, False: 3]
  ------------------
  403|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 2}, "AES-192/OCB");
  404|      0|      case 0x80B86:
  ------------------
  |  Branch (404:7): [True: 0, False: 3]
  ------------------
  405|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 3}, "AES-256/OCB");
  406|      0|      case 0x80B87:
  ------------------
  |  Branch (406:7): [True: 0, False: 3]
  ------------------
  407|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 4}, "Serpent/OCB");
  408|      0|      case 0x80B88:
  ------------------
  |  Branch (408:7): [True: 0, False: 3]
  ------------------
  409|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 5}, "Twofish/OCB");
  410|      0|      case 0x80B89:
  ------------------
  |  Branch (410:7): [True: 0, False: 3]
  ------------------
  411|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 6}, "Camellia-128/OCB");
  412|      0|      case 0x80B8A:
  ------------------
  |  Branch (412:7): [True: 0, False: 3]
  ------------------
  413|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 7}, "Camellia-192/OCB");
  414|      0|      case 0x80B8B:
  ------------------
  |  Branch (414:7): [True: 0, False: 3]
  ------------------
  415|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2, 8}, "Camellia-256/OCB");
  416|      0|      case 0x80D06:
  ------------------
  |  Branch (416:7): [True: 0, False: 3]
  ------------------
  417|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 1}, "AES-128/SIV");
  418|      0|      case 0x80D07:
  ------------------
  |  Branch (418:7): [True: 0, False: 3]
  ------------------
  419|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 2}, "AES-192/SIV");
  420|      0|      case 0x80D08:
  ------------------
  |  Branch (420:7): [True: 0, False: 3]
  ------------------
  421|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 3}, "AES-256/SIV");
  422|      0|      case 0x80D09:
  ------------------
  |  Branch (422:7): [True: 0, False: 3]
  ------------------
  423|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 4}, "Serpent/SIV");
  424|      0|      case 0x80D0A:
  ------------------
  |  Branch (424:7): [True: 0, False: 3]
  ------------------
  425|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 5}, "Twofish/SIV");
  426|      0|      case 0x80D0B:
  ------------------
  |  Branch (426:7): [True: 0, False: 3]
  ------------------
  427|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 6}, "Camellia-128/SIV");
  428|      0|      case 0x80D0C:
  ------------------
  |  Branch (428:7): [True: 0, False: 3]
  ------------------
  429|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 7}, "Camellia-192/SIV");
  430|      0|      case 0x80D0D:
  ------------------
  |  Branch (430:7): [True: 0, False: 3]
  ------------------
  431|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 8}, "Camellia-256/SIV");
  432|      0|      case 0x80D0E:
  ------------------
  |  Branch (432:7): [True: 0, False: 3]
  ------------------
  433|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 4, 9}, "SM4/SIV");
  434|      0|      case 0x84C6A:
  ------------------
  |  Branch (434:7): [True: 0, False: 3]
  ------------------
  435|      0|         return if_match(oid, {1, 2, 392, 200011, 61, 1, 1, 1, 2}, "Camellia-128/CBC");
  436|      0|      case 0x84C6B:
  ------------------
  |  Branch (436:7): [True: 0, False: 3]
  ------------------
  437|      0|         return if_match(oid, {1, 2, 392, 200011, 61, 1, 1, 1, 3}, "Camellia-192/CBC");
  438|      0|      case 0x84C6C:
  ------------------
  |  Branch (438:7): [True: 0, False: 3]
  ------------------
  439|      0|         return if_match(oid, {1, 2, 392, 200011, 61, 1, 1, 1, 4}, "Camellia-256/CBC");
  440|      0|      case 0x88CD3:
  ------------------
  |  Branch (440:7): [True: 0, False: 3]
  ------------------
  441|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 16, 3, 6}, "KeyWrap.TripleDES");
  442|      0|      case 0x88CD5:
  ------------------
  |  Branch (442:7): [True: 0, False: 3]
  ------------------
  443|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 16, 3, 8}, "Compression.Zlib");
  444|      0|      case 0x88CDE:
  ------------------
  |  Branch (444:7): [True: 0, False: 3]
  ------------------
  445|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 16, 3, 17}, "HSS-LMS");
  446|      0|      case 0x88CDF:
  ------------------
  |  Branch (446:7): [True: 0, False: 3]
  ------------------
  447|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 16, 3, 18}, "ChaCha20Poly1305");
  448|      0|      case 0x92296:
  ------------------
  |  Branch (448:7): [True: 0, False: 3]
  ------------------
  449|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 2}, "AES-128/CBC");
  450|      0|      case 0x92299:
  ------------------
  |  Branch (450:7): [True: 0, False: 3]
  ------------------
  451|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 5}, "KeyWrap.AES-128");
  452|      0|      case 0x9229A:
  ------------------
  |  Branch (452:7): [True: 0, False: 3]
  ------------------
  453|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 6}, "AES-128/GCM");
  454|      0|      case 0x9229B:
  ------------------
  |  Branch (454:7): [True: 0, False: 3]
  ------------------
  455|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 7}, "AES-128/CCM");
  456|      0|      case 0x922AA:
  ------------------
  |  Branch (456:7): [True: 0, False: 3]
  ------------------
  457|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 22}, "AES-192/CBC");
  458|      0|      case 0x922AD:
  ------------------
  |  Branch (458:7): [True: 0, False: 3]
  ------------------
  459|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 25}, "KeyWrap.AES-192");
  460|      0|      case 0x922AE:
  ------------------
  |  Branch (460:7): [True: 0, False: 3]
  ------------------
  461|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 26}, "AES-192/GCM");
  462|      0|      case 0x922AF:
  ------------------
  |  Branch (462:7): [True: 0, False: 3]
  ------------------
  463|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 27}, "AES-192/CCM");
  464|      0|      case 0x922BE:
  ------------------
  |  Branch (464:7): [True: 0, False: 3]
  ------------------
  465|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 42}, "AES-256/CBC");
  466|      0|      case 0x922C1:
  ------------------
  |  Branch (466:7): [True: 0, False: 3]
  ------------------
  467|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 45}, "KeyWrap.AES-256");
  468|      0|      case 0x922C2:
  ------------------
  |  Branch (468:7): [True: 0, False: 3]
  ------------------
  469|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 46}, "AES-256/GCM");
  470|      0|      case 0x922C3:
  ------------------
  |  Branch (470:7): [True: 0, False: 3]
  ------------------
  471|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 1, 47}, "AES-256/CCM");
  472|      0|      case 0x92356:
  ------------------
  |  Branch (472:7): [True: 0, False: 3]
  ------------------
  473|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 1}, "SHA-256");
  474|      0|      case 0x92357:
  ------------------
  |  Branch (474:7): [True: 0, False: 3]
  ------------------
  475|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 2}, "SHA-384");
  476|      0|      case 0x92358:
  ------------------
  |  Branch (476:7): [True: 0, False: 3]
  ------------------
  477|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 3}, "SHA-512");
  478|      0|      case 0x92359:
  ------------------
  |  Branch (478:7): [True: 0, False: 3]
  ------------------
  479|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 4}, "SHA-224");
  480|      0|      case 0x9235B:
  ------------------
  |  Branch (480:7): [True: 0, False: 3]
  ------------------
  481|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 6}, "SHA-512-256");
  482|      0|      case 0x9235C:
  ------------------
  |  Branch (482:7): [True: 0, False: 3]
  ------------------
  483|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 7}, "SHA-3(224)");
  484|      0|      case 0x9235D:
  ------------------
  |  Branch (484:7): [True: 0, False: 3]
  ------------------
  485|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 8}, "SHA-3(256)");
  486|      0|      case 0x9235E:
  ------------------
  |  Branch (486:7): [True: 0, False: 3]
  ------------------
  487|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 9}, "SHA-3(384)");
  488|      0|      case 0x9235F:
  ------------------
  |  Branch (488:7): [True: 0, False: 3]
  ------------------
  489|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 10}, "SHA-3(512)");
  490|      0|      case 0x92360:
  ------------------
  |  Branch (490:7): [True: 0, False: 3]
  ------------------
  491|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 11}, "SHAKE-128");
  492|      0|      case 0x92361:
  ------------------
  |  Branch (492:7): [True: 0, False: 3]
  ------------------
  493|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 2, 12}, "SHAKE-256");
  494|      0|      case 0x92417:
  ------------------
  |  Branch (494:7): [True: 0, False: 3]
  ------------------
  495|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 1}, "DSA/SHA-224");
  496|      0|      case 0x92418:
  ------------------
  |  Branch (496:7): [True: 0, False: 3]
  ------------------
  497|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 2}, "DSA/SHA-256");
  498|      0|      case 0x92419:
  ------------------
  |  Branch (498:7): [True: 0, False: 3]
  ------------------
  499|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 3}, "DSA/SHA-384");
  500|      0|      case 0x9241A:
  ------------------
  |  Branch (500:7): [True: 0, False: 3]
  ------------------
  501|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 4}, "DSA/SHA-512");
  502|      0|      case 0x9241B:
  ------------------
  |  Branch (502:7): [True: 0, False: 3]
  ------------------
  503|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 5}, "DSA/SHA-3(224)");
  504|      0|      case 0x9241C:
  ------------------
  |  Branch (504:7): [True: 0, False: 3]
  ------------------
  505|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 6}, "DSA/SHA-3(256)");
  506|      0|      case 0x9241D:
  ------------------
  |  Branch (506:7): [True: 0, False: 3]
  ------------------
  507|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 7}, "DSA/SHA-3(384)");
  508|      0|      case 0x9241E:
  ------------------
  |  Branch (508:7): [True: 0, False: 3]
  ------------------
  509|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 8}, "DSA/SHA-3(512)");
  510|      0|      case 0x9241F:
  ------------------
  |  Branch (510:7): [True: 0, False: 3]
  ------------------
  511|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 9}, "ECDSA/SHA-3(224)");
  512|      0|      case 0x92420:
  ------------------
  |  Branch (512:7): [True: 0, False: 3]
  ------------------
  513|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 10}, "ECDSA/SHA-3(256)");
  514|      0|      case 0x92421:
  ------------------
  |  Branch (514:7): [True: 0, False: 3]
  ------------------
  515|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 11}, "ECDSA/SHA-3(384)");
  516|      0|      case 0x92422:
  ------------------
  |  Branch (516:7): [True: 0, False: 3]
  ------------------
  517|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 12}, "ECDSA/SHA-3(512)");
  518|      0|      case 0x92423:
  ------------------
  |  Branch (518:7): [True: 0, False: 3]
  ------------------
  519|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 13}, "RSA/PKCS1v15(SHA-3(224))");
  520|      0|      case 0x92424:
  ------------------
  |  Branch (520:7): [True: 0, False: 3]
  ------------------
  521|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 14}, "RSA/PKCS1v15(SHA-3(256))");
  522|      0|      case 0x92425:
  ------------------
  |  Branch (522:7): [True: 0, False: 3]
  ------------------
  523|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 15}, "RSA/PKCS1v15(SHA-3(384))");
  524|      0|      case 0x92426:
  ------------------
  |  Branch (524:7): [True: 0, False: 3]
  ------------------
  525|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 16}, "RSA/PKCS1v15(SHA-3(512))");
  526|      0|      case 0x92427:
  ------------------
  |  Branch (526:7): [True: 0, False: 3]
  ------------------
  527|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 17}, "ML-DSA-4x4");
  528|      0|      case 0x92428:
  ------------------
  |  Branch (528:7): [True: 0, False: 3]
  ------------------
  529|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 18}, "ML-DSA-6x5");
  530|      0|      case 0x92429:
  ------------------
  |  Branch (530:7): [True: 0, False: 3]
  ------------------
  531|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 19}, "ML-DSA-8x7");
  532|      0|      case 0x9242A:
  ------------------
  |  Branch (532:7): [True: 0, False: 3]
  ------------------
  533|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 20}, "SLH-DSA-SHA2-128s");
  534|      0|      case 0x9242B:
  ------------------
  |  Branch (534:7): [True: 0, False: 3]
  ------------------
  535|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 21}, "SLH-DSA-SHA2-128f");
  536|      0|      case 0x9242C:
  ------------------
  |  Branch (536:7): [True: 0, False: 3]
  ------------------
  537|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 22}, "SLH-DSA-SHA2-192s");
  538|      0|      case 0x9242D:
  ------------------
  |  Branch (538:7): [True: 0, False: 3]
  ------------------
  539|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 23}, "SLH-DSA-SHA2-192f");
  540|      0|      case 0x9242E:
  ------------------
  |  Branch (540:7): [True: 0, False: 3]
  ------------------
  541|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 24}, "SLH-DSA-SHA2-256s");
  542|      0|      case 0x9242F:
  ------------------
  |  Branch (542:7): [True: 0, False: 3]
  ------------------
  543|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 25}, "SLH-DSA-SHA2-256f");
  544|      0|      case 0x92430:
  ------------------
  |  Branch (544:7): [True: 0, False: 3]
  ------------------
  545|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 26}, "SLH-DSA-SHAKE-128s");
  546|      0|      case 0x92431:
  ------------------
  |  Branch (546:7): [True: 0, False: 3]
  ------------------
  547|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 27}, "SLH-DSA-SHAKE-128f");
  548|      0|      case 0x92432:
  ------------------
  |  Branch (548:7): [True: 0, False: 3]
  ------------------
  549|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 28}, "SLH-DSA-SHAKE-192s");
  550|      0|      case 0x92433:
  ------------------
  |  Branch (550:7): [True: 0, False: 3]
  ------------------
  551|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 29}, "SLH-DSA-SHAKE-192f");
  552|      0|      case 0x92434:
  ------------------
  |  Branch (552:7): [True: 0, False: 3]
  ------------------
  553|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 30}, "SLH-DSA-SHAKE-256s");
  554|      0|      case 0x92435:
  ------------------
  |  Branch (554:7): [True: 0, False: 3]
  ------------------
  555|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 3, 31}, "SLH-DSA-SHAKE-256f");
  556|      0|      case 0x924D8:
  ------------------
  |  Branch (556:7): [True: 0, False: 3]
  ------------------
  557|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 4, 1}, "ML-KEM-512");
  558|      0|      case 0x924D9:
  ------------------
  |  Branch (558:7): [True: 0, False: 3]
  ------------------
  559|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 4, 2}, "ML-KEM-768");
  560|      0|      case 0x924DA:
  ------------------
  |  Branch (560:7): [True: 0, False: 3]
  ------------------
  561|      0|         return if_match(oid, {2, 16, 840, 1, 101, 3, 4, 4, 3}, "ML-KEM-1024");
  562|      0|      case 0x9479F:
  ------------------
  |  Branch (562:7): [True: 0, False: 3]
  ------------------
  563|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 1, 1}, "PKIX.AuthorityInformationAccess");
  564|      0|      case 0x947A5:
  ------------------
  |  Branch (564:7): [True: 0, False: 3]
  ------------------
  565|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 1, 7}, "PKIX.IpAddrBlocks");
  566|      0|      case 0x947A6:
  ------------------
  |  Branch (566:7): [True: 0, False: 3]
  ------------------
  567|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 1, 8}, "PKIX.AutonomousSysIds");
  568|      0|      case 0x947B8:
  ------------------
  |  Branch (568:7): [True: 0, False: 3]
  ------------------
  569|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 1, 26}, "PKIX.TNAuthList");
  570|      0|      case 0x94921:
  ------------------
  |  Branch (570:7): [True: 0, False: 3]
  ------------------
  571|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 1}, "PKIX.ServerAuth");
  572|      0|      case 0x94922:
  ------------------
  |  Branch (572:7): [True: 0, False: 3]
  ------------------
  573|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 2}, "PKIX.ClientAuth");
  574|      0|      case 0x94923:
  ------------------
  |  Branch (574:7): [True: 0, False: 3]
  ------------------
  575|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 3}, "PKIX.CodeSigning");
  576|      0|      case 0x94924:
  ------------------
  |  Branch (576:7): [True: 0, False: 3]
  ------------------
  577|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 4}, "PKIX.EmailProtection");
  578|      0|      case 0x94925:
  ------------------
  |  Branch (578:7): [True: 0, False: 3]
  ------------------
  579|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 5}, "PKIX.IPsecEndSystem");
  580|      0|      case 0x94926:
  ------------------
  |  Branch (580:7): [True: 0, False: 3]
  ------------------
  581|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 6}, "PKIX.IPsecTunnel");
  582|      0|      case 0x94927:
  ------------------
  |  Branch (582:7): [True: 0, False: 3]
  ------------------
  583|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 7}, "PKIX.IPsecUser");
  584|      0|      case 0x94928:
  ------------------
  |  Branch (584:7): [True: 0, False: 3]
  ------------------
  585|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 8}, "PKIX.TimeStamping");
  586|      0|      case 0x94929:
  ------------------
  |  Branch (586:7): [True: 0, False: 3]
  ------------------
  587|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 3, 9}, "PKIX.OCSPSigning");
  588|      0|      case 0x94CEA:
  ------------------
  |  Branch (588:7): [True: 0, False: 3]
  ------------------
  589|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 8, 5}, "PKIX.XMPPAddr");
  590|      0|      case 0x94CEE:
  ------------------
  |  Branch (590:7): [True: 0, False: 3]
  ------------------
  591|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 8, 9}, "PKIX.SmtpUTF8Mailbox");
  592|      0|      case 0x954DB:
  ------------------
  |  Branch (592:7): [True: 0, False: 3]
  ------------------
  593|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 311, 20, 2, 2}, "Microsoft SmartcardLogon");
  594|      0|      case 0x954DC:
  ------------------
  |  Branch (594:7): [True: 0, False: 3]
  ------------------
  595|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 311, 20, 2, 3}, "Microsoft UPN");
  596|      0|      case 0x96B0E:
  ------------------
  |  Branch (596:7): [True: 0, False: 3]
  ------------------
  597|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 48, 1}, "PKIX.OCSP");
  598|      0|      case 0x96B0F:
  ------------------
  |  Branch (598:7): [True: 0, False: 3]
  ------------------
  599|      0|         return if_match(oid, {1, 3, 6, 1, 5, 5, 7, 48, 2}, "PKIX.CertificateAuthorityIssuers");
  600|      0|      case 0x96C77:
  ------------------
  |  Branch (600:7): [True: 0, False: 3]
  ------------------
  601|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 1, 3}, "PBE-SHA1-3DES");
  602|      0|      case 0x96C78:
  ------------------
  |  Branch (602:7): [True: 0, False: 3]
  ------------------
  603|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 12, 1, 4}, "PBE-SHA1-2DES");
  604|      0|      case 0x9A008:
  ------------------
  |  Branch (604:7): [True: 0, False: 3]
  ------------------
  605|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 1}, "brainpool160r1");
  606|      0|      case 0x9A00A:
  ------------------
  |  Branch (606:7): [True: 0, False: 3]
  ------------------
  607|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 3}, "brainpool192r1");
  608|      0|      case 0x9A00C:
  ------------------
  |  Branch (608:7): [True: 0, False: 3]
  ------------------
  609|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 5}, "brainpool224r1");
  610|      0|      case 0x9A00E:
  ------------------
  |  Branch (610:7): [True: 0, False: 3]
  ------------------
  611|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 7}, "brainpool256r1");
  612|      0|      case 0x9A010:
  ------------------
  |  Branch (612:7): [True: 0, False: 3]
  ------------------
  613|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 9}, "brainpool320r1");
  614|      0|      case 0x9A012:
  ------------------
  |  Branch (614:7): [True: 0, False: 3]
  ------------------
  615|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 11}, "brainpool384r1");
  616|      0|      case 0x9A014:
  ------------------
  |  Branch (616:7): [True: 0, False: 3]
  ------------------
  617|      0|         return if_match(oid, {1, 3, 36, 3, 3, 2, 8, 1, 1, 13}, "brainpool512r1");
  618|      0|      case 0xA0D61:
  ------------------
  |  Branch (618:7): [True: 0, False: 3]
  ------------------
  619|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 3}, "McEliece");
  620|      0|      case 0xA0D63:
  ------------------
  |  Branch (620:7): [True: 0, False: 3]
  ------------------
  621|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 5}, "XMSS-draft6");
  622|      0|      case 0xA0D66:
  ------------------
  |  Branch (622:7): [True: 0, False: 3]
  ------------------
  623|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 8}, "XMSS-draft12");
  624|      0|      case 0xA0D6B:
  ------------------
  |  Branch (624:7): [True: 0, False: 3]
  ------------------
  625|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 1, 13}, "HSS-LMS-Private-Key");
  626|      0|      case 0xA0EE1:
  ------------------
  |  Branch (626:7): [True: 0, False: 3]
  ------------------
  627|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 1}, "Serpent/CBC");
  628|      0|      case 0xA0EE2:
  ------------------
  |  Branch (628:7): [True: 0, False: 3]
  ------------------
  629|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 2}, "Threefish-512/CBC");
  630|      0|      case 0xA0EE3:
  ------------------
  |  Branch (630:7): [True: 0, False: 3]
  ------------------
  631|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 3}, "Twofish/CBC");
  632|      0|      case 0xA0F45:
  ------------------
  |  Branch (632:7): [True: 0, False: 3]
  ------------------
  633|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 101}, "Serpent/GCM");
  634|      0|      case 0xA0F46:
  ------------------
  |  Branch (634:7): [True: 0, False: 3]
  ------------------
  635|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 3, 102}, "Twofish/GCM");
  636|      0|      case 0xA0FA2:
  ------------------
  |  Branch (636:7): [True: 0, False: 3]
  ------------------
  637|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 4, 1}, "numsp256d1");
  638|      0|      case 0xA0FA3:
  ------------------
  |  Branch (638:7): [True: 0, False: 3]
  ------------------
  639|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 4, 2}, "numsp384d1");
  640|      0|      case 0xA0FA4:
  ------------------
  |  Branch (640:7): [True: 0, False: 3]
  ------------------
  641|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 25258, 4, 3}, "numsp512d1");
  642|      0|      case 0xA244B:
  ------------------
  |  Branch (642:7): [True: 0, False: 3]
  ------------------
  643|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 1}, "ClassicMcEliece_348864");
  644|      0|      case 0xA244C:
  ------------------
  |  Branch (644:7): [True: 0, False: 3]
  ------------------
  645|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 2}, "ClassicMcEliece_348864f");
  646|      0|      case 0xA244D:
  ------------------
  |  Branch (646:7): [True: 0, False: 3]
  ------------------
  647|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 3}, "ClassicMcEliece_460896");
  648|      0|      case 0xA244E:
  ------------------
  |  Branch (648:7): [True: 0, False: 3]
  ------------------
  649|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 4}, "ClassicMcEliece_460896f");
  650|      0|      case 0xA244F:
  ------------------
  |  Branch (650:7): [True: 0, False: 3]
  ------------------
  651|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 5}, "ClassicMcEliece_6688128");
  652|      0|      case 0xA2450:
  ------------------
  |  Branch (652:7): [True: 0, False: 3]
  ------------------
  653|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 6}, "ClassicMcEliece_6688128f");
  654|      0|      case 0xA2451:
  ------------------
  |  Branch (654:7): [True: 0, False: 3]
  ------------------
  655|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 7}, "ClassicMcEliece_6960119");
  656|      0|      case 0xA2452:
  ------------------
  |  Branch (656:7): [True: 0, False: 3]
  ------------------
  657|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 8}, "ClassicMcEliece_6960119f");
  658|      0|      case 0xA2453:
  ------------------
  |  Branch (658:7): [True: 0, False: 3]
  ------------------
  659|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 9}, "ClassicMcEliece_8192128");
  660|      0|      case 0xA2454:
  ------------------
  |  Branch (660:7): [True: 0, False: 3]
  ------------------
  661|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 22554, 5, 1, 10}, "ClassicMcEliece_8192128f");
  662|      0|      case 0xAF989:
  ------------------
  |  Branch (662:7): [True: 0, False: 3]
  ------------------
  663|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 1}, "RSA");
  664|      0|      case 0xAF98A:
  ------------------
  |  Branch (664:7): [True: 0, False: 3]
  ------------------
  665|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 2}, "RSA/PKCS1v15(MD2)");
  666|      0|      case 0xAF98C:
  ------------------
  |  Branch (666:7): [True: 0, False: 3]
  ------------------
  667|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 4}, "RSA/PKCS1v15(MD5)");
  668|      0|      case 0xAF98D:
  ------------------
  |  Branch (668:7): [True: 0, False: 3]
  ------------------
  669|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 5}, "RSA/PKCS1v15(SHA-1)");
  670|      0|      case 0xAF98F:
  ------------------
  |  Branch (670:7): [True: 0, False: 3]
  ------------------
  671|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 7}, "RSA/OAEP");
  672|      0|      case 0xAF990:
  ------------------
  |  Branch (672:7): [True: 0, False: 3]
  ------------------
  673|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 8}, "MGF1");
  674|      0|      case 0xAF992:
  ------------------
  |  Branch (674:7): [True: 0, False: 3]
  ------------------
  675|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 10}, "RSA/PSS");
  676|      0|      case 0xAF993:
  ------------------
  |  Branch (676:7): [True: 0, False: 3]
  ------------------
  677|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 11}, "RSA/PKCS1v15(SHA-256)");
  678|      0|      case 0xAF994:
  ------------------
  |  Branch (678:7): [True: 0, False: 3]
  ------------------
  679|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 12}, "RSA/PKCS1v15(SHA-384)");
  680|      0|      case 0xAF995:
  ------------------
  |  Branch (680:7): [True: 0, False: 3]
  ------------------
  681|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 13}, "RSA/PKCS1v15(SHA-512)");
  682|      0|      case 0xAF996:
  ------------------
  |  Branch (682:7): [True: 0, False: 3]
  ------------------
  683|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 14}, "RSA/PKCS1v15(SHA-224)");
  684|      0|      case 0xAF998:
  ------------------
  |  Branch (684:7): [True: 0, False: 3]
  ------------------
  685|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 1, 16}, "RSA/PKCS1v15(SHA-512-256)");
  686|      0|      case 0xAFC98:
  ------------------
  |  Branch (686:7): [True: 0, False: 3]
  ------------------
  687|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 5, 12}, "PKCS5.PBKDF2");
  688|      0|      case 0xAFC99:
  ------------------
  |  Branch (688:7): [True: 0, False: 3]
  ------------------
  689|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 5, 13}, "PBE-PKCS5v20");
  690|      0|      case 0xAFE0F:
  ------------------
  |  Branch (690:7): [True: 0, False: 3]
  ------------------
  691|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 7, 1}, "PKCS7.Data");
  692|      0|      case 0xAFE14:
  ------------------
  |  Branch (692:7): [True: 0, False: 3]
  ------------------
  693|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 7, 6}, "PKCS7.EncryptedData");
  694|      0|      case 0xAFF91:
  ------------------
  |  Branch (694:7): [True: 0, False: 3]
  ------------------
  695|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 1}, "PKCS9.EmailAddress");
  696|      0|      case 0xAFF92:
  ------------------
  |  Branch (696:7): [True: 0, False: 3]
  ------------------
  697|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 2}, "PKCS9.UnstructuredName");
  698|      0|      case 0xAFF93:
  ------------------
  |  Branch (698:7): [True: 0, False: 3]
  ------------------
  699|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 3}, "PKCS9.ContentType");
  700|      0|      case 0xAFF94:
  ------------------
  |  Branch (700:7): [True: 0, False: 3]
  ------------------
  701|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 4}, "PKCS9.MessageDigest");
  702|      0|      case 0xAFF97:
  ------------------
  |  Branch (702:7): [True: 0, False: 3]
  ------------------
  703|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 7}, "PKCS9.ChallengePassword");
  704|      0|      case 0xAFF9E:
  ------------------
  |  Branch (704:7): [True: 0, False: 3]
  ------------------
  705|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 14}, "PKCS9.ExtensionRequest");
  706|      0|      case 0xAFFA4:
  ------------------
  |  Branch (706:7): [True: 0, False: 3]
  ------------------
  707|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 20}, "PKCS9.FriendlyName");
  708|      0|      case 0xAFFA5:
  ------------------
  |  Branch (708:7): [True: 0, False: 3]
  ------------------
  709|      0|         return if_match(oid, {1, 2, 840, 113549, 1, 9, 21}, "PKCS9.LocalKeyId");
  710|      0|      case 0xC0226:
  ------------------
  |  Branch (710:7): [True: 0, False: 3]
  ------------------
  711|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 11591, 4, 11}, "Scrypt");
  712|      0|      case 0xC0A67:
  ------------------
  |  Branch (712:7): [True: 0, False: 3]
  ------------------
  713|      0|         return if_match(oid, {1, 3, 6, 1, 4, 1, 11591, 15, 1}, "OpenPGP.Ed25519");
  714|      0|      case 0xC4CE5:
  ------------------
  |  Branch (714:7): [True: 0, False: 3]
  ------------------
  715|      0|         return if_match(oid, {1, 2, 643, 100, 1}, "GOST.OGRN");
  716|      0|      case 0xC4D53:
  ------------------
  |  Branch (716:7): [True: 0, False: 3]
  ------------------
  717|      0|         return if_match(oid, {1, 2, 643, 100, 111}, "GOST.SubjectSigningTool");
  718|      0|      case 0xC4D54:
  ------------------
  |  Branch (718:7): [True: 0, False: 3]
  ------------------
  719|      0|         return if_match(oid, {1, 2, 643, 100, 112}, "GOST.IssuerSigningTool");
  720|      0|      case 0xC9C50:
  ------------------
  |  Branch (720:7): [True: 0, False: 3]
  ------------------
  721|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 1}, "secp192r1");
  722|      0|      case 0xC9C51:
  ------------------
  |  Branch (722:7): [True: 0, False: 3]
  ------------------
  723|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 2}, "x962_p192v2");
  724|      0|      case 0xC9C52:
  ------------------
  |  Branch (724:7): [True: 0, False: 3]
  ------------------
  725|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 3}, "x962_p192v3");
  726|      0|      case 0xC9C53:
  ------------------
  |  Branch (726:7): [True: 0, False: 3]
  ------------------
  727|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 4}, "x962_p239v1");
  728|      0|      case 0xC9C54:
  ------------------
  |  Branch (728:7): [True: 0, False: 3]
  ------------------
  729|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 5}, "x962_p239v2");
  730|      0|      case 0xC9C55:
  ------------------
  |  Branch (730:7): [True: 0, False: 3]
  ------------------
  731|      0|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 6}, "x962_p239v3");
  732|      1|      case 0xC9C56:
  ------------------
  |  Branch (732:7): [True: 1, False: 2]
  ------------------
  733|      1|         return if_match(oid, {1, 2, 840, 10045, 3, 1, 7}, "secp256r1");
  734|      0|      case 0xCFA13:
  ------------------
  |  Branch (734:7): [True: 0, False: 3]
  ------------------
  735|      0|         return if_match(oid, {1, 2, 840, 10040, 4, 1}, "DSA");
  736|      0|      case 0xCFA15:
  ------------------
  |  Branch (736:7): [True: 0, False: 3]
  ------------------
  737|      0|         return if_match(oid, {1, 2, 840, 10040, 4, 3}, "DSA/SHA-1");
  738|      0|      default:
  ------------------
  |  Branch (738:7): [True: 0, False: 3]
  ------------------
  739|      0|         return {};
  740|      3|   }
  741|      3|}
_ZN5Botan7OID_Map22lookup_static_oid_nameENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  744|  6.29k|std::optional<OID> OID_Map::lookup_static_oid_name(std::string_view req) {
  745|  6.29k|   const uint32_t hc = hash_oid_name(req);
  746|       |
  747|  6.29k|   switch(hc) {
  748|      0|      case 0x00545:
  ------------------
  |  Branch (748:7): [True: 0, False: 6.29k]
  ------------------
  749|      0|         return if_match(req, "Twofish/GCM", {1, 3, 6, 1, 4, 1, 25258, 3, 102});
  750|      0|      case 0x00CF3:
  ------------------
  |  Branch (750:7): [True: 0, False: 6.29k]
  ------------------
  751|      0|         return if_match(req, "SphincsPlus-sha2-192f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 4});
  752|      0|      case 0x015FE:
  ------------------
  |  Branch (752:7): [True: 0, False: 6.29k]
  ------------------
  753|      0|         return if_match(req, "FrodoKEM-640-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 14, 1});
  754|      0|      case 0x01F9E:
  ------------------
  |  Branch (754:7): [True: 0, False: 6.29k]
  ------------------
  755|      0|         return if_match(req, "MD5", {1, 2, 840, 113549, 2, 5});
  756|      0|      case 0x02293:
  ------------------
  |  Branch (756:7): [True: 0, False: 6.29k]
  ------------------
  757|      0|         return if_match(req, "SphincsPlus-shake-192f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 4});
  758|      0|      case 0x02B93:
  ------------------
  |  Branch (758:7): [True: 0, False: 6.29k]
  ------------------
  759|      0|         return if_match(req, "Microsoft SmartcardLogon", {1, 3, 6, 1, 4, 1, 311, 20, 2, 2});
  760|      0|      case 0x041D5:
  ------------------
  |  Branch (760:7): [True: 0, False: 6.29k]
  ------------------
  761|      0|         return if_match(req, "secp160k1", {1, 3, 132, 0, 9});
  762|      0|      case 0x044B3:
  ------------------
  |  Branch (762:7): [True: 0, False: 6.29k]
  ------------------
  763|      0|         return if_match(req, "Camellia-256/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 8});
  764|      0|      case 0x048B2:
  ------------------
  |  Branch (764:7): [True: 0, False: 6.29k]
  ------------------
  765|      0|         return if_match(req, "secp160r1", {1, 3, 132, 0, 8});
  766|      0|      case 0x048B3:
  ------------------
  |  Branch (766:7): [True: 0, False: 6.29k]
  ------------------
  767|      0|         return if_match(req, "secp160r2", {1, 3, 132, 0, 30});
  768|      0|      case 0x05CDA:
  ------------------
  |  Branch (768:7): [True: 0, False: 6.29k]
  ------------------
  769|      0|         return if_match(req, "X520.Country", {2, 5, 4, 6});
  770|      0|      case 0x07783:
  ------------------
  |  Branch (770:7): [True: 0, False: 6.29k]
  ------------------
  771|      0|         return if_match(req, "PKIX.ServerAuth", {1, 3, 6, 1, 5, 5, 7, 3, 1});
  772|      0|      case 0x086C7:
  ------------------
  |  Branch (772:7): [True: 0, False: 6.29k]
  ------------------
  773|      0|         return if_match(req, "numsp384d1", {1, 3, 6, 1, 4, 1, 25258, 4, 2});
  774|      0|      case 0x08A92:
  ------------------
  |  Branch (774:7): [True: 0, False: 6.29k]
  ------------------
  775|      0|         return if_match(req, "RSA/PKCS1v15(SHA-1)", {1, 2, 840, 113549, 1, 1, 5});
  776|      0|      case 0x09EA0:
  ------------------
  |  Branch (776:7): [True: 0, False: 6.29k]
  ------------------
  777|      0|         return if_match(req, "DES/CBC", {1, 3, 14, 3, 2, 7});
  778|      0|      case 0x0B2D6:
  ------------------
  |  Branch (778:7): [True: 0, False: 6.29k]
  ------------------
  779|      0|         return if_match(req, "ECDSA/SHA-3(512)", {2, 16, 840, 1, 101, 3, 4, 3, 12});
  780|      0|      case 0x0BA72:
  ------------------
  |  Branch (780:7): [True: 0, False: 6.29k]
  ------------------
  781|      0|         return if_match(req, "SphincsPlus-sha2-128s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 1});
  782|      0|      case 0x0BE23:
  ------------------
  |  Branch (782:7): [True: 0, False: 6.29k]
  ------------------
  783|      0|         return if_match(req, "ECGDSA", {1, 3, 36, 3, 3, 2, 5, 2, 1});
  784|      0|      case 0x0C109:
  ------------------
  |  Branch (784:7): [True: 0, False: 6.29k]
  ------------------
  785|      0|         return if_match(req, "PKCS9.FriendlyName", {1, 2, 840, 113549, 1, 9, 20});
  786|      0|      case 0x0D012:
  ------------------
  |  Branch (786:7): [True: 0, False: 6.29k]
  ------------------
  787|      0|         return if_match(req, "SphincsPlus-shake-128s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 1});
  788|      0|      case 0x0DCE9:
  ------------------
  |  Branch (788:7): [True: 0, False: 6.29k]
  ------------------
  789|      0|         return if_match(req, "ClassicMcEliece_8192128f", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 10});
  790|      0|      case 0x0E52A:
  ------------------
  |  Branch (790:7): [True: 0, False: 6.29k]
  ------------------
  791|      0|         return if_match(req, "numsp512d1", {1, 3, 6, 1, 4, 1, 25258, 4, 3});
  792|      0|      case 0x0F9CC:
  ------------------
  |  Branch (792:7): [True: 0, False: 6.29k]
  ------------------
  793|      0|         return if_match(req, "PKCS9.UnstructuredName", {1, 2, 840, 113549, 1, 9, 2});
  794|      0|      case 0x0FF45:
  ------------------
  |  Branch (794:7): [True: 0, False: 6.29k]
  ------------------
  795|      0|         return if_match(req, "Camellia-256/GCM", {0, 3, 4401, 5, 3, 1, 9, 46});
  796|      0|      case 0x1033D:
  ------------------
  |  Branch (796:7): [True: 0, False: 6.29k]
  ------------------
  797|      0|         return if_match(req, "DSA/SHA-3(384)", {2, 16, 840, 1, 101, 3, 4, 3, 7});
  798|      0|      case 0x1139D:
  ------------------
  |  Branch (798:7): [True: 0, False: 6.29k]
  ------------------
  799|      0|         return if_match(req, "secp192k1", {1, 3, 132, 0, 31});
  800|      0|      case 0x113D6:
  ------------------
  |  Branch (800:7): [True: 0, False: 6.29k]
  ------------------
  801|      0|         return if_match(req, "X520.DNQualifier", {2, 5, 4, 46});
  802|      0|      case 0x11A7A:
  ------------------
  |  Branch (802:7): [True: 0, False: 6.29k]
  ------------------
  803|      0|         return if_match(req, "secp192r1", {1, 2, 840, 10045, 3, 1, 1});
  804|      0|      case 0x12096:
  ------------------
  |  Branch (804:7): [True: 0, False: 6.29k]
  ------------------
  805|      0|         return if_match(req, "SM2_Kex", {1, 2, 156, 10197, 1, 301, 2});
  806|      0|      case 0x13FC1:
  ------------------
  |  Branch (806:7): [True: 0, False: 6.29k]
  ------------------
  807|      0|         return if_match(req, "X520.GenerationalQualifier", {2, 5, 4, 44});
  808|      0|      case 0x1445B:
  ------------------
  |  Branch (808:7): [True: 0, False: 6.29k]
  ------------------
  809|      0|         return if_match(req, "PKCS5.PBKDF2", {1, 2, 840, 113549, 1, 5, 12});
  810|      0|      case 0x1495D:
  ------------------
  |  Branch (810:7): [True: 0, False: 6.29k]
  ------------------
  811|      0|         return if_match(req, "eFrodoKEM-1344-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 17, 3});
  812|      0|      case 0x14E30:
  ------------------
  |  Branch (812:7): [True: 0, False: 6.29k]
  ------------------
  813|      0|         return if_match(req, "ClassicMcEliece_460896", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 3});
  814|      0|      case 0x14FB1:
  ------------------
  |  Branch (814:7): [True: 0, False: 6.29k]
  ------------------
  815|      0|         return if_match(req, "XMSS-draft12", {1, 3, 6, 1, 4, 1, 25258, 1, 8});
  816|      0|      case 0x156E3:
  ------------------
  |  Branch (816:7): [True: 0, False: 6.29k]
  ------------------
  817|      0|         return if_match(req, "Compression.Zlib", {1, 2, 840, 113549, 1, 9, 16, 3, 8});
  818|      0|      case 0x1579E:
  ------------------
  |  Branch (818:7): [True: 0, False: 6.29k]
  ------------------
  819|      0|         return if_match(req, "Streebog-512", {1, 2, 643, 7, 1, 1, 2, 3});
  820|      0|      case 0x1701A:
  ------------------
  |  Branch (820:7): [True: 0, False: 6.29k]
  ------------------
  821|      0|         return if_match(req, "X509v3.AnyExtendedKeyUsage", {2, 5, 29, 37, 0});
  822|      0|      case 0x175EF:
  ------------------
  |  Branch (822:7): [True: 0, False: 6.29k]
  ------------------
  823|      0|         return if_match(req, "Kyber-1024-90s-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 11, 3});
  824|      0|      case 0x17709:
  ------------------
  |  Branch (824:7): [True: 0, False: 6.29k]
  ------------------
  825|      0|         return if_match(req, "X520.GivenName", {2, 5, 4, 42});
  826|      0|      case 0x17AD9:
  ------------------
  |  Branch (826:7): [True: 0, False: 6.29k]
  ------------------
  827|      0|         return if_match(req, "RSA/PKCS1v15(SM3)", {1, 2, 156, 10197, 1, 504});
  828|      0|      case 0x17CE2:
  ------------------
  |  Branch (828:7): [True: 0, False: 6.29k]
  ------------------
  829|      0|         return if_match(req, "SLH-DSA-SHA2-256f", {2, 16, 840, 1, 101, 3, 4, 3, 25});
  830|      0|      case 0x17CEF:
  ------------------
  |  Branch (830:7): [True: 0, False: 6.29k]
  ------------------
  831|      0|         return if_match(req, "SLH-DSA-SHA2-256s", {2, 16, 840, 1, 101, 3, 4, 3, 24});
  832|      0|      case 0x18618:
  ------------------
  |  Branch (832:7): [True: 0, False: 6.29k]
  ------------------
  833|      0|         return if_match(req, "FrodoKEM-976-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 15, 2});
  834|      0|      case 0x19480:
  ------------------
  |  Branch (834:7): [True: 0, False: 6.29k]
  ------------------
  835|      0|         return if_match(req, "eFrodoKEM-1344-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 16, 3});
  836|      0|      case 0x1958A:
  ------------------
  |  Branch (836:7): [True: 0, False: 6.29k]
  ------------------
  837|      0|         return if_match(req, "X509v3.InvalidityDate", {2, 5, 29, 24});
  838|      0|      case 0x19851:
  ------------------
  |  Branch (838:7): [True: 0, False: 6.29k]
  ------------------
  839|      0|         return if_match(req, "DSA/SHA-1", {1, 2, 840, 10040, 4, 3});
  840|      0|      case 0x1B2E7:
  ------------------
  |  Branch (840:7): [True: 0, False: 6.29k]
  ------------------
  841|      0|         return if_match(req, "KeyWrap.AES-128", {2, 16, 840, 1, 101, 3, 4, 1, 5});
  842|      0|      case 0x1B9BE:
  ------------------
  |  Branch (842:7): [True: 0, False: 6.29k]
  ------------------
  843|      0|         return if_match(req, "KeyWrap.AES-192", {2, 16, 840, 1, 101, 3, 4, 1, 25});
  844|      0|      case 0x1D439:
  ------------------
  |  Branch (844:7): [True: 0, False: 6.29k]
  ------------------
  845|      0|         return if_match(req, "SphincsPlus-haraka-192f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 4});
  846|      0|      case 0x2065B:
  ------------------
  |  Branch (846:7): [True: 0, False: 6.29k]
  ------------------
  847|      0|         return if_match(req, "KeyWrap.CAST-128", {1, 2, 840, 113533, 7, 66, 15});
  848|      0|      case 0x216A0:
  ------------------
  |  Branch (848:7): [True: 0, False: 6.29k]
  ------------------
  849|      0|         return if_match(req, "ML-KEM-512", {2, 16, 840, 1, 101, 3, 4, 4, 1});
  850|      0|      case 0x2216B:
  ------------------
  |  Branch (850:7): [True: 0, False: 6.29k]
  ------------------
  851|      0|         return if_match(req, "GOST-34.10-2012-512", {1, 2, 643, 7, 1, 1, 1, 2});
  852|      0|      case 0x22C2C:
  ------------------
  |  Branch (852:7): [True: 0, False: 6.29k]
  ------------------
  853|      0|         return if_match(req, "ElGamal", {1, 3, 6, 1, 4, 1, 3029, 1, 2, 1});
  854|      0|      case 0x2559A:
  ------------------
  |  Branch (854:7): [True: 0, False: 6.29k]
  ------------------
  855|      0|         return if_match(req, "X520.Initials", {2, 5, 4, 43});
  856|      0|      case 0x271AC:
  ------------------
  |  Branch (856:7): [True: 0, False: 6.29k]
  ------------------
  857|      0|         return if_match(req, "PKIX.AutonomousSysIds", {1, 3, 6, 1, 5, 5, 7, 1, 8});
  858|      0|      case 0x2808B:
  ------------------
  |  Branch (858:7): [True: 0, False: 6.29k]
  ------------------
  859|      0|         return if_match(req, "PKCS7.Data", {1, 2, 840, 113549, 1, 7, 1});
  860|      0|      case 0x281B8:
  ------------------
  |  Branch (860:7): [True: 0, False: 6.29k]
  ------------------
  861|      0|         return if_match(req, "SphincsPlus-haraka-128s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 1});
  862|      0|      case 0x282FE:
  ------------------
  |  Branch (862:7): [True: 0, False: 6.29k]
  ------------------
  863|      0|         return if_match(req, "PKIX.OCSP.Nonce", {1, 3, 6, 1, 5, 5, 7, 48, 1, 2});
  864|      0|      case 0x29999:
  ------------------
  |  Branch (864:7): [True: 0, False: 6.29k]
  ------------------
  865|      0|         return if_match(req, "DSA/SHA-3(256)", {2, 16, 840, 1, 101, 3, 4, 3, 6});
  866|      0|      case 0x2A83D:
  ------------------
  |  Branch (866:7): [True: 0, False: 6.29k]
  ------------------
  867|      0|         return if_match(req, "SHA-224", {2, 16, 840, 1, 101, 3, 4, 2, 4});
  868|      0|      case 0x2AB30:
  ------------------
  |  Branch (868:7): [True: 0, False: 6.29k]
  ------------------
  869|      0|         return if_match(req, "SHA-256", {2, 16, 840, 1, 101, 3, 4, 2, 1});
  870|      0|      case 0x2ABEF:
  ------------------
  |  Branch (870:7): [True: 0, False: 6.29k]
  ------------------
  871|      0|         return if_match(req, "KeyWrap.AES-256", {2, 16, 840, 1, 101, 3, 4, 1, 45});
  872|      0|      case 0x2BAEF:
  ------------------
  |  Branch (872:7): [True: 0, False: 6.29k]
  ------------------
  873|      0|         return if_match(req, "SM2_Sig/SM3", {1, 2, 156, 10197, 1, 501});
  874|      0|      case 0x2C39A:
  ------------------
  |  Branch (874:7): [True: 0, False: 6.29k]
  ------------------
  875|      0|         return if_match(req, "ECGDSA/RIPEMD-160", {1, 3, 36, 3, 3, 2, 5, 4, 1});
  876|      0|      case 0x2C54F:
  ------------------
  |  Branch (876:7): [True: 0, False: 6.29k]
  ------------------
  877|      0|         return if_match(req, "ECDSA/SHA-3(224)", {2, 16, 840, 1, 101, 3, 4, 3, 9});
  878|      0|      case 0x2EEA6:
  ------------------
  |  Branch (878:7): [True: 0, False: 6.29k]
  ------------------
  879|      0|         return if_match(req, "RSA/PKCS1v15(RIPEMD-160)", {1, 3, 36, 3, 3, 1, 2});
  880|      0|      case 0x2EFBA:
  ------------------
  |  Branch (880:7): [True: 0, False: 6.29k]
  ------------------
  881|      0|         return if_match(req, "Kyber-512-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 7, 1});
  882|      0|      case 0x2F0AD:
  ------------------
  |  Branch (882:7): [True: 0, False: 6.29k]
  ------------------
  883|      0|         return if_match(req, "PKCS7.EncryptedData", {1, 2, 840, 113549, 1, 7, 6});
  884|      0|      case 0x2F219:
  ------------------
  |  Branch (884:7): [True: 0, False: 6.29k]
  ------------------
  885|      0|         return if_match(req, "PBE-SHA1-2DES", {1, 2, 840, 113549, 1, 12, 1, 4});
  886|      0|      case 0x3133E:
  ------------------
  |  Branch (886:7): [True: 0, False: 6.29k]
  ------------------
  887|      0|         return if_match(req, "SLH-DSA-SHA2-128f", {2, 16, 840, 1, 101, 3, 4, 3, 21});
  888|      0|      case 0x3134B:
  ------------------
  |  Branch (888:7): [True: 0, False: 6.29k]
  ------------------
  889|      0|         return if_match(req, "SLH-DSA-SHA2-128s", {2, 16, 840, 1, 101, 3, 4, 3, 20});
  890|      0|      case 0x3160D:
  ------------------
  |  Branch (890:7): [True: 0, False: 6.29k]
  ------------------
  891|      0|         return if_match(req, "RSA/PKCS1v15(SHA-3(224))", {2, 16, 840, 1, 101, 3, 4, 3, 13});
  892|      0|      case 0x319E0:
  ------------------
  |  Branch (892:7): [True: 0, False: 6.29k]
  ------------------
  893|      0|         return if_match(req, "GOST-34.10-2012-256/Streebog-256", {1, 2, 643, 7, 1, 1, 3, 2});
  894|      0|      case 0x31B3D:
  ------------------
  |  Branch (894:7): [True: 0, False: 6.29k]
  ------------------
  895|      0|         return if_match(req, "HMAC(SHA-512)", {1, 2, 840, 113549, 2, 11});
  896|      0|      case 0x31C6D:
  ------------------
  |  Branch (896:7): [True: 0, False: 6.29k]
  ------------------
  897|      0|         return if_match(req, "secp384r1", {1, 3, 132, 0, 34});
  898|      0|      case 0x32899:
  ------------------
  |  Branch (898:7): [True: 0, False: 6.29k]
  ------------------
  899|      0|         return if_match(req, "TripleDES/CBC", {1, 2, 840, 113549, 3, 7});
  900|      0|      case 0x33C9C:
  ------------------
  |  Branch (900:7): [True: 0, False: 6.29k]
  ------------------
  901|      0|         return if_match(req, "PKIX.SmtpUTF8Mailbox", {1, 3, 6, 1, 5, 5, 7, 8, 9});
  902|      0|      case 0x33D04:
  ------------------
  |  Branch (902:7): [True: 0, False: 6.29k]
  ------------------
  903|      0|         return if_match(req, "PKCS12.SecretBag", {1, 2, 840, 113549, 1, 12, 10, 1, 5});
  904|      0|      case 0x3615D:
  ------------------
  |  Branch (904:7): [True: 0, False: 6.29k]
  ------------------
  905|      0|         return if_match(req, "FrodoKEM-976-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 14, 2});
  906|      0|      case 0x361B8:
  ------------------
  |  Branch (906:7): [True: 0, False: 6.29k]
  ------------------
  907|      0|         return if_match(req, "Ed25519", {1, 3, 101, 112});
  908|      0|      case 0x3649D:
  ------------------
  |  Branch (908:7): [True: 0, False: 6.29k]
  ------------------
  909|      0|         return if_match(req, "SHAKE-128", {2, 16, 840, 1, 101, 3, 4, 2, 11});
  910|      0|      case 0x36693:
  ------------------
  |  Branch (910:7): [True: 0, False: 6.29k]
  ------------------
  911|      0|         return if_match(req, "ClassicMcEliece_348864", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 1});
  912|      0|      case 0x373C7:
  ------------------
  |  Branch (912:7): [True: 0, False: 6.29k]
  ------------------
  913|      0|         return if_match(req, "ML-DSA-4x4", {2, 16, 840, 1, 101, 3, 4, 3, 17});
  914|      0|      case 0x3750B:
  ------------------
  |  Branch (914:7): [True: 0, False: 6.29k]
  ------------------
  915|      0|         return if_match(req, "ClassicMcEliece_8192128", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 9});
  916|      0|      case 0x39890:
  ------------------
  |  Branch (916:7): [True: 0, False: 6.29k]
  ------------------
  917|      0|         return if_match(req, "Ed448", {1, 3, 101, 113});
  918|      0|      case 0x3A438:
  ------------------
  |  Branch (918:7): [True: 0, False: 6.29k]
  ------------------
  919|      0|         return if_match(req, "SHA-384", {2, 16, 840, 1, 101, 3, 4, 2, 2});
  920|      0|      case 0x3A963:
  ------------------
  |  Branch (920:7): [True: 0, False: 6.29k]
  ------------------
  921|      0|         return if_match(req, "DH", {1, 2, 840, 10046, 2, 1});
  922|      0|      case 0x3AC83:
  ------------------
  |  Branch (922:7): [True: 0, False: 6.29k]
  ------------------
  923|      0|         return if_match(req, "MGF1", {1, 2, 840, 113549, 1, 1, 8});
  924|      0|      case 0x3ACBA:
  ------------------
  |  Branch (924:7): [True: 0, False: 6.29k]
  ------------------
  925|      0|         return if_match(req, "X509v3.IssuerAlternativeName", {2, 5, 29, 18});
  926|      0|      case 0x3B273:
  ------------------
  |  Branch (926:7): [True: 0, False: 6.29k]
  ------------------
  927|      0|         return if_match(req, "KeyWrap.TripleDES", {1, 2, 840, 113549, 1, 9, 16, 3, 6});
  928|      0|      case 0x3B91E:
  ------------------
  |  Branch (928:7): [True: 0, False: 6.29k]
  ------------------
  929|      0|         return if_match(req, "X509v3.PrivateKeyUsagePeriod", {2, 5, 29, 16});
  930|      0|      case 0x3BC8A:
  ------------------
  |  Branch (930:7): [True: 0, False: 6.29k]
  ------------------
  931|      0|         return if_match(req, "SLH-DSA-SHAKE-192f", {2, 16, 840, 1, 101, 3, 4, 3, 29});
  932|      0|      case 0x3BC97:
  ------------------
  |  Branch (932:7): [True: 0, False: 6.29k]
  ------------------
  933|      0|         return if_match(req, "SLH-DSA-SHAKE-192s", {2, 16, 840, 1, 101, 3, 4, 3, 28});
  934|      0|      case 0x3D127:
  ------------------
  |  Branch (934:7): [True: 0, False: 6.29k]
  ------------------
  935|      0|         return if_match(req, "DSA", {1, 2, 840, 10040, 4, 1});
  936|      0|      case 0x3E249:
  ------------------
  |  Branch (936:7): [True: 0, False: 6.29k]
  ------------------
  937|      0|         return if_match(req, "HSS-LMS", {1, 2, 840, 113549, 1, 9, 16, 3, 17});
  938|      0|      case 0x3E7D5:
  ------------------
  |  Branch (938:7): [True: 0, False: 6.29k]
  ------------------
  939|      0|         return if_match(req, "RSA/PKCS1v15(SHA-3(256))", {2, 16, 840, 1, 101, 3, 4, 3, 14});
  940|      0|      case 0x3F748:
  ------------------
  |  Branch (940:7): [True: 0, False: 6.29k]
  ------------------
  941|      0|         return if_match(req, "GOST.OGRN", {1, 2, 643, 100, 1});
  942|      0|      case 0x3F99F:
  ------------------
  |  Branch (942:7): [True: 0, False: 6.29k]
  ------------------
  943|      0|         return if_match(req, "X509v3.BasicConstraints", {2, 5, 29, 19});
  944|      0|      case 0x40726:
  ------------------
  |  Branch (944:7): [True: 0, False: 6.29k]
  ------------------
  945|      0|         return if_match(req, "SHA-3(512)", {2, 16, 840, 1, 101, 3, 4, 2, 10});
  946|      0|      case 0x407BF:
  ------------------
  |  Branch (946:7): [True: 0, False: 6.29k]
  ------------------
  947|      0|         return if_match(req, "ML-KEM-768", {2, 16, 840, 1, 101, 3, 4, 4, 2});
  948|      0|      case 0x41334:
  ------------------
  |  Branch (948:7): [True: 0, False: 6.29k]
  ------------------
  949|      0|         return if_match(req, "ECDSA/SHA-3(384)", {2, 16, 840, 1, 101, 3, 4, 3, 11});
  950|      0|      case 0x42DF3:
  ------------------
  |  Branch (950:7): [True: 0, False: 6.29k]
  ------------------
  951|      0|         return if_match(req, "X509v3.CRLDistributionPoints", {2, 5, 29, 31});
  952|      0|      case 0x437FB:
  ------------------
  |  Branch (952:7): [True: 0, False: 6.29k]
  ------------------
  953|      0|         return if_match(req, "brainpool160r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 1});
  954|      0|      case 0x441F5:
  ------------------
  |  Branch (954:7): [True: 0, False: 6.29k]
  ------------------
  955|      0|         return if_match(req, "gost_256A", {1, 2, 643, 7, 1, 2, 1, 1, 1});
  956|      0|      case 0x441F6:
  ------------------
  |  Branch (956:7): [True: 0, False: 6.29k]
  ------------------
  957|      0|         return if_match(req, "gost_256B", {1, 2, 643, 7, 1, 2, 1, 1, 2});
  958|      0|      case 0x44221:
  ------------------
  |  Branch (958:7): [True: 0, False: 6.29k]
  ------------------
  959|      0|         return if_match(req, "GOST-34.10-2012-512/Streebog-512", {1, 2, 643, 7, 1, 1, 3, 3});
  960|      0|      case 0x44322:
  ------------------
  |  Branch (960:7): [True: 0, False: 6.29k]
  ------------------
  961|      0|         return if_match(req, "ClassicMcEliece_6960119pc", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 3});
  962|      0|      case 0x44973:
  ------------------
  |  Branch (962:7): [True: 0, False: 6.29k]
  ------------------
  963|      0|         return if_match(req, "Kyber-512-90s-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 11, 1});
  964|      0|      case 0x45C27:
  ------------------
  |  Branch (964:7): [True: 0, False: 6.29k]
  ------------------
  965|      0|         return if_match(req, "RSA/PKCS1v15(SHA-512-256)", {1, 2, 840, 113549, 1, 1, 16});
  966|      0|      case 0x45C85:
  ------------------
  |  Branch (966:7): [True: 0, False: 6.29k]
  ------------------
  967|      0|         return if_match(req, "X509v3.ReasonCode", {2, 5, 29, 21});
  968|      0|      case 0x45DA5:
  ------------------
  |  Branch (968:7): [True: 0, False: 6.29k]
  ------------------
  969|      0|         return if_match(req, "SHAKE-256", {2, 16, 840, 1, 101, 3, 4, 2, 12});
  970|      0|      case 0x4663C:
  ------------------
  |  Branch (970:7): [True: 0, False: 6.29k]
  ------------------
  971|      0|         return if_match(req, "X509v3.PolicyConstraints", {2, 5, 29, 36});
  972|      0|      case 0x480F7:
  ------------------
  |  Branch (972:7): [True: 0, False: 6.29k]
  ------------------
  973|      0|         return if_match(req, "Serpent/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 4});
  974|      0|      case 0x48627:
  ------------------
  |  Branch (974:7): [True: 0, False: 6.29k]
  ------------------
  975|      0|         return if_match(req, "Dilithium-4x4-AES-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 10, 1});
  976|      0|      case 0x48861:
  ------------------
  |  Branch (976:7): [True: 0, False: 6.29k]
  ------------------
  977|      0|         return if_match(req, "ChaCha20Poly1305", {1, 2, 840, 113549, 1, 9, 16, 3, 18});
  978|      0|      case 0x4A292:
  ------------------
  |  Branch (978:7): [True: 0, False: 6.29k]
  ------------------
  979|      0|         return if_match(req, "frp256v1", {1, 2, 250, 1, 223, 101, 256, 1});
  980|      0|      case 0x4A9EE:
  ------------------
  |  Branch (980:7): [True: 0, False: 6.29k]
  ------------------
  981|      0|         return if_match(req, "ClassicMcEliece_6960119f", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 8});
  982|      0|      case 0x4BF87:
  ------------------
  |  Branch (982:7): [True: 0, False: 6.29k]
  ------------------
  983|      0|         return if_match(req, "PKIX.TNAuthList", {1, 3, 6, 1, 5, 5, 7, 1, 26});
  984|      0|      case 0x4C088:
  ------------------
  |  Branch (984:7): [True: 0, False: 6.29k]
  ------------------
  985|      0|         return if_match(req, "eFrodoKEM-976-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 17, 2});
  986|      0|      case 0x4C513:
  ------------------
  |  Branch (986:7): [True: 0, False: 6.29k]
  ------------------
  987|      0|         return if_match(req, "DSA/SHA-224", {2, 16, 840, 1, 101, 3, 4, 3, 1});
  988|      0|      case 0x4C806:
  ------------------
  |  Branch (988:7): [True: 0, False: 6.29k]
  ------------------
  989|      0|         return if_match(req, "DSA/SHA-256", {2, 16, 840, 1, 101, 3, 4, 3, 2});
  990|      0|      case 0x4D740:
  ------------------
  |  Branch (990:7): [True: 0, False: 6.29k]
  ------------------
  991|      0|         return if_match(req, "X509v3.AnyPolicy", {2, 5, 29, 32, 0});
  992|      0|      case 0x4DE49:
  ------------------
  |  Branch (992:7): [True: 0, False: 6.29k]
  ------------------
  993|      0|         return if_match(req, "RSA/PKCS1v15(SHA-512)", {1, 2, 840, 113549, 1, 1, 13});
  994|      0|      case 0x4ED5D:
  ------------------
  |  Branch (994:7): [True: 0, False: 6.29k]
  ------------------
  995|      0|         return if_match(req, "CAST-128/CBC", {1, 2, 840, 113533, 7, 66, 10});
  996|      0|      case 0x4FCDC:
  ------------------
  |  Branch (996:7): [True: 0, False: 6.29k]
  ------------------
  997|      0|         return if_match(req, "RSA", {1, 2, 840, 113549, 1, 1, 1});
  998|      0|      case 0x501CB:
  ------------------
  |  Branch (998:7): [True: 0, False: 6.29k]
  ------------------
  999|      0|         return if_match(req, "ECDSA/SHA-224", {1, 2, 840, 10045, 4, 3, 1});
 1000|      0|      case 0x50395:
  ------------------
  |  Branch (1000:7): [True: 0, False: 6.29k]
  ------------------
 1001|      0|         return if_match(req, "GOST-34.10/GOST-R-34.11-94", {1, 2, 643, 2, 2, 3});
 1002|      0|      case 0x504BE:
  ------------------
  |  Branch (1002:7): [True: 0, False: 6.29k]
  ------------------
 1003|      0|         return if_match(req, "ECDSA/SHA-256", {1, 2, 840, 10045, 4, 3, 2});
 1004|      0|      case 0x509C3:
  ------------------
  |  Branch (1004:7): [True: 0, False: 6.29k]
  ------------------
 1005|      0|         return if_match(req, "brainpool192r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 3});
 1006|      0|      case 0x509F9:
  ------------------
  |  Branch (1006:7): [True: 0, False: 6.29k]
  ------------------
 1007|      0|         return if_match(req, "PKCS9.ContentType", {1, 2, 840, 113549, 1, 9, 3});
 1008|      0|      case 0x50B26:
  ------------------
  |  Branch (1008:7): [True: 0, False: 6.29k]
  ------------------
 1009|      0|         return if_match(req, "FrodoKEM-640-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 15, 1});
 1010|      0|      case 0x50D78:
  ------------------
  |  Branch (1010:7): [True: 0, False: 6.29k]
  ------------------
 1011|      0|         return if_match(req, "x962_p192v2", {1, 2, 840, 10045, 3, 1, 2});
 1012|      0|      case 0x50D79:
  ------------------
  |  Branch (1012:7): [True: 0, False: 6.29k]
  ------------------
 1013|      0|         return if_match(req, "x962_p192v3", {1, 2, 840, 10045, 3, 1, 3});
 1014|      0|      case 0x51DC6:
  ------------------
  |  Branch (1014:7): [True: 0, False: 6.29k]
  ------------------
 1015|      0|         return if_match(req, "AES-128/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 1});
 1016|      0|      case 0x52DB6:
  ------------------
  |  Branch (1016:7): [True: 0, False: 6.29k]
  ------------------
 1017|      0|         return if_match(req, "HMAC(SHA-224)", {1, 2, 840, 113549, 2, 8});
 1018|      0|      case 0x53E11:
  ------------------
  |  Branch (1018:7): [True: 0, False: 6.29k]
  ------------------
 1019|      0|         return if_match(req, "FrodoKEM-1344-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 14, 3});
 1020|      0|      case 0x54012:
  ------------------
  |  Branch (1020:7): [True: 0, False: 6.29k]
  ------------------
 1021|      0|         return if_match(req, "PKIX.TimeStamping", {1, 3, 6, 1, 5, 5, 7, 3, 8});
 1022|      0|      case 0x5407A:
  ------------------
  |  Branch (1022:7): [True: 0, False: 6.29k]
  ------------------
 1023|      0|         return if_match(req, "Serpent/CBC", {1, 3, 6, 1, 4, 1, 25258, 3, 1});
 1024|      0|      case 0x5576D:
  ------------------
  |  Branch (1024:7): [True: 0, False: 6.29k]
  ------------------
 1025|      0|         return if_match(req, "SphincsPlus-sha2-128f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 2});
 1026|      0|      case 0x55EF6:
  ------------------
  |  Branch (1026:7): [True: 0, False: 6.29k]
  ------------------
 1027|      0|         return if_match(req, "AES-192/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 2});
 1028|      0|      case 0x55FFA:
  ------------------
  |  Branch (1028:7): [True: 0, False: 6.29k]
  ------------------
 1029|      0|         return if_match(req, "ML-DSA-6x5", {2, 16, 840, 1, 101, 3, 4, 3, 18});
 1030|      0|      case 0x56826:
  ------------------
  |  Branch (1030:7): [True: 0, False: 6.29k]
  ------------------
 1031|      0|         return if_match(req, "brainpool320r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 9});
 1032|      0|      case 0x56D0D:
  ------------------
  |  Branch (1032:7): [True: 0, False: 6.29k]
  ------------------
 1033|      0|         return if_match(req, "SphincsPlus-shake-128f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 2});
 1034|      0|      case 0x57077:
  ------------------
  |  Branch (1034:7): [True: 0, False: 6.29k]
  ------------------
 1035|      0|         return if_match(req, "XMSS-draft6", {1, 3, 6, 1, 4, 1, 25258, 1, 5});
 1036|      0|      case 0x5818B:
  ------------------
  |  Branch (1036:7): [True: 0, False: 6.29k]
  ------------------
 1037|      0|         return if_match(req, "ECGDSA/SHA-224", {1, 3, 36, 3, 3, 2, 5, 4, 3});
 1038|      0|      case 0x5847E:
  ------------------
  |  Branch (1038:7): [True: 0, False: 6.29k]
  ------------------
 1039|      0|         return if_match(req, "ECGDSA/SHA-256", {1, 3, 36, 3, 3, 2, 5, 4, 4});
 1040|      0|      case 0x5898B:
  ------------------
  |  Branch (1040:7): [True: 0, False: 6.29k]
  ------------------
 1041|      0|         return if_match(req, "SHA-512", {2, 16, 840, 1, 101, 3, 4, 2, 3});
 1042|      0|      case 0x58991:
  ------------------
  |  Branch (1042:7): [True: 0, False: 6.29k]
  ------------------
 1043|      0|         return if_match(req, "PKIX.OCSP.NoCheck", {1, 3, 6, 1, 5, 5, 7, 48, 1, 5});
 1044|      0|      case 0x59717:
  ------------------
  |  Branch (1044:7): [True: 0, False: 6.29k]
  ------------------
 1045|      0|         return if_match(req, "X509v3.SubjectKeyIdentifier", {2, 5, 29, 14});
 1046|      0|      case 0x5A1E1:
  ------------------
  |  Branch (1046:7): [True: 0, False: 6.29k]
  ------------------
 1047|      0|         return if_match(req, "PKCS12.KeyBag", {1, 2, 840, 113549, 1, 12, 10, 1, 1});
 1048|      0|      case 0x5A570:
  ------------------
  |  Branch (1048:7): [True: 0, False: 6.29k]
  ------------------
 1049|      0|         return if_match(req, "X520.CommonName", {2, 5, 4, 3});
 1050|      0|      case 0x5A990:
  ------------------
  |  Branch (1050:7): [True: 0, False: 6.29k]
  ------------------
 1051|      0|         return if_match(req, "ECDSA/SHA-3(256)", {2, 16, 840, 1, 101, 3, 4, 3, 10});
 1052|      0|      case 0x5AB0E:
  ------------------
  |  Branch (1052:7): [True: 0, False: 6.29k]
  ------------------
 1053|      0|         return if_match(req, "SphincsPlus-sha2-256s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 5});
 1054|      0|      case 0x5AC4A:
  ------------------
  |  Branch (1054:7): [True: 0, False: 6.29k]
  ------------------
 1055|      0|         return if_match(req, "X520.Surname", {2, 5, 4, 4});
 1056|      0|      case 0x5AF2C:
  ------------------
  |  Branch (1056:7): [True: 0, False: 6.29k]
  ------------------
 1057|      0|         return if_match(req, "ClassicMcEliece_8192128pc", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 5});
 1058|      0|      case 0x5BC39:
  ------------------
  |  Branch (1058:7): [True: 0, False: 6.29k]
  ------------------
 1059|      0|         return if_match(req, "X509v3.KeyUsage", {2, 5, 29, 15});
 1060|      0|      case 0x5BDDB:
  ------------------
  |  Branch (1060:7): [True: 0, False: 6.29k]
  ------------------
 1061|      0|         return if_match(req, "numsp256d1", {1, 3, 6, 1, 4, 1, 25258, 4, 1});
 1062|      0|      case 0x5C0AE:
  ------------------
  |  Branch (1062:7): [True: 0, False: 6.29k]
  ------------------
 1063|      0|         return if_match(req, "SphincsPlus-shake-256s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 5});
 1064|      0|      case 0x5C10E:
  ------------------
  |  Branch (1064:7): [True: 0, False: 6.29k]
  ------------------
 1065|      0|         return if_match(req, "DSA/SHA-384", {2, 16, 840, 1, 101, 3, 4, 3, 3});
 1066|      0|      case 0x5CFE5:
  ------------------
  |  Branch (1066:7): [True: 0, False: 6.29k]
  ------------------
 1067|      0|         return if_match(req, "PKCS9.X509Certificate", {1, 2, 840, 113549, 1, 9, 22, 1});
 1068|      0|      case 0x5D1CF:
  ------------------
  |  Branch (1068:7): [True: 0, False: 6.29k]
  ------------------
 1069|      0|         return if_match(req, "X520.SerialNumber", {2, 5, 4, 5});
 1070|      0|      case 0x5D375:
  ------------------
  |  Branch (1070:7): [True: 0, False: 6.29k]
  ------------------
 1071|      0|         return if_match(req, "SM4/OCB", {1, 2, 156, 10197, 1, 104, 100});
 1072|      0|      case 0x5DD49:
  ------------------
  |  Branch (1072:7): [True: 0, False: 6.29k]
  ------------------
 1073|      0|         return if_match(req, "AES-128/CBC", {2, 16, 840, 1, 101, 3, 4, 1, 2});
 1074|      0|      case 0x5DE4E:
  ------------------
  |  Branch (1074:7): [True: 0, False: 6.29k]
  ------------------
 1075|      0|         return if_match(req, "AES-128/CCM", {2, 16, 840, 1, 101, 3, 4, 1, 7});
 1076|      0|      case 0x5DF23:
  ------------------
  |  Branch (1076:7): [True: 0, False: 6.29k]
  ------------------
 1077|      0|         return if_match(req, "HMAC(SHA-512-256)", {1, 2, 840, 113549, 2, 13});
 1078|      0|      case 0x5ED04:
  ------------------
  |  Branch (1078:7): [True: 0, False: 6.29k]
  ------------------
 1079|      0|         return if_match(req, "SM2", {1, 2, 156, 10197, 1, 301, 1});
 1080|      0|      case 0x5ED05:
  ------------------
  |  Branch (1080:7): [True: 0, False: 6.29k]
  ------------------
 1081|      0|         return if_match(req, "SM3", {1, 2, 156, 10197, 1, 401});
 1082|      0|      case 0x5FDC6:
  ------------------
  |  Branch (1082:7): [True: 0, False: 6.29k]
  ------------------
 1083|      0|         return if_match(req, "ECDSA/SHA-384", {1, 2, 840, 10045, 4, 3, 3});
 1084|      0|      case 0x6199F:
  ------------------
  |  Branch (1084:7): [True: 0, False: 6.29k]
  ------------------
 1085|      0|         return if_match(req, "SHA-3(224)", {2, 16, 840, 1, 101, 3, 4, 2, 7});
 1086|      0|      case 0x61E79:
  ------------------
  |  Branch (1086:7): [True: 0, False: 6.29k]
  ------------------
 1087|      0|         return if_match(req, "AES-192/CBC", {2, 16, 840, 1, 101, 3, 4, 1, 22});
 1088|      0|      case 0x61F7E:
  ------------------
  |  Branch (1088:7): [True: 0, False: 6.29k]
  ------------------
 1089|      0|         return if_match(req, "AES-192/CCM", {2, 16, 840, 1, 101, 3, 4, 1, 27});
 1090|      0|      case 0x64947:
  ------------------
  |  Branch (1090:7): [True: 0, False: 6.29k]
  ------------------
 1091|      0|         return if_match(req, "OpenPGP.Ed25519", {1, 3, 6, 1, 4, 1, 11591, 15, 1});
 1092|      2|      case 0x652E7:
  ------------------
  |  Branch (1092:7): [True: 2, False: 6.29k]
  ------------------
 1093|      2|         return if_match(req, "sm2p256v1", {1, 2, 156, 10197, 1, 301});
 1094|      0|      case 0x6697B:
  ------------------
  |  Branch (1094:7): [True: 0, False: 6.29k]
  ------------------
 1095|      0|         return if_match(req, "FrodoKEM-1344-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 15, 3});
 1096|      0|      case 0x67B2C:
  ------------------
  |  Branch (1096:7): [True: 0, False: 6.29k]
  ------------------
 1097|      0|         return if_match(req, "X520.State", {2, 5, 4, 8});
 1098|      0|      case 0x67B9B:
  ------------------
  |  Branch (1098:7): [True: 0, False: 6.29k]
  ------------------
 1099|      0|         return if_match(req, "HMAC(SHA-384)", {1, 2, 840, 113549, 2, 10});
 1100|      0|      case 0x67D86:
  ------------------
  |  Branch (1100:7): [True: 0, False: 6.29k]
  ------------------
 1101|      0|         return if_match(req, "ECGDSA/SHA-384", {1, 3, 36, 3, 3, 2, 5, 4, 5});
 1102|      0|      case 0x68A0B:
  ------------------
  |  Branch (1102:7): [True: 0, False: 6.29k]
  ------------------
 1103|      0|         return if_match(req, "Camellia-128/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 6});
 1104|      0|      case 0x68E33:
  ------------------
  |  Branch (1104:7): [True: 0, False: 6.29k]
  ------------------
 1105|      0|         return if_match(req, "PKCS9.ExtensionRequest", {1, 2, 840, 113549, 1, 9, 14});
 1106|      0|      case 0x69126:
  ------------------
  |  Branch (1106:7): [True: 0, False: 6.29k]
  ------------------
 1107|      0|         return if_match(req, "X509v3.SubjectAlternativeName", {2, 5, 29, 17});
 1108|      0|      case 0x692F8:
  ------------------
  |  Branch (1108:7): [True: 0, False: 6.29k]
  ------------------
 1109|      0|         return if_match(req, "SM4/CBC", {1, 2, 156, 10197, 1, 104, 2});
 1110|      0|      case 0x695E1:
  ------------------
  |  Branch (1110:7): [True: 0, False: 6.29k]
  ------------------
 1111|      0|         return if_match(req, "Dilithium-4x4-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 9, 1});
 1112|      0|      case 0x696DC:
  ------------------
  |  Branch (1112:7): [True: 0, False: 6.29k]
  ------------------
 1113|      0|         return if_match(req, "PKIX.IpAddrBlocks", {1, 3, 6, 1, 5, 5, 7, 1, 7});
 1114|      0|      case 0x6A7CA:
  ------------------
  |  Branch (1114:7): [True: 0, False: 6.29k]
  ------------------
 1115|      0|         return if_match(req, "ECDSA", {1, 2, 840, 10045, 2, 1});
 1116|      0|      case 0x6BD26:
  ------------------
  |  Branch (1116:7): [True: 0, False: 6.29k]
  ------------------
 1117|      0|         return if_match(req, "GOST.INN", {1, 2, 643, 3, 131, 1, 1});
 1118|      0|      case 0x6CB3B:
  ------------------
  |  Branch (1118:7): [True: 0, False: 6.29k]
  ------------------
 1119|      0|         return if_match(req, "Camellia-192/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 7});
 1120|      0|      case 0x6E602:
  ------------------
  |  Branch (1120:7): [True: 0, False: 6.29k]
  ------------------
 1121|      0|         return if_match(req, "Dilithium-8x7-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 9, 3});
 1122|      0|      case 0x6F0C2:
  ------------------
  |  Branch (1122:7): [True: 0, False: 6.29k]
  ------------------
 1123|      0|         return if_match(req, "RSA/PKCS1v15(SHA-224)", {1, 2, 840, 113549, 1, 1, 14});
 1124|      0|      case 0x6F9F8:
  ------------------
  |  Branch (1124:7): [True: 0, False: 6.29k]
  ------------------
 1125|      0|         return if_match(req, "PKCS12.SafeContentsBag", {1, 2, 840, 113549, 1, 12, 10, 1, 6});
 1126|      0|      case 0x6FB26:
  ------------------
  |  Branch (1126:7): [True: 0, False: 6.29k]
  ------------------
 1127|      0|         return if_match(req, "PKIX.AuthorityInformationAccess", {1, 3, 6, 1, 5, 5, 7, 1, 1});
 1128|      0|      case 0x70BB6:
  ------------------
  |  Branch (1128:7): [True: 0, False: 6.29k]
  ------------------
 1129|      0|         return if_match(req, "brainpool384r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 11});
 1130|      0|      case 0x70EA6:
  ------------------
  |  Branch (1130:7): [True: 0, False: 6.29k]
  ------------------
 1131|      0|         return if_match(req, "PKCS12.PKCS8ShroudedKeyBag", {1, 2, 840, 113549, 1, 12, 10, 1, 2});
 1132|      0|      case 0x71EB3:
  ------------------
  |  Branch (1132:7): [True: 0, False: 6.29k]
  ------------------
 1133|      0|         return if_match(req, "SphincsPlus-haraka-128f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 2});
 1134|      0|      case 0x7382C:
  ------------------
  |  Branch (1134:7): [True: 0, False: 6.29k]
  ------------------
 1135|      0|         return if_match(req, "ML-KEM-1024", {2, 16, 840, 1, 101, 3, 4, 4, 3});
 1136|      0|      case 0x743BD:
  ------------------
  |  Branch (1136:7): [True: 0, False: 6.29k]
  ------------------
 1137|      0|         return if_match(req, "AES-256/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 3});
 1138|      0|      case 0x7498E:
  ------------------
  |  Branch (1138:7): [True: 0, False: 6.29k]
  ------------------
 1139|      0|         return if_match(req, "Camellia-128/CBC", {1, 2, 392, 200011, 61, 1, 1, 1, 2});
 1140|      0|      case 0x74C2E:
  ------------------
  |  Branch (1140:7): [True: 0, False: 6.29k]
  ------------------
 1141|      0|         return if_match(req, "ML-DSA-8x7", {2, 16, 840, 1, 101, 3, 4, 3, 19});
 1142|      0|      case 0x7505F:
  ------------------
  |  Branch (1142:7): [True: 0, False: 6.29k]
  ------------------
 1143|      0|         return if_match(req, "PKIX.XMPPAddr", {1, 3, 6, 1, 5, 5, 7, 8, 5});
 1144|      0|      case 0x7517A:
  ------------------
  |  Branch (1144:7): [True: 0, False: 6.29k]
  ------------------
 1145|      0|         return if_match(req, "RSA/PKCS1v15(MD2)", {1, 2, 840, 113549, 1, 1, 2});
 1146|      0|      case 0x7546B:
  ------------------
  |  Branch (1146:7): [True: 0, False: 6.29k]
  ------------------
 1147|      0|         return if_match(req, "RSA/PKCS1v15(MD5)", {1, 2, 840, 113549, 1, 1, 4});
 1148|      0|      case 0x75921:
  ------------------
  |  Branch (1148:7): [True: 0, False: 6.29k]
  ------------------
 1149|      0|         return if_match(req, "ClassicMcEliece_348864f", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 2});
 1150|      0|      case 0x76784:
  ------------------
  |  Branch (1150:7): [True: 0, False: 6.29k]
  ------------------
 1151|      0|         return if_match(req, "SHA-3(384)", {2, 16, 840, 1, 101, 3, 4, 2, 9});
 1152|      0|      case 0x768FD:
  ------------------
  |  Branch (1152:7): [True: 0, False: 6.29k]
  ------------------
 1153|      0|         return if_match(req, "PKCS9.LocalKeyId", {1, 2, 840, 113549, 1, 9, 21});
 1154|      0|      case 0x76A19:
  ------------------
  |  Branch (1154:7): [True: 0, False: 6.29k]
  ------------------
 1155|      0|         return if_match(req, "brainpool512r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 13});
 1156|      0|      case 0x77254:
  ------------------
  |  Branch (1156:7): [True: 0, False: 6.29k]
  ------------------
 1157|      0|         return if_match(req, "SphincsPlus-haraka-256s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 5});
 1158|      0|      case 0x77ADC:
  ------------------
  |  Branch (1158:7): [True: 0, False: 6.29k]
  ------------------
 1159|      0|         return if_match(req, "secp224k1", {1, 3, 132, 0, 32});
 1160|      0|      case 0x781B9:
  ------------------
  |  Branch (1160:7): [True: 0, False: 6.29k]
  ------------------
 1161|      0|         return if_match(req, "secp224r1", {1, 3, 132, 0, 33});
 1162|      0|      case 0x78ABE:
  ------------------
  |  Branch (1162:7): [True: 0, False: 6.29k]
  ------------------
 1163|      0|         return if_match(req, "Camellia-192/CBC", {1, 2, 392, 200011, 61, 1, 1, 1, 3});
 1164|      0|      case 0x792F2:
  ------------------
  |  Branch (1164:7): [True: 0, False: 6.29k]
  ------------------
 1165|      0|         return if_match(req, "ClassicMcEliece_6688128pc", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 1});
 1166|      0|      case 0x7A661:
  ------------------
  |  Branch (1166:7): [True: 0, False: 6.29k]
  ------------------
 1167|      0|         return if_match(req, "DSA/SHA-512", {2, 16, 840, 1, 101, 3, 4, 3, 4});
 1168|      0|      case 0x7A977:
  ------------------
  |  Branch (1168:7): [True: 0, False: 6.29k]
  ------------------
 1169|      0|         return if_match(req, "X509v3.ExtendedKeyUsage", {2, 5, 29, 37});
 1170|      0|      case 0x7AE67:
  ------------------
  |  Branch (1170:7): [True: 0, False: 6.29k]
  ------------------
 1171|      0|         return if_match(req, "SM2_Enc", {1, 2, 156, 10197, 1, 301, 3});
 1172|      0|      case 0x7B602:
  ------------------
  |  Branch (1172:7): [True: 0, False: 6.29k]
  ------------------
 1173|      0|         return if_match(req, "Twofish/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 5});
 1174|      0|      case 0x7B9A1:
  ------------------
  |  Branch (1174:7): [True: 0, False: 6.29k]
  ------------------
 1175|      0|         return if_match(req, "SphincsPlus-sha2-192s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 3});
 1176|      0|      case 0x7BB0A:
  ------------------
  |  Branch (1176:7): [True: 0, False: 6.29k]
  ------------------
 1177|      0|         return if_match(req, "SLH-DSA-SHAKE-256f", {2, 16, 840, 1, 101, 3, 4, 3, 31});
 1178|      0|      case 0x7BB17:
  ------------------
  |  Branch (1178:7): [True: 0, False: 6.29k]
  ------------------
 1179|      0|         return if_match(req, "SLH-DSA-SHAKE-256s", {2, 16, 840, 1, 101, 3, 4, 3, 30});
 1180|      0|      case 0x7BCF3:
  ------------------
  |  Branch (1180:7): [True: 0, False: 6.29k]
  ------------------
 1181|      0|         return if_match(req, "PKIX.EmailProtection", {1, 3, 6, 1, 5, 5, 7, 3, 4});
 1182|      0|      case 0x7CC2C:
  ------------------
  |  Branch (1182:7): [True: 0, False: 6.29k]
  ------------------
 1183|      0|         return if_match(req, "SHA-512-256", {2, 16, 840, 1, 101, 3, 4, 2, 6});
 1184|      0|      case 0x7CF41:
  ------------------
  |  Branch (1184:7): [True: 0, False: 6.29k]
  ------------------
 1185|      0|         return if_match(req, "SphincsPlus-shake-192s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 3});
 1186|      0|      case 0x7DB91:
  ------------------
  |  Branch (1186:7): [True: 0, False: 6.29k]
  ------------------
 1187|      0|         return if_match(req, "GOST-34.10", {1, 2, 643, 2, 2, 19});
 1188|      0|      case 0x7E319:
  ------------------
  |  Branch (1188:7): [True: 0, False: 6.29k]
  ------------------
 1189|      0|         return if_match(req, "ECDSA/SHA-512", {1, 2, 840, 10045, 4, 3, 4});
 1190|      0|      case 0x7E874:
  ------------------
  |  Branch (1190:7): [True: 0, False: 6.29k]
  ------------------
 1191|      0|         return if_match(req, "ClassicMcEliece_6688128f", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 6});
 1192|      0|      case 0x7EAAF:
  ------------------
  |  Branch (1192:7): [True: 0, False: 6.29k]
  ------------------
 1193|      0|         return if_match(req, "eFrodoKEM-640-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 16, 1});
 1194|      0|      case 0x7F51F:
  ------------------
  |  Branch (1194:7): [True: 0, False: 6.29k]
  ------------------
 1195|      0|         return if_match(req, "PKIX.IPsecTunnel", {1, 3, 6, 1, 5, 5, 7, 3, 6});
 1196|      0|      case 0x80272:
  ------------------
  |  Branch (1196:7): [True: 0, False: 6.29k]
  ------------------
 1197|      0|         return if_match(req, "X520.Organization", {2, 5, 4, 10});
 1198|      0|      case 0x80340:
  ------------------
  |  Branch (1198:7): [True: 0, False: 6.29k]
  ------------------
 1199|      0|         return if_match(req, "AES-256/CBC", {2, 16, 840, 1, 101, 3, 4, 1, 42});
 1200|      0|      case 0x80445:
  ------------------
  |  Branch (1200:7): [True: 0, False: 6.29k]
  ------------------
 1201|      0|         return if_match(req, "AES-256/CCM", {2, 16, 840, 1, 101, 3, 4, 1, 47});
 1202|      0|      case 0x811F7:
  ------------------
  |  Branch (1202:7): [True: 0, False: 6.29k]
  ------------------
 1203|      0|         return if_match(req, "HMAC(SHA-256)", {1, 2, 840, 113549, 2, 9});
 1204|      0|      case 0x82434:
  ------------------
  |  Branch (1204:7): [True: 0, False: 6.29k]
  ------------------
 1205|      0|         return if_match(req, "PKCS9.X509CRL", {1, 2, 840, 113549, 1, 9, 23, 1});
 1206|      0|      case 0x82B47:
  ------------------
  |  Branch (1206:7): [True: 0, False: 6.29k]
  ------------------
 1207|      0|         return if_match(req, "Threefish-512/CBC", {1, 3, 6, 1, 4, 1, 25258, 3, 2});
 1208|      0|      case 0x83EA7:
  ------------------
  |  Branch (1208:7): [True: 0, False: 6.29k]
  ------------------
 1209|      0|         return if_match(req, "RSA/PKCS1v15(SHA-384)", {1, 2, 840, 113549, 1, 1, 12});
 1210|      0|      case 0x84596:
  ------------------
  |  Branch (1210:7): [True: 0, False: 6.29k]
  ------------------
 1211|      0|         return if_match(req, "eFrodoKEM-640-AES", {1, 3, 6, 1, 4, 1, 25258, 1, 17, 1});
 1212|      0|      case 0x8469F:
  ------------------
  |  Branch (1212:7): [True: 0, False: 6.29k]
  ------------------
 1213|      0|         return if_match(req, "ClassicMcEliece_6960119pcf", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 4});
 1214|  1.30k|      case 0x84CA4:
  ------------------
  |  Branch (1214:7): [True: 1.30k, False: 4.98k]
  ------------------
 1215|  1.30k|         return if_match(req, "secp256k1", {1, 3, 132, 0, 10});
 1216|  4.98k|      case 0x85381:
  ------------------
  |  Branch (1216:7): [True: 4.98k, False: 1.30k]
  ------------------
 1217|  4.98k|         return if_match(req, "secp256r1", {1, 2, 840, 10045, 3, 1, 7});
 1218|      0|      case 0x854FC:
  ------------------
  |  Branch (1218:7): [True: 0, False: 6.29k]
  ------------------
 1219|      0|         return if_match(req, "PKIX.IPsecUser", {1, 3, 6, 1, 5, 5, 7, 3, 7});
 1220|      0|      case 0x85F51:
  ------------------
  |  Branch (1220:7): [True: 0, False: 6.29k]
  ------------------
 1221|      0|         return if_match(req, "Serpent/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 4});
 1222|      0|      case 0x862D9:
  ------------------
  |  Branch (1222:7): [True: 0, False: 6.29k]
  ------------------
 1223|      0|         return if_match(req, "ECGDSA/SHA-512", {1, 3, 36, 3, 3, 2, 5, 4, 6});
 1224|      0|      case 0x87585:
  ------------------
  |  Branch (1224:7): [True: 0, False: 6.29k]
  ------------------
 1225|      0|         return if_match(req, "Twofish/CBC", {1, 3, 6, 1, 4, 1, 25258, 3, 3});
 1226|      0|      case 0x877D1:
  ------------------
  |  Branch (1226:7): [True: 0, False: 6.29k]
  ------------------
 1227|      0|         return if_match(req, "PKCS9.EmailAddress", {1, 2, 840, 113549, 1, 9, 1});
 1228|      0|      case 0x87D27:
  ------------------
  |  Branch (1228:7): [True: 0, False: 6.29k]
  ------------------
 1229|      0|         return if_match(req, "PKIX.CertificateAuthorityIssuers", {1, 3, 6, 1, 5, 5, 7, 48, 2});
 1230|      0|      case 0x87E42:
  ------------------
  |  Branch (1230:7): [True: 0, False: 6.29k]
  ------------------
 1231|      0|         return if_match(req, "X509v3.AuthorityKeyIdentifier", {2, 5, 29, 35});
 1232|      0|      case 0x889B1:
  ------------------
  |  Branch (1232:7): [True: 0, False: 6.29k]
  ------------------
 1233|      0|         return if_match(req, "ECDSA/SHA-1", {1, 2, 840, 10045, 4, 1});
 1234|      0|      case 0x89658:
  ------------------
  |  Branch (1234:7): [True: 0, False: 6.29k]
  ------------------
 1235|      0|         return if_match(req, "PBE-PKCS5v20", {1, 2, 840, 113549, 1, 5, 13});
 1236|      0|      case 0x8976D:
  ------------------
  |  Branch (1236:7): [True: 0, False: 6.29k]
  ------------------
 1237|      0|         return if_match(req, "PKCS9.MessageDigest", {1, 2, 840, 113549, 1, 9, 4});
 1238|      0|      case 0x8B002:
  ------------------
  |  Branch (1238:7): [True: 0, False: 6.29k]
  ------------------
 1239|      0|         return if_match(req, "Camellia-256/OCB", {1, 3, 6, 1, 4, 1, 25258, 3, 2, 8});
 1240|      0|      case 0x8B935:
  ------------------
  |  Branch (1240:7): [True: 0, False: 6.29k]
  ------------------
 1241|      0|         return if_match(req, "ClassicMcEliece_6688128", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 5});
 1242|      0|      case 0x8BB11:
  ------------------
  |  Branch (1242:7): [True: 0, False: 6.29k]
  ------------------
 1243|      0|         return if_match(req, "X509v3.NoRevocationAvailable", {2, 5, 29, 56});
 1244|      0|      case 0x8CE3D:
  ------------------
  |  Branch (1244:7): [True: 0, False: 6.29k]
  ------------------
 1245|      0|         return if_match(req, "PKCS9.ChallengePassword", {1, 2, 840, 113549, 1, 9, 7});
 1246|      0|      case 0x8D45C:
  ------------------
  |  Branch (1246:7): [True: 0, False: 6.29k]
  ------------------
 1247|      0|         return if_match(req, "ECKCDSA", {1, 0, 14888, 3, 0, 5});
 1248|      0|      case 0x8E0C1:
  ------------------
  |  Branch (1248:7): [True: 0, False: 6.29k]
  ------------------
 1249|      0|         return if_match(req, "X509v3.CertificatePolicies", {2, 5, 29, 32});
 1250|      0|      case 0x8E39A:
  ------------------
  |  Branch (1250:7): [True: 0, False: 6.29k]
  ------------------
 1251|      0|         return if_match(req, "HSS-LMS-Private-Key", {1, 3, 6, 1, 4, 1, 25258, 1, 13});
 1252|      0|      case 0x8EC51:
  ------------------
  |  Branch (1252:7): [True: 0, False: 6.29k]
  ------------------
 1253|      0|         return if_match(req, "Kyber-768-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 7, 2});
 1254|      0|      case 0x8F94A:
  ------------------
  |  Branch (1254:7): [True: 0, False: 6.29k]
  ------------------
 1255|      0|         return if_match(req, "Dilithium-6x5-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 9, 2});
 1256|      0|      case 0x8FC20:
  ------------------
  |  Branch (1256:7): [True: 0, False: 6.29k]
  ------------------
 1257|      0|         return if_match(req, "AES-128/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 1});
 1258|      0|      case 0x8FDE0:
  ------------------
  |  Branch (1258:7): [True: 0, False: 6.29k]
  ------------------
 1259|      0|         return if_match(req, "SHA-3(256)", {2, 16, 840, 1, 101, 3, 4, 2, 8});
 1260|      0|      case 0x919E3:
  ------------------
  |  Branch (1260:7): [True: 0, False: 6.29k]
  ------------------
 1261|      0|         return if_match(req, "Serpent/GCM", {1, 3, 6, 1, 4, 1, 25258, 3, 101});
 1262|      0|      case 0x91C1A:
  ------------------
  |  Branch (1262:7): [True: 0, False: 6.29k]
  ------------------
 1263|      0|         return if_match(req, "X25519", {1, 3, 101, 110});
 1264|      0|      case 0x91DC4:
  ------------------
  |  Branch (1264:7): [True: 0, False: 6.29k]
  ------------------
 1265|      0|         return if_match(req, "McEliece", {1, 3, 6, 1, 4, 1, 25258, 1, 3});
 1266|      0|      case 0x93467:
  ------------------
  |  Branch (1266:7): [True: 0, False: 6.29k]
  ------------------
 1267|      0|         return if_match(req, "Dilithium-6x5-AES-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 10, 2});
 1268|      0|      case 0x93D50:
  ------------------
  |  Branch (1268:7): [True: 0, False: 6.29k]
  ------------------
 1269|      0|         return if_match(req, "AES-192/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 2});
 1270|      0|      case 0x95166:
  ------------------
  |  Branch (1270:7): [True: 0, False: 6.29k]
  ------------------
 1271|      0|         return if_match(req, "SLH-DSA-SHAKE-128f", {2, 16, 840, 1, 101, 3, 4, 3, 27});
 1272|      0|      case 0x95173:
  ------------------
  |  Branch (1272:7): [True: 0, False: 6.29k]
  ------------------
 1273|      0|         return if_match(req, "SLH-DSA-SHAKE-128s", {2, 16, 840, 1, 101, 3, 4, 3, 26});
 1274|      0|      case 0x952D6:
  ------------------
  |  Branch (1274:7): [True: 0, False: 6.29k]
  ------------------
 1275|      0|         return if_match(req, "PKIX.OCSP", {1, 3, 6, 1, 5, 5, 7, 48, 1});
 1276|      0|      case 0x959B9:
  ------------------
  |  Branch (1276:7): [True: 0, False: 6.29k]
  ------------------
 1277|      0|         return if_match(req, "PKIX.IPsecEndSystem", {1, 3, 6, 1, 5, 5, 7, 3, 5});
 1278|      0|      case 0x96F85:
  ------------------
  |  Branch (1278:7): [True: 0, False: 6.29k]
  ------------------
 1279|      0|         return if_match(req, "Camellia-256/CBC", {1, 2, 392, 200011, 61, 1, 1, 1, 4});
 1280|      0|      case 0x97D5E:
  ------------------
  |  Branch (1280:7): [True: 0, False: 6.29k]
  ------------------
 1281|      0|         return if_match(req, "HMAC(SHA-1)", {1, 2, 840, 113549, 2, 7});
 1282|      0|      case 0x9805C:
  ------------------
  |  Branch (1282:7): [True: 0, False: 6.29k]
  ------------------
 1283|      0|         return if_match(req, "SEED/CBC", {1, 2, 410, 200004, 1, 4});
 1284|      0|      case 0x980E7:
  ------------------
  |  Branch (1284:7): [True: 0, False: 6.29k]
  ------------------
 1285|      0|         return if_match(req, "SphincsPlus-haraka-192s-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 3});
 1286|      0|      case 0x980F5:
  ------------------
  |  Branch (1286:7): [True: 0, False: 6.29k]
  ------------------
 1287|      0|         return if_match(req, "GOST.SubjectSigningTool", {1, 2, 643, 100, 111});
 1288|      0|      case 0x98B03:
  ------------------
  |  Branch (1288:7): [True: 0, False: 6.29k]
  ------------------
 1289|      0|         return if_match(req, "XMSS", {0, 4, 0, 127, 0, 15, 1, 1, 13, 0});
 1290|      0|      case 0x9A6B2:
  ------------------
  |  Branch (1290:7): [True: 0, False: 6.29k]
  ------------------
 1291|      0|         return if_match(req, "ECKCDSA/SHA-1", {1, 2, 410, 200004, 1, 100, 4, 3});
 1292|      0|      case 0x9B1CF:
  ------------------
  |  Branch (1292:7): [True: 0, False: 6.29k]
  ------------------
 1293|      0|         return if_match(req, "SM4/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 9});
 1294|      0|      case 0x9B6B2:
  ------------------
  |  Branch (1294:7): [True: 0, False: 6.29k]
  ------------------
 1295|      0|         return if_match(req, "AES-128/GCM", {2, 16, 840, 1, 101, 3, 4, 1, 6});
 1296|      0|      case 0x9B6BB:
  ------------------
  |  Branch (1296:7): [True: 0, False: 6.29k]
  ------------------
 1297|      0|         return if_match(req, "X520.OrganizationalUnit", {2, 5, 4, 11});
 1298|      0|      case 0x9B851:
  ------------------
  |  Branch (1298:7): [True: 0, False: 6.29k]
  ------------------
 1299|      0|         return if_match(req, "OpenPGP.Curve25519", {1, 3, 6, 1, 4, 1, 3029, 1, 5, 1});
 1300|      0|      case 0x9C80B:
  ------------------
  |  Branch (1300:7): [True: 0, False: 6.29k]
  ------------------
 1301|      0|         return if_match(req, "SLH-DSA-SHA2-192f", {2, 16, 840, 1, 101, 3, 4, 3, 23});
 1302|      0|      case 0x9C818:
  ------------------
  |  Branch (1302:7): [True: 0, False: 6.29k]
  ------------------
 1303|      0|         return if_match(req, "SLH-DSA-SHA2-192s", {2, 16, 840, 1, 101, 3, 4, 3, 22});
 1304|      0|      case 0x9CD2B:
  ------------------
  |  Branch (1304:7): [True: 0, False: 6.29k]
  ------------------
 1305|      0|         return if_match(req, "Scrypt", {1, 3, 6, 1, 4, 1, 11591, 4, 11});
 1306|      0|      case 0x9CDE1:
  ------------------
  |  Branch (1306:7): [True: 0, False: 6.29k]
  ------------------
 1307|      0|         return if_match(req, "GOST-34.10-2012-256/SHA-256", {1, 3, 6, 1, 4, 1, 25258, 1, 6, 1});
 1308|      0|      case 0x9CF73:
  ------------------
  |  Branch (1308:7): [True: 0, False: 6.29k]
  ------------------
 1309|      0|         return if_match(req, "ClassicMcEliece_460896f", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 4});
 1310|      0|      case 0x9D354:
  ------------------
  |  Branch (1310:7): [True: 0, False: 6.29k]
  ------------------
 1311|      0|         return if_match(req, "RIPEMD-160", {1, 3, 36, 3, 2, 1});
 1312|      0|      case 0x9D503:
  ------------------
  |  Branch (1312:7): [True: 0, False: 6.29k]
  ------------------
 1313|      0|         return if_match(req, "RSA/PKCS1v15(SHA-256)", {1, 2, 840, 113549, 1, 1, 11});
 1314|      0|      case 0x9EC88:
  ------------------
  |  Branch (1314:7): [True: 0, False: 6.29k]
  ------------------
 1315|      0|         return if_match(req, "DSA/SHA-3(512)", {2, 16, 840, 1, 101, 3, 4, 3, 8});
 1316|      0|      case 0x9EF36:
  ------------------
  |  Branch (1316:7): [True: 0, False: 6.29k]
  ------------------
 1317|      0|         return if_match(req, "ClassicMcEliece_6960119", {1, 3, 6, 1, 4, 1, 22554, 5, 1, 7});
 1318|      0|      case 0x9F764:
  ------------------
  |  Branch (1318:7): [True: 0, False: 6.29k]
  ------------------
 1319|      0|         return if_match(req, "X448", {1, 3, 101, 111});
 1320|      0|      case 0x9F7E2:
  ------------------
  |  Branch (1320:7): [True: 0, False: 6.29k]
  ------------------
 1321|      0|         return if_match(req, "AES-192/GCM", {2, 16, 840, 1, 101, 3, 4, 1, 26});
 1322|      0|      case 0x9F9C5:
  ------------------
  |  Branch (1322:7): [True: 0, False: 6.29k]
  ------------------
 1323|      0|         return if_match(req, "ClassicMcEliece_6688128pcf", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 2});
 1324|      0|      case 0xA0805:
  ------------------
  |  Branch (1324:7): [True: 0, False: 6.29k]
  ------------------
 1325|      0|         return if_match(req, "PKCS9.SDSICertificate", {1, 2, 840, 113549, 1, 9, 22, 2});
 1326|      0|      case 0xA2B5B:
  ------------------
  |  Branch (1326:7): [True: 0, False: 6.29k]
  ------------------
 1327|      0|         return if_match(req, "X509v3.CRLNumber", {2, 5, 29, 20});
 1328|      0|      case 0xA3005:
  ------------------
  |  Branch (1328:7): [True: 0, False: 6.29k]
  ------------------
 1329|      0|         return if_match(req, "X520.Title", {2, 5, 4, 12});
 1330|      0|      case 0xA323F:
  ------------------
  |  Branch (1330:7): [True: 0, False: 6.29k]
  ------------------
 1331|      0|         return if_match(req, "X509v3.NameConstraints", {2, 5, 29, 30});
 1332|      0|      case 0xA3C55:
  ------------------
  |  Branch (1332:7): [True: 0, False: 6.29k]
  ------------------
 1333|      0|         return if_match(req, "X520.Pseudonym", {2, 5, 4, 65});
 1334|      0|      case 0xA4809:
  ------------------
  |  Branch (1334:7): [True: 0, False: 6.29k]
  ------------------
 1335|      0|         return if_match(req, "SphincsPlus-sha2-256f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 2, 6});
 1336|      0|      case 0xA57AF:
  ------------------
  |  Branch (1336:7): [True: 0, False: 6.29k]
  ------------------
 1337|      0|         return if_match(req, "secp521r1", {1, 3, 132, 0, 35});
 1338|      0|      case 0xA5DA9:
  ------------------
  |  Branch (1338:7): [True: 0, False: 6.29k]
  ------------------
 1339|      0|         return if_match(req, "SphincsPlus-shake-256f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 1, 6});
 1340|      0|      case 0xA6865:
  ------------------
  |  Branch (1340:7): [True: 0, False: 6.29k]
  ------------------
 1341|      0|         return if_match(req, "Camellia-128/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 6});
 1342|      0|      case 0xA6C61:
  ------------------
  |  Branch (1342:7): [True: 0, False: 6.29k]
  ------------------
 1343|      0|         return if_match(req, "SM4/GCM", {1, 2, 156, 10197, 1, 104, 8});
 1344|      0|      case 0xA8439:
  ------------------
  |  Branch (1344:7): [True: 0, False: 6.29k]
  ------------------
 1345|      0|         return if_match(req, "PKCS12.CertBag", {1, 2, 840, 113549, 1, 12, 10, 1, 3});
 1346|      0|      case 0xA9061:
  ------------------
  |  Branch (1346:7): [True: 0, False: 6.29k]
  ------------------
 1347|      0|         return if_match(req, "Kyber-768-90s-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 11, 2});
 1348|      0|      case 0xAA995:
  ------------------
  |  Branch (1348:7): [True: 0, False: 6.29k]
  ------------------
 1349|      0|         return if_match(req, "Camellia-192/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 7});
 1350|      0|      case 0xAAE2B:
  ------------------
  |  Branch (1350:7): [True: 0, False: 6.29k]
  ------------------
 1351|      0|         return if_match(req, "Dilithium-8x7-AES-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 10, 3});
 1352|      0|      case 0xABCED:
  ------------------
  |  Branch (1352:7): [True: 0, False: 6.29k]
  ------------------
 1353|      0|         return if_match(req, "GOST.IssuerSigningTool", {1, 2, 643, 100, 112});
 1354|      0|      case 0xABD24:
  ------------------
  |  Branch (1354:7): [True: 0, False: 6.29k]
  ------------------
 1355|      0|         return if_match(req, "RSA/OAEP", {1, 2, 840, 113549, 1, 1, 7});
 1356|      0|      case 0xAC2EC:
  ------------------
  |  Branch (1356:7): [True: 0, False: 6.29k]
  ------------------
 1357|      0|         return if_match(req, "Streebog-256", {1, 2, 643, 7, 1, 1, 2, 2});
 1358|      0|      case 0xAC3DD:
  ------------------
  |  Branch (1358:7): [True: 0, False: 6.29k]
  ------------------
 1359|      0|         return if_match(req, "Certificate Comment", {2, 16, 840, 1, 113730, 1, 13});
 1360|      0|      case 0xAC511:
  ------------------
  |  Branch (1360:7): [True: 0, False: 6.29k]
  ------------------
 1361|      0|         return if_match(req, "PBE-SHA1-3DES", {1, 2, 840, 113549, 1, 12, 1, 3});
 1362|      0|      case 0xAE6FE:
  ------------------
  |  Branch (1362:7): [True: 0, False: 6.29k]
  ------------------
 1363|      0|         return if_match(req, "PKIX.ClientAuth", {1, 3, 6, 1, 5, 5, 7, 3, 2});
 1364|      0|      case 0xAE8D3:
  ------------------
  |  Branch (1364:7): [True: 0, False: 6.29k]
  ------------------
 1365|      0|         return if_match(req, "ClassicMcEliece_8192128pcf", {1, 3, 6, 1, 4, 1, 25258, 1, 18, 6});
 1366|      0|      case 0xAF476:
  ------------------
  |  Branch (1366:7): [True: 0, False: 6.29k]
  ------------------
 1367|      0|         return if_match(req, "ECDH", {1, 3, 132, 1, 12});
 1368|      0|      case 0xAFA6A:
  ------------------
  |  Branch (1368:7): [True: 0, False: 6.29k]
  ------------------
 1369|      0|         return if_match(req, "RSA/PKCS1v15(SHA-3(384))", {2, 16, 840, 1, 101, 3, 4, 3, 15});
 1370|      0|      case 0xB2217:
  ------------------
  |  Branch (1370:7): [True: 0, False: 6.29k]
  ------------------
 1371|      0|         return if_match(req, "AES-256/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 3});
 1372|      0|      case 0xB22F7:
  ------------------
  |  Branch (1372:7): [True: 0, False: 6.29k]
  ------------------
 1373|      0|         return if_match(req, "Camellia-128/GCM", {0, 3, 4401, 5, 3, 1, 9, 6});
 1374|      0|      case 0xB23DE:
  ------------------
  |  Branch (1374:7): [True: 0, False: 6.29k]
  ------------------
 1375|      0|         return if_match(req, "X520.Locality", {2, 5, 4, 7});
 1376|      0|      case 0xB2FBD:
  ------------------
  |  Branch (1376:7): [True: 0, False: 6.29k]
  ------------------
 1377|      0|         return if_match(req, "ECKCDSA/SHA-224", {1, 2, 410, 200004, 1, 100, 4, 4});
 1378|      0|      case 0xB32B0:
  ------------------
  |  Branch (1378:7): [True: 0, False: 6.29k]
  ------------------
 1379|      0|         return if_match(req, "ECKCDSA/SHA-256", {1, 2, 410, 200004, 1, 100, 4, 5});
 1380|      0|      case 0xB360E:
  ------------------
  |  Branch (1380:7): [True: 0, False: 6.29k]
  ------------------
 1381|      0|         return if_match(req, "eFrodoKEM-976-SHAKE", {1, 3, 6, 1, 4, 1, 25258, 1, 16, 2});
 1382|      0|      case 0xB4368:
  ------------------
  |  Branch (1382:7): [True: 0, False: 6.29k]
  ------------------
 1383|      0|         return if_match(req, "ECGDSA/SHA-1", {1, 3, 36, 3, 3, 2, 5, 4, 2});
 1384|      0|      case 0xB58CD:
  ------------------
  |  Branch (1384:7): [True: 0, False: 6.29k]
  ------------------
 1385|      0|         return if_match(req, "RSA/PKCS1v15(SHA-3(512))", {2, 16, 840, 1, 101, 3, 4, 3, 16});
 1386|      0|      case 0xB6427:
  ------------------
  |  Branch (1386:7): [True: 0, False: 6.29k]
  ------------------
 1387|      0|         return if_match(req, "Camellia-192/GCM", {0, 3, 4401, 5, 3, 1, 9, 26});
 1388|      0|      case 0xB7102:
  ------------------
  |  Branch (1388:7): [True: 0, False: 6.29k]
  ------------------
 1389|      0|         return if_match(req, "brainpool224r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 5});
 1390|      0|      case 0xB710D:
  ------------------
  |  Branch (1390:7): [True: 0, False: 6.29k]
  ------------------
 1391|      0|         return if_match(req, "X509v3.CRLIssuingDistributionPoint", {2, 5, 29, 28});
 1392|      0|      case 0xB72D4:
  ------------------
  |  Branch (1392:7): [True: 0, False: 6.29k]
  ------------------
 1393|      0|         return if_match(req, "Microsoft UPN", {1, 3, 6, 1, 4, 1, 311, 20, 2, 3});
 1394|      0|      case 0xB73A5:
  ------------------
  |  Branch (1394:7): [True: 0, False: 6.29k]
  ------------------
 1395|      0|         return if_match(req, "RSA/PSS", {1, 2, 840, 113549, 1, 1, 10});
 1396|      0|      case 0xB84B3:
  ------------------
  |  Branch (1396:7): [True: 0, False: 6.29k]
  ------------------
 1397|      0|         return if_match(req, "PKIX.CodeSigning", {1, 3, 6, 1, 5, 5, 7, 3, 3});
 1398|      0|      case 0xB8CB9:
  ------------------
  |  Branch (1398:7): [True: 0, False: 6.29k]
  ------------------
 1399|      0|         return if_match(req, "GOST-34.10-2012-256", {1, 2, 643, 7, 1, 1, 1, 1});
 1400|      0|      case 0xB945C:
  ------------------
  |  Branch (1400:7): [True: 0, False: 6.29k]
  ------------------
 1401|      0|         return if_match(req, "Twofish/SIV", {1, 3, 6, 1, 4, 1, 25258, 3, 4, 5});
 1402|      0|      case 0xB94E4:
  ------------------
  |  Branch (1402:7): [True: 0, False: 6.29k]
  ------------------
 1403|      0|         return if_match(req, "gost_512A", {1, 2, 643, 7, 1, 2, 1, 2, 1});
 1404|      0|      case 0xB94E5:
  ------------------
  |  Branch (1404:7): [True: 0, False: 6.29k]
  ------------------
 1405|      0|         return if_match(req, "gost_512B", {1, 2, 643, 7, 1, 2, 1, 2, 2});
 1406|      0|      case 0xBA1D8:
  ------------------
  |  Branch (1406:7): [True: 0, False: 6.29k]
  ------------------
 1407|      0|         return if_match(req, "X520.StreetAddress", {2, 5, 4, 9});
 1408|      0|      case 0xBCB45:
  ------------------
  |  Branch (1408:7): [True: 0, False: 6.29k]
  ------------------
 1409|      0|         return if_match(req, "PKCS12.CRLBag", {1, 2, 840, 113549, 1, 12, 10, 1, 4});
 1410|      0|      case 0xBCC82:
  ------------------
  |  Branch (1410:7): [True: 0, False: 6.29k]
  ------------------
 1411|      0|         return if_match(req, "x962_p239v1", {1, 2, 840, 10045, 3, 1, 4});
 1412|      0|      case 0xBCC83:
  ------------------
  |  Branch (1412:7): [True: 0, False: 6.29k]
  ------------------
 1413|      0|         return if_match(req, "x962_p239v2", {1, 2, 840, 10045, 3, 1, 5});
 1414|      0|      case 0xBCC84:
  ------------------
  |  Branch (1414:7): [True: 0, False: 6.29k]
  ------------------
 1415|      0|         return if_match(req, "x962_p239v3", {1, 2, 840, 10045, 3, 1, 6});
 1416|      0|      case 0xBD92B:
  ------------------
  |  Branch (1416:7): [True: 0, False: 6.29k]
  ------------------
 1417|      0|         return if_match(req, "X509v3.HoldInstructionCode", {2, 5, 29, 23});
 1418|      0|      case 0xBDCA9:
  ------------------
  |  Branch (1418:7): [True: 0, False: 6.29k]
  ------------------
 1419|      0|         return if_match(req, "AES-256/GCM", {2, 16, 840, 1, 101, 3, 4, 1, 46});
 1420|      0|      case 0xBE48D:
  ------------------
  |  Branch (1420:7): [True: 0, False: 6.29k]
  ------------------
 1421|      0|         return if_match(req, "PKIX.OCSP.BasicResponse", {1, 3, 6, 1, 5, 5, 7, 48, 1, 1});
 1422|      0|      case 0xBF71E:
  ------------------
  |  Branch (1422:7): [True: 0, False: 6.29k]
  ------------------
 1423|      0|         return if_match(req, "Kyber-1024-r3", {1, 3, 6, 1, 4, 1, 25258, 1, 7, 3});
 1424|      0|      case 0xBFF01:
  ------------------
  |  Branch (1424:7): [True: 0, False: 6.29k]
  ------------------
 1425|      0|         return if_match(req, "DSA/SHA-3(224)", {2, 16, 840, 1, 101, 3, 4, 3, 5});
 1426|      0|      case 0xC0F4F:
  ------------------
  |  Branch (1426:7): [True: 0, False: 6.29k]
  ------------------
 1427|      0|         return if_match(req, "SphincsPlus-haraka-256f-r3.1", {1, 3, 6, 1, 4, 1, 25258, 1, 12, 3, 6});
 1428|      0|      case 0xC1875:
  ------------------
  |  Branch (1428:7): [True: 0, False: 6.29k]
  ------------------
 1429|      0|         return if_match(req, "SHA-1", {1, 3, 14, 3, 2, 26});
 1430|      0|      case 0xC28D1:
  ------------------
  |  Branch (1430:7): [True: 0, False: 6.29k]
  ------------------
 1431|      0|         return if_match(req, "PKIX.OCSPSigning", {1, 3, 6, 1, 5, 5, 7, 3, 9});
 1432|      0|      case 0xC42CA:
  ------------------
  |  Branch (1432:7): [True: 0, False: 6.29k]
  ------------------
 1433|      0|         return if_match(req, "brainpool256r1", {1, 3, 36, 3, 3, 2, 8, 1, 1, 7});
 1434|      0|      default:
  ------------------
  |  Branch (1434:7): [True: 0, False: 6.29k]
  ------------------
 1435|      0|         return {};
 1436|  6.29k|   }
 1437|  6.29k|}
_ZN5Botan7OID_Map16load_oid2str_mapEv:
 1439|      1|std::unordered_map<OID, std::string> OID_Map::load_oid2str_map() {
 1440|      1|   return {
 1441|      1|      {OID{2, 5, 8, 1, 1}, "RSA"},
 1442|      1|      {OID{1, 3, 6, 1, 4, 1, 8301, 3, 1, 2, 9, 0, 38}, "secp521r1"},
 1443|      1|      {OID{1, 2, 643, 2, 2, 35, 1}, "gost_256A"},
 1444|      1|      {OID{1, 2, 643, 2, 2, 36, 0}, "gost_256A"},
 1445|      1|   };
 1446|      1|}
_ZN5Botan7OID_Map16load_str2oid_mapEv:
 1448|      1|std::unordered_map<std::string, OID> OID_Map::load_str2oid_map() {
 1449|      1|   return {
 1450|      1|      {"Curve25519", OID{1, 3, 101, 110}},
 1451|      1|      {"SM2_Sig", OID{1, 2, 156, 10197, 1, 301, 1}},
 1452|      1|      {"RSA/EMSA3(MD2)", OID{1, 2, 840, 113549, 1, 1, 2}},
 1453|      1|      {"RSA/EMSA3(MD5)", OID{1, 2, 840, 113549, 1, 1, 4}},
 1454|      1|      {"RSA/EMSA3(SHA-1)", OID{1, 2, 840, 113549, 1, 1, 5}},
 1455|      1|      {"RSA/EMSA3(SHA-256)", OID{1, 2, 840, 113549, 1, 1, 11}},
 1456|      1|      {"RSA/EMSA3(SHA-384)", OID{1, 2, 840, 113549, 1, 1, 12}},
 1457|      1|      {"RSA/EMSA3(SHA-512)", OID{1, 2, 840, 113549, 1, 1, 13}},
 1458|      1|      {"RSA/EMSA3(SHA-224)", OID{1, 2, 840, 113549, 1, 1, 14}},
 1459|      1|      {"RSA/EMSA3(SHA-512-256)", OID{1, 2, 840, 113549, 1, 1, 16}},
 1460|      1|      {"RSA/EMSA3(SHA-3(224))", OID{2, 16, 840, 1, 101, 3, 4, 3, 13}},
 1461|      1|      {"RSA/EMSA3(SHA-3(256))", OID{2, 16, 840, 1, 101, 3, 4, 3, 14}},
 1462|      1|      {"RSA/EMSA3(SHA-3(384))", OID{2, 16, 840, 1, 101, 3, 4, 3, 15}},
 1463|      1|      {"RSA/EMSA3(SHA-3(512))", OID{2, 16, 840, 1, 101, 3, 4, 3, 16}},
 1464|      1|      {"RSA/EMSA3(SM3)", OID{1, 2, 156, 10197, 1, 504}},
 1465|      1|      {"RSA/EMSA3(RIPEMD-160)", OID{1, 3, 36, 3, 3, 1, 2}},
 1466|      1|      {"RSA/EMSA4", OID{1, 2, 840, 113549, 1, 1, 10}},
 1467|      1|      {"PBES2", OID{1, 2, 840, 113549, 1, 5, 13}},
 1468|      1|   };
 1469|      1|}
static_oids.cpp:_ZN5Botan12_GLOBAL__N_18if_matchERKNS_3OIDESt16initializer_listIjENSt3__117basic_string_viewIcNS6_11char_traitsIcEEEE:
   18|      3|std::optional<std::string_view> if_match(const OID& oid, std::initializer_list<uint32_t> val, std::string_view name) {
   19|      3|   if(oid.matches(val)) {
  ------------------
  |  Branch (19:7): [True: 3, False: 0]
  ------------------
   20|      3|      return name;
   21|      3|   } else {
   22|      0|      return {};
   23|      0|   }
   24|      3|}
static_oids.cpp:_ZN5Botan12_GLOBAL__N_113hash_oid_nameENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   34|  6.29k|uint32_t hash_oid_name(std::string_view s) {
   35|  6.29k|   uint64_t hash = 0x8188B31879A4879A;
   36|       |
   37|  56.6k|   for(const char c : s) {
  ------------------
  |  Branch (37:21): [True: 56.6k, False: 6.29k]
  ------------------
   38|  56.6k|      hash *= 251;
   39|  56.6k|      hash += c;
   40|  56.6k|   }
   41|       |
   42|  6.29k|   return static_cast<uint32_t>(hash % 805289);
   43|  6.29k|}
static_oids.cpp:_ZN5Botan12_GLOBAL__N_18if_matchENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_St16initializer_listIjE:
   26|  6.29k|std::optional<OID> if_match(std::string_view req, std::string_view actual, std::initializer_list<uint32_t> oid) {
   27|  6.29k|   if(req == actual) {
  ------------------
  |  Branch (27:7): [True: 6.29k, False: 0]
  ------------------
   28|  6.29k|      return OID(oid);
   29|  6.29k|   } else {
   30|      0|      return {};
   31|      0|   }
   32|  6.29k|}

_ZN5Botan20Buffered_Computation9update_leEj:
   42|  43.4k|void Buffered_Computation::update_le(uint32_t val) {
   43|  43.4k|   uint8_t inb[sizeof(val)];
   44|  43.4k|   store_le(val, inb);
   45|  43.4k|   add_data({inb, sizeof(inb)});
   46|  43.4k|}
_ZN5Botan20Buffered_Computation9update_leEm:
   48|  27.0k|void Buffered_Computation::update_le(uint64_t val) {
   49|  27.0k|   uint8_t inb[sizeof(val)];
   50|  27.0k|   store_le(val, inb);
   51|  27.0k|   add_data({inb, sizeof(inb)});
   52|  27.0k|}
_ZN5Botan20Buffered_Computation5finalENSt3__14spanIhLm18446744073709551615EEE:
   54|  2.33M|void Buffered_Computation::final(std::span<uint8_t> out) {
   55|  2.33M|   BOTAN_ARG_CHECK(out.size() >= output_length(), "Output buffer has insufficient capacity");
  ------------------
  |  |   35|  2.33M|   do {                                                          \
  |  |   36|  2.33M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.33M|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.33M]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.33M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.33M]
  |  |  ------------------
  ------------------
   56|       |   // Pass exactly output_length() bytes so that an oversized buffer has the
   57|       |   // result written to its leading bytes with the remainder left untouched.
   58|  2.33M|   final_result(out.first(output_length()));
   59|  2.33M|}

_ZN5Botan18SymmetricAlgorithm7set_keyENSt3__14spanIKhLm18446744073709551615EEE:
   22|   251k|void SymmetricAlgorithm::set_key(std::span<const uint8_t> key) {
   23|   251k|   if(!valid_keylength(key.size())) {
  ------------------
  |  Branch (23:7): [True: 0, False: 251k]
  ------------------
   24|      0|      throw Invalid_Key_Length(name(), key.size());
   25|      0|   }
   26|   251k|   key_schedule(key);
   27|   251k|}

_ZNK5Botan7AES_12811parallelismEv:
  807|  11.3k|size_t AES_128::parallelism() const {
  808|  11.3k|   return aes_parallelism();
  809|  11.3k|}
_ZNK5Botan7AES_19211parallelismEv:
  811|  3.07k|size_t AES_192::parallelism() const {
  812|  3.07k|   return aes_parallelism();
  813|  3.07k|}
_ZNK5Botan7AES_25611parallelismEv:
  815|  7.14k|size_t AES_256::parallelism() const {
  816|  7.14k|   return aes_parallelism();
  817|  7.14k|}
_ZNK5Botan7AES_12819has_keying_materialEv:
  819|  1.86M|bool AES_128::has_keying_material() const {
  820|  1.86M|   return !m_EK.empty();
  821|  1.86M|}
_ZNK5Botan7AES_19219has_keying_materialEv:
  823|   635k|bool AES_192::has_keying_material() const {
  824|   635k|   return !m_EK.empty();
  825|   635k|}
_ZNK5Botan7AES_25619has_keying_materialEv:
  827|  10.6M|bool AES_256::has_keying_material() const {
  828|  10.6M|   return !m_EK.empty();
  829|  10.6M|}
_ZNK5Botan7AES_1289encrypt_nEPKhPhm:
  831|   603k|void AES_128::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  832|   603k|   assert_key_material_set();
  833|       |
  834|       |#if defined(BOTAN_HAS_AES_VAES)
  835|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  836|       |      return x86_vaes_encrypt_n(in, out, blocks);
  837|       |   }
  838|       |#endif
  839|       |
  840|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  841|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  842|       |      return hw_aes_encrypt_n(in, out, blocks);
  843|       |   }
  844|       |#endif
  845|       |
  846|       |#if defined(BOTAN_HAS_AES_VPERM)
  847|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  848|       |      return vperm_encrypt_n(in, out, blocks);
  849|       |   }
  850|       |#endif
  851|       |
  852|   603k|   aes_encrypt_n(in, out, blocks, m_EK);
  853|   603k|}
_ZNK5Botan7AES_1289decrypt_nEPKhPhm:
  855|  29.3k|void AES_128::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  856|  29.3k|   assert_key_material_set();
  857|       |
  858|       |#if defined(BOTAN_HAS_AES_VAES)
  859|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  860|       |      return x86_vaes_decrypt_n(in, out, blocks);
  861|       |   }
  862|       |#endif
  863|       |
  864|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  865|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  866|       |      return hw_aes_decrypt_n(in, out, blocks);
  867|       |   }
  868|       |#endif
  869|       |
  870|       |#if defined(BOTAN_HAS_AES_VPERM)
  871|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  872|       |      return vperm_decrypt_n(in, out, blocks);
  873|       |   }
  874|       |#endif
  875|       |
  876|  29.3k|   aes_decrypt_n(in, out, blocks, m_DK);
  877|  29.3k|}
_ZN5Botan7AES_12812key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  879|  4.90k|void AES_128::key_schedule(std::span<const uint8_t> key) {
  880|       |#if defined(BOTAN_HAS_AES_NI)
  881|       |   if(CPUID::has(CPUID::Feature::AESNI)) {
  882|       |      return aesni_key_schedule(key.data(), key.size());
  883|       |   }
  884|       |#endif
  885|       |
  886|       |#if defined(BOTAN_HAS_AES_VAES)
  887|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  888|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, true);
  889|       |   }
  890|       |#endif
  891|       |
  892|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  893|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  894|       |      constexpr bool is_little_endian = std::endian::native == std::endian::little;
  895|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, is_little_endian);
  896|       |   }
  897|       |#endif
  898|       |
  899|       |#if defined(BOTAN_HAS_AES_VPERM)
  900|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  901|       |      return vperm_key_schedule(key.data(), key.size());
  902|       |   }
  903|       |#endif
  904|       |
  905|  4.90k|   aes_key_schedule(key.data(), key.size(), m_EK, m_DK);
  906|  4.90k|}
_ZN5Botan7AES_1285clearEv:
  908|    775|void AES_128::clear() {
  909|    775|   zap(m_EK);
  910|    775|   zap(m_DK);
  911|    775|}
_ZNK5Botan7AES_1929encrypt_nEPKhPhm:
  913|   259k|void AES_192::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  914|   259k|   assert_key_material_set();
  915|       |
  916|       |#if defined(BOTAN_HAS_AES_VAES)
  917|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  918|       |      return x86_vaes_encrypt_n(in, out, blocks);
  919|       |   }
  920|       |#endif
  921|       |
  922|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  923|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  924|       |      return hw_aes_encrypt_n(in, out, blocks);
  925|       |   }
  926|       |#endif
  927|       |
  928|       |#if defined(BOTAN_HAS_AES_VPERM)
  929|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  930|       |      return vperm_encrypt_n(in, out, blocks);
  931|       |   }
  932|       |#endif
  933|       |
  934|   259k|   aes_encrypt_n(in, out, blocks, m_EK);
  935|   259k|}
_ZNK5Botan7AES_1929decrypt_nEPKhPhm:
  937|  1.91k|void AES_192::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  938|  1.91k|   assert_key_material_set();
  939|       |
  940|       |#if defined(BOTAN_HAS_AES_VAES)
  941|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  942|       |      return x86_vaes_decrypt_n(in, out, blocks);
  943|       |   }
  944|       |#endif
  945|       |
  946|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  947|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  948|       |      return hw_aes_decrypt_n(in, out, blocks);
  949|       |   }
  950|       |#endif
  951|       |
  952|       |#if defined(BOTAN_HAS_AES_VPERM)
  953|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  954|       |      return vperm_decrypt_n(in, out, blocks);
  955|       |   }
  956|       |#endif
  957|       |
  958|  1.91k|   aes_decrypt_n(in, out, blocks, m_DK);
  959|  1.91k|}
_ZN5Botan7AES_19212key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  961|  1.51k|void AES_192::key_schedule(std::span<const uint8_t> key) {
  962|       |#if defined(BOTAN_HAS_AES_NI)
  963|       |   if(CPUID::has(CPUID::Feature::AESNI)) {
  964|       |      return aesni_key_schedule(key.data(), key.size());
  965|       |   }
  966|       |#endif
  967|       |
  968|       |#if defined(BOTAN_HAS_AES_VAES)
  969|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  970|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, true);
  971|       |   }
  972|       |#endif
  973|       |
  974|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  975|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  976|       |      constexpr bool is_little_endian = std::endian::native == std::endian::little;
  977|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, is_little_endian);
  978|       |   }
  979|       |#endif
  980|       |
  981|       |#if defined(BOTAN_HAS_AES_VPERM)
  982|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  983|       |      return vperm_key_schedule(key.data(), key.size());
  984|       |   }
  985|       |#endif
  986|       |
  987|  1.51k|   aes_key_schedule(key.data(), key.size(), m_EK, m_DK);
  988|  1.51k|}
_ZN5Botan7AES_1925clearEv:
  990|    293|void AES_192::clear() {
  991|    293|   zap(m_EK);
  992|    293|   zap(m_DK);
  993|    293|}
_ZNK5Botan7AES_2569encrypt_nEPKhPhm:
  995|  4.78M|void AES_256::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  996|  4.78M|   assert_key_material_set();
  997|       |
  998|       |#if defined(BOTAN_HAS_AES_VAES)
  999|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
 1000|       |      return x86_vaes_encrypt_n(in, out, blocks);
 1001|       |   }
 1002|       |#endif
 1003|       |
 1004|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
 1005|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
 1006|       |      return hw_aes_encrypt_n(in, out, blocks);
 1007|       |   }
 1008|       |#endif
 1009|       |
 1010|       |#if defined(BOTAN_HAS_AES_VPERM)
 1011|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
 1012|       |      return vperm_encrypt_n(in, out, blocks);
 1013|       |   }
 1014|       |#endif
 1015|       |
 1016|  4.78M|   aes_encrypt_n(in, out, blocks, m_EK);
 1017|  4.78M|}
_ZNK5Botan7AES_2569decrypt_nEPKhPhm:
 1019|   155k|void AES_256::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
 1020|   155k|   assert_key_material_set();
 1021|       |
 1022|       |#if defined(BOTAN_HAS_AES_VAES)
 1023|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
 1024|       |      return x86_vaes_decrypt_n(in, out, blocks);
 1025|       |   }
 1026|       |#endif
 1027|       |
 1028|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
 1029|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
 1030|       |      return hw_aes_decrypt_n(in, out, blocks);
 1031|       |   }
 1032|       |#endif
 1033|       |
 1034|       |#if defined(BOTAN_HAS_AES_VPERM)
 1035|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
 1036|       |      return vperm_decrypt_n(in, out, blocks);
 1037|       |   }
 1038|       |#endif
 1039|       |
 1040|   155k|   aes_decrypt_n(in, out, blocks, m_DK);
 1041|   155k|}
_ZN5Botan7AES_25612key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
 1043|  9.12k|void AES_256::key_schedule(std::span<const uint8_t> key) {
 1044|       |#if defined(BOTAN_HAS_AES_NI)
 1045|       |   if(CPUID::has(CPUID::Feature::AESNI)) {
 1046|       |      return aesni_key_schedule(key.data(), key.size());
 1047|       |   }
 1048|       |#endif
 1049|       |
 1050|       |#if defined(BOTAN_HAS_AES_VAES)
 1051|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
 1052|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, true);
 1053|       |   }
 1054|       |#endif
 1055|       |
 1056|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
 1057|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
 1058|       |      constexpr bool is_little_endian = std::endian::native == std::endian::little;
 1059|       |      return aes_key_schedule(key.data(), key.size(), m_EK, m_DK, is_little_endian);
 1060|       |   }
 1061|       |#endif
 1062|       |
 1063|       |#if defined(BOTAN_HAS_AES_VPERM)
 1064|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
 1065|       |      return vperm_key_schedule(key.data(), key.size());
 1066|       |   }
 1067|       |#endif
 1068|       |
 1069|  9.12k|   aes_key_schedule(key.data(), key.size(), m_EK, m_DK);
 1070|  9.12k|}
_ZN5Botan7AES_2565clearEv:
 1072|    700|void AES_256::clear() {
 1073|    700|   zap(m_EK);
 1074|    700|   zap(m_DK);
 1075|    700|}
aes.cpp:_ZN5Botan12_GLOBAL__N_115aes_parallelismEv:
  748|  21.5k|size_t aes_parallelism() {
  749|       |#if defined(BOTAN_HAS_AES_VAES)
  750|       |   if(CPUID::has(CPUID::Feature::AVX2_AES)) {
  751|       |      return 8;  // pipelined
  752|       |   }
  753|       |#endif
  754|       |
  755|       |#if defined(BOTAN_HAS_HW_AES_SUPPORT)
  756|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  757|       |      return 4;  // pipelined
  758|       |   }
  759|       |#endif
  760|       |
  761|       |#if defined(BOTAN_HAS_AES_VPERM)
  762|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
  763|       |      return 2;  // pipelined
  764|       |   }
  765|       |#endif
  766|       |
  767|       |   // bitsliced:
  768|  21.5k|   return 2;
  769|  21.5k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_113aes_encrypt_nEPKhPhmRKNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  512|  5.64M|void aes_encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks, const secure_vector<uint32_t>& EK) {
  513|  5.64M|   BOTAN_ASSERT(EK.size() == 44 || EK.size() == 52 || EK.size() == 60, "Key was set");
  ------------------
  |  |   64|  5.64M|   do {                                                                                 \
  |  |   65|  5.64M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  21.1M|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:12): [True: 603k, False: 5.04M]
  |  |  |  Branch (66:12): [True: 259k, False: 4.78M]
  |  |  |  Branch (66:12): [True: 4.78M, False: 0]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  5.64M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 5.64M]
  |  |  ------------------
  ------------------
  514|       |
  515|  5.64M|   const size_t rounds = (EK.size() - 4) / 4;
  516|       |
  517|  5.64M|   uint32_t KS[13 * 8] = {0};  // actual maximum is (rounds - 1) * 8
  518|  76.1M|   for(size_t i = 0; i < rounds - 1; i += 1) {
  ------------------
  |  Branch (518:22): [True: 70.5M, False: 5.64M]
  ------------------
  519|  70.5M|      ks_expand(&KS[8 * i], EK.data(), 4 * i + 4);
  520|  70.5M|   }
  521|       |
  522|  5.64M|   const size_t BLOCK_SIZE = 16;
  523|  5.64M|   const size_t BITSLICED_BLOCKS = 8 * sizeof(uint32_t) / BLOCK_SIZE;
  524|       |
  525|  13.0M|   while(blocks > 0) {
  ------------------
  |  Branch (525:10): [True: 7.38M, False: 5.64M]
  ------------------
  526|  7.38M|      const size_t this_loop = std::min(blocks, BITSLICED_BLOCKS);
  527|       |
  528|  7.38M|      uint32_t B[8] = {0};
  529|       |
  530|  7.38M|      load_be(B, in, this_loop * 4);
  531|       |
  532|  7.38M|      CT::poison(B, 8);
  533|       |
  534|  66.4M|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (534:25): [True: 59.0M, False: 7.38M]
  ------------------
  535|  59.0M|         B[i] ^= EK[i % 4];
  536|  59.0M|      }
  537|       |
  538|  7.38M|      bit_transpose(B);
  539|       |
  540|  98.7M|      for(size_t r = 0; r != rounds - 1; ++r) {
  ------------------
  |  Branch (540:25): [True: 91.3M, False: 7.38M]
  ------------------
  541|  91.3M|         AES_SBOX(B);
  542|  91.3M|         shift_rows(B);
  543|  91.3M|         mix_columns(B);
  544|       |
  545|   822M|         for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (545:28): [True: 730M, False: 91.3M]
  ------------------
  546|   730M|            B[i] ^= KS[8 * r + i];
  547|   730M|         }
  548|  91.3M|      }
  549|       |
  550|       |      // Final round:
  551|  7.38M|      AES_SBOX(B);
  552|  7.38M|      shift_rows(B);
  553|  7.38M|      bit_transpose(B);
  554|       |
  555|  66.4M|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (555:25): [True: 59.0M, False: 7.38M]
  ------------------
  556|  59.0M|         B[i] ^= EK[4 * rounds + i % 4];
  557|  59.0M|      }
  558|       |
  559|  7.38M|      CT::unpoison(B, 8);
  560|       |
  561|  7.38M|      copy_out_be(std::span(out, this_loop * 4 * sizeof(uint32_t)), B);
  562|       |
  563|  7.38M|      in += this_loop * BLOCK_SIZE;
  564|  7.38M|      out += this_loop * BLOCK_SIZE;
  565|  7.38M|      blocks -= this_loop;
  566|  7.38M|   }
  567|  5.64M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_19ks_expandEPjPKjm:
  390|  72.8M|inline void ks_expand(uint32_t B[8], const uint32_t K[], size_t r) {
  391|       |   /*
  392|       |   This is bit_transpose of K[r..r+4] || K[r..r+4], we can save some computation
  393|       |   due to knowing the first and second halves are the same data.
  394|       |   */
  395|   364M|   for(size_t i = 0; i != 4; ++i) {
  ------------------
  |  Branch (395:22): [True: 291M, False: 72.8M]
  ------------------
  396|   291M|      B[i] = K[r + i];
  397|   291M|   }
  398|       |
  399|  72.8M|   swap_bits<uint32_t>(B[1], B[0], 0x55555555, 1);
  400|  72.8M|   swap_bits<uint32_t>(B[3], B[2], 0x55555555, 1);
  401|       |
  402|  72.8M|   swap_bits<uint32_t>(B[2], B[0], 0x33333333, 2);
  403|  72.8M|   swap_bits<uint32_t>(B[3], B[1], 0x33333333, 2);
  404|       |
  405|  72.8M|   B[4] = B[0];
  406|  72.8M|   B[5] = B[1];
  407|  72.8M|   B[6] = B[2];
  408|  72.8M|   B[7] = B[3];
  409|       |
  410|  72.8M|   swap_bits<uint32_t>(B[4], B[0], 0x0F0F0F0F, 4);
  411|  72.8M|   swap_bits<uint32_t>(B[5], B[1], 0x0F0F0F0F, 4);
  412|  72.8M|   swap_bits<uint32_t>(B[6], B[2], 0x0F0F0F0F, 4);
  413|  72.8M|   swap_bits<uint32_t>(B[7], B[3], 0x0F0F0F0F, 4);
  414|  72.8M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_113bit_transposeEPj:
  373|  15.8M|inline void bit_transpose(uint32_t B[8]) {
  374|  15.8M|   swap_bits<uint32_t>(B[1], B[0], 0x55555555, 1);
  375|  15.8M|   swap_bits<uint32_t>(B[3], B[2], 0x55555555, 1);
  376|  15.8M|   swap_bits<uint32_t>(B[5], B[4], 0x55555555, 1);
  377|  15.8M|   swap_bits<uint32_t>(B[7], B[6], 0x55555555, 1);
  378|       |
  379|  15.8M|   swap_bits<uint32_t>(B[2], B[0], 0x33333333, 2);
  380|  15.8M|   swap_bits<uint32_t>(B[3], B[1], 0x33333333, 2);
  381|  15.8M|   swap_bits<uint32_t>(B[6], B[4], 0x33333333, 2);
  382|  15.8M|   swap_bits<uint32_t>(B[7], B[5], 0x33333333, 2);
  383|       |
  384|  15.8M|   swap_bits<uint32_t>(B[4], B[0], 0x0F0F0F0F, 4);
  385|  15.8M|   swap_bits<uint32_t>(B[5], B[1], 0x0F0F0F0F, 4);
  386|  15.8M|   swap_bits<uint32_t>(B[6], B[2], 0x0F0F0F0F, 4);
  387|  15.8M|   swap_bits<uint32_t>(B[7], B[3], 0x0F0F0F0F, 4);
  388|  15.8M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_18AES_SBOXEPj:
   92|  98.9M|void AES_SBOX(uint32_t V[8]) {
   93|  98.9M|   const uint32_t U0 = V[0];
   94|  98.9M|   const uint32_t U1 = V[1];
   95|  98.9M|   const uint32_t U2 = V[2];
   96|  98.9M|   const uint32_t U3 = V[3];
   97|  98.9M|   const uint32_t U4 = V[4];
   98|  98.9M|   const uint32_t U5 = V[5];
   99|  98.9M|   const uint32_t U6 = V[6];
  100|  98.9M|   const uint32_t U7 = V[7];
  101|       |
  102|  98.9M|   const uint32_t y14 = U3 ^ U5;
  103|  98.9M|   const uint32_t y13 = U0 ^ U6;
  104|  98.9M|   const uint32_t y9 = U0 ^ U3;
  105|  98.9M|   const uint32_t y8 = U0 ^ U5;
  106|  98.9M|   const uint32_t t0 = U1 ^ U2;
  107|  98.9M|   const uint32_t y1 = t0 ^ U7;
  108|  98.9M|   const uint32_t y4 = y1 ^ U3;
  109|  98.9M|   const uint32_t y12 = y13 ^ y14;
  110|  98.9M|   const uint32_t y2 = y1 ^ U0;
  111|  98.9M|   const uint32_t y5 = y1 ^ U6;
  112|  98.9M|   const uint32_t y3 = y5 ^ y8;
  113|  98.9M|   const uint32_t t1 = U4 ^ y12;
  114|  98.9M|   const uint32_t y15 = t1 ^ U5;
  115|  98.9M|   const uint32_t y20 = t1 ^ U1;
  116|  98.9M|   const uint32_t y6 = y15 ^ U7;
  117|  98.9M|   const uint32_t y10 = y15 ^ t0;
  118|  98.9M|   const uint32_t y11 = y20 ^ y9;
  119|  98.9M|   const uint32_t y7 = U7 ^ y11;
  120|  98.9M|   const uint32_t y17 = y10 ^ y11;
  121|  98.9M|   const uint32_t y19 = y10 ^ y8;
  122|  98.9M|   const uint32_t y16 = t0 ^ y11;
  123|  98.9M|   const uint32_t y21 = y13 ^ y16;
  124|  98.9M|   const uint32_t y18 = U0 ^ y16;
  125|  98.9M|   const uint32_t t2 = y12 & y15;
  126|  98.9M|   const uint32_t t3 = y3 & y6;
  127|  98.9M|   const uint32_t t4 = t3 ^ t2;
  128|  98.9M|   const uint32_t t5 = y4 & U7;
  129|  98.9M|   const uint32_t t6 = t5 ^ t2;
  130|  98.9M|   const uint32_t t7 = y13 & y16;
  131|  98.9M|   const uint32_t t8 = y5 & y1;
  132|  98.9M|   const uint32_t t9 = t8 ^ t7;
  133|  98.9M|   const uint32_t t10 = y2 & y7;
  134|  98.9M|   const uint32_t t11 = t10 ^ t7;
  135|  98.9M|   const uint32_t t12 = y9 & y11;
  136|  98.9M|   const uint32_t t13 = y14 & y17;
  137|  98.9M|   const uint32_t t14 = t13 ^ t12;
  138|  98.9M|   const uint32_t t15 = y8 & y10;
  139|  98.9M|   const uint32_t t16 = t15 ^ t12;
  140|  98.9M|   const uint32_t t17 = t4 ^ y20;
  141|  98.9M|   const uint32_t t18 = t6 ^ t16;
  142|  98.9M|   const uint32_t t19 = t9 ^ t14;
  143|  98.9M|   const uint32_t t20 = t11 ^ t16;
  144|  98.9M|   const uint32_t t21 = t17 ^ t14;
  145|  98.9M|   const uint32_t t22 = t18 ^ y19;
  146|  98.9M|   const uint32_t t23 = t19 ^ y21;
  147|  98.9M|   const uint32_t t24 = t20 ^ y18;
  148|  98.9M|   const uint32_t t25 = t21 ^ t22;
  149|  98.9M|   const uint32_t t26 = t21 & t23;
  150|  98.9M|   const uint32_t t27 = t24 ^ t26;
  151|  98.9M|   const uint32_t t28 = t25 & t27;
  152|  98.9M|   const uint32_t t29 = t28 ^ t22;
  153|  98.9M|   const uint32_t t30 = t23 ^ t24;
  154|  98.9M|   const uint32_t t31 = t22 ^ t26;
  155|  98.9M|   const uint32_t t32 = t31 & t30;
  156|  98.9M|   const uint32_t t33 = t32 ^ t24;
  157|  98.9M|   const uint32_t t34 = t23 ^ t33;
  158|  98.9M|   const uint32_t t35 = t27 ^ t33;
  159|  98.9M|   const uint32_t t36 = t24 & t35;
  160|  98.9M|   const uint32_t t37 = t36 ^ t34;
  161|  98.9M|   const uint32_t t38 = t27 ^ t36;
  162|  98.9M|   const uint32_t t39 = t29 & t38;
  163|  98.9M|   const uint32_t t40 = t25 ^ t39;
  164|  98.9M|   const uint32_t t41 = t40 ^ t37;
  165|  98.9M|   const uint32_t t42 = t29 ^ t33;
  166|  98.9M|   const uint32_t t43 = t29 ^ t40;
  167|  98.9M|   const uint32_t t44 = t33 ^ t37;
  168|  98.9M|   const uint32_t t45 = t42 ^ t41;
  169|  98.9M|   const uint32_t z0 = t44 & y15;
  170|  98.9M|   const uint32_t z1 = t37 & y6;
  171|  98.9M|   const uint32_t z2 = t33 & U7;
  172|  98.9M|   const uint32_t z3 = t43 & y16;
  173|  98.9M|   const uint32_t z4 = t40 & y1;
  174|  98.9M|   const uint32_t z5 = t29 & y7;
  175|  98.9M|   const uint32_t z6 = t42 & y11;
  176|  98.9M|   const uint32_t z7 = t45 & y17;
  177|  98.9M|   const uint32_t z8 = t41 & y10;
  178|  98.9M|   const uint32_t z9 = t44 & y12;
  179|  98.9M|   const uint32_t z10 = t37 & y3;
  180|  98.9M|   const uint32_t z11 = t33 & y4;
  181|  98.9M|   const uint32_t z12 = t43 & y13;
  182|  98.9M|   const uint32_t z13 = t40 & y5;
  183|  98.9M|   const uint32_t z14 = t29 & y2;
  184|  98.9M|   const uint32_t z15 = t42 & y9;
  185|  98.9M|   const uint32_t z16 = t45 & y14;
  186|  98.9M|   const uint32_t z17 = t41 & y8;
  187|  98.9M|   const uint32_t tc1 = z15 ^ z16;
  188|  98.9M|   const uint32_t tc2 = z10 ^ tc1;
  189|  98.9M|   const uint32_t tc3 = z9 ^ tc2;
  190|  98.9M|   const uint32_t tc4 = z0 ^ z2;
  191|  98.9M|   const uint32_t tc5 = z1 ^ z0;
  192|  98.9M|   const uint32_t tc6 = z3 ^ z4;
  193|  98.9M|   const uint32_t tc7 = z12 ^ tc4;
  194|  98.9M|   const uint32_t tc8 = z7 ^ tc6;
  195|  98.9M|   const uint32_t tc9 = z8 ^ tc7;
  196|  98.9M|   const uint32_t tc10 = tc8 ^ tc9;
  197|  98.9M|   const uint32_t tc11 = tc6 ^ tc5;
  198|  98.9M|   const uint32_t tc12 = z3 ^ z5;
  199|  98.9M|   const uint32_t tc13 = z13 ^ tc1;
  200|  98.9M|   const uint32_t tc14 = tc4 ^ tc12;
  201|  98.9M|   const uint32_t S3 = tc3 ^ tc11;
  202|  98.9M|   const uint32_t tc16 = z6 ^ tc8;
  203|  98.9M|   const uint32_t tc17 = z14 ^ tc10;
  204|  98.9M|   const uint32_t tc18 = ~tc13 ^ tc14;
  205|  98.9M|   const uint32_t S7 = z12 ^ tc18;
  206|  98.9M|   const uint32_t tc20 = z15 ^ tc16;
  207|  98.9M|   const uint32_t tc21 = tc2 ^ z11;
  208|  98.9M|   const uint32_t S0 = tc3 ^ tc16;
  209|  98.9M|   const uint32_t S6 = tc10 ^ tc18;
  210|  98.9M|   const uint32_t S4 = tc14 ^ S3;
  211|  98.9M|   const uint32_t S1 = ~(S3 ^ tc16);
  212|  98.9M|   const uint32_t tc26 = tc17 ^ tc20;
  213|  98.9M|   const uint32_t S2 = ~(tc26 ^ z17);
  214|  98.9M|   const uint32_t S5 = tc21 ^ tc17;
  215|       |
  216|  98.9M|   V[0] = S0;
  217|  98.9M|   V[1] = S1;
  218|  98.9M|   V[2] = S2;
  219|  98.9M|   V[3] = S3;
  220|  98.9M|   V[4] = S4;
  221|  98.9M|   V[5] = S5;
  222|  98.9M|   V[6] = S6;
  223|  98.9M|   V[7] = S7;
  224|  98.9M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_110shift_rowsEPj:
  416|  98.7M|inline void shift_rows(uint32_t B[8]) {
  417|       |   // 3 0 1 2 7 4 5 6 10 11 8 9 14 15 12 13 17 18 19 16 21 22 23 20 24 25 26 27 28 29 30 31
  418|  98.7M|   if constexpr(HasNative64BitRegisters) {
  419|   493M|      for(size_t i = 0; i != 8; i += 2) {
  ------------------
  |  Branch (419:25): [True: 395M, False: 98.7M]
  ------------------
  420|   395M|         uint64_t x = (static_cast<uint64_t>(B[i]) << 32) | B[i + 1];
  421|   395M|         x = bit_permute_step<uint64_t>(x, 0x0022331100223311, 2);
  422|   395M|         x = bit_permute_step<uint64_t>(x, 0x0055005500550055, 1);
  423|   395M|         B[i] = static_cast<uint32_t>(x >> 32);
  424|   395M|         B[i + 1] = static_cast<uint32_t>(x);
  425|   395M|      }
  426|       |   } else {
  427|       |      for(size_t i = 0; i != 8; ++i) {
  428|       |         uint32_t x = B[i];
  429|       |         x = bit_permute_step<uint32_t>(x, 0x00223311, 2);
  430|       |         x = bit_permute_step<uint32_t>(x, 0x00550055, 1);
  431|       |         B[i] = x;
  432|       |      }
  433|       |   }
  434|  98.7M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_111mix_columnsEPj:
  457|  97.8M|inline void mix_columns(uint32_t B[8]) {
  458|       |   // carry high bits in B[0] to positions in 0x1b == 0b11011
  459|  97.8M|   const uint32_t X2[8] = {
  460|  97.8M|      B[1],
  461|  97.8M|      B[2],
  462|  97.8M|      B[3],
  463|  97.8M|      B[4] ^ B[0],
  464|  97.8M|      B[5] ^ B[0],
  465|  97.8M|      B[6],
  466|  97.8M|      B[7] ^ B[0],
  467|  97.8M|      B[0],
  468|  97.8M|   };
  469|       |
  470|   880M|   for(size_t i = 0; i != 8; i++) {
  ------------------
  |  Branch (470:22): [True: 782M, False: 97.8M]
  ------------------
  471|   782M|      const uint32_t X3 = B[i] ^ X2[i];
  472|   782M|      B[i] = X2[i] ^ rotr<8>(B[i]) ^ rotr<16>(B[i]) ^ rotr<24>(X3);
  473|   782M|   }
  474|  97.8M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_113aes_decrypt_nEPKhPhmRKNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  572|   186k|void aes_decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks, const secure_vector<uint32_t>& DK) {
  573|   186k|   BOTAN_ASSERT(DK.size() == 44 || DK.size() == 52 || DK.size() == 60, "Key was set");
  ------------------
  |  |   64|   186k|   do {                                                                                 \
  |  |   65|   186k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|   685k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:12): [True: 29.3k, False: 157k]
  |  |  |  Branch (66:12): [True: 1.91k, False: 155k]
  |  |  |  Branch (66:12): [True: 155k, False: 0]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|   186k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 186k]
  |  |  ------------------
  ------------------
  574|       |
  575|   186k|   const size_t rounds = (DK.size() - 4) / 4;
  576|       |
  577|   186k|   uint32_t KS[13 * 8] = {0};  // actual maximum is (rounds - 1) * 8
  578|  2.48M|   for(size_t i = 0; i < rounds - 1; i += 1) {
  ------------------
  |  Branch (578:22): [True: 2.30M, False: 186k]
  ------------------
  579|  2.30M|      ks_expand(&KS[8 * i], DK.data(), 4 * i + 4);
  580|  2.30M|   }
  581|       |
  582|   186k|   const size_t BLOCK_SIZE = 16;
  583|   186k|   const size_t BITSLICED_BLOCKS = 8 * sizeof(uint32_t) / BLOCK_SIZE;
  584|       |
  585|   718k|   while(blocks > 0) {
  ------------------
  |  Branch (585:10): [True: 531k, False: 186k]
  ------------------
  586|   531k|      const size_t this_loop = std::min(blocks, BITSLICED_BLOCKS);
  587|       |
  588|   531k|      uint32_t B[8] = {0};
  589|       |
  590|   531k|      load_be(B, in, this_loop * 4);
  591|       |
  592|   531k|      CT::poison(B, 8);
  593|       |
  594|  4.78M|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (594:25): [True: 4.25M, False: 531k]
  ------------------
  595|  4.25M|         B[i] ^= DK[i % 4];
  596|  4.25M|      }
  597|       |
  598|   531k|      bit_transpose(B);
  599|       |
  600|  6.98M|      for(size_t r = 0; r != rounds - 1; ++r) {
  ------------------
  |  Branch (600:25): [True: 6.44M, False: 531k]
  ------------------
  601|  6.44M|         AES_INV_SBOX(B);
  602|  6.44M|         inv_shift_rows(B);
  603|  6.44M|         inv_mix_columns(B);
  604|       |
  605|  58.0M|         for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (605:28): [True: 51.5M, False: 6.44M]
  ------------------
  606|  51.5M|            B[i] ^= KS[8 * r + i];
  607|  51.5M|         }
  608|  6.44M|      }
  609|       |
  610|       |      // Final round:
  611|   531k|      AES_INV_SBOX(B);
  612|   531k|      inv_shift_rows(B);
  613|   531k|      bit_transpose(B);
  614|       |
  615|  4.78M|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (615:25): [True: 4.25M, False: 531k]
  ------------------
  616|  4.25M|         B[i] ^= DK[4 * rounds + i % 4];
  617|  4.25M|      }
  618|       |
  619|   531k|      CT::unpoison(B, 8);
  620|       |
  621|   531k|      copy_out_be(std::span(out, this_loop * 4 * sizeof(uint32_t)), B);
  622|       |
  623|   531k|      in += this_loop * BLOCK_SIZE;
  624|   531k|      out += this_loop * BLOCK_SIZE;
  625|   531k|      blocks -= this_loop;
  626|   531k|   }
  627|   186k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_112AES_INV_SBOXEPj:
  231|  6.98M|void AES_INV_SBOX(uint32_t V[8]) {
  232|  6.98M|   const uint32_t U0 = V[0];
  233|  6.98M|   const uint32_t U1 = V[1];
  234|  6.98M|   const uint32_t U2 = V[2];
  235|  6.98M|   const uint32_t U3 = V[3];
  236|  6.98M|   const uint32_t U4 = V[4];
  237|  6.98M|   const uint32_t U5 = V[5];
  238|  6.98M|   const uint32_t U6 = V[6];
  239|  6.98M|   const uint32_t U7 = V[7];
  240|       |
  241|  6.98M|   const uint32_t Y0 = U0 ^ U3;
  242|  6.98M|   const uint32_t Y2 = ~(U1 ^ U3);
  243|  6.98M|   const uint32_t Y4 = U0 ^ Y2;
  244|  6.98M|   const uint32_t RTL0 = U6 ^ U7;
  245|  6.98M|   const uint32_t Y1 = Y2 ^ RTL0;
  246|  6.98M|   const uint32_t Y7 = ~(U2 ^ Y1);
  247|  6.98M|   const uint32_t RTL1 = U3 ^ U4;
  248|  6.98M|   const uint32_t Y6 = ~(U7 ^ RTL1);
  249|  6.98M|   const uint32_t Y3 = Y1 ^ RTL1;
  250|  6.98M|   const uint32_t RTL2 = ~(U0 ^ U2);
  251|  6.98M|   const uint32_t Y5 = U5 ^ RTL2;
  252|  6.98M|   const uint32_t sa1 = Y0 ^ Y2;
  253|  6.98M|   const uint32_t sa0 = Y1 ^ Y3;
  254|  6.98M|   const uint32_t sb1 = Y4 ^ Y6;
  255|  6.98M|   const uint32_t sb0 = Y5 ^ Y7;
  256|  6.98M|   const uint32_t ah = Y0 ^ Y1;
  257|  6.98M|   const uint32_t al = Y2 ^ Y3;
  258|  6.98M|   const uint32_t aa = sa0 ^ sa1;
  259|  6.98M|   const uint32_t bh = Y4 ^ Y5;
  260|  6.98M|   const uint32_t bl = Y6 ^ Y7;
  261|  6.98M|   const uint32_t bb = sb0 ^ sb1;
  262|  6.98M|   const uint32_t ab20 = sa0 ^ sb0;
  263|  6.98M|   const uint32_t ab22 = al ^ bl;
  264|  6.98M|   const uint32_t ab23 = Y3 ^ Y7;
  265|  6.98M|   const uint32_t ab21 = sa1 ^ sb1;
  266|  6.98M|   const uint32_t abcd1 = ah & bh;
  267|  6.98M|   const uint32_t rr1 = Y0 & Y4;
  268|  6.98M|   const uint32_t ph11 = ab20 ^ abcd1;
  269|  6.98M|   const uint32_t t01 = Y1 & Y5;
  270|  6.98M|   const uint32_t ph01 = t01 ^ abcd1;
  271|  6.98M|   const uint32_t abcd2 = al & bl;
  272|  6.98M|   const uint32_t r1 = Y2 & Y6;
  273|  6.98M|   const uint32_t pl11 = ab22 ^ abcd2;
  274|  6.98M|   const uint32_t r2 = Y3 & Y7;
  275|  6.98M|   const uint32_t pl01 = r2 ^ abcd2;
  276|  6.98M|   const uint32_t r3 = sa0 & sb0;
  277|  6.98M|   const uint32_t vr1 = aa & bb;
  278|  6.98M|   const uint32_t pr1 = vr1 ^ r3;
  279|  6.98M|   const uint32_t wr1 = sa1 & sb1;
  280|  6.98M|   const uint32_t qr1 = wr1 ^ r3;
  281|  6.98M|   const uint32_t ab0 = ph11 ^ rr1;
  282|  6.98M|   const uint32_t ab1 = ph01 ^ ab21;
  283|  6.98M|   const uint32_t ab2 = pl11 ^ r1;
  284|  6.98M|   const uint32_t ab3 = pl01 ^ qr1;
  285|  6.98M|   const uint32_t cp1 = ab0 ^ pr1;
  286|  6.98M|   const uint32_t cp2 = ab1 ^ qr1;
  287|  6.98M|   const uint32_t cp3 = ab2 ^ pr1;
  288|  6.98M|   const uint32_t cp4 = ab3 ^ ab23;
  289|  6.98M|   const uint32_t tinv1 = cp3 ^ cp4;
  290|  6.98M|   const uint32_t tinv2 = cp3 & cp1;
  291|  6.98M|   const uint32_t tinv3 = cp2 ^ tinv2;
  292|  6.98M|   const uint32_t tinv4 = cp1 ^ cp2;
  293|  6.98M|   const uint32_t tinv5 = cp4 ^ tinv2;
  294|  6.98M|   const uint32_t tinv6 = tinv5 & tinv4;
  295|  6.98M|   const uint32_t tinv7 = tinv3 & tinv1;
  296|  6.98M|   const uint32_t d2 = cp4 ^ tinv7;
  297|  6.98M|   const uint32_t d0 = cp2 ^ tinv6;
  298|  6.98M|   const uint32_t tinv8 = cp1 & cp4;
  299|  6.98M|   const uint32_t tinv9 = tinv4 & tinv8;
  300|  6.98M|   const uint32_t tinv10 = tinv4 ^ tinv2;
  301|  6.98M|   const uint32_t d1 = tinv9 ^ tinv10;
  302|  6.98M|   const uint32_t tinv11 = cp2 & cp3;
  303|  6.98M|   const uint32_t tinv12 = tinv1 & tinv11;
  304|  6.98M|   const uint32_t tinv13 = tinv1 ^ tinv2;
  305|  6.98M|   const uint32_t d3 = tinv12 ^ tinv13;
  306|  6.98M|   const uint32_t sd1 = d1 ^ d3;
  307|  6.98M|   const uint32_t sd0 = d0 ^ d2;
  308|  6.98M|   const uint32_t dl = d0 ^ d1;  // NOLINT(misc-confusable-identifiers)
  309|  6.98M|   const uint32_t dh = d2 ^ d3;
  310|  6.98M|   const uint32_t dd = sd0 ^ sd1;
  311|  6.98M|   const uint32_t abcd3 = dh & bh;
  312|  6.98M|   const uint32_t rr2 = d3 & Y4;
  313|  6.98M|   const uint32_t t02 = d2 & Y5;
  314|  6.98M|   const uint32_t abcd4 = dl & bl;
  315|  6.98M|   const uint32_t r4 = d1 & Y6;
  316|  6.98M|   const uint32_t r5 = d0 & Y7;
  317|  6.98M|   const uint32_t r6 = sd0 & sb0;
  318|  6.98M|   const uint32_t vr2 = dd & bb;
  319|  6.98M|   const uint32_t wr2 = sd1 & sb1;
  320|  6.98M|   const uint32_t abcd5 = dh & ah;
  321|  6.98M|   const uint32_t r7 = d3 & Y0;
  322|  6.98M|   const uint32_t r8 = d2 & Y1;
  323|  6.98M|   const uint32_t abcd6 = dl & al;
  324|  6.98M|   const uint32_t r9 = d1 & Y2;
  325|  6.98M|   const uint32_t r10 = d0 & Y3;
  326|  6.98M|   const uint32_t r11 = sd0 & sa0;
  327|  6.98M|   const uint32_t vr3 = dd & aa;
  328|  6.98M|   const uint32_t wr3 = sd1 & sa1;
  329|  6.98M|   const uint32_t ph12 = rr2 ^ abcd3;
  330|  6.98M|   const uint32_t ph02 = t02 ^ abcd3;
  331|  6.98M|   const uint32_t pl12 = r4 ^ abcd4;
  332|  6.98M|   const uint32_t pl02 = r5 ^ abcd4;
  333|  6.98M|   const uint32_t pr2 = vr2 ^ r6;
  334|  6.98M|   const uint32_t qr2 = wr2 ^ r6;
  335|  6.98M|   const uint32_t p0 = ph12 ^ pr2;
  336|  6.98M|   const uint32_t p1 = ph02 ^ qr2;
  337|  6.98M|   const uint32_t p2 = pl12 ^ pr2;
  338|  6.98M|   const uint32_t p3 = pl02 ^ qr2;
  339|  6.98M|   const uint32_t ph13 = r7 ^ abcd5;
  340|  6.98M|   const uint32_t ph03 = r8 ^ abcd5;
  341|  6.98M|   const uint32_t pl13 = r9 ^ abcd6;
  342|  6.98M|   const uint32_t pl03 = r10 ^ abcd6;
  343|  6.98M|   const uint32_t pr3 = vr3 ^ r11;
  344|  6.98M|   const uint32_t qr3 = wr3 ^ r11;
  345|  6.98M|   const uint32_t p4 = ph13 ^ pr3;
  346|  6.98M|   const uint32_t S7 = ph03 ^ qr3;
  347|  6.98M|   const uint32_t p6 = pl13 ^ pr3;
  348|  6.98M|   const uint32_t p7 = pl03 ^ qr3;
  349|  6.98M|   const uint32_t S3 = p1 ^ p6;
  350|  6.98M|   const uint32_t S6 = p2 ^ p6;
  351|  6.98M|   const uint32_t S0 = p3 ^ p6;
  352|  6.98M|   const uint32_t X11 = p0 ^ p2;
  353|  6.98M|   const uint32_t S5 = S0 ^ X11;
  354|  6.98M|   const uint32_t X13 = p4 ^ p7;
  355|  6.98M|   const uint32_t X14 = X11 ^ X13;
  356|  6.98M|   const uint32_t S1 = S3 ^ X14;
  357|  6.98M|   const uint32_t X16 = p1 ^ S7;
  358|  6.98M|   const uint32_t S2 = X14 ^ X16;
  359|  6.98M|   const uint32_t X18 = p0 ^ p4;
  360|  6.98M|   const uint32_t X19 = S5 ^ X16;
  361|  6.98M|   const uint32_t S4 = X18 ^ X19;
  362|       |
  363|  6.98M|   V[0] = S0;
  364|  6.98M|   V[1] = S1;
  365|  6.98M|   V[2] = S2;
  366|  6.98M|   V[3] = S3;
  367|  6.98M|   V[4] = S4;
  368|  6.98M|   V[5] = S5;
  369|  6.98M|   V[6] = S6;
  370|  6.98M|   V[7] = S7;
  371|  6.98M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_114inv_shift_rowsEPj:
  436|  6.98M|inline void inv_shift_rows(uint32_t B[8]) {
  437|       |   // Inverse of shift_rows, just inverting the steps
  438|       |
  439|  6.98M|   if constexpr(HasNative64BitRegisters) {
  440|  34.9M|      for(size_t i = 0; i != 8; i += 2) {
  ------------------
  |  Branch (440:25): [True: 27.9M, False: 6.98M]
  ------------------
  441|  27.9M|         uint64_t x = (static_cast<uint64_t>(B[i]) << 32) | B[i + 1];
  442|  27.9M|         x = bit_permute_step<uint64_t>(x, 0x0055005500550055, 1);
  443|  27.9M|         x = bit_permute_step<uint64_t>(x, 0x0022331100223311, 2);
  444|  27.9M|         B[i] = static_cast<uint32_t>(x >> 32);
  445|  27.9M|         B[i + 1] = static_cast<uint32_t>(x);
  446|  27.9M|      }
  447|       |   } else {
  448|       |      for(size_t i = 0; i != 8; ++i) {
  449|       |         uint32_t x = B[i];
  450|       |         x = bit_permute_step<uint32_t>(x, 0x00550055, 1);
  451|       |         x = bit_permute_step<uint32_t>(x, 0x00223311, 2);
  452|       |         B[i] = x;
  453|       |      }
  454|       |   }
  455|  6.98M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_115inv_mix_columnsEPj:
  476|  6.44M|void inv_mix_columns(uint32_t B[8]) {
  477|       |   /*
  478|       |   OpenSSL's bsaes implementation credits Jussi Kivilinna with the lovely
  479|       |   matrix decomposition
  480|       |
  481|       |   | 0e 0b 0d 09 |   | 02 03 01 01 |   | 05 00 04 00 |
  482|       |   | 09 0e 0b 0d | = | 01 02 03 01 | x | 00 05 00 04 |
  483|       |   | 0d 09 0e 0b |   | 01 01 02 03 |   | 04 00 05 00 |
  484|       |   | 0b 0d 09 0e |   | 03 01 01 02 |   | 00 04 00 05 |
  485|       |
  486|       |   Notice the first component is simply the MixColumns matrix. So we can
  487|       |   multiply first by (05,00,04,00) then perform MixColumns to get the equivalent
  488|       |   of InvMixColumn.
  489|       |   */
  490|  6.44M|   const uint32_t X4[8] = {
  491|  6.44M|      B[2],
  492|  6.44M|      B[3],
  493|  6.44M|      B[4] ^ B[0],
  494|  6.44M|      B[5] ^ B[0] ^ B[1],
  495|  6.44M|      B[6] ^ B[1],
  496|  6.44M|      B[7] ^ B[0],
  497|  6.44M|      B[0] ^ B[1],
  498|  6.44M|      B[1],
  499|  6.44M|   };
  500|       |
  501|  58.0M|   for(size_t i = 0; i != 8; i++) {
  ------------------
  |  Branch (501:22): [True: 51.5M, False: 6.44M]
  ------------------
  502|  51.5M|      const uint32_t X5 = X4[i] ^ B[i];
  503|  51.5M|      B[i] = X5 ^ rotr<16>(X4[i]);
  504|  51.5M|   }
  505|       |
  506|  6.44M|   mix_columns(B);
  507|  6.44M|}
aes.cpp:_ZN5Botan12_GLOBAL__N_116aes_key_scheduleEPKhmRNSt3__16vectorIjNS_16secure_allocatorIjEEEES8_b:
  678|  15.5k|                      bool bswap_keys = false) {
  679|  15.5k|   static const uint32_t RC[10] = {0x01000000,
  680|  15.5k|                                   0x02000000,
  681|  15.5k|                                   0x04000000,
  682|  15.5k|                                   0x08000000,
  683|  15.5k|                                   0x10000000,
  684|  15.5k|                                   0x20000000,
  685|  15.5k|                                   0x40000000,
  686|  15.5k|                                   0x80000000,
  687|  15.5k|                                   0x1B000000,
  688|  15.5k|                                   0x36000000};
  689|       |
  690|  15.5k|   const size_t X = length / 4;
  691|       |
  692|       |   // Can't happen, but make static analyzers happy
  693|  15.5k|   BOTAN_ASSERT_NOMSG(X == 4 || X == 6 || X == 8);
  ------------------
  |  |   77|  15.5k|   do {                                                                     \
  |  |   78|  15.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  50.8k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 4.90k, False: 10.6k]
  |  |  |  Branch (79:12): [True: 1.51k, False: 9.12k]
  |  |  |  Branch (79:12): [True: 9.12k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  15.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 15.5k]
  |  |  ------------------
  ------------------
  694|       |
  695|  15.5k|   const size_t rounds = (length / 4) + 6;
  696|       |
  697|       |   // Help the optimizer
  698|  15.5k|   BOTAN_ASSERT_NOMSG(rounds == 10 || rounds == 12 || rounds == 14);
  ------------------
  |  |   77|  15.5k|   do {                                                                     \
  |  |   78|  15.5k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  50.8k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 4.90k, False: 10.6k]
  |  |  |  Branch (79:12): [True: 1.51k, False: 9.12k]
  |  |  |  Branch (79:12): [True: 9.12k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  15.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 15.5k]
  |  |  ------------------
  ------------------
  699|       |
  700|  15.5k|   CT::poison(key, length);
  701|       |
  702|  15.5k|   const size_t KS_len = length + 28;
  703|  15.5k|   EK.resize(KS_len);
  704|  15.5k|   DK.resize(KS_len);
  705|       |
  706|   117k|   for(size_t i = 0; i != X; ++i) {
  ------------------
  |  Branch (706:22): [True: 101k, False: 15.5k]
  ------------------
  707|   101k|      EK[i] = load_be<uint32_t>(key, i);
  708|   101k|   }
  709|       |
  710|   140k|   for(size_t i = X; i < 4 * (rounds + 1); i += X) {
  ------------------
  |  Branch (710:22): [True: 124k, False: 15.5k]
  ------------------
  711|   124k|      EK[i] = EK[i - X] ^ RC[(i - X) / X] ^ rotl<8>(SE_word(EK[i - 1]));
  712|       |
  713|   739k|      for(size_t j = 1; j != X && (i + j) < EK.size(); ++j) {
  ------------------
  |  Branch (713:25): [True: 625k, False: 114k]
  |  Branch (713:35): [True: 614k, False: 10.6k]
  ------------------
  714|   614k|         EK[i + j] = EK[i + j - X];
  715|       |
  716|   614k|         if(X == 8 && j == 4) {
  ------------------
  |  Branch (716:13): [True: 410k, False: 204k]
  |  Branch (716:23): [True: 54.7k, False: 355k]
  ------------------
  717|  54.7k|            EK[i + j] ^= SE_word(EK[i + j - 1]);
  718|   560k|         } else {
  719|   560k|            EK[i + j] ^= EK[i + j - 1];
  720|   560k|         }
  721|   614k|      }
  722|   124k|   }
  723|       |
  724|   225k|   for(size_t i = 0; i != 4 * (rounds + 1); i += 4) {
  ------------------
  |  Branch (724:22): [True: 210k, False: 15.5k]
  ------------------
  725|   210k|      DK[i] = EK[4 * rounds - i];
  726|   210k|      DK[i + 1] = EK[4 * rounds - i + 1];
  727|   210k|      DK[i + 2] = EK[4 * rounds - i + 2];
  728|   210k|      DK[i + 3] = EK[4 * rounds - i + 3];
  729|   210k|   }
  730|       |
  731|   194k|   for(size_t i = 4; i != 4 * rounds; i += 4) {
  ------------------
  |  Branch (731:22): [True: 179k, False: 15.5k]
  ------------------
  732|   179k|      InvMixColumn_x4(&DK[i]);
  733|   179k|   }
  734|       |
  735|  15.5k|   if(bswap_keys) {
  ------------------
  |  Branch (735:7): [True: 0, False: 15.5k]
  ------------------
  736|       |      // HW AES on little endian needs the subkeys to be byte reversed
  737|      0|      for(size_t i = 0; i != KS_len; ++i) {
  ------------------
  |  Branch (737:25): [True: 0, False: 0]
  ------------------
  738|      0|         EK[i] = reverse_bytes(EK[i]);
  739|      0|         DK[i] = reverse_bytes(DK[i]);
  740|      0|      }
  741|      0|   }
  742|       |
  743|  15.5k|   CT::unpoison(EK.data(), EK.size());
  744|  15.5k|   CT::unpoison(DK.data(), DK.size());
  745|  15.5k|   CT::unpoison(key, length);
  746|  15.5k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_17SE_wordEj:
  656|   179k|uint32_t SE_word(uint32_t x) {
  657|   179k|   uint32_t I[8] = {0};
  658|       |
  659|  1.61M|   for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (659:22): [True: 1.43M, False: 179k]
  ------------------
  660|  1.43M|      I[i] = (x >> (7 - i)) & 0x01010101;
  661|  1.43M|   }
  662|       |
  663|   179k|   AES_SBOX(I);
  664|       |
  665|   179k|   x = 0;
  666|       |
  667|  1.61M|   for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (667:22): [True: 1.43M, False: 179k]
  ------------------
  668|  1.43M|      x |= ((I[i] & 0x01010101) << (7 - i));
  669|  1.43M|   }
  670|       |
  671|   179k|   return x;
  672|   179k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_115InvMixColumn_x4EPj:
  649|   179k|void InvMixColumn_x4(uint32_t x[4]) {
  650|   179k|   x[0] = InvMixColumn(x[0]);
  651|   179k|   x[1] = InvMixColumn(x[1]);
  652|   179k|   x[2] = InvMixColumn(x[2]);
  653|   179k|   x[3] = InvMixColumn(x[3]);
  654|   179k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_112InvMixColumnEj:
  637|   717k|inline uint32_t InvMixColumn(uint32_t s1) {
  638|   717k|   const uint32_t s2 = xtime32(s1);
  639|   717k|   const uint32_t s4 = xtime32(s2);
  640|   717k|   const uint32_t s8 = xtime32(s4);
  641|   717k|   const uint32_t s9 = s8 ^ s1;
  642|   717k|   const uint32_t s11 = s9 ^ s2;
  643|   717k|   const uint32_t s13 = s9 ^ s4;
  644|   717k|   const uint32_t s14 = s8 ^ s4 ^ s2;
  645|       |
  646|   717k|   return s14 ^ rotr<8>(s9) ^ rotr<16>(s13) ^ rotr<24>(s11);
  647|   717k|}
aes.cpp:_ZN5Botan12_GLOBAL__N_17xtime32Ej:
  629|  2.15M|inline uint32_t xtime32(uint32_t s) {
  630|  2.15M|   const uint32_t lo_bit = 0x01010101;
  631|  2.15M|   const uint32_t mask = 0x7F7F7F7F;
  632|  2.15M|   const uint32_t poly = 0x1B;
  633|       |
  634|  2.15M|   return ((s & mask) << 1) ^ (((s >> 7) & lo_bit) * poly);
  635|  2.15M|}

_ZN5Botan11BlockCipher6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
   96|  28.2k|std::unique_ptr<BlockCipher> BlockCipher::create(std::string_view algo, std::string_view provider) {
   97|       |#if defined(BOTAN_HAS_COMMONCRYPTO)
   98|       |   if(provider.empty() || provider == "commoncrypto") {
   99|       |      if(auto bc = make_commoncrypto_block_cipher(algo))
  100|       |         return bc;
  101|       |
  102|       |      if(!provider.empty())
  103|       |         return nullptr;
  104|       |   }
  105|       |#endif
  106|       |
  107|       |   // TODO: CryptoAPI
  108|       |   // TODO: /dev/crypto
  109|       |
  110|       |   // Only base providers from here on out
  111|  28.2k|   if(provider.empty() == false && provider != "base") {
  ------------------
  |  Branch (111:7): [True: 0, False: 28.2k]
  |  Branch (111:36): [True: 0, False: 0]
  ------------------
  112|      0|      return nullptr;
  113|      0|   }
  114|       |
  115|  28.2k|#if defined(BOTAN_HAS_AES)
  116|  28.2k|   if(algo == "AES-128") {
  ------------------
  |  Branch (116:7): [True: 4.12k, False: 24.1k]
  ------------------
  117|  4.12k|      return std::make_unique<AES_128>();
  118|  4.12k|   }
  119|       |
  120|  24.1k|   if(algo == "AES-192") {
  ------------------
  |  Branch (120:7): [True: 1.21k, False: 22.9k]
  ------------------
  121|  1.21k|      return std::make_unique<AES_192>();
  122|  1.21k|   }
  123|       |
  124|  22.9k|   if(algo == "AES-256") {
  ------------------
  |  Branch (124:7): [True: 8.42k, False: 14.4k]
  ------------------
  125|  8.42k|      return std::make_unique<AES_256>();
  126|  8.42k|   }
  127|  14.4k|#endif
  128|       |
  129|       |#if defined(BOTAN_HAS_ARIA)
  130|       |   if(algo == "ARIA-128") {
  131|       |      return std::make_unique<ARIA_128>();
  132|       |   }
  133|       |
  134|       |   if(algo == "ARIA-192") {
  135|       |      return std::make_unique<ARIA_192>();
  136|       |   }
  137|       |
  138|       |   if(algo == "ARIA-256") {
  139|       |      return std::make_unique<ARIA_256>();
  140|       |   }
  141|       |#endif
  142|       |
  143|       |#if defined(BOTAN_HAS_SERPENT)
  144|       |   if(algo == "Serpent") {
  145|       |      return std::make_unique<Serpent>();
  146|       |   }
  147|       |#endif
  148|       |
  149|       |#if defined(BOTAN_HAS_SHACAL2)
  150|       |   if(algo == "SHACAL2") {
  151|       |      return std::make_unique<SHACAL2>();
  152|       |   }
  153|       |#endif
  154|       |
  155|  14.4k|#if defined(BOTAN_HAS_TWOFISH)
  156|  14.4k|   if(algo == "Twofish") {
  ------------------
  |  Branch (156:7): [True: 1.82k, False: 12.6k]
  ------------------
  157|  1.82k|      return std::make_unique<Twofish>();
  158|  1.82k|   }
  159|  12.6k|#endif
  160|       |
  161|       |#if defined(BOTAN_HAS_THREEFISH_512)
  162|       |   if(algo == "Threefish-512") {
  163|       |      return std::make_unique<Threefish_512>();
  164|       |   }
  165|       |#endif
  166|       |
  167|  12.6k|#if defined(BOTAN_HAS_BLOWFISH)
  168|  12.6k|   if(algo == "Blowfish") {
  ------------------
  |  Branch (168:7): [True: 262, False: 12.3k]
  ------------------
  169|    262|      return std::make_unique<Blowfish>();
  170|    262|   }
  171|  12.3k|#endif
  172|       |
  173|  12.3k|#if defined(BOTAN_HAS_CAMELLIA)
  174|  12.3k|   if(algo == "Camellia-128") {
  ------------------
  |  Branch (174:7): [True: 4.45k, False: 7.93k]
  ------------------
  175|  4.45k|      return std::make_unique<Camellia_128>();
  176|  4.45k|   }
  177|       |
  178|  7.93k|   if(algo == "Camellia-192") {
  ------------------
  |  Branch (178:7): [True: 3.33k, False: 4.60k]
  ------------------
  179|  3.33k|      return std::make_unique<Camellia_192>();
  180|  3.33k|   }
  181|       |
  182|  4.60k|   if(algo == "Camellia-256") {
  ------------------
  |  Branch (182:7): [True: 949, False: 3.65k]
  ------------------
  183|    949|      return std::make_unique<Camellia_256>();
  184|    949|   }
  185|  3.65k|#endif
  186|       |
  187|  3.65k|#if defined(BOTAN_HAS_DES)
  188|  3.65k|   if(algo == "DES") {
  ------------------
  |  Branch (188:7): [True: 0, False: 3.65k]
  ------------------
  189|      0|      return std::make_unique<DES>();
  190|      0|   }
  191|       |
  192|  3.65k|   if(algo == "TripleDES" || algo == "3DES" || algo == "DES-EDE") {
  ------------------
  |  Branch (192:7): [True: 379, False: 3.27k]
  |  Branch (192:30): [True: 0, False: 3.27k]
  |  Branch (192:48): [True: 0, False: 3.27k]
  ------------------
  193|    379|      return std::make_unique<TripleDES>();
  194|    379|   }
  195|  3.27k|#endif
  196|       |
  197|       |#if defined(BOTAN_HAS_NOEKEON)
  198|       |   if(algo == "Noekeon") {
  199|       |      return std::make_unique<Noekeon>();
  200|       |   }
  201|       |#endif
  202|       |
  203|  3.27k|#if defined(BOTAN_HAS_CAST_128)
  204|  3.27k|   if(algo == "CAST-128" || algo == "CAST5") {
  ------------------
  |  Branch (204:7): [True: 567, False: 2.70k]
  |  Branch (204:29): [True: 0, False: 2.70k]
  ------------------
  205|    567|      return std::make_unique<CAST_128>();
  206|    567|   }
  207|  2.70k|#endif
  208|       |
  209|  2.70k|#if defined(BOTAN_HAS_IDEA)
  210|  2.70k|   if(algo == "IDEA") {
  ------------------
  |  Branch (210:7): [True: 1.00k, False: 1.70k]
  ------------------
  211|  1.00k|      return std::make_unique<IDEA>();
  212|  1.00k|   }
  213|  1.70k|#endif
  214|       |
  215|       |#if defined(BOTAN_HAS_KUZNYECHIK)
  216|       |   if(algo == "Kuznyechik") {
  217|       |      return std::make_unique<Kuznyechik>();
  218|       |   }
  219|       |#endif
  220|       |
  221|       |#if defined(BOTAN_HAS_SEED)
  222|       |   if(algo == "SEED") {
  223|       |      return std::make_unique<SEED>();
  224|       |   }
  225|       |#endif
  226|       |
  227|  1.70k|#if defined(BOTAN_HAS_SM4)
  228|  1.70k|   if(algo == "SM4") {
  ------------------
  |  Branch (228:7): [True: 1.70k, False: 0]
  ------------------
  229|  1.70k|      return std::make_unique<SM4>();
  230|  1.70k|   }
  231|      0|#endif
  232|       |
  233|      0|   const SCAN_Name req(algo);
  234|       |
  235|       |#if defined(BOTAN_HAS_GOST_28147_89)
  236|       |   if(req.algo_name() == "GOST-28147-89") {
  237|       |      return std::make_unique<GOST_28147_89>(req.arg(0, "R3411_94_TestParam"));
  238|       |   }
  239|       |#endif
  240|       |
  241|       |#if defined(BOTAN_HAS_CASCADE)
  242|       |   if(req.algo_name() == "Cascade" && req.arg_count() == 2) {
  243|       |      auto c1 = BlockCipher::create(req.arg(0));
  244|       |      auto c2 = BlockCipher::create(req.arg(1));
  245|       |
  246|       |      if(c1 && c2) {
  247|       |         return std::make_unique<Cascade_Cipher>(std::move(c1), std::move(c2));
  248|       |      }
  249|       |   }
  250|       |#endif
  251|       |
  252|       |#if defined(BOTAN_HAS_LION)
  253|       |   if(req.algo_name() == "Lion" && req.arg_count_between(2, 3)) {
  254|       |      auto hash = HashFunction::create(req.arg(0));
  255|       |      auto stream = StreamCipher::create(req.arg(1));
  256|       |
  257|       |      if(hash && stream) {
  258|       |         const size_t block_size = req.arg_as_integer(2, 1024);
  259|       |         return std::make_unique<Lion>(std::move(hash), std::move(stream), block_size);
  260|       |      }
  261|       |   }
  262|       |#endif
  263|       |
  264|      0|   BOTAN_UNUSED(req);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  265|      0|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  266|       |
  267|      0|   return nullptr;
  268|  1.70k|}

_ZNK5Botan8Blowfish9encrypt_nEPKhPhm:
  156|   708k|void Blowfish::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  157|   708k|   assert_key_material_set();
  158|       |
  159|   850k|   while(blocks >= 4) {
  ------------------
  |  Branch (159:10): [True: 141k, False: 708k]
  ------------------
  160|   141k|      uint32_t L0 = load_be<uint32_t>(in, 0);
  161|   141k|      uint32_t R0 = load_be<uint32_t>(in, 1);
  162|   141k|      uint32_t L1 = load_be<uint32_t>(in, 2);
  163|   141k|      uint32_t R1 = load_be<uint32_t>(in, 3);
  164|   141k|      uint32_t L2 = load_be<uint32_t>(in, 4);
  165|   141k|      uint32_t R2 = load_be<uint32_t>(in, 5);
  166|   141k|      uint32_t L3 = load_be<uint32_t>(in, 6);
  167|   141k|      uint32_t R3 = load_be<uint32_t>(in, 7);
  168|       |
  169|  1.27M|      for(size_t r = 0; r != 16; r += 2) {
  ------------------
  |  Branch (169:25): [True: 1.13M, False: 141k]
  ------------------
  170|  1.13M|         L0 ^= m_P[r];
  171|  1.13M|         L1 ^= m_P[r];
  172|  1.13M|         L2 ^= m_P[r];
  173|  1.13M|         L3 ^= m_P[r];
  174|  1.13M|         R0 ^= BFF(L0, m_S);
  175|  1.13M|         R1 ^= BFF(L1, m_S);
  176|  1.13M|         R2 ^= BFF(L2, m_S);
  177|  1.13M|         R3 ^= BFF(L3, m_S);
  178|       |
  179|  1.13M|         R0 ^= m_P[r + 1];
  180|  1.13M|         R1 ^= m_P[r + 1];
  181|  1.13M|         R2 ^= m_P[r + 1];
  182|  1.13M|         R3 ^= m_P[r + 1];
  183|  1.13M|         L0 ^= BFF(R0, m_S);
  184|  1.13M|         L1 ^= BFF(R1, m_S);
  185|  1.13M|         L2 ^= BFF(R2, m_S);
  186|  1.13M|         L3 ^= BFF(R3, m_S);
  187|  1.13M|      }
  188|       |
  189|   141k|      L0 ^= m_P[16];
  190|   141k|      R0 ^= m_P[17];
  191|   141k|      L1 ^= m_P[16];
  192|   141k|      R1 ^= m_P[17];
  193|   141k|      L2 ^= m_P[16];
  194|   141k|      R2 ^= m_P[17];
  195|   141k|      L3 ^= m_P[16];
  196|   141k|      R3 ^= m_P[17];
  197|       |
  198|   141k|      store_be(out, R0, L0, R1, L1, R2, L2, R3, L3);
  199|       |
  200|   141k|      in += 4 * BLOCK_SIZE;
  201|   141k|      out += 4 * BLOCK_SIZE;
  202|   141k|      blocks -= 4;
  203|   141k|   }
  204|       |
  205|  1.27M|   while(blocks > 0) {
  ------------------
  |  Branch (205:10): [True: 566k, False: 708k]
  ------------------
  206|   566k|      uint32_t L = load_be<uint32_t>(in, 0);
  207|   566k|      uint32_t R = load_be<uint32_t>(in, 1);
  208|       |
  209|  5.10M|      for(size_t r = 0; r != 16; r += 2) {
  ------------------
  |  Branch (209:25): [True: 4.53M, False: 566k]
  ------------------
  210|  4.53M|         L ^= m_P[r];
  211|  4.53M|         R ^= BFF(L, m_S);
  212|       |
  213|  4.53M|         R ^= m_P[r + 1];
  214|  4.53M|         L ^= BFF(R, m_S);
  215|  4.53M|      }
  216|       |
  217|   566k|      L ^= m_P[16];
  218|   566k|      R ^= m_P[17];
  219|       |
  220|   566k|      store_be(out, R, L);
  221|       |
  222|   566k|      in += BLOCK_SIZE;
  223|   566k|      out += BLOCK_SIZE;
  224|   566k|      blocks--;
  225|   566k|   }
  226|   708k|}
_ZNK5Botan8Blowfish19has_keying_materialEv:
  304|   970k|bool Blowfish::has_keying_material() const {
  305|   970k|   return !m_P.empty();
  306|   970k|}
_ZN5Botan8Blowfish12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  311|    167|void Blowfish::key_schedule(std::span<const uint8_t> key) {
  312|    167|   m_P.resize(18);
  313|    167|   copy_mem(m_P.data(), P_INIT, 18);
  314|       |
  315|    167|   m_S.resize(1024);
  316|    167|   copy_mem(m_S.data(), S_INIT, 1024);
  317|       |
  318|    167|   key_expansion(key.data(), key.size(), nullptr, 0);
  319|    167|}
_ZN5Botan8Blowfish13key_expansionEPKhmS2_m:
  321|    167|void Blowfish::key_expansion(const uint8_t key[], size_t length, const uint8_t salt[], size_t salt_length) {
  322|    167|   BOTAN_ASSERT_NOMSG(length > 0);
  ------------------
  |  |   77|    167|   do {                                                                     \
  |  |   78|    167|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    167|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 167]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    167|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 167]
  |  |  ------------------
  ------------------
  323|    167|   BOTAN_ASSERT_NOMSG(salt_length % 4 == 0);
  ------------------
  |  |   77|    167|   do {                                                                     \
  |  |   78|    167|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    167|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 167]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    167|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 167]
  |  |  ------------------
  ------------------
  324|       |
  325|  3.17k|   for(size_t i = 0, j = 0; i != 18; ++i, j += 4) {
  ------------------
  |  Branch (325:29): [True: 3.00k, False: 167]
  ------------------
  326|  3.00k|      m_P[i] ^= make_uint32(key[(j) % length], key[(j + 1) % length], key[(j + 2) % length], key[(j + 3) % length]);
  327|  3.00k|   }
  328|       |
  329|    167|   const size_t P_salt_offset = (salt_length > 0) ? 18 % (salt_length / 4) : 0;
  ------------------
  |  Branch (329:33): [True: 0, False: 167]
  ------------------
  330|       |
  331|    167|   uint32_t L = 0;
  332|    167|   uint32_t R = 0;
  333|    167|   generate_sbox(m_P, L, R, salt, salt_length, 0);
  334|    167|   generate_sbox(m_S, L, R, salt, salt_length, P_salt_offset);
  335|    167|}
_ZNK5Botan8Blowfish13generate_sboxERNSt3__16vectorIjNS_16secure_allocatorIjEEEERjS7_PKhmm:
  377|    334|                             size_t salt_off) const {
  378|  87.3k|   for(size_t i = 0; i != box.size(); i += 2) {
  ------------------
  |  Branch (378:22): [True: 87.0k, False: 334]
  ------------------
  379|  87.0k|      if(salt_length > 0) {
  ------------------
  |  Branch (379:10): [True: 0, False: 87.0k]
  ------------------
  380|      0|         L ^= load_be<uint32_t>(salt, (i + salt_off) % (salt_length / 4));
  381|      0|         R ^= load_be<uint32_t>(salt, (i + salt_off + 1) % (salt_length / 4));
  382|      0|      }
  383|       |
  384|   783k|      for(size_t r = 0; r != 16; r += 2) {
  ------------------
  |  Branch (384:25): [True: 696k, False: 87.0k]
  ------------------
  385|   696k|         L ^= m_P[r];
  386|   696k|         R ^= BFF(L, m_S);
  387|       |
  388|   696k|         R ^= m_P[r + 1];
  389|   696k|         L ^= BFF(R, m_S);
  390|   696k|      }
  391|       |
  392|       |      // Must read-then-write since sometimes sbox parameter is m_P
  393|  87.0k|      const uint32_t T = R;
  394|  87.0k|      R = L ^ m_P[16];
  395|  87.0k|      L = T ^ m_P[17];
  396|  87.0k|      box[i] = L;
  397|  87.0k|      box[i + 1] = R;
  398|  87.0k|   }
  399|    334|}
_ZN5Botan8Blowfish5clearEv:
  404|     49|void Blowfish::clear() {
  405|     49|   zap(m_P);
  406|     49|   zap(m_S);
  407|     49|}
blowfish.cpp:_ZN5Botan12_GLOBAL__N_13BFFEjRKNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  142|  19.5M|inline uint32_t BFF(uint32_t X, const secure_vector<uint32_t>& S) {
  143|  19.5M|   const uint32_t s0 = S[get_byte<0>(X)];
  144|  19.5M|   const uint32_t s1 = S[get_byte<1>(X) + 256];
  145|  19.5M|   const uint32_t s2 = S[get_byte<2>(X) + 512];
  146|  19.5M|   const uint32_t s3 = S[get_byte<3>(X) + 768];
  147|       |
  148|  19.5M|   return (((s0 + s1) ^ s2) + s3);
  149|  19.5M|}

_ZNK5Botan12Camellia_1289encrypt_nEPKhPhm:
  431|  2.27M|void Camellia_128::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  432|  2.27M|   assert_key_material_set();
  433|       |
  434|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  435|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  436|       |      return avx512_gfni_encrypt(in, out, blocks, m_SK);
  437|       |   }
  438|       |#endif
  439|       |
  440|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  441|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  442|       |      return avx2_gfni_encrypt(in, out, blocks, m_SK);
  443|       |   }
  444|       |#endif
  445|       |
  446|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  447|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  448|       |      return hwaes_encrypt(in, out, blocks, m_SK);
  449|       |   }
  450|       |#endif
  451|       |
  452|  2.27M|   Camellia_F::encrypt(in, out, blocks, m_SK, 9);
  453|  2.27M|}
_ZNK5Botan12Camellia_1929encrypt_nEPKhPhm:
  455|  2.70M|void Camellia_192::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  456|  2.70M|   assert_key_material_set();
  457|       |
  458|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  459|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  460|       |      return avx512_gfni_encrypt(in, out, blocks, m_SK);
  461|       |   }
  462|       |#endif
  463|       |
  464|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  465|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  466|       |      return avx2_gfni_encrypt(in, out, blocks, m_SK);
  467|       |   }
  468|       |#endif
  469|       |
  470|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  471|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  472|       |      return hwaes_encrypt(in, out, blocks, m_SK);
  473|       |   }
  474|       |#endif
  475|       |
  476|  2.70M|   Camellia_F::encrypt(in, out, blocks, m_SK, 12);
  477|  2.70M|}
_ZNK5Botan12Camellia_2569encrypt_nEPKhPhm:
  479|   301k|void Camellia_256::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  480|   301k|   assert_key_material_set();
  481|       |
  482|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  483|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  484|       |      return avx512_gfni_encrypt(in, out, blocks, m_SK);
  485|       |   }
  486|       |#endif
  487|       |
  488|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  489|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  490|       |      return avx2_gfni_encrypt(in, out, blocks, m_SK);
  491|       |   }
  492|       |#endif
  493|       |
  494|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  495|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  496|       |      return hwaes_encrypt(in, out, blocks, m_SK);
  497|       |   }
  498|       |#endif
  499|       |
  500|   301k|   Camellia_F::encrypt(in, out, blocks, m_SK, 12);
  501|   301k|}
_ZNK5Botan12Camellia_1289decrypt_nEPKhPhm:
  503|  2.43k|void Camellia_128::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  504|  2.43k|   assert_key_material_set();
  505|       |
  506|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  507|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  508|       |      return avx512_gfni_decrypt(in, out, blocks, m_SK);
  509|       |   }
  510|       |#endif
  511|       |
  512|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  513|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  514|       |      return avx2_gfni_decrypt(in, out, blocks, m_SK);
  515|       |   }
  516|       |#endif
  517|       |
  518|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  519|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  520|       |      return hwaes_decrypt(in, out, blocks, m_SK);
  521|       |   }
  522|       |#endif
  523|       |
  524|  2.43k|   Camellia_F::decrypt(in, out, blocks, m_SK, 9);
  525|  2.43k|}
_ZNK5Botan12Camellia_1929decrypt_nEPKhPhm:
  527|   406k|void Camellia_192::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  528|   406k|   assert_key_material_set();
  529|       |
  530|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  531|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  532|       |      return avx512_gfni_decrypt(in, out, blocks, m_SK);
  533|       |   }
  534|       |#endif
  535|       |
  536|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  537|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  538|       |      return avx2_gfni_decrypt(in, out, blocks, m_SK);
  539|       |   }
  540|       |#endif
  541|       |
  542|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  543|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  544|       |      return hwaes_decrypt(in, out, blocks, m_SK);
  545|       |   }
  546|       |#endif
  547|       |
  548|   406k|   Camellia_F::decrypt(in, out, blocks, m_SK, 12);
  549|   406k|}
_ZNK5Botan12Camellia_2569decrypt_nEPKhPhm:
  551|  17.7k|void Camellia_256::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  552|  17.7k|   assert_key_material_set();
  553|       |
  554|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  555|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  556|       |      return avx512_gfni_decrypt(in, out, blocks, m_SK);
  557|       |   }
  558|       |#endif
  559|       |
  560|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  561|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  562|       |      return avx2_gfni_decrypt(in, out, blocks, m_SK);
  563|       |   }
  564|       |#endif
  565|       |
  566|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  567|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  568|       |      return hwaes_decrypt(in, out, blocks, m_SK);
  569|       |   }
  570|       |#endif
  571|       |
  572|  17.7k|   Camellia_F::decrypt(in, out, blocks, m_SK, 12);
  573|  17.7k|}
_ZNK5Botan12Camellia_12819has_keying_materialEv:
  575|  4.68M|bool Camellia_128::has_keying_material() const {
  576|  4.68M|   return !m_SK.empty();
  577|  4.68M|}
_ZNK5Botan12Camellia_19219has_keying_materialEv:
  579|  8.10M|bool Camellia_192::has_keying_material() const {
  580|  8.10M|   return !m_SK.empty();
  581|  8.10M|}
_ZNK5Botan12Camellia_25619has_keying_materialEv:
  583|   454k|bool Camellia_256::has_keying_material() const {
  584|   454k|   return !m_SK.empty();
  585|   454k|}
_ZN5Botan12Camellia_12812key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  587|  4.94k|void Camellia_128::key_schedule(std::span<const uint8_t> key) {
  588|  4.94k|   Camellia_F::key_schedule(m_SK, key);
  589|  4.94k|}
_ZN5Botan12Camellia_19212key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  591|  4.03k|void Camellia_192::key_schedule(std::span<const uint8_t> key) {
  592|  4.03k|   Camellia_F::key_schedule(m_SK, key);
  593|  4.03k|}
_ZN5Botan12Camellia_25612key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  595|  1.12k|void Camellia_256::key_schedule(std::span<const uint8_t> key) {
  596|  1.12k|   Camellia_F::key_schedule(m_SK, key);
  597|  1.12k|}
_ZN5Botan12Camellia_1285clearEv:
  599|    494|void Camellia_128::clear() {
  600|    494|   zap(m_SK);
  601|    494|}
_ZN5Botan12Camellia_1925clearEv:
  603|    699|void Camellia_192::clear() {
  604|    699|   zap(m_SK);
  605|    699|}
_ZN5Botan12Camellia_2565clearEv:
  607|    177|void Camellia_256::clear() {
  608|    177|   zap(m_SK);
  609|    177|}
_ZNK5Botan12Camellia_12811parallelismEv:
  623|  4.90k|size_t Camellia_128::parallelism() const {
  624|  4.90k|   return Camellia_F::parallelism();
  625|  4.90k|}
_ZNK5Botan12Camellia_19211parallelismEv:
  627|  8.54k|size_t Camellia_192::parallelism() const {
  628|  8.54k|   return Camellia_F::parallelism();
  629|  8.54k|}
_ZNK5Botan12Camellia_25611parallelismEv:
  631|  1.86k|size_t Camellia_256::parallelism() const {
  632|  1.86k|   return Camellia_F::parallelism();
  633|  1.86k|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F7encryptEPKhPhmRKNSt3__16vectorImNS_16secure_allocatorImEEEEm:
  173|  5.27M|void encrypt(const uint8_t in[], uint8_t out[], size_t blocks, const secure_vector<uint64_t>& SK, size_t rounds) {
  174|  5.27M|   prefetch_arrays(SBOX1, SBOX2, SBOX3, SBOX4);
  175|       |
  176|  14.6M|   for(size_t i = 0; i < blocks; ++i) {
  ------------------
  |  Branch (176:22): [True: 9.32M, False: 5.27M]
  ------------------
  177|  9.32M|      uint64_t D1 = load_be<uint64_t>(in, 2 * i + 0);
  178|  9.32M|      uint64_t D2 = load_be<uint64_t>(in, 2 * i + 1);
  179|       |
  180|  9.32M|      const uint64_t* K = SK.data();
  181|       |
  182|  9.32M|      D1 ^= *K++;
  183|  9.32M|      D2 ^= *K++;
  184|       |
  185|  9.32M|      D2 ^= F(D1, *K++);
  186|  9.32M|      D1 ^= F(D2, *K++);
  187|       |
  188|  90.2M|      for(size_t r = 1; r != rounds - 1; ++r) {
  ------------------
  |  Branch (188:25): [True: 80.8M, False: 9.32M]
  ------------------
  189|  80.8M|         if(r % 3 == 0) {
  ------------------
  |  Branch (189:13): [True: 23.8M, False: 57.0M]
  ------------------
  190|  23.8M|            D1 = FL(D1, *K++);
  191|  23.8M|            D2 = FLINV(D2, *K++);
  192|  23.8M|         }
  193|       |
  194|  80.8M|         D2 ^= F(D1, *K++);
  195|  80.8M|         D1 ^= F(D2, *K++);
  196|  80.8M|      }
  197|       |
  198|  9.32M|      D2 ^= F(D1, *K++);
  199|  9.32M|      D1 ^= F(D2, *K++);
  200|       |
  201|  9.32M|      D2 ^= *K++;
  202|  9.32M|      D1 ^= *K++;
  203|       |
  204|  9.32M|      store_be(out + 16 * i, D2, D1);
  205|  9.32M|   }
  206|  5.27M|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F1FEmm:
  118|   239M|uint64_t F(uint64_t v, uint64_t K) {
  119|   239M|   const uint64_t x = v ^ K;
  120|       |
  121|   239M|   return P(SBOX1[get_byte<0>(x)],
  122|   239M|            SBOX2[get_byte<1>(x)],
  123|   239M|            SBOX3[get_byte<2>(x)],
  124|   239M|            SBOX4[get_byte<3>(x)],
  125|   239M|            SBOX2[get_byte<4>(x)],
  126|   239M|            SBOX3[get_byte<5>(x)],
  127|   239M|            SBOX4[get_byte<6>(x)],
  128|   239M|            SBOX1[get_byte<7>(x)]);
  129|   239M|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F1PEhhhhhhhh:
   96|   240M|inline uint64_t P(uint8_t z1, uint8_t z2, uint8_t z3, uint8_t z4, uint8_t z5, uint8_t z6, uint8_t z7, uint8_t z8) {
   97|   240M|   constexpr uint64_t M1 = 0x0101010001000001;
   98|   240M|   constexpr uint64_t M2 = 0x0001010101010000;
   99|   240M|   constexpr uint64_t M3 = 0x0100010100010100;
  100|   240M|   constexpr uint64_t M4 = 0x0101000100000101;
  101|   240M|   constexpr uint64_t M5 = 0x0001010100010101;
  102|   240M|   constexpr uint64_t M6 = 0x0100010101000101;
  103|   240M|   constexpr uint64_t M7 = 0x0101000101010001;
  104|   240M|   constexpr uint64_t M8 = 0x0101010001010100;
  105|       |
  106|   240M|   const uint64_t Z1 = M1 * z1;
  107|   240M|   const uint64_t Z2 = M2 * z2;
  108|   240M|   const uint64_t Z3 = M3 * z3;
  109|   240M|   const uint64_t Z4 = M4 * z4;
  110|   240M|   const uint64_t Z5 = M5 * z5;
  111|   240M|   const uint64_t Z6 = M6 * z6;
  112|   240M|   const uint64_t Z7 = M7 * z7;
  113|   240M|   const uint64_t Z8 = M8 * z8;
  114|       |
  115|   240M|   return Z1 ^ Z2 ^ Z3 ^ Z4 ^ Z5 ^ Z6 ^ Z7 ^ Z8;
  116|   240M|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F2FLEmm:
  144|  28.9M|inline uint64_t FL(uint64_t v, uint64_t K) {
  145|  28.9M|   uint32_t x1 = static_cast<uint32_t>(v >> 32);
  146|  28.9M|   uint32_t x2 = static_cast<uint32_t>(v & 0xFFFFFFFF);
  147|       |
  148|  28.9M|   const uint32_t k1 = static_cast<uint32_t>(K >> 32);
  149|  28.9M|   const uint32_t k2 = static_cast<uint32_t>(K & 0xFFFFFFFF);
  150|       |
  151|  28.9M|   x2 ^= rotl<1>(x1 & k1);
  152|  28.9M|   x1 ^= (x2 | k2);
  153|       |
  154|  28.9M|   return ((static_cast<uint64_t>(x1) << 32) | x2);
  155|  28.9M|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F5FLINVEmm:
  157|  28.9M|inline uint64_t FLINV(uint64_t v, uint64_t K) {
  158|  28.9M|   uint32_t x1 = static_cast<uint32_t>(v >> 32);
  159|  28.9M|   uint32_t x2 = static_cast<uint32_t>(v & 0xFFFFFFFF);
  160|       |
  161|  28.9M|   const uint32_t k1 = static_cast<uint32_t>(K >> 32);
  162|  28.9M|   const uint32_t k2 = static_cast<uint32_t>(K & 0xFFFFFFFF);
  163|       |
  164|  28.9M|   x1 ^= (x2 | k2);
  165|  28.9M|   x2 ^= rotl<1>(x1 & k1);
  166|       |
  167|  28.9M|   return ((static_cast<uint64_t>(x1) << 32) | x2);
  168|  28.9M|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F7decryptEPKhPhmRKNSt3__16vectorImNS_16secure_allocatorImEEEEm:
  211|   427k|void decrypt(const uint8_t in[], uint8_t out[], size_t blocks, const secure_vector<uint64_t>& SK, size_t rounds) {
  212|   427k|   prefetch_arrays(SBOX1, SBOX2, SBOX3, SBOX4);
  213|       |
  214|  2.13M|   for(size_t i = 0; i < blocks; ++i) {
  ------------------
  |  Branch (214:22): [True: 1.70M, False: 427k]
  ------------------
  215|  1.70M|      uint64_t D1 = load_be<uint64_t>(in, 2 * i + 0);
  216|  1.70M|      uint64_t D2 = load_be<uint64_t>(in, 2 * i + 1);
  217|       |
  218|  1.70M|      const uint64_t* K = &SK[SK.size() - 1];
  219|       |
  220|  1.70M|      D2 ^= *K--;
  221|  1.70M|      D1 ^= *K--;
  222|       |
  223|  1.70M|      D2 ^= F(D1, *K--);
  224|  1.70M|      D1 ^= F(D2, *K--);
  225|       |
  226|  18.7M|      for(size_t r = 1; r != rounds - 1; ++r) {
  ------------------
  |  Branch (226:25): [True: 17.0M, False: 1.70M]
  ------------------
  227|  17.0M|         if(r % 3 == 0) {
  ------------------
  |  Branch (227:13): [True: 5.11M, False: 11.9M]
  ------------------
  228|  5.11M|            D1 = FL(D1, *K--);
  229|  5.11M|            D2 = FLINV(D2, *K--);
  230|  5.11M|         }
  231|       |
  232|  17.0M|         D2 ^= F(D1, *K--);
  233|  17.0M|         D1 ^= F(D2, *K--);
  234|  17.0M|      }
  235|       |
  236|  1.70M|      D2 ^= F(D1, *K--);
  237|  1.70M|      D1 ^= F(D2, *K--);
  238|       |
  239|  1.70M|      D1 ^= *K--;
  240|  1.70M|      D2 ^= *K;
  241|       |
  242|  1.70M|      store_be(out + 16 * i, D2, D1);
  243|  1.70M|   }
  244|   427k|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F12key_scheduleERNSt3__16vectorImNS_16secure_allocatorImEEEENS2_4spanIKhLm18446744073709551615EEE:
  263|  10.1k|void key_schedule(secure_vector<uint64_t>& SK, std::span<const uint8_t> key) {
  264|  10.1k|   prefetch_arrays(SBOX1);
  265|       |
  266|  10.1k|   constexpr uint64_t Sigma1 = 0xA09E667F3BCC908B;
  267|  10.1k|   constexpr uint64_t Sigma2 = 0xB67AE8584CAA73B2;
  268|  10.1k|   constexpr uint64_t Sigma3 = 0xC6EF372FE94F82BE;
  269|  10.1k|   constexpr uint64_t Sigma4 = 0x54FF53A5F1D36F1C;
  270|  10.1k|   constexpr uint64_t Sigma5 = 0x10E527FADE682D1D;
  271|  10.1k|   constexpr uint64_t Sigma6 = 0xB05688C2B3E6C1FD;
  272|       |
  273|  10.1k|   const uint64_t KL_H = load_be<uint64_t>(key.data(), 0);
  274|  10.1k|   const uint64_t KL_L = load_be<uint64_t>(key.data(), 1);
  275|       |
  276|  10.1k|   const uint64_t KR_H = (key.size() >= 24) ? load_be<uint64_t>(key.data(), 2) : 0;
  ------------------
  |  Branch (276:26): [True: 5.16k, False: 4.94k]
  ------------------
  277|       |
  278|  10.1k|   const uint64_t KR_L = [&]() -> uint64_t {
  279|  10.1k|      if(key.size() == 32) {
  280|  10.1k|         return load_be<uint64_t>(key.data(), 3);
  281|  10.1k|      } else if(key.size() == 24) {
  282|  10.1k|         return ~KR_H;
  283|  10.1k|      } else {
  284|  10.1k|         return 0;
  285|  10.1k|      }
  286|  10.1k|   }();
  287|       |
  288|  10.1k|   uint64_t D1 = KL_H ^ KR_H;
  289|  10.1k|   uint64_t D2 = KL_L ^ KR_L;
  290|  10.1k|   D2 ^= F_1tab(D1, Sigma1);
  291|  10.1k|   D1 ^= F_1tab(D2, Sigma2);
  292|  10.1k|   D1 ^= KL_H;
  293|  10.1k|   D2 ^= KL_L;
  294|  10.1k|   D2 ^= F_1tab(D1, Sigma3);
  295|  10.1k|   D1 ^= F_1tab(D2, Sigma4);
  296|       |
  297|  10.1k|   const uint64_t KA_H = D1;
  298|  10.1k|   const uint64_t KA_L = D2;
  299|       |
  300|  10.1k|   D1 = KA_H ^ KR_H;
  301|  10.1k|   D2 = KA_L ^ KR_L;
  302|  10.1k|   D2 ^= F_1tab(D1, Sigma5);
  303|  10.1k|   D1 ^= F_1tab(D2, Sigma6);
  304|       |
  305|  10.1k|   const uint64_t KB_H = D1;
  306|  10.1k|   const uint64_t KB_L = D2;
  307|       |
  308|  10.1k|   if(key.size() == 16) {
  ------------------
  |  Branch (308:7): [True: 4.94k, False: 5.16k]
  ------------------
  309|  4.94k|      SK.resize(26);
  310|       |
  311|  4.94k|      SK[0] = KL_H;
  312|  4.94k|      SK[1] = KL_L;
  313|  4.94k|      SK[2] = KA_H;
  314|  4.94k|      SK[3] = KA_L;
  315|  4.94k|      SK[4] = left_rot_hi(KL_H, KL_L, 15);
  316|  4.94k|      SK[5] = left_rot_lo(KL_H, KL_L, 15);
  317|  4.94k|      SK[6] = left_rot_hi(KA_H, KA_L, 15);
  318|  4.94k|      SK[7] = left_rot_lo(KA_H, KA_L, 15);
  319|  4.94k|      SK[8] = left_rot_hi(KA_H, KA_L, 30);
  320|  4.94k|      SK[9] = left_rot_lo(KA_H, KA_L, 30);
  321|  4.94k|      SK[10] = left_rot_hi(KL_H, KL_L, 45);
  322|  4.94k|      SK[11] = left_rot_lo(KL_H, KL_L, 45);
  323|  4.94k|      SK[12] = left_rot_hi(KA_H, KA_L, 45);
  324|  4.94k|      SK[13] = left_rot_lo(KL_H, KL_L, 60);
  325|  4.94k|      SK[14] = left_rot_hi(KA_H, KA_L, 60);
  326|  4.94k|      SK[15] = left_rot_lo(KA_H, KA_L, 60);
  327|  4.94k|      SK[16] = left_rot_lo(KL_H, KL_L, 77);
  328|  4.94k|      SK[17] = left_rot_hi(KL_H, KL_L, 77);
  329|  4.94k|      SK[18] = left_rot_lo(KL_H, KL_L, 94);
  330|  4.94k|      SK[19] = left_rot_hi(KL_H, KL_L, 94);
  331|  4.94k|      SK[20] = left_rot_lo(KA_H, KA_L, 94);
  332|  4.94k|      SK[21] = left_rot_hi(KA_H, KA_L, 94);
  333|  4.94k|      SK[22] = left_rot_lo(KL_H, KL_L, 111);
  334|  4.94k|      SK[23] = left_rot_hi(KL_H, KL_L, 111);
  335|  4.94k|      SK[24] = left_rot_lo(KA_H, KA_L, 111);
  336|  4.94k|      SK[25] = left_rot_hi(KA_H, KA_L, 111);
  337|  5.16k|   } else {
  338|  5.16k|      SK.resize(34);
  339|       |
  340|  5.16k|      SK[0] = KL_H;
  341|  5.16k|      SK[1] = KL_L;
  342|  5.16k|      SK[2] = KB_H;
  343|  5.16k|      SK[3] = KB_L;
  344|       |
  345|  5.16k|      SK[4] = left_rot_hi(KR_H, KR_L, 15);
  346|  5.16k|      SK[5] = left_rot_lo(KR_H, KR_L, 15);
  347|  5.16k|      SK[6] = left_rot_hi(KA_H, KA_L, 15);
  348|  5.16k|      SK[7] = left_rot_lo(KA_H, KA_L, 15);
  349|       |
  350|  5.16k|      SK[8] = left_rot_hi(KR_H, KR_L, 30);
  351|  5.16k|      SK[9] = left_rot_lo(KR_H, KR_L, 30);
  352|  5.16k|      SK[10] = left_rot_hi(KB_H, KB_L, 30);
  353|  5.16k|      SK[11] = left_rot_lo(KB_H, KB_L, 30);
  354|       |
  355|  5.16k|      SK[12] = left_rot_hi(KL_H, KL_L, 45);
  356|  5.16k|      SK[13] = left_rot_lo(KL_H, KL_L, 45);
  357|  5.16k|      SK[14] = left_rot_hi(KA_H, KA_L, 45);
  358|  5.16k|      SK[15] = left_rot_lo(KA_H, KA_L, 45);
  359|       |
  360|  5.16k|      SK[16] = left_rot_hi(KL_H, KL_L, 60);
  361|  5.16k|      SK[17] = left_rot_lo(KL_H, KL_L, 60);
  362|  5.16k|      SK[18] = left_rot_hi(KR_H, KR_L, 60);
  363|  5.16k|      SK[19] = left_rot_lo(KR_H, KR_L, 60);
  364|  5.16k|      SK[20] = left_rot_hi(KB_H, KB_L, 60);
  365|  5.16k|      SK[21] = left_rot_lo(KB_H, KB_L, 60);
  366|       |
  367|  5.16k|      SK[22] = left_rot_lo(KL_H, KL_L, 77);
  368|  5.16k|      SK[23] = left_rot_hi(KL_H, KL_L, 77);
  369|  5.16k|      SK[24] = left_rot_lo(KA_H, KA_L, 77);
  370|  5.16k|      SK[25] = left_rot_hi(KA_H, KA_L, 77);
  371|       |
  372|  5.16k|      SK[26] = left_rot_lo(KR_H, KR_L, 94);
  373|  5.16k|      SK[27] = left_rot_hi(KR_H, KR_L, 94);
  374|  5.16k|      SK[28] = left_rot_lo(KA_H, KA_L, 94);
  375|  5.16k|      SK[29] = left_rot_hi(KA_H, KA_L, 94);
  376|  5.16k|      SK[30] = left_rot_lo(KL_H, KL_L, 111);
  377|  5.16k|      SK[31] = left_rot_hi(KL_H, KL_L, 111);
  378|  5.16k|      SK[32] = left_rot_lo(KB_H, KB_L, 111);
  379|  5.16k|      SK[33] = left_rot_hi(KB_H, KB_L, 111);
  380|  5.16k|   }
  381|  10.1k|}
camellia.cpp:_ZZN5Botan12_GLOBAL__N_110Camellia_F12key_scheduleERNSt3__16vectorImNS_16secure_allocatorImEEEENS2_4spanIKhLm18446744073709551615EEEENK3$_0clEv:
  278|  10.1k|   const uint64_t KR_L = [&]() -> uint64_t {
  279|  10.1k|      if(key.size() == 32) {
  ------------------
  |  Branch (279:10): [True: 1.12k, False: 8.98k]
  ------------------
  280|  1.12k|         return load_be<uint64_t>(key.data(), 3);
  281|  8.98k|      } else if(key.size() == 24) {
  ------------------
  |  Branch (281:17): [True: 4.03k, False: 4.94k]
  ------------------
  282|  4.03k|         return ~KR_H;
  283|  4.94k|      } else {
  284|  4.94k|         return 0;
  285|  4.94k|      }
  286|  10.1k|   }();
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F6F_1tabEmm:
  131|  60.6k|uint64_t F_1tab(uint64_t v, uint64_t K) {
  132|  60.6k|   const uint64_t x = v ^ K;
  133|       |
  134|  60.6k|   return P(SBOX1[get_byte<0>(x)],
  135|  60.6k|            rotl<1>(SBOX1[get_byte<1>(x)]),
  136|  60.6k|            rotl<7>(SBOX1[get_byte<2>(x)]),
  137|  60.6k|            SBOX1[rotl<1>(get_byte<3>(x))],
  138|  60.6k|            rotl<1>(SBOX1[get_byte<4>(x)]),
  139|  60.6k|            rotl<7>(SBOX1[get_byte<5>(x)]),
  140|  60.6k|            SBOX1[rotl<1>(get_byte<6>(x))],
  141|  60.6k|            SBOX1[get_byte<7>(x)]);
  142|  60.6k|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F11left_rot_hiEmmm:
  246|   131k|inline uint64_t left_rot_hi(uint64_t h, uint64_t l, size_t shift) {
  247|   131k|   if(shift >= 64) {
  ------------------
  |  Branch (247:7): [True: 55.6k, False: 76.1k]
  ------------------
  248|  55.6k|      shift -= 64;
  249|  55.6k|   }
  250|   131k|   return (h << shift) | (l >> (64 - shift));
  251|   131k|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F11left_rot_loEmmm:
  253|   131k|inline uint64_t left_rot_lo(uint64_t h, uint64_t l, size_t shift) {
  254|   131k|   if(shift >= 64) {
  ------------------
  |  Branch (254:7): [True: 55.6k, False: 76.1k]
  ------------------
  255|  55.6k|      shift -= 64;
  256|  55.6k|   }
  257|   131k|   return (h >> (64 - shift)) | (l << shift);
  258|   131k|}
camellia.cpp:_ZN5Botan12_GLOBAL__N_110Camellia_F11parallelismEv:
  405|  15.3k|size_t parallelism() {
  406|       |#if defined(BOTAN_HAS_CAMELLIA_AVX512_GFNI)
  407|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  408|       |      return 16;
  409|       |   }
  410|       |#endif
  411|       |
  412|       |#if defined(BOTAN_HAS_CAMELLIA_AVX2_GFNI)
  413|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  414|       |      return 4;
  415|       |   }
  416|       |#endif
  417|       |
  418|       |#if defined(BOTAN_HAS_CAMELLIA_HWAES)
  419|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  420|       |      return 2;
  421|       |   }
  422|       |#endif
  423|       |
  424|  15.3k|   return 1;
  425|  15.3k|}

_ZNK5Botan8CAST_1289encrypt_nEPKhPhm:
  187|   354k|void CAST_128::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  188|   354k|   assert_key_material_set();
  189|       |
  190|   495k|   while(blocks >= 2) {
  ------------------
  |  Branch (190:10): [True: 141k, False: 354k]
  ------------------
  191|   141k|      uint32_t L0 = 0;
  192|   141k|      uint32_t R0 = 0;
  193|   141k|      uint32_t L1 = 0;
  194|   141k|      uint32_t R1 = 0;
  195|   141k|      load_be(in, L0, R0, L1, R1);
  196|       |
  197|   141k|      L0 ^= F1(R0, m_MK[0], m_RK[0]);
  198|   141k|      L1 ^= F1(R1, m_MK[0], m_RK[0]);
  199|   141k|      R0 ^= F2(L0, m_MK[1], m_RK[1]);
  200|   141k|      R1 ^= F2(L1, m_MK[1], m_RK[1]);
  201|   141k|      L0 ^= F3(R0, m_MK[2], m_RK[2]);
  202|   141k|      L1 ^= F3(R1, m_MK[2], m_RK[2]);
  203|   141k|      R0 ^= F1(L0, m_MK[3], m_RK[3]);
  204|   141k|      R1 ^= F1(L1, m_MK[3], m_RK[3]);
  205|   141k|      L0 ^= F2(R0, m_MK[4], m_RK[4]);
  206|   141k|      L1 ^= F2(R1, m_MK[4], m_RK[4]);
  207|   141k|      R0 ^= F3(L0, m_MK[5], m_RK[5]);
  208|   141k|      R1 ^= F3(L1, m_MK[5], m_RK[5]);
  209|   141k|      L0 ^= F1(R0, m_MK[6], m_RK[6]);
  210|   141k|      L1 ^= F1(R1, m_MK[6], m_RK[6]);
  211|   141k|      R0 ^= F2(L0, m_MK[7], m_RK[7]);
  212|   141k|      R1 ^= F2(L1, m_MK[7], m_RK[7]);
  213|   141k|      L0 ^= F3(R0, m_MK[8], m_RK[8]);
  214|   141k|      L1 ^= F3(R1, m_MK[8], m_RK[8]);
  215|   141k|      R0 ^= F1(L0, m_MK[9], m_RK[9]);
  216|   141k|      R1 ^= F1(L1, m_MK[9], m_RK[9]);
  217|   141k|      L0 ^= F2(R0, m_MK[10], m_RK[10]);
  218|   141k|      L1 ^= F2(R1, m_MK[10], m_RK[10]);
  219|   141k|      R0 ^= F3(L0, m_MK[11], m_RK[11]);
  220|   141k|      R1 ^= F3(L1, m_MK[11], m_RK[11]);
  221|   141k|      L0 ^= F1(R0, m_MK[12], m_RK[12]);
  222|   141k|      L1 ^= F1(R1, m_MK[12], m_RK[12]);
  223|   141k|      R0 ^= F2(L0, m_MK[13], m_RK[13]);
  224|   141k|      R1 ^= F2(L1, m_MK[13], m_RK[13]);
  225|   141k|      L0 ^= F3(R0, m_MK[14], m_RK[14]);
  226|   141k|      L1 ^= F3(R1, m_MK[14], m_RK[14]);
  227|   141k|      R0 ^= F1(L0, m_MK[15], m_RK[15]);
  228|   141k|      R1 ^= F1(L1, m_MK[15], m_RK[15]);
  229|       |
  230|   141k|      store_be(out, R0, L0, R1, L1);
  231|       |
  232|   141k|      blocks -= 2;
  233|   141k|      out += 2 * BLOCK_SIZE;
  234|   141k|      in += 2 * BLOCK_SIZE;
  235|   141k|   }
  236|       |
  237|   354k|   if(blocks > 0) {
  ------------------
  |  Branch (237:7): [True: 283k, False: 70.5k]
  ------------------
  238|   283k|      uint32_t L = 0;
  239|   283k|      uint32_t R = 0;
  240|   283k|      load_be(in, L, R);
  241|       |
  242|   283k|      L ^= F1(R, m_MK[0], m_RK[0]);
  243|   283k|      R ^= F2(L, m_MK[1], m_RK[1]);
  244|   283k|      L ^= F3(R, m_MK[2], m_RK[2]);
  245|   283k|      R ^= F1(L, m_MK[3], m_RK[3]);
  246|   283k|      L ^= F2(R, m_MK[4], m_RK[4]);
  247|   283k|      R ^= F3(L, m_MK[5], m_RK[5]);
  248|   283k|      L ^= F1(R, m_MK[6], m_RK[6]);
  249|   283k|      R ^= F2(L, m_MK[7], m_RK[7]);
  250|   283k|      L ^= F3(R, m_MK[8], m_RK[8]);
  251|   283k|      R ^= F1(L, m_MK[9], m_RK[9]);
  252|   283k|      L ^= F2(R, m_MK[10], m_RK[10]);
  253|   283k|      R ^= F3(L, m_MK[11], m_RK[11]);
  254|   283k|      L ^= F1(R, m_MK[12], m_RK[12]);
  255|   283k|      R ^= F2(L, m_MK[13], m_RK[13]);
  256|   283k|      L ^= F3(R, m_MK[14], m_RK[14]);
  257|   283k|      R ^= F1(L, m_MK[15], m_RK[15]);
  258|       |
  259|   283k|      store_be(out, R, L);
  260|   283k|   }
  261|   354k|}
_ZNK5Botan8CAST_12819has_keying_materialEv:
  342|   469k|bool CAST_128::has_keying_material() const {
  343|   469k|   return !m_RK.empty();
  344|   469k|}
_ZN5Botan8CAST_12812key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  349|    657|void CAST_128::key_schedule(std::span<const uint8_t> key) {
  350|    657|   m_MK.resize(48);
  351|    657|   m_RK.resize(48);
  352|       |
  353|    657|   secure_vector<uint8_t> key16(16);
  354|    657|   copy_mem(key16.data(), key.data(), key.size());
  355|       |
  356|    657|   secure_vector<uint32_t> X(4);
  357|  3.28k|   for(size_t i = 0; i != 4; ++i) {
  ------------------
  |  Branch (357:22): [True: 2.62k, False: 657]
  ------------------
  358|  2.62k|      X[i] = load_be<uint32_t>(key16.data(), i);
  359|  2.62k|   }
  360|       |
  361|    657|   cast_ks(m_MK, X);
  362|       |
  363|    657|   secure_vector<uint32_t> RK32(48);
  364|    657|   cast_ks(RK32, X);
  365|       |
  366|  11.1k|   for(size_t i = 0; i != 16; ++i) {
  ------------------
  |  Branch (366:22): [True: 10.5k, False: 657]
  ------------------
  367|  10.5k|      m_RK[i] = RK32[i] % 32;
  368|  10.5k|   }
  369|    657|}
_ZN5Botan8CAST_1285clearEv:
  371|    152|void CAST_128::clear() {
  372|    152|   zap(m_MK);
  373|    152|   zap(m_RK);
  374|    152|}
_ZN5Botan8CAST_1287cast_ksERNSt3__16vectorIjNS_16secure_allocatorIjEEEES6_:
  379|  1.31k|void CAST_128::cast_ks(secure_vector<uint32_t>& K, secure_vector<uint32_t>& X) {
  380|  1.31k|   alignas(256) static const uint32_t S5[256] = {
  381|  1.31k|      0x7EC90C04, 0x2C6E74B9, 0x9B0E66DF, 0xA6337911, 0xB86A7FFF, 0x1DD358F5, 0x44DD9D44, 0x1731167F, 0x08FBF1FA,
  382|  1.31k|      0xE7F511CC, 0xD2051B00, 0x735ABA00, 0x2AB722D8, 0x386381CB, 0xACF6243A, 0x69BEFD7A, 0xE6A2E77F, 0xF0C720CD,
  383|  1.31k|      0xC4494816, 0xCCF5C180, 0x38851640, 0x15B0A848, 0xE68B18CB, 0x4CAADEFF, 0x5F480A01, 0x0412B2AA, 0x259814FC,
  384|  1.31k|      0x41D0EFE2, 0x4E40B48D, 0x248EB6FB, 0x8DBA1CFE, 0x41A99B02, 0x1A550A04, 0xBA8F65CB, 0x7251F4E7, 0x95A51725,
  385|  1.31k|      0xC106ECD7, 0x97A5980A, 0xC539B9AA, 0x4D79FE6A, 0xF2F3F763, 0x68AF8040, 0xED0C9E56, 0x11B4958B, 0xE1EB5A88,
  386|  1.31k|      0x8709E6B0, 0xD7E07156, 0x4E29FEA7, 0x6366E52D, 0x02D1C000, 0xC4AC8E05, 0x9377F571, 0x0C05372A, 0x578535F2,
  387|  1.31k|      0x2261BE02, 0xD642A0C9, 0xDF13A280, 0x74B55BD2, 0x682199C0, 0xD421E5EC, 0x53FB3CE8, 0xC8ADEDB3, 0x28A87FC9,
  388|  1.31k|      0x3D959981, 0x5C1FF900, 0xFE38D399, 0x0C4EFF0B, 0x062407EA, 0xAA2F4FB1, 0x4FB96976, 0x90C79505, 0xB0A8A774,
  389|  1.31k|      0xEF55A1FF, 0xE59CA2C2, 0xA6B62D27, 0xE66A4263, 0xDF65001F, 0x0EC50966, 0xDFDD55BC, 0x29DE0655, 0x911E739A,
  390|  1.31k|      0x17AF8975, 0x32C7911C, 0x89F89468, 0x0D01E980, 0x524755F4, 0x03B63CC9, 0x0CC844B2, 0xBCF3F0AA, 0x87AC36E9,
  391|  1.31k|      0xE53A7426, 0x01B3D82B, 0x1A9E7449, 0x64EE2D7E, 0xCDDBB1DA, 0x01C94910, 0xB868BF80, 0x0D26F3FD, 0x9342EDE7,
  392|  1.31k|      0x04A5C284, 0x636737B6, 0x50F5B616, 0xF24766E3, 0x8ECA36C1, 0x136E05DB, 0xFEF18391, 0xFB887A37, 0xD6E7F7D4,
  393|  1.31k|      0xC7FB7DC9, 0x3063FCDF, 0xB6F589DE, 0xEC2941DA, 0x26E46695, 0xB7566419, 0xF654EFC5, 0xD08D58B7, 0x48925401,
  394|  1.31k|      0xC1BACB7F, 0xE5FF550F, 0xB6083049, 0x5BB5D0E8, 0x87D72E5A, 0xAB6A6EE1, 0x223A66CE, 0xC62BF3CD, 0x9E0885F9,
  395|  1.31k|      0x68CB3E47, 0x086C010F, 0xA21DE820, 0xD18B69DE, 0xF3F65777, 0xFA02C3F6, 0x407EDAC3, 0xCBB3D550, 0x1793084D,
  396|  1.31k|      0xB0D70EBA, 0x0AB378D5, 0xD951FB0C, 0xDED7DA56, 0x4124BBE4, 0x94CA0B56, 0x0F5755D1, 0xE0E1E56E, 0x6184B5BE,
  397|  1.31k|      0x580A249F, 0x94F74BC0, 0xE327888E, 0x9F7B5561, 0xC3DC0280, 0x05687715, 0x646C6BD7, 0x44904DB3, 0x66B4F0A3,
  398|  1.31k|      0xC0F1648A, 0x697ED5AF, 0x49E92FF6, 0x309E374F, 0x2CB6356A, 0x85808573, 0x4991F840, 0x76F0AE02, 0x083BE84D,
  399|  1.31k|      0x28421C9A, 0x44489406, 0x736E4CB8, 0xC1092910, 0x8BC95FC6, 0x7D869CF4, 0x134F616F, 0x2E77118D, 0xB31B2BE1,
  400|  1.31k|      0xAA90B472, 0x3CA5D717, 0x7D161BBA, 0x9CAD9010, 0xAF462BA2, 0x9FE459D2, 0x45D34559, 0xD9F2DA13, 0xDBC65487,
  401|  1.31k|      0xF3E4F94E, 0x176D486F, 0x097C13EA, 0x631DA5C7, 0x445F7382, 0x175683F4, 0xCDC66A97, 0x70BE0288, 0xB3CDCF72,
  402|  1.31k|      0x6E5DD2F3, 0x20936079, 0x459B80A5, 0xBE60E2DB, 0xA9C23101, 0xEBA5315C, 0x224E42F2, 0x1C5C1572, 0xF6721B2C,
  403|  1.31k|      0x1AD2FFF3, 0x8C25404E, 0x324ED72F, 0x4067B7FD, 0x0523138E, 0x5CA3BC78, 0xDC0FD66E, 0x75922283, 0x784D6B17,
  404|  1.31k|      0x58EBB16E, 0x44094F85, 0x3F481D87, 0xFCFEAE7B, 0x77B5FF76, 0x8C2302BF, 0xAAF47556, 0x5F46B02A, 0x2B092801,
  405|  1.31k|      0x3D38F5F7, 0x0CA81F36, 0x52AF4A8A, 0x66D5E7C0, 0xDF3B0874, 0x95055110, 0x1B5AD7A8, 0xF61ED5AD, 0x6CF6E479,
  406|  1.31k|      0x20758184, 0xD0CEFA65, 0x88F7BE58, 0x4A046826, 0x0FF6F8F3, 0xA09C7F70, 0x5346ABA0, 0x5CE96C28, 0xE176EDA3,
  407|  1.31k|      0x6BAC307F, 0x376829D2, 0x85360FA9, 0x17E3FE2A, 0x24B79767, 0xF5A96B20, 0xD6CD2595, 0x68FF1EBF, 0x7555442C,
  408|  1.31k|      0xF19F06BE, 0xF9E0659A, 0xEEB9491D, 0x34010718, 0xBB30CAB8, 0xE822FE15, 0x88570983, 0x750E6249, 0xDA627E55,
  409|  1.31k|      0x5E76FFA8, 0xB1534546, 0x6D47DE08, 0xEFE9E7D4};
  410|       |
  411|  1.31k|   alignas(256) static const uint32_t S6[256] = {
  412|  1.31k|      0xF6FA8F9D, 0x2CAC6CE1, 0x4CA34867, 0xE2337F7C, 0x95DB08E7, 0x016843B4, 0xECED5CBC, 0x325553AC, 0xBF9F0960,
  413|  1.31k|      0xDFA1E2ED, 0x83F0579D, 0x63ED86B9, 0x1AB6A6B8, 0xDE5EBE39, 0xF38FF732, 0x8989B138, 0x33F14961, 0xC01937BD,
  414|  1.31k|      0xF506C6DA, 0xE4625E7E, 0xA308EA99, 0x4E23E33C, 0x79CBD7CC, 0x48A14367, 0xA3149619, 0xFEC94BD5, 0xA114174A,
  415|  1.31k|      0xEAA01866, 0xA084DB2D, 0x09A8486F, 0xA888614A, 0x2900AF98, 0x01665991, 0xE1992863, 0xC8F30C60, 0x2E78EF3C,
  416|  1.31k|      0xD0D51932, 0xCF0FEC14, 0xF7CA07D2, 0xD0A82072, 0xFD41197E, 0x9305A6B0, 0xE86BE3DA, 0x74BED3CD, 0x372DA53C,
  417|  1.31k|      0x4C7F4448, 0xDAB5D440, 0x6DBA0EC3, 0x083919A7, 0x9FBAEED9, 0x49DBCFB0, 0x4E670C53, 0x5C3D9C01, 0x64BDB941,
  418|  1.31k|      0x2C0E636A, 0xBA7DD9CD, 0xEA6F7388, 0xE70BC762, 0x35F29ADB, 0x5C4CDD8D, 0xF0D48D8C, 0xB88153E2, 0x08A19866,
  419|  1.31k|      0x1AE2EAC8, 0x284CAF89, 0xAA928223, 0x9334BE53, 0x3B3A21BF, 0x16434BE3, 0x9AEA3906, 0xEFE8C36E, 0xF890CDD9,
  420|  1.31k|      0x80226DAE, 0xC340A4A3, 0xDF7E9C09, 0xA694A807, 0x5B7C5ECC, 0x221DB3A6, 0x9A69A02F, 0x68818A54, 0xCEB2296F,
  421|  1.31k|      0x53C0843A, 0xFE893655, 0x25BFE68A, 0xB4628ABC, 0xCF222EBF, 0x25AC6F48, 0xA9A99387, 0x53BDDB65, 0xE76FFBE7,
  422|  1.31k|      0xE967FD78, 0x0BA93563, 0x8E342BC1, 0xE8A11BE9, 0x4980740D, 0xC8087DFC, 0x8DE4BF99, 0xA11101A0, 0x7FD37975,
  423|  1.31k|      0xDA5A26C0, 0xE81F994F, 0x9528CD89, 0xFD339FED, 0xB87834BF, 0x5F04456D, 0x22258698, 0xC9C4C83B, 0x2DC156BE,
  424|  1.31k|      0x4F628DAA, 0x57F55EC5, 0xE2220ABE, 0xD2916EBF, 0x4EC75B95, 0x24F2C3C0, 0x42D15D99, 0xCD0D7FA0, 0x7B6E27FF,
  425|  1.31k|      0xA8DC8AF0, 0x7345C106, 0xF41E232F, 0x35162386, 0xE6EA8926, 0x3333B094, 0x157EC6F2, 0x372B74AF, 0x692573E4,
  426|  1.31k|      0xE9A9D848, 0xF3160289, 0x3A62EF1D, 0xA787E238, 0xF3A5F676, 0x74364853, 0x20951063, 0x4576698D, 0xB6FAD407,
  427|  1.31k|      0x592AF950, 0x36F73523, 0x4CFB6E87, 0x7DA4CEC0, 0x6C152DAA, 0xCB0396A8, 0xC50DFE5D, 0xFCD707AB, 0x0921C42F,
  428|  1.31k|      0x89DFF0BB, 0x5FE2BE78, 0x448F4F33, 0x754613C9, 0x2B05D08D, 0x48B9D585, 0xDC049441, 0xC8098F9B, 0x7DEDE786,
  429|  1.31k|      0xC39A3373, 0x42410005, 0x6A091751, 0x0EF3C8A6, 0x890072D6, 0x28207682, 0xA9A9F7BE, 0xBF32679D, 0xD45B5B75,
  430|  1.31k|      0xB353FD00, 0xCBB0E358, 0x830F220A, 0x1F8FB214, 0xD372CF08, 0xCC3C4A13, 0x8CF63166, 0x061C87BE, 0x88C98F88,
  431|  1.31k|      0x6062E397, 0x47CF8E7A, 0xB6C85283, 0x3CC2ACFB, 0x3FC06976, 0x4E8F0252, 0x64D8314D, 0xDA3870E3, 0x1E665459,
  432|  1.31k|      0xC10908F0, 0x513021A5, 0x6C5B68B7, 0x822F8AA0, 0x3007CD3E, 0x74719EEF, 0xDC872681, 0x073340D4, 0x7E432FD9,
  433|  1.31k|      0x0C5EC241, 0x8809286C, 0xF592D891, 0x08A930F6, 0x957EF305, 0xB7FBFFBD, 0xC266E96F, 0x6FE4AC98, 0xB173ECC0,
  434|  1.31k|      0xBC60B42A, 0x953498DA, 0xFBA1AE12, 0x2D4BD736, 0x0F25FAAB, 0xA4F3FCEB, 0xE2969123, 0x257F0C3D, 0x9348AF49,
  435|  1.31k|      0x361400BC, 0xE8816F4A, 0x3814F200, 0xA3F94043, 0x9C7A54C2, 0xBC704F57, 0xDA41E7F9, 0xC25AD33A, 0x54F4A084,
  436|  1.31k|      0xB17F5505, 0x59357CBE, 0xEDBD15C8, 0x7F97C5AB, 0xBA5AC7B5, 0xB6F6DEAF, 0x3A479C3A, 0x5302DA25, 0x653D7E6A,
  437|  1.31k|      0x54268D49, 0x51A477EA, 0x5017D55B, 0xD7D25D88, 0x44136C76, 0x0404A8C8, 0xB8E5A121, 0xB81A928A, 0x60ED5869,
  438|  1.31k|      0x97C55B96, 0xEAEC991B, 0x29935913, 0x01FDB7F1, 0x088E8DFA, 0x9AB6F6F5, 0x3B4CBF9F, 0x4A5DE3AB, 0xE6051D35,
  439|  1.31k|      0xA0E1D855, 0xD36B4CF1, 0xF544EDEB, 0xB0E93524, 0xBEBB8FBD, 0xA2D762CF, 0x49C92F54, 0x38B5F331, 0x7128A454,
  440|  1.31k|      0x48392905, 0xA65B1DB8, 0x851C97BD, 0xD675CF2F};
  441|       |
  442|  1.31k|   alignas(256) static const uint32_t S7[256] = {
  443|  1.31k|      0x85E04019, 0x332BF567, 0x662DBFFF, 0xCFC65693, 0x2A8D7F6F, 0xAB9BC912, 0xDE6008A1, 0x2028DA1F, 0x0227BCE7,
  444|  1.31k|      0x4D642916, 0x18FAC300, 0x50F18B82, 0x2CB2CB11, 0xB232E75C, 0x4B3695F2, 0xB28707DE, 0xA05FBCF6, 0xCD4181E9,
  445|  1.31k|      0xE150210C, 0xE24EF1BD, 0xB168C381, 0xFDE4E789, 0x5C79B0D8, 0x1E8BFD43, 0x4D495001, 0x38BE4341, 0x913CEE1D,
  446|  1.31k|      0x92A79C3F, 0x089766BE, 0xBAEEADF4, 0x1286BECF, 0xB6EACB19, 0x2660C200, 0x7565BDE4, 0x64241F7A, 0x8248DCA9,
  447|  1.31k|      0xC3B3AD66, 0x28136086, 0x0BD8DFA8, 0x356D1CF2, 0x107789BE, 0xB3B2E9CE, 0x0502AA8F, 0x0BC0351E, 0x166BF52A,
  448|  1.31k|      0xEB12FF82, 0xE3486911, 0xD34D7516, 0x4E7B3AFF, 0x5F43671B, 0x9CF6E037, 0x4981AC83, 0x334266CE, 0x8C9341B7,
  449|  1.31k|      0xD0D854C0, 0xCB3A6C88, 0x47BC2829, 0x4725BA37, 0xA66AD22B, 0x7AD61F1E, 0x0C5CBAFA, 0x4437F107, 0xB6E79962,
  450|  1.31k|      0x42D2D816, 0x0A961288, 0xE1A5C06E, 0x13749E67, 0x72FC081A, 0xB1D139F7, 0xF9583745, 0xCF19DF58, 0xBEC3F756,
  451|  1.31k|      0xC06EBA30, 0x07211B24, 0x45C28829, 0xC95E317F, 0xBC8EC511, 0x38BC46E9, 0xC6E6FA14, 0xBAE8584A, 0xAD4EBC46,
  452|  1.31k|      0x468F508B, 0x7829435F, 0xF124183B, 0x821DBA9F, 0xAFF60FF4, 0xEA2C4E6D, 0x16E39264, 0x92544A8B, 0x009B4FC3,
  453|  1.31k|      0xABA68CED, 0x9AC96F78, 0x06A5B79A, 0xB2856E6E, 0x1AEC3CA9, 0xBE838688, 0x0E0804E9, 0x55F1BE56, 0xE7E5363B,
  454|  1.31k|      0xB3A1F25D, 0xF7DEBB85, 0x61FE033C, 0x16746233, 0x3C034C28, 0xDA6D0C74, 0x79AAC56C, 0x3CE4E1AD, 0x51F0C802,
  455|  1.31k|      0x98F8F35A, 0x1626A49F, 0xEED82B29, 0x1D382FE3, 0x0C4FB99A, 0xBB325778, 0x3EC6D97B, 0x6E77A6A9, 0xCB658B5C,
  456|  1.31k|      0xD45230C7, 0x2BD1408B, 0x60C03EB7, 0xB9068D78, 0xA33754F4, 0xF430C87D, 0xC8A71302, 0xB96D8C32, 0xEBD4E7BE,
  457|  1.31k|      0xBE8B9D2D, 0x7979FB06, 0xE7225308, 0x8B75CF77, 0x11EF8DA4, 0xE083C858, 0x8D6B786F, 0x5A6317A6, 0xFA5CF7A0,
  458|  1.31k|      0x5DDA0033, 0xF28EBFB0, 0xF5B9C310, 0xA0EAC280, 0x08B9767A, 0xA3D9D2B0, 0x79D34217, 0x021A718D, 0x9AC6336A,
  459|  1.31k|      0x2711FD60, 0x438050E3, 0x069908A8, 0x3D7FEDC4, 0x826D2BEF, 0x4EEB8476, 0x488DCF25, 0x36C9D566, 0x28E74E41,
  460|  1.31k|      0xC2610ACA, 0x3D49A9CF, 0xBAE3B9DF, 0xB65F8DE6, 0x92AEAF64, 0x3AC7D5E6, 0x9EA80509, 0xF22B017D, 0xA4173F70,
  461|  1.31k|      0xDD1E16C3, 0x15E0D7F9, 0x50B1B887, 0x2B9F4FD5, 0x625ABA82, 0x6A017962, 0x2EC01B9C, 0x15488AA9, 0xD716E740,
  462|  1.31k|      0x40055A2C, 0x93D29A22, 0xE32DBF9A, 0x058745B9, 0x3453DC1E, 0xD699296E, 0x496CFF6F, 0x1C9F4986, 0xDFE2ED07,
  463|  1.31k|      0xB87242D1, 0x19DE7EAE, 0x053E561A, 0x15AD6F8C, 0x66626C1C, 0x7154C24C, 0xEA082B2A, 0x93EB2939, 0x17DCB0F0,
  464|  1.31k|      0x58D4F2AE, 0x9EA294FB, 0x52CF564C, 0x9883FE66, 0x2EC40581, 0x763953C3, 0x01D6692E, 0xD3A0C108, 0xA1E7160E,
  465|  1.31k|      0xE4F2DFA6, 0x693ED285, 0x74904698, 0x4C2B0EDD, 0x4F757656, 0x5D393378, 0xA132234F, 0x3D321C5D, 0xC3F5E194,
  466|  1.31k|      0x4B269301, 0xC79F022F, 0x3C997E7E, 0x5E4F9504, 0x3FFAFBBD, 0x76F7AD0E, 0x296693F4, 0x3D1FCE6F, 0xC61E45BE,
  467|  1.31k|      0xD3B5AB34, 0xF72BF9B7, 0x1B0434C0, 0x4E72B567, 0x5592A33D, 0xB5229301, 0xCFD2A87F, 0x60AEB767, 0x1814386B,
  468|  1.31k|      0x30BCC33D, 0x38A0C07D, 0xFD1606F2, 0xC363519B, 0x589DD390, 0x5479F8E6, 0x1CB8D647, 0x97FD61A9, 0xEA7759F4,
  469|  1.31k|      0x2D57539D, 0x569A58CF, 0xE84E63AD, 0x462E1B78, 0x6580F87E, 0xF3817914, 0x91DA55F4, 0x40A230F3, 0xD1988F35,
  470|  1.31k|      0xB6E318D2, 0x3FFA50BC, 0x3D40F021, 0xC3C0BDAE, 0x4958C24C, 0x518F36B2, 0x84B1D370, 0x0FEDCE83, 0x878DDADA,
  471|  1.31k|      0xF2A279C7, 0x94E01BE8, 0x90716F4B, 0x954B8AA3};
  472|       |
  473|  1.31k|   alignas(256) static const uint32_t S8[256] = {
  474|  1.31k|      0xE216300D, 0xBBDDFFFC, 0xA7EBDABD, 0x35648095, 0x7789F8B7, 0xE6C1121B, 0x0E241600, 0x052CE8B5, 0x11A9CFB0,
  475|  1.31k|      0xE5952F11, 0xECE7990A, 0x9386D174, 0x2A42931C, 0x76E38111, 0xB12DEF3A, 0x37DDDDFC, 0xDE9ADEB1, 0x0A0CC32C,
  476|  1.31k|      0xBE197029, 0x84A00940, 0xBB243A0F, 0xB4D137CF, 0xB44E79F0, 0x049EEDFD, 0x0B15A15D, 0x480D3168, 0x8BBBDE5A,
  477|  1.31k|      0x669DED42, 0xC7ECE831, 0x3F8F95E7, 0x72DF191B, 0x7580330D, 0x94074251, 0x5C7DCDFA, 0xABBE6D63, 0xAA402164,
  478|  1.31k|      0xB301D40A, 0x02E7D1CA, 0x53571DAE, 0x7A3182A2, 0x12A8DDEC, 0xFDAA335D, 0x176F43E8, 0x71FB46D4, 0x38129022,
  479|  1.31k|      0xCE949AD4, 0xB84769AD, 0x965BD862, 0x82F3D055, 0x66FB9767, 0x15B80B4E, 0x1D5B47A0, 0x4CFDE06F, 0xC28EC4B8,
  480|  1.31k|      0x57E8726E, 0x647A78FC, 0x99865D44, 0x608BD593, 0x6C200E03, 0x39DC5FF6, 0x5D0B00A3, 0xAE63AFF2, 0x7E8BD632,
  481|  1.31k|      0x70108C0C, 0xBBD35049, 0x2998DF04, 0x980CF42A, 0x9B6DF491, 0x9E7EDD53, 0x06918548, 0x58CB7E07, 0x3B74EF2E,
  482|  1.31k|      0x522FFFB1, 0xD24708CC, 0x1C7E27CD, 0xA4EB215B, 0x3CF1D2E2, 0x19B47A38, 0x424F7618, 0x35856039, 0x9D17DEE7,
  483|  1.31k|      0x27EB35E6, 0xC9AFF67B, 0x36BAF5B8, 0x09C467CD, 0xC18910B1, 0xE11DBF7B, 0x06CD1AF8, 0x7170C608, 0x2D5E3354,
  484|  1.31k|      0xD4DE495A, 0x64C6D006, 0xBCC0C62C, 0x3DD00DB3, 0x708F8F34, 0x77D51B42, 0x264F620F, 0x24B8D2BF, 0x15C1B79E,
  485|  1.31k|      0x46A52564, 0xF8D7E54E, 0x3E378160, 0x7895CDA5, 0x859C15A5, 0xE6459788, 0xC37BC75F, 0xDB07BA0C, 0x0676A3AB,
  486|  1.31k|      0x7F229B1E, 0x31842E7B, 0x24259FD7, 0xF8BEF472, 0x835FFCB8, 0x6DF4C1F2, 0x96F5B195, 0xFD0AF0FC, 0xB0FE134C,
  487|  1.31k|      0xE2506D3D, 0x4F9B12EA, 0xF215F225, 0xA223736F, 0x9FB4C428, 0x25D04979, 0x34C713F8, 0xC4618187, 0xEA7A6E98,
  488|  1.31k|      0x7CD16EFC, 0x1436876C, 0xF1544107, 0xBEDEEE14, 0x56E9AF27, 0xA04AA441, 0x3CF7C899, 0x92ECBAE6, 0xDD67016D,
  489|  1.31k|      0x151682EB, 0xA842EEDF, 0xFDBA60B4, 0xF1907B75, 0x20E3030F, 0x24D8C29E, 0xE139673B, 0xEFA63FB8, 0x71873054,
  490|  1.31k|      0xB6F2CF3B, 0x9F326442, 0xCB15A4CC, 0xB01A4504, 0xF1E47D8D, 0x844A1BE5, 0xBAE7DFDC, 0x42CBDA70, 0xCD7DAE0A,
  491|  1.31k|      0x57E85B7A, 0xD53F5AF6, 0x20CF4D8C, 0xCEA4D428, 0x79D130A4, 0x3486EBFB, 0x33D3CDDC, 0x77853B53, 0x37EFFCB5,
  492|  1.31k|      0xC5068778, 0xE580B3E6, 0x4E68B8F4, 0xC5C8B37E, 0x0D809EA2, 0x398FEB7C, 0x132A4F94, 0x43B7950E, 0x2FEE7D1C,
  493|  1.31k|      0x223613BD, 0xDD06CAA2, 0x37DF932B, 0xC4248289, 0xACF3EBC3, 0x5715F6B7, 0xEF3478DD, 0xF267616F, 0xC148CBE4,
  494|  1.31k|      0x9052815E, 0x5E410FAB, 0xB48A2465, 0x2EDA7FA4, 0xE87B40E4, 0xE98EA084, 0x5889E9E1, 0xEFD390FC, 0xDD07D35B,
  495|  1.31k|      0xDB485694, 0x38D7E5B2, 0x57720101, 0x730EDEBC, 0x5B643113, 0x94917E4F, 0x503C2FBA, 0x646F1282, 0x7523D24A,
  496|  1.31k|      0xE0779695, 0xF9C17A8F, 0x7A5B2121, 0xD187B896, 0x29263A4D, 0xBA510CDF, 0x81F47C9F, 0xAD1163ED, 0xEA7B5965,
  497|  1.31k|      0x1A00726E, 0x11403092, 0x00DA6D77, 0x4A0CDD61, 0xAD1F4603, 0x605BDFB0, 0x9EEDC364, 0x22EBE6A8, 0xCEE7D28A,
  498|  1.31k|      0xA0E736A0, 0x5564A6B9, 0x10853209, 0xC7EB8F37, 0x2DE705CA, 0x8951570F, 0xDF09822B, 0xBD691A6C, 0xAA12E4F2,
  499|  1.31k|      0x87451C0F, 0xE0F6A27A, 0x3ADA4819, 0x4CF1764F, 0x0D771C2B, 0x67CDB156, 0x350D8384, 0x5938FA0F, 0x42399EF3,
  500|  1.31k|      0x36997B07, 0x0E84093D, 0x4AA93E61, 0x8360D87B, 0x1FA98B0C, 0x1149382C, 0xE97625A5, 0x0614D1B7, 0x0E25244B,
  501|  1.31k|      0x0C768347, 0x589E8D82, 0x0D2059D1, 0xA466BB1E, 0xF8DA0A82, 0x04F19130, 0xBA6E4EC0, 0x99265164, 0x1EE7230D,
  502|  1.31k|      0x50B2AD80, 0xEAEE6801, 0x8DB2A283, 0xEA8BF59E};
  503|       |
  504|  1.31k|   class ByteReader final {
  505|  1.31k|      public:
  506|  1.31k|         uint8_t operator()(size_t i) const { return static_cast<uint8_t>(m_X[i / 4] >> (8 * (3 - (i % 4)))); }
  507|       |
  508|  1.31k|         explicit ByteReader(const uint32_t* x) : m_X(x) {}
  509|       |
  510|  1.31k|      private:
  511|  1.31k|         const uint32_t* m_X;
  512|  1.31k|   };
  513|       |
  514|  1.31k|   secure_vector<uint32_t> Z(4);
  515|  1.31k|   const ByteReader x(X.data());
  516|  1.31k|   const ByteReader z(Z.data());
  517|       |
  518|  1.31k|   Z[0] = X[0] ^ S5[x(13)] ^ S6[x(15)] ^ S7[x(12)] ^ S8[x(14)] ^ S7[x(8)];
  519|  1.31k|   Z[1] = X[2] ^ S5[z(0)] ^ S6[z(2)] ^ S7[z(1)] ^ S8[z(3)] ^ S8[x(10)];
  520|  1.31k|   Z[2] = X[3] ^ S5[z(7)] ^ S6[z(6)] ^ S7[z(5)] ^ S8[z(4)] ^ S5[x(9)];
  521|  1.31k|   Z[3] = X[1] ^ S5[z(10)] ^ S6[z(9)] ^ S7[z(11)] ^ S8[z(8)] ^ S6[x(11)];
  522|  1.31k|   K[0] = S5[z(8)] ^ S6[z(9)] ^ S7[z(7)] ^ S8[z(6)] ^ S5[z(2)];
  523|  1.31k|   K[1] = S5[z(10)] ^ S6[z(11)] ^ S7[z(5)] ^ S8[z(4)] ^ S6[z(6)];
  524|  1.31k|   K[2] = S5[z(12)] ^ S6[z(13)] ^ S7[z(3)] ^ S8[z(2)] ^ S7[z(9)];
  525|  1.31k|   K[3] = S5[z(14)] ^ S6[z(15)] ^ S7[z(1)] ^ S8[z(0)] ^ S8[z(12)];
  526|  1.31k|   X[0] = Z[2] ^ S5[z(5)] ^ S6[z(7)] ^ S7[z(4)] ^ S8[z(6)] ^ S7[z(0)];
  527|  1.31k|   X[1] = Z[0] ^ S5[x(0)] ^ S6[x(2)] ^ S7[x(1)] ^ S8[x(3)] ^ S8[z(2)];
  528|  1.31k|   X[2] = Z[1] ^ S5[x(7)] ^ S6[x(6)] ^ S7[x(5)] ^ S8[x(4)] ^ S5[z(1)];
  529|  1.31k|   X[3] = Z[3] ^ S5[x(10)] ^ S6[x(9)] ^ S7[x(11)] ^ S8[x(8)] ^ S6[z(3)];
  530|  1.31k|   K[4] = S5[x(3)] ^ S6[x(2)] ^ S7[x(12)] ^ S8[x(13)] ^ S5[x(8)];
  531|  1.31k|   K[5] = S5[x(1)] ^ S6[x(0)] ^ S7[x(14)] ^ S8[x(15)] ^ S6[x(13)];
  532|  1.31k|   K[6] = S5[x(7)] ^ S6[x(6)] ^ S7[x(8)] ^ S8[x(9)] ^ S7[x(3)];
  533|  1.31k|   K[7] = S5[x(5)] ^ S6[x(4)] ^ S7[x(10)] ^ S8[x(11)] ^ S8[x(7)];
  534|  1.31k|   Z[0] = X[0] ^ S5[x(13)] ^ S6[x(15)] ^ S7[x(12)] ^ S8[x(14)] ^ S7[x(8)];
  535|  1.31k|   Z[1] = X[2] ^ S5[z(0)] ^ S6[z(2)] ^ S7[z(1)] ^ S8[z(3)] ^ S8[x(10)];
  536|  1.31k|   Z[2] = X[3] ^ S5[z(7)] ^ S6[z(6)] ^ S7[z(5)] ^ S8[z(4)] ^ S5[x(9)];
  537|  1.31k|   Z[3] = X[1] ^ S5[z(10)] ^ S6[z(9)] ^ S7[z(11)] ^ S8[z(8)] ^ S6[x(11)];
  538|  1.31k|   K[8] = S5[z(3)] ^ S6[z(2)] ^ S7[z(12)] ^ S8[z(13)] ^ S5[z(9)];
  539|  1.31k|   K[9] = S5[z(1)] ^ S6[z(0)] ^ S7[z(14)] ^ S8[z(15)] ^ S6[z(12)];
  540|  1.31k|   K[10] = S5[z(7)] ^ S6[z(6)] ^ S7[z(8)] ^ S8[z(9)] ^ S7[z(2)];
  541|  1.31k|   K[11] = S5[z(5)] ^ S6[z(4)] ^ S7[z(10)] ^ S8[z(11)] ^ S8[z(6)];
  542|  1.31k|   X[0] = Z[2] ^ S5[z(5)] ^ S6[z(7)] ^ S7[z(4)] ^ S8[z(6)] ^ S7[z(0)];
  543|  1.31k|   X[1] = Z[0] ^ S5[x(0)] ^ S6[x(2)] ^ S7[x(1)] ^ S8[x(3)] ^ S8[z(2)];
  544|  1.31k|   X[2] = Z[1] ^ S5[x(7)] ^ S6[x(6)] ^ S7[x(5)] ^ S8[x(4)] ^ S5[z(1)];
  545|  1.31k|   X[3] = Z[3] ^ S5[x(10)] ^ S6[x(9)] ^ S7[x(11)] ^ S8[x(8)] ^ S6[z(3)];
  546|  1.31k|   K[12] = S5[x(8)] ^ S6[x(9)] ^ S7[x(7)] ^ S8[x(6)] ^ S5[x(3)];
  547|  1.31k|   K[13] = S5[x(10)] ^ S6[x(11)] ^ S7[x(5)] ^ S8[x(4)] ^ S6[x(7)];
  548|  1.31k|   K[14] = S5[x(12)] ^ S6[x(13)] ^ S7[x(3)] ^ S8[x(2)] ^ S7[x(8)];
  549|  1.31k|   K[15] = S5[x(14)] ^ S6[x(15)] ^ S7[x(1)] ^ S8[x(0)] ^ S8[x(13)];
  550|  1.31k|}
cast128.cpp:_ZN5Botan12_GLOBAL__N_12F1Ejjh:
  145|  3.39M|inline uint32_t F1(uint32_t R, uint32_t MK, uint8_t RK) {
  146|  3.39M|   const uint32_t T = rotl_var(MK + R, RK);
  147|  3.39M|   const uint32_t S1 = CAST_SBOX1[get_byte<0>(T)];
  148|  3.39M|   const uint32_t S2 = CAST_SBOX2[get_byte<1>(T)];
  149|  3.39M|   const uint32_t S3 = CAST_SBOX3[get_byte<2>(T)];
  150|  3.39M|   const uint32_t S4 = CAST_SBOX4[get_byte<3>(T)];
  151|       |
  152|  3.39M|   return (S1 ^ S2) - S3 + S4;
  153|  3.39M|}
cast128.cpp:_ZN5Botan12_GLOBAL__N_12F2Ejjh:
  158|  2.83M|inline uint32_t F2(uint32_t R, uint32_t MK, uint8_t RK) {
  159|  2.83M|   const uint32_t T = rotl_var(MK ^ R, RK);
  160|  2.83M|   const uint32_t S1 = CAST_SBOX1[get_byte<0>(T)];
  161|  2.83M|   const uint32_t S2 = CAST_SBOX2[get_byte<1>(T)];
  162|  2.83M|   const uint32_t S3 = CAST_SBOX3[get_byte<2>(T)];
  163|  2.83M|   const uint32_t S4 = CAST_SBOX4[get_byte<3>(T)];
  164|       |
  165|  2.83M|   return (S1 - S2 + S3) ^ S4;
  166|  2.83M|}
cast128.cpp:_ZN5Botan12_GLOBAL__N_12F3Ejjh:
  171|  2.83M|inline uint32_t F3(uint32_t R, uint32_t MK, uint8_t RK) {
  172|  2.83M|   const uint32_t T = rotl_var(MK - R, RK);
  173|       |
  174|  2.83M|   const uint32_t S1 = CAST_SBOX1[get_byte<0>(T)];
  175|  2.83M|   const uint32_t S2 = CAST_SBOX2[get_byte<1>(T)];
  176|  2.83M|   const uint32_t S3 = CAST_SBOX3[get_byte<2>(T)];
  177|  2.83M|   const uint32_t S4 = CAST_SBOX4[get_byte<3>(T)];
  178|       |
  179|  2.83M|   return ((S1 + S2) ^ S3) - S4;
  180|  2.83M|}
cast128.cpp:_ZZN5Botan8CAST_1287cast_ksERNSt3__16vectorIjNS_16secure_allocatorIjEEEES6_EN10ByteReaderC2EPKj:
  508|  2.62k|         explicit ByteReader(const uint32_t* x) : m_X(x) {}
cast128.cpp:_ZZN5Botan8CAST_1287cast_ksERNSt3__16vectorIjNS_16secure_allocatorIjEEEES6_ENK10ByteReaderclEm:
  506|   210k|         uint8_t operator()(size_t i) const { return static_cast<uint8_t>(m_X[i / 4] >> (8 * (3 - (i % 4)))); }

_ZNK5Botan9TripleDES9encrypt_nEPKhPhm:
  769|   531k|void TripleDES::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  770|   531k|   assert_key_material_set();
  771|       |
  772|   531k|   const uint32_t* k1 = m_round_key.data();
  773|   531k|   const uint32_t* k2 = k1 + 16 * 48;
  774|   531k|   const uint32_t* k3 = k2 + 16 * 48;
  775|       |
  776|   531k|   uint32_t B[64];
  777|       |
  778|   548k|   while(blocks >= 32) {
  ------------------
  |  Branch (778:10): [True: 16.9k, False: 531k]
  ------------------
  779|  16.9k|      transpose_in(B, in, 32);
  780|  16.9k|      des_encrypt(&B[0], &B[32], k1);
  781|  16.9k|      des_decrypt(&B[32], &B[0], k2);
  782|  16.9k|      des_encrypt(&B[0], &B[32], k3);
  783|  16.9k|      transpose_out(out, B, 32);
  784|       |
  785|  16.9k|      in += 32 * BLOCK_SIZE;
  786|  16.9k|      out += 32 * BLOCK_SIZE;
  787|  16.9k|      blocks -= 32;
  788|  16.9k|   }
  789|       |
  790|   531k|   if(blocks > 0) {
  ------------------
  |  Branch (790:7): [True: 527k, False: 4.24k]
  ------------------
  791|   527k|      transpose_in(B, in, blocks);
  792|   527k|      des_encrypt(&B[0], &B[32], k1);
  793|   527k|      des_decrypt(&B[32], &B[0], k2);
  794|   527k|      des_encrypt(&B[0], &B[32], k3);
  795|   527k|      transpose_out(out, B, blocks);
  796|   527k|   }
  797|   531k|}
_ZNK5Botan9TripleDES19has_keying_materialEv:
  832|   541k|bool TripleDES::has_keying_material() const {
  833|   541k|   return !m_round_key.empty();
  834|   541k|}
_ZN5Botan9TripleDES12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  839|    370|void TripleDES::key_schedule(std::span<const uint8_t> key) {
  840|    370|   m_round_key.resize(3 * 16 * 48);
  841|    370|   des_key_schedule(m_round_key.data(), key.first(8).data());
  842|    370|   des_key_schedule(m_round_key.data() + 16 * 48, key.subspan(8, 8).data());
  843|       |
  844|    370|   if(key.size() == 24) {
  ------------------
  |  Branch (844:7): [True: 370, False: 0]
  ------------------
  845|    370|      des_key_schedule(m_round_key.data() + 2 * 16 * 48, key.last(8).data());
  846|    370|   } else {
  847|      0|      copy_mem(m_round_key.data() + 2 * 16 * 48, m_round_key.data(), 16 * 48);
  848|      0|   }
  849|    370|}
_ZN5Botan9TripleDES5clearEv:
  851|     83|void TripleDES::clear() {
  852|     83|   zap(m_round_key);
  853|     83|}
des.cpp:_ZN5Botan12_GLOBAL__N_112transpose_inEPjPKhm:
  537|   544k|void transpose_in(uint32_t B[64], const uint8_t in[], size_t n_blocks) {
  538|   544k|   uint64_t M[32] = {};
  539|       |
  540|   544k|   load_be<uint64_t>(M, in, n_blocks);
  541|       |
  542|   544k|   des_transpose(M);
  543|       |
  544|       |   // clang-format off
  545|   544k|   static constexpr uint8_t IP[64] = {
  546|   544k|      57, 49, 41, 33, 25, 17, 9,  1,
  547|   544k|      59, 51, 43, 35, 27, 19, 11, 3,
  548|   544k|      61, 53, 45, 37, 29, 21, 13, 5,
  549|   544k|      63, 55, 47, 39, 31, 23, 15, 7,
  550|   544k|      56, 48, 40, 32, 24, 16, 8,  0,
  551|   544k|      58, 50, 42, 34, 26, 18, 10, 2,
  552|   544k|      60, 52, 44, 36, 28, 20, 12, 4,
  553|   544k|      62, 54, 46, 38, 30, 22, 14, 6
  554|   544k|   };
  555|       |   // clang-format on
  556|       |
  557|  35.3M|   for(size_t i = 0; i < 64; ++i) {
  ------------------
  |  Branch (557:22): [True: 34.8M, False: 544k]
  ------------------
  558|  34.8M|      const uint8_t src = IP[i];
  559|  34.8M|      if(src < 32) {
  ------------------
  |  Branch (559:10): [True: 17.4M, False: 17.4M]
  ------------------
  560|  17.4M|         B[i] = static_cast<uint32_t>(M[31 - src] >> 32);
  561|  17.4M|      } else {
  562|  17.4M|         B[i] = static_cast<uint32_t>(M[63 - src]);
  563|  17.4M|      }
  564|  34.8M|   }
  565|   544k|}
des.cpp:_ZN5Botan12_GLOBAL__N_113des_transposeEPm:
  509|  1.08M|void des_transpose(uint64_t M[32]) {
  510|  18.5M|   for(size_t i = 0; i != 16; ++i) {
  ------------------
  |  Branch (510:22): [True: 17.4M, False: 1.08M]
  ------------------
  511|  17.4M|      swap_bits<uint64_t>(M[i], M[i + 16], 0x0000FFFF0000FFFF, 16);
  512|  17.4M|   }
  513|       |
  514|  3.26M|   for(size_t i = 0; i != 32; i += 16) {
  ------------------
  |  Branch (514:22): [True: 2.17M, False: 1.08M]
  ------------------
  515|  19.5M|      for(size_t j = 0; j != 8; ++j) {
  ------------------
  |  Branch (515:25): [True: 17.4M, False: 2.17M]
  ------------------
  516|  17.4M|         swap_bits<uint64_t>(M[i + j], M[i + j + 8], 0x00FF00FF00FF00FF, 8);
  517|  17.4M|      }
  518|  2.17M|   }
  519|       |
  520|  5.44M|   for(size_t i = 0; i != 32; i += 8) {
  ------------------
  |  Branch (520:22): [True: 4.35M, False: 1.08M]
  ------------------
  521|  21.7M|      for(size_t j = 0; j != 4; ++j) {
  ------------------
  |  Branch (521:25): [True: 17.4M, False: 4.35M]
  ------------------
  522|  17.4M|         swap_bits<uint64_t>(M[i + j + 0], M[i + j + 4], 0x0F0F0F0F0F0F0F0F, 4);
  523|  17.4M|      }
  524|  4.35M|   }
  525|       |
  526|  9.79M|   for(size_t i = 0; i != 32; i += 4) {
  ------------------
  |  Branch (526:22): [True: 8.71M, False: 1.08M]
  ------------------
  527|  26.1M|      for(size_t j = 0; j != 2; ++j) {
  ------------------
  |  Branch (527:25): [True: 17.4M, False: 8.71M]
  ------------------
  528|  17.4M|         swap_bits<uint64_t>(M[i + j + 0], M[i + j + 2], 0x3333333333333333, 2);
  529|  17.4M|      }
  530|  8.71M|   }
  531|       |
  532|  18.5M|   for(size_t i = 0; i != 32; i += 2) {
  ------------------
  |  Branch (532:22): [True: 17.4M, False: 1.08M]
  ------------------
  533|  17.4M|      swap_bits<uint64_t>(M[i], M[i + 1], 0x5555555555555555, 1);
  534|  17.4M|   }
  535|  1.08M|}
des.cpp:_ZN5Botan12_GLOBAL__N_111des_encryptEPjS1_PKj:
  638|  1.08M|void des_encrypt(uint32_t L[32], uint32_t R[32], const uint32_t round_key[]) {
  639|  9.79M|   for(size_t round = 0; round < 16; round += 2) {
  ------------------
  |  Branch (639:26): [True: 8.71M, False: 1.08M]
  ------------------
  640|  8.71M|      des_round(L, R, &round_key[round * 48]);
  641|  8.71M|      des_round(R, L, &round_key[(round + 1) * 48]);
  642|  8.71M|   }
  643|  1.08M|}
des.cpp:_ZN5Botan12_GLOBAL__N_19des_roundEPjPKjS3_:
  602|  26.1M|void des_round(uint32_t L[32], const uint32_t R[32], const uint32_t RK[48]) {
  603|       |   // clang-format off
  604|  26.1M|   SBox1(R[31] ^ RK[ 0], R[ 0] ^ RK[ 1], R[ 1] ^ RK[ 2],
  605|  26.1M|         R[ 2] ^ RK[ 3], R[ 3] ^ RK[ 4], R[ 4] ^ RK[ 5],
  606|  26.1M|         L[ 8], L[16], L[22], L[30]);
  607|       |
  608|  26.1M|   SBox2(R[ 3] ^ RK[ 6], R[ 4] ^ RK[ 7], R[ 5] ^ RK[ 8],
  609|  26.1M|         R[ 6] ^ RK[ 9], R[ 7] ^ RK[10], R[ 8] ^ RK[11],
  610|  26.1M|         L[12], L[27], L[ 1], L[17]);
  611|       |
  612|  26.1M|   SBox3(R[ 7] ^ RK[12], R[ 8] ^ RK[13], R[ 9] ^ RK[14],
  613|  26.1M|         R[10] ^ RK[15], R[11] ^ RK[16], R[12] ^ RK[17],
  614|  26.1M|         L[23], L[15], L[29], L[ 5]);
  615|       |
  616|  26.1M|   SBox4(R[11] ^ RK[18], R[12] ^ RK[19], R[13] ^ RK[20],
  617|  26.1M|         R[14] ^ RK[21], R[15] ^ RK[22], R[16] ^ RK[23],
  618|  26.1M|         L[25], L[19], L[ 9], L[ 0]);
  619|       |
  620|  26.1M|   SBox5(R[15] ^ RK[24], R[16] ^ RK[25], R[17] ^ RK[26],
  621|  26.1M|         R[18] ^ RK[27], R[19] ^ RK[28], R[20] ^ RK[29],
  622|  26.1M|         L[ 7], L[13], L[24], L[ 2]);
  623|       |
  624|  26.1M|   SBox6(R[19] ^ RK[30], R[20] ^ RK[31], R[21] ^ RK[32],
  625|  26.1M|         R[22] ^ RK[33], R[23] ^ RK[34], R[24] ^ RK[35],
  626|  26.1M|         L[ 3], L[28], L[10], L[18]);
  627|       |
  628|  26.1M|   SBox7(R[23] ^ RK[36], R[24] ^ RK[37], R[25] ^ RK[38],
  629|  26.1M|         R[26] ^ RK[39], R[27] ^ RK[40], R[28] ^ RK[41],
  630|  26.1M|         L[31], L[11], L[21], L[ 6]);
  631|       |
  632|  26.1M|   SBox8(R[27] ^ RK[42], R[28] ^ RK[43], R[29] ^ RK[44],
  633|  26.1M|         R[30] ^ RK[45], R[31] ^ RK[46], R[ 0] ^ RK[47],
  634|  26.1M|         L[ 4], L[26], L[14], L[20]);
  635|       |   // clang-format on
  636|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox1ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
   38|  26.1M|BOTAN_FORCE_INLINE void SBox1(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
   39|  26.1M|   const T x1 = a1 & ~a5;
   40|  26.1M|   const T x2 = a4 ^ x1;
   41|  26.1M|   const T x3 = a3 | a6;
   42|  26.1M|   const T x4 = a1 ^ a3;
   43|  26.1M|   const T x5 = x3 & x4;
   44|  26.1M|   const T x6 = a4 ^ x5;
   45|  26.1M|   const T x7 = x6 & ~x2;
   46|       |
   47|  26.1M|   const T x8 = a5 ^ a6;
   48|  26.1M|   const T x9 = a3 ^ x8;
   49|  26.1M|   const T x10 = x2 & ~x9;
   50|  26.1M|   const T x11 = a6 | x5;
   51|  26.1M|   const T x12 = x10 ^ x11;
   52|  26.1M|   const T x13 = x12 & ~x7;
   53|       |
   54|  26.1M|   const T x14 = a1 | a6;
   55|  26.1M|   const T x15 = x12 | x14;
   56|  26.1M|   const T x16 = a5 & ~x6;
   57|  26.1M|   const T x17 = x15 ^ x16;
   58|       |
   59|  26.1M|   const T x18 = a4 & ~x14;
   60|  26.1M|   const T x19 = x16 ^ x18;
   61|  26.1M|   const T x20 = x8 & ~x4;
   62|  26.1M|   const T x21 = x19 | x20;
   63|       |
   64|  26.1M|   const T x22 = a3 & ~x1;
   65|  26.1M|   const T x23 = x2 ^ x15;
   66|  26.1M|   const T x24 = x23 & ~x22;
   67|  26.1M|   const T x25 = ~x24;
   68|  26.1M|   const T x26 = x3 & x12;
   69|  26.1M|   const T x27 = x25 ^ x26;
   70|  26.1M|   const T x28 = x17 & ~a2;
   71|  26.1M|   const T x29 = x28 ^ x27;
   72|  26.1M|   out3 ^= x29;
   73|       |
   74|  26.1M|   const T x30 = x8 ^ x24;
   75|  26.1M|   const T x31 = x16 | x30;
   76|  26.1M|   const T x32 = x3 ^ x31;
   77|  26.1M|   const T x33 = a1 ^ x32;
   78|  26.1M|   const T x34 = x27 ^ x33;
   79|  26.1M|   const T x35 = x7 | a2;
   80|  26.1M|   const T x36 = x35 ^ x34;
   81|  26.1M|   out1 ^= x36;
   82|       |
   83|  26.1M|   const T x37 = x2 & ~x21;
   84|  26.1M|   const T x38 = x30 ^ x37;
   85|  26.1M|   const T x39 = x16 ^ x32;
   86|  26.1M|   const T x40 = x34 & ~x39;
   87|  26.1M|   const T x41 = x38 ^ x40;
   88|  26.1M|   const T x42 = a2 & ~x13;
   89|  26.1M|   const T x43 = x42 ^ x41;
   90|  26.1M|   out2 ^= x43;
   91|       |
   92|  26.1M|   const T x44 = x9 ^ x20;
   93|  26.1M|   const T x45 = x14 ^ x40;
   94|  26.1M|   const T x46 = x45 & ~x44;
   95|  26.1M|   const T x47 = x41 ^ x46;
   96|  26.1M|   const T x48 = x47 | a2;
   97|  26.1M|   const T x49 = x48 ^ x21;
   98|  26.1M|   out4 ^= x49;
   99|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox2ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  102|  26.1M|BOTAN_FORCE_INLINE void SBox2(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  103|  26.1M|   const T x1 = a2 ^ a5;
  104|       |
  105|  26.1M|   const T x2 = a1 & ~a6;
  106|  26.1M|   const T x3 = a5 & ~x2;
  107|  26.1M|   const T x4 = a2 | x3;
  108|       |
  109|  26.1M|   const T x5 = x1 & ~a6;
  110|  26.1M|   const T x6 = a1 & x1;
  111|  26.1M|   const T x7 = a5 ^ x6;
  112|  26.1M|   const T x8 = x7 & ~x5;
  113|       |
  114|  26.1M|   const T x9 = a3 & a6;
  115|  26.1M|   const T x10 = x3 ^ x5;
  116|  26.1M|   const T x11 = x4 & x10;
  117|  26.1M|   const T x12 = x11 & ~x9;
  118|       |
  119|  26.1M|   const T x13 = a3 & x11;
  120|  26.1M|   const T x14 = ~a1;
  121|  26.1M|   const T x15 = x13 ^ x14;
  122|  26.1M|   const T x16 = a6 ^ x1;
  123|  26.1M|   const T x17 = x16 & ~x9;
  124|  26.1M|   const T x18 = x15 ^ x17;
  125|  26.1M|   const T x19 = a4 & ~x12;
  126|  26.1M|   const T x20 = x19 ^ x18;
  127|  26.1M|   out2 ^= x20;
  128|       |
  129|  26.1M|   const T x21 = a2 & ~x17;
  130|  26.1M|   const T x22 = x7 ^ x21;
  131|  26.1M|   const T x23 = x15 & ~x22;
  132|  26.1M|   const T x24 = a3 ^ x16;
  133|  26.1M|   const T x25 = x23 ^ x24;
  134|  26.1M|   const T x26 = x4 & ~a4;
  135|  26.1M|   const T x27 = x26 ^ x25;
  136|  26.1M|   out1 ^= x27;
  137|       |
  138|  26.1M|   const T x28 = a2 & ~x9;
  139|  26.1M|   const T x29 = x24 | x28;
  140|  26.1M|   const T x30 = x4 ^ x18;
  141|  26.1M|   const T x31 = x9 | x30;
  142|  26.1M|   const T x32 = x29 ^ x31;
  143|       |
  144|  26.1M|   const T x33 = x11 ^ x18;
  145|  26.1M|   const T x34 = x25 ^ x33;
  146|  26.1M|   const T x35 = x31 & x34;
  147|  26.1M|   const T x36 = x1 & x29;
  148|  26.1M|   const T x37 = x35 ^ x36;
  149|  26.1M|   const T x38 = x37 | a4;
  150|  26.1M|   const T x39 = x38 ^ x32;
  151|  26.1M|   out3 ^= x39;
  152|       |
  153|  26.1M|   const T x40 = x37 & ~x22;
  154|  26.1M|   const T x41 = x16 | x30;
  155|  26.1M|   const T x42 = x40 ^ x41;
  156|  26.1M|   const T x43 = x8 | a4;
  157|  26.1M|   const T x44 = x43 ^ x42;
  158|  26.1M|   out4 ^= x44;
  159|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox3ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  162|  26.1M|BOTAN_FORCE_INLINE void SBox3(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  163|  26.1M|   const T x1 = a1 & ~a2;
  164|  26.1M|   const T x2 = a3 ^ a6;
  165|  26.1M|   const T x3 = x1 | x2;
  166|  26.1M|   const T x4 = a4 ^ a6;
  167|  26.1M|   const T x5 = x4 & ~a1;
  168|  26.1M|   const T x6 = x3 ^ x5;
  169|       |
  170|  26.1M|   const T x7 = a2 ^ x2;
  171|  26.1M|   const T x8 = x7 & ~a6;
  172|  26.1M|   const T x9 = x3 ^ x8;
  173|  26.1M|   const T x10 = x6 & ~x9;
  174|       |
  175|  26.1M|   const T x11 = a6 & x6;
  176|  26.1M|   const T x12 = a4 | x11;
  177|  26.1M|   const T x13 = a1 & x12;
  178|  26.1M|   const T x14 = x7 ^ x13;
  179|  26.1M|   const T x15 = x6 & ~a5;
  180|  26.1M|   const T x16 = x15 ^ x14;
  181|  26.1M|   out4 ^= x16;
  182|       |
  183|  26.1M|   const T x17 = x2 & x4;
  184|  26.1M|   const T x18 = a1 ^ a4;
  185|  26.1M|   const T x19 = x9 ^ x18;
  186|  26.1M|   const T x20 = a3 | x19;
  187|  26.1M|   const T x21 = x20 & ~x17;
  188|       |
  189|  26.1M|   const T x22 = x5 | x18;
  190|  26.1M|   const T x23 = x14 & ~x22;
  191|  26.1M|   const T x24 = a4 & a6;
  192|  26.1M|   const T x25 = x24 & ~a2;
  193|  26.1M|   const T x26 = x23 ^ x25;
  194|       |
  195|  26.1M|   const T x27 = x9 & x26;
  196|  26.1M|   const T x28 = x7 | x24;
  197|  26.1M|   const T x29 = x28 & ~x27;
  198|  26.1M|   const T x30 = a1 ^ x29;
  199|  26.1M|   const T x31 = x21 & a5;
  200|  26.1M|   const T x32 = x31 ^ x30;
  201|  26.1M|   out2 ^= x32;
  202|       |
  203|  26.1M|   const T x33 = x6 & ~a2;
  204|  26.1M|   const T x34 = x33 & ~a3;
  205|  26.1M|   const T x35 = ~x7;
  206|  26.1M|   const T x36 = x22 ^ x35;
  207|  26.1M|   const T x37 = x34 ^ x36;
  208|  26.1M|   const T x38 = a5 & ~x10;
  209|  26.1M|   const T x39 = x38 ^ x37;
  210|  26.1M|   out1 ^= x39;
  211|       |
  212|  26.1M|   const T x40 = x34 | x36;
  213|  26.1M|   const T x41 = x5 | x33;
  214|  26.1M|   const T x42 = x40 ^ x41;
  215|  26.1M|   const T x43 = a4 & ~x6;
  216|  26.1M|   const T x44 = x42 | x43;
  217|  26.1M|   const T x45 = a5 & ~x26;
  218|  26.1M|   const T x46 = x45 ^ x44;
  219|  26.1M|   out3 ^= x46;
  220|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox4ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  223|  26.1M|BOTAN_FORCE_INLINE void SBox4(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  224|  26.1M|   const T x1 = a1 ^ a3;
  225|  26.1M|   const T x2 = a3 ^ a5;
  226|  26.1M|   const T x3 = a2 | a4;
  227|  26.1M|   const T x4 = a5 ^ x3;
  228|  26.1M|   const T x5 = x2 & ~x4;
  229|  26.1M|   const T x6 = x2 & ~a2;
  230|  26.1M|   const T x7 = a4 ^ x6;
  231|  26.1M|   const T x8 = x1 | x7;
  232|  26.1M|   const T x9 = x8 & ~x5;
  233|  26.1M|   const T x10 = a2 ^ x9;
  234|       |
  235|  26.1M|   const T x11 = x7 & x10;
  236|  26.1M|   const T x12 = x2 & ~x11;
  237|  26.1M|   const T x13 = x1 ^ x10;
  238|  26.1M|   const T x14 = x13 & ~x12;
  239|  26.1M|   const T x15 = x5 ^ x14;
  240|       |
  241|  26.1M|   const T x16 = a2 ^ a4;
  242|  26.1M|   const T x17 = a5 | x6;
  243|  26.1M|   const T x18 = x13 ^ x17;
  244|  26.1M|   const T x19 = x18 & ~x16;
  245|  26.1M|   const T x20 = x9 ^ x19;
  246|  26.1M|   const T x21 = a6 & ~x15;
  247|  26.1M|   const T x22 = x21 ^ x20;
  248|  26.1M|   out1 ^= x22;
  249|       |
  250|  26.1M|   const T x23 = ~x20;
  251|  26.1M|   const T x24 = x15 & ~a6;
  252|  26.1M|   const T x25 = x24 ^ x23;
  253|  26.1M|   out2 ^= x25;
  254|       |
  255|  26.1M|   const T x26 = x15 ^ x23;
  256|  26.1M|   const T x27 = x26 & ~x16;
  257|  26.1M|   const T x28 = x11 | x27;
  258|  26.1M|   const T x29 = x18 ^ x28;
  259|  26.1M|   const T x30 = x10 | a6;
  260|  26.1M|   const T x31 = x30 ^ x29;
  261|  26.1M|   out3 ^= x31;
  262|       |
  263|  26.1M|   const T x32 = a6 & x10;
  264|  26.1M|   const T x33 = x32 ^ x29;
  265|  26.1M|   out4 ^= x33;
  266|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox5ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  269|  26.1M|BOTAN_FORCE_INLINE void SBox5(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  270|  26.1M|   const T x1 = a1 | a3;
  271|  26.1M|   const T x2 = x1 & ~a6;
  272|  26.1M|   const T x3 = a1 ^ x2;
  273|  26.1M|   const T x4 = a3 ^ x3;
  274|  26.1M|   const T x5 = a4 | x4;
  275|       |
  276|  26.1M|   const T x6 = x2 & ~a4;
  277|  26.1M|   const T x7 = a3 ^ x6;
  278|  26.1M|   const T x8 = a5 & x7;
  279|  26.1M|   const T x9 = a1 | x4;
  280|  26.1M|   const T x10 = x8 ^ x9;
  281|  26.1M|   const T x11 = a4 ^ x10;
  282|       |
  283|  26.1M|   const T x12 = a6 ^ x11;
  284|  26.1M|   const T x13 = x3 | x12;
  285|  26.1M|   const T x14 = a5 & x13;
  286|  26.1M|   const T x15 = x3 ^ x14;
  287|  26.1M|   const T x16 = a4 & x9;
  288|  26.1M|   const T x17 = x15 ^ x16;
  289|       |
  290|  26.1M|   const T x18 = x13 & ~a1;
  291|  26.1M|   const T x19 = x7 ^ x18;
  292|  26.1M|   const T x20 = a5 ^ x5;
  293|  26.1M|   const T x21 = x20 & ~x19;
  294|  26.1M|   const T x22 = ~x21;
  295|  26.1M|   const T x23 = x22 & ~a2;
  296|  26.1M|   const T x24 = x23 ^ x11;
  297|  26.1M|   out3 ^= x24;
  298|       |
  299|  26.1M|   const T x25 = x7 & ~x14;
  300|  26.1M|   const T x26 = x18 ^ x20;
  301|  26.1M|   const T x27 = x17 | x26;
  302|  26.1M|   const T x28 = x27 & ~x25;
  303|  26.1M|   const T x29 = x5 & ~x28;
  304|       |
  305|  26.1M|   const T x30 = x12 & x28;
  306|  26.1M|   const T x31 = x20 ^ x30;
  307|  26.1M|   const T x32 = x7 & x9;
  308|  26.1M|   const T x33 = x31 | x32;
  309|  26.1M|   const T x34 = x14 ^ x33;
  310|  26.1M|   const T x35 = x34 & a2;
  311|  26.1M|   const T x36 = x35 ^ x17;
  312|  26.1M|   out4 ^= x36;
  313|       |
  314|  26.1M|   const T x37 = x1 ^ x28;
  315|  26.1M|   const T x38 = a1 ^ x37;
  316|  26.1M|   const T x39 = a4 & x31;
  317|  26.1M|   const T x40 = x38 ^ x39;
  318|  26.1M|   const T x41 = x29 | a2;
  319|  26.1M|   const T x42 = x41 ^ x40;
  320|  26.1M|   out1 ^= x42;
  321|       |
  322|  26.1M|   const T x43 = x5 ^ x7;
  323|  26.1M|   const T x44 = x43 & ~x40;
  324|  26.1M|   const T x45 = x3 ^ x31;
  325|  26.1M|   const T x46 = x44 ^ x45;
  326|  26.1M|   const T x47 = x5 & a2;
  327|  26.1M|   const T x48 = x47 ^ x46;
  328|  26.1M|   out2 ^= x48;
  329|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox6ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  332|  26.1M|BOTAN_FORCE_INLINE void SBox6(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  333|  26.1M|   const T x1 = a2 ^ a5;
  334|       |
  335|  26.1M|   const T x2 = a2 | a6;
  336|  26.1M|   const T x3 = a1 & x2;
  337|  26.1M|   const T x4 = x1 ^ x3;
  338|  26.1M|   const T x5 = a6 ^ x4;
  339|  26.1M|   const T x6 = a5 & ~x5;
  340|       |
  341|  26.1M|   const T x7 = a1 & x5;
  342|  26.1M|   const T x8 = a2 ^ x7;
  343|  26.1M|   const T x9 = a1 ^ a3;
  344|  26.1M|   const T x10 = x8 | x9;
  345|  26.1M|   const T x11 = x4 ^ x10;
  346|       |
  347|  26.1M|   const T x12 = a3 & x11;
  348|  26.1M|   const T x13 = x12 & ~a6;
  349|  26.1M|   const T x14 = x6 | x8;
  350|  26.1M|   const T x15 = x13 ^ x14;
  351|  26.1M|   const T x16 = x15 & a4;
  352|  26.1M|   const T x17 = x16 ^ x11;
  353|  26.1M|   out4 ^= x17;
  354|       |
  355|  26.1M|   const T x18 = a2 ^ x10;
  356|  26.1M|   const T x19 = a6 & ~x18;
  357|  26.1M|   const T x20 = a3 ^ x19;
  358|  26.1M|   const T x21 = a5 & ~x12;
  359|  26.1M|   const T x22 = x20 | x21;
  360|       |
  361|  26.1M|   const T x23 = a2 | x9;
  362|  26.1M|   const T x24 = x15 ^ x23;
  363|  26.1M|   const T x25 = x3 | x22;
  364|  26.1M|   const T x26 = x24 ^ x25;
  365|       |
  366|  26.1M|   const T x27 = a1 | x11;
  367|  26.1M|   const T x28 = x14 & x27;
  368|  26.1M|   const T x29 = x20 ^ x28;
  369|  26.1M|   const T x30 = x29 & ~x13;
  370|  26.1M|   const T x31 = x6 | a4;
  371|  26.1M|   const T x32 = x31 ^ x30;
  372|  26.1M|   out3 ^= x32;
  373|       |
  374|  26.1M|   const T x33 = x4 ^ x29;
  375|  26.1M|   const T x34 = a5 & ~x33;
  376|  26.1M|   const T x35 = ~x23;
  377|  26.1M|   const T x36 = x18 ^ x35;
  378|  26.1M|   const T x37 = x34 ^ x36;
  379|  26.1M|   const T x38 = x37 & ~a4;
  380|  26.1M|   const T x39 = x38 ^ x26;
  381|  26.1M|   out2 ^= x39;
  382|       |
  383|  26.1M|   const T x40 = a6 ^ x7;
  384|  26.1M|   const T x41 = a1 ^ x20;
  385|  26.1M|   const T x42 = x40 & x41;
  386|  26.1M|   const T x43 = x12 ^ x36;
  387|  26.1M|   const T x44 = x42 ^ x43;
  388|  26.1M|   const T x45 = x22 & ~a4;
  389|  26.1M|   const T x46 = x45 ^ x44;
  390|  26.1M|   out1 ^= x46;
  391|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox7ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  394|  26.1M|BOTAN_FORCE_INLINE void SBox7(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  395|  26.1M|   const T x1 = a4 ^ a5;
  396|  26.1M|   const T x2 = a3 ^ x1;
  397|  26.1M|   const T x3 = a6 & x2;
  398|  26.1M|   const T x4 = a4 & x1;
  399|  26.1M|   const T x5 = a2 ^ x4;
  400|  26.1M|   const T x6 = x3 & x5;
  401|       |
  402|  26.1M|   const T x7 = a6 & x4;
  403|  26.1M|   const T x8 = a3 ^ x7;
  404|  26.1M|   const T x9 = x5 | x8;
  405|  26.1M|   const T x10 = a6 ^ x1;
  406|  26.1M|   const T x11 = x9 ^ x10;
  407|  26.1M|   const T x12 = a1 & ~x6;
  408|  26.1M|   const T x13 = x12 ^ x11;
  409|  26.1M|   out4 ^= x13;
  410|       |
  411|  26.1M|   const T x14 = a5 & ~x2;
  412|  26.1M|   const T x15 = x5 | x14;
  413|  26.1M|   const T x16 = x3 ^ x8;
  414|  26.1M|   const T x17 = x15 ^ x16;
  415|       |
  416|  26.1M|   const T x18 = x3 ^ x10;
  417|  26.1M|   const T x19 = a4 & ~x18;
  418|  26.1M|   const T x20 = x5 & ~x19;
  419|  26.1M|   const T x21 = a5 ^ x16;
  420|  26.1M|   const T x22 = x20 ^ x21;
  421|       |
  422|  26.1M|   const T x23 = x18 & ~x7;
  423|  26.1M|   const T x24 = x19 | x23;
  424|  26.1M|   const T x25 = a2 ^ x9;
  425|  26.1M|   const T x26 = x22 & x25;
  426|  26.1M|   const T x27 = x24 ^ x26;
  427|  26.1M|   const T x28 = x27 & a1;
  428|  26.1M|   const T x29 = x28 ^ x22;
  429|  26.1M|   out3 ^= x29;
  430|       |
  431|  26.1M|   const T x30 = x5 & ~a3;
  432|  26.1M|   const T x31 = x23 | x30;
  433|  26.1M|   const T x32 = x4 | x22;
  434|  26.1M|   const T x33 = x31 & x32;
  435|  26.1M|   const T x34 = x27 ^ x33;
  436|       |
  437|  26.1M|   const T x35 = x17 | x24;
  438|  26.1M|   const T x36 = x14 ^ x35;
  439|  26.1M|   const T x37 = a6 & x36;
  440|  26.1M|   const T x38 = x33 ^ x37;
  441|  26.1M|   const T x39 = x38 & ~a1;
  442|  26.1M|   const T x40 = x39 ^ x17;
  443|  26.1M|   out1 ^= x40;
  444|       |
  445|  26.1M|   const T x41 = ~x37;
  446|  26.1M|   const T x42 = a2 | x41;
  447|  26.1M|   const T x43 = x17 ^ x33;
  448|  26.1M|   const T x44 = x42 ^ x43;
  449|  26.1M|   const T x45 = x34 | a1;
  450|  26.1M|   const T x46 = x45 ^ x44;
  451|  26.1M|   out2 ^= x46;
  452|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_15SBox8ITkNS0_9BitsliceTEjEEvT_S2_S2_S2_S2_S2_RS2_S3_S3_S3_:
  455|  26.1M|BOTAN_FORCE_INLINE void SBox8(T a1, T a2, T a3, T a4, T a5, T a6, T& out1, T& out2, T& out3, T& out4) {
  456|  26.1M|   const T x1 = a3 & ~a2;
  457|  26.1M|   const T x2 = a5 & ~a3;
  458|  26.1M|   const T x3 = a4 ^ x2;
  459|  26.1M|   const T x4 = a1 & x3;
  460|  26.1M|   const T x5 = x4 & ~x1;
  461|       |
  462|  26.1M|   const T x6 = a2 & ~x3;
  463|  26.1M|   const T x7 = a1 | x6;
  464|  26.1M|   const T x8 = a2 & ~a3;
  465|  26.1M|   const T x9 = a5 ^ x8;
  466|  26.1M|   const T x10 = x7 & x9;
  467|  26.1M|   const T x11 = x4 | x10;
  468|       |
  469|  26.1M|   const T x12 = ~x3;
  470|  26.1M|   const T x13 = x10 ^ x12;
  471|  26.1M|   const T x14 = a3 & ~x7;
  472|  26.1M|   const T x15 = x13 ^ x14;
  473|  26.1M|   const T x16 = x1 ^ x15;
  474|  26.1M|   const T x17 = x5 | a6;
  475|  26.1M|   const T x18 = x17 ^ x16;
  476|  26.1M|   out2 ^= x18;
  477|       |
  478|  26.1M|   const T x19 = a1 ^ x16;
  479|  26.1M|   const T x20 = a5 & x19;
  480|  26.1M|   const T x21 = a2 ^ x15;
  481|  26.1M|   const T x22 = x20 ^ x21;
  482|  26.1M|   const T x23 = x6 ^ x22;
  483|       |
  484|  26.1M|   const T x24 = x11 ^ x22;
  485|  26.1M|   const T x25 = a2 | x24;
  486|  26.1M|   const T x26 = a5 ^ x19;
  487|  26.1M|   const T x27 = x25 ^ x26;
  488|  26.1M|   const T x28 = x11 & a6;
  489|  26.1M|   const T x29 = x28 ^ x27;
  490|  26.1M|   out3 ^= x29;
  491|       |
  492|  26.1M|   const T x30 = x9 ^ x23;
  493|  26.1M|   const T x31 = a4 | x21;
  494|  26.1M|   const T x32 = x30 ^ x31;
  495|  26.1M|   const T x33 = a1 ^ x32;
  496|  26.1M|   const T x34 = x33 & a6;
  497|  26.1M|   const T x35 = x34 ^ x23;
  498|  26.1M|   out4 ^= x35;
  499|       |
  500|  26.1M|   const T x36 = x30 & ~a4;
  501|  26.1M|   const T x37 = x27 & x36;
  502|  26.1M|   const T x38 = x5 ^ x32;
  503|  26.1M|   const T x39 = x37 ^ x38;
  504|  26.1M|   const T x40 = x39 | a6;
  505|  26.1M|   const T x41 = x40 ^ x23;
  506|  26.1M|   out1 ^= x41;
  507|  26.1M|}
des.cpp:_ZN5Botan12_GLOBAL__N_113transpose_outEPhPKjm:
  567|   544k|void transpose_out(uint8_t out[], const uint32_t B[64], size_t n_blocks) {
  568|       |   // clang-format off
  569|   544k|   static constexpr uint8_t FP[64] = {
  570|   544k|      39, 7, 47, 15, 55, 23, 63, 31,
  571|   544k|      38, 6, 46, 14, 54, 22, 62, 30,
  572|   544k|      37, 5, 45, 13, 53, 21, 61, 29,
  573|   544k|      36, 4, 44, 12, 52, 20, 60, 28,
  574|   544k|      35, 3, 43, 11, 51, 19, 59, 27,
  575|   544k|      34, 2, 42, 10, 50, 18, 58, 26,
  576|   544k|      33, 1, 41,  9, 49, 17, 57, 25,
  577|   544k|      32, 0, 40,  8, 48, 16, 56, 24
  578|   544k|   };
  579|       |   // clang-format on
  580|       |
  581|   544k|   uint64_t M[32];
  582|  17.9M|   for(size_t i = 0; i != 32; ++i) {
  ------------------
  |  Branch (582:22): [True: 17.4M, False: 544k]
  ------------------
  583|       |      // XOR with 32 here absorbs the DES output swap into the FP
  584|  17.4M|      M[i] = (static_cast<uint64_t>(B[FP[31 - i] ^ 32]) << 32) | B[FP[63 - i] ^ 32];
  585|  17.4M|   }
  586|       |
  587|   544k|   des_transpose(M);
  588|       |
  589|  1.61M|   for(size_t i = 0; i != n_blocks; ++i) {
  ------------------
  |  Branch (589:22): [True: 1.07M, False: 544k]
  ------------------
  590|  1.07M|      store_be(out + i * 8, M[i]);
  591|  1.07M|   }
  592|   544k|}
des.cpp:_ZN5Botan12_GLOBAL__N_111des_decryptEPjS1_PKj:
  645|   544k|void des_decrypt(uint32_t L[32], uint32_t R[32], const uint32_t round_key[]) {
  646|  4.89M|   for(size_t round = 16; round > 0; round -= 2) {
  ------------------
  |  Branch (646:27): [True: 4.35M, False: 544k]
  ------------------
  647|  4.35M|      des_round(L, R, &round_key[(round - 1) * 48]);
  648|  4.35M|      des_round(R, L, &round_key[(round - 2) * 48]);
  649|  4.35M|   }
  650|   544k|}
des.cpp:_ZN5Botan12_GLOBAL__N_116des_key_scheduleEPjPKh:
  656|  1.11k|void des_key_schedule(uint32_t round_key[], const uint8_t key[8]) {
  657|  1.11k|   static const uint8_t ROT[16] = {1, 1, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 1};
  658|       |
  659|  1.11k|   uint32_t C = ((key[7] & 0x80) << 20) | ((key[6] & 0x80) << 19) | ((key[5] & 0x80) << 18) | ((key[4] & 0x80) << 17) |
  660|  1.11k|                ((key[3] & 0x80) << 16) | ((key[2] & 0x80) << 15) | ((key[1] & 0x80) << 14) | ((key[0] & 0x80) << 13) |
  661|  1.11k|                ((key[7] & 0x40) << 13) | ((key[6] & 0x40) << 12) | ((key[5] & 0x40) << 11) | ((key[4] & 0x40) << 10) |
  662|  1.11k|                ((key[3] & 0x40) << 9) | ((key[2] & 0x40) << 8) | ((key[1] & 0x40) << 7) | ((key[0] & 0x40) << 6) |
  663|  1.11k|                ((key[7] & 0x20) << 6) | ((key[6] & 0x20) << 5) | ((key[5] & 0x20) << 4) | ((key[4] & 0x20) << 3) |
  664|  1.11k|                ((key[3] & 0x20) << 2) | ((key[2] & 0x20) << 1) | ((key[1] & 0x20)) | ((key[0] & 0x20) >> 1) |
  665|  1.11k|                ((key[7] & 0x10) >> 1) | ((key[6] & 0x10) >> 2) | ((key[5] & 0x10) >> 3) | ((key[4] & 0x10) >> 4);
  666|  1.11k|   uint32_t D = ((key[7] & 0x02) << 26) | ((key[6] & 0x02) << 25) | ((key[5] & 0x02) << 24) | ((key[4] & 0x02) << 23) |
  667|  1.11k|                ((key[3] & 0x02) << 22) | ((key[2] & 0x02) << 21) | ((key[1] & 0x02) << 20) | ((key[0] & 0x02) << 19) |
  668|  1.11k|                ((key[7] & 0x04) << 17) | ((key[6] & 0x04) << 16) | ((key[5] & 0x04) << 15) | ((key[4] & 0x04) << 14) |
  669|  1.11k|                ((key[3] & 0x04) << 13) | ((key[2] & 0x04) << 12) | ((key[1] & 0x04) << 11) | ((key[0] & 0x04) << 10) |
  670|  1.11k|                ((key[7] & 0x08) << 8) | ((key[6] & 0x08) << 7) | ((key[5] & 0x08) << 6) | ((key[4] & 0x08) << 5) |
  671|  1.11k|                ((key[3] & 0x08) << 4) | ((key[2] & 0x08) << 3) | ((key[1] & 0x08) << 2) | ((key[0] & 0x08) << 1) |
  672|  1.11k|                ((key[3] & 0x10) >> 1) | ((key[2] & 0x10) >> 2) | ((key[1] & 0x10) >> 3) | ((key[0] & 0x10) >> 4);
  673|       |
  674|  1.11k|   static const uint8_t PC2_C[24] = {13, 16, 10, 23, 0,  4, 2,  27, 14, 5,  20, 9,
  675|  1.11k|                                     22, 18, 11, 3,  25, 7, 15, 6,  26, 19, 12, 1};
  676|       |
  677|  1.11k|   static const uint8_t PC2_D[24] = {12, 23, 2,  8,  18, 26, 1,  11, 22, 16, 4, 19,
  678|  1.11k|                                     15, 20, 10, 27, 5,  24, 17, 13, 21, 7,  0, 3};
  679|       |
  680|  18.8k|   for(size_t i = 0; i != 16; ++i) {
  ------------------
  |  Branch (680:22): [True: 17.7k, False: 1.11k]
  ------------------
  681|  17.7k|      C = ((C << ROT[i]) | (C >> (28 - ROT[i]))) & 0x0FFFFFFF;
  682|  17.7k|      D = ((D << ROT[i]) | (D >> (28 - ROT[i]))) & 0x0FFFFFFF;
  683|       |
  684|  17.7k|      uint32_t* rk = &round_key[i * 48];
  685|       |
  686|   444k|      for(size_t j = 0; j < 24; ++j) {
  ------------------
  |  Branch (686:25): [True: 426k, False: 17.7k]
  ------------------
  687|   426k|         const uint32_t bit = (C >> (27 - PC2_C[j])) & 1;
  688|   426k|         rk[j] = static_cast<uint32_t>(0) - bit;
  689|   426k|      }
  690|       |
  691|   444k|      for(size_t j = 0; j < 24; ++j) {
  ------------------
  |  Branch (691:25): [True: 426k, False: 17.7k]
  ------------------
  692|   426k|         const uint32_t bit = (D >> (27 - PC2_D[j])) & 1;
  693|   426k|         rk[24 + j] = static_cast<uint32_t>(0) - bit;
  694|   426k|      }
  695|  17.7k|   }
  696|  1.11k|}

_ZNK5Botan4IDEA11parallelismEv:
  108|  2.89k|size_t IDEA::parallelism() const {
  109|       |#if defined(BOTAN_HAS_IDEA_AVX2)
  110|       |   if(CPUID::has(CPUID::Feature::AVX2)) {
  111|       |      return 16;
  112|       |   }
  113|       |#endif
  114|       |
  115|       |#if defined(BOTAN_HAS_IDEA_SSE2)
  116|       |   if(CPUID::has(CPUID::Feature::SSE2)) {
  117|       |      return 8;
  118|       |   }
  119|       |#endif
  120|       |
  121|  2.89k|   return 1;
  122|  2.89k|}
_ZNK5Botan4IDEA9encrypt_nEPKhPhm:
  143|   727k|void IDEA::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  144|   727k|   assert_key_material_set();
  145|       |
  146|       |#if defined(BOTAN_HAS_IDEA_AVX2)
  147|       |   if(CPUID::has(CPUID::Feature::AVX2)) {
  148|       |      while(blocks >= 16) {
  149|       |         avx2_idea_op_16(in, out, m_EK.data());
  150|       |         in += 16 * BLOCK_SIZE;
  151|       |         out += 16 * BLOCK_SIZE;
  152|       |         blocks -= 16;
  153|       |      }
  154|       |   }
  155|       |#endif
  156|       |
  157|       |#if defined(BOTAN_HAS_IDEA_SSE2)
  158|       |   if(CPUID::has(CPUID::Feature::SSE2)) {
  159|       |      while(blocks >= 8) {
  160|       |         sse2_idea_op_8(in, out, m_EK.data());
  161|       |         in += 8 * BLOCK_SIZE;
  162|       |         out += 8 * BLOCK_SIZE;
  163|       |         blocks -= 8;
  164|       |      }
  165|       |   }
  166|       |#endif
  167|       |
  168|   727k|   idea_op(in, out, blocks, m_EK.data());
  169|   727k|}
_ZNK5Botan4IDEA19has_keying_materialEv:
  202|  1.00M|bool IDEA::has_keying_material() const {
  203|  1.00M|   return !m_EK.empty();
  204|  1.00M|}
_ZN5Botan4IDEA12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  209|  1.64k|void IDEA::key_schedule(std::span<const uint8_t> key) {
  210|  1.64k|   m_EK.resize(52);
  211|  1.64k|   m_DK.resize(52);
  212|       |
  213|  1.64k|   CT::poison(key.data(), 16);
  214|  1.64k|   CT::poison(m_EK.data(), 52);
  215|  1.64k|   CT::poison(m_DK.data(), 52);
  216|       |
  217|  1.64k|   secure_vector<uint64_t> K(2);
  218|       |
  219|  1.64k|   K[0] = load_be<uint64_t>(key.data(), 0);
  220|  1.64k|   K[1] = load_be<uint64_t>(key.data(), 1);
  221|       |
  222|  11.4k|   for(size_t off = 0; off != 48; off += 8) {
  ------------------
  |  Branch (222:24): [True: 9.84k, False: 1.64k]
  ------------------
  223|  88.5k|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (223:25): [True: 78.7k, False: 9.84k]
  ------------------
  224|  78.7k|         m_EK[off + i] = static_cast<uint16_t>(K[i / 4] >> (48 - 16 * (i % 4)));
  225|  78.7k|      }
  226|       |
  227|  9.84k|      const uint64_t Kx = (K[0] >> 39);
  228|  9.84k|      const uint64_t Ky = (K[1] >> 39);
  229|       |
  230|  9.84k|      K[0] = (K[0] << 25) | Ky;
  231|  9.84k|      K[1] = (K[1] << 25) | Kx;
  232|  9.84k|   }
  233|       |
  234|  8.20k|   for(size_t i = 0; i != 4; ++i) {
  ------------------
  |  Branch (234:22): [True: 6.56k, False: 1.64k]
  ------------------
  235|  6.56k|      m_EK[48 + i] = static_cast<uint16_t>(K[i / 4] >> (48 - 16 * (i % 4)));
  236|  6.56k|   }
  237|       |
  238|  1.64k|   m_DK[0] = mul_inv(m_EK[48]);
  239|  1.64k|   m_DK[1] = -m_EK[49];
  240|  1.64k|   m_DK[2] = -m_EK[50];
  241|  1.64k|   m_DK[3] = mul_inv(m_EK[51]);
  242|       |
  243|  14.7k|   for(size_t i = 0; i != 8 * 6; i += 6) {
  ------------------
  |  Branch (243:22): [True: 13.1k, False: 1.64k]
  ------------------
  244|  13.1k|      m_DK[i + 4] = m_EK[46 - i];
  245|  13.1k|      m_DK[i + 5] = m_EK[47 - i];
  246|  13.1k|      m_DK[i + 6] = mul_inv(m_EK[42 - i]);
  247|  13.1k|      m_DK[i + 7] = -m_EK[44 - i];
  248|  13.1k|      m_DK[i + 8] = -m_EK[43 - i];
  249|  13.1k|      m_DK[i + 9] = mul_inv(m_EK[45 - i]);
  250|  13.1k|   }
  251|       |
  252|  1.64k|   std::swap(m_DK[49], m_DK[50]);
  253|       |
  254|  1.64k|   CT::unpoison(key.data(), 16);
  255|  1.64k|   CT::unpoison(m_EK.data(), 52);
  256|  1.64k|   CT::unpoison(m_DK.data(), 52);
  257|  1.64k|}
_ZN5Botan4IDEA5clearEv:
  259|    708|void IDEA::clear() {
  260|    708|   zap(m_EK);
  261|    708|   zap(m_DK);
  262|    708|}
idea.cpp:_ZN5Botan12_GLOBAL__N_17idea_opEPKhPhmPKt:
   60|   727k|void idea_op(const uint8_t in[], uint8_t out[], size_t blocks, const uint16_t K[52]) {
   61|   727k|   const size_t BLOCK_SIZE = 8;
   62|       |
   63|   727k|   CT::poison(in, blocks * 8);
   64|   727k|   CT::poison(out, blocks * 8);
   65|   727k|   CT::poison(K, 52);
   66|       |
   67|  1.88M|   for(size_t i = 0; i < blocks; ++i) {
  ------------------
  |  Branch (67:22): [True: 1.16M, False: 727k]
  ------------------
   68|  1.16M|      uint16_t X1 = 0;
   69|  1.16M|      uint16_t X2 = 0;
   70|  1.16M|      uint16_t X3 = 0;
   71|  1.16M|      uint16_t X4 = 0;
   72|  1.16M|      load_be(in + BLOCK_SIZE * i, X1, X2, X3, X4);
   73|       |
   74|  10.4M|      for(size_t j = 0; j != 8; ++j) {
  ------------------
  |  Branch (74:25): [True: 9.30M, False: 1.16M]
  ------------------
   75|  9.30M|         X1 = mul(X1, K[6 * j + 0]);
   76|  9.30M|         X2 += K[6 * j + 1];
   77|  9.30M|         X3 += K[6 * j + 2];
   78|  9.30M|         X4 = mul(X4, K[6 * j + 3]);
   79|       |
   80|  9.30M|         const uint16_t T0 = X3;
   81|  9.30M|         X3 = mul(X3 ^ X1, K[6 * j + 4]);
   82|       |
   83|  9.30M|         const uint16_t T1 = X2;
   84|  9.30M|         X2 = mul((X2 ^ X4) + X3, K[6 * j + 5]);
   85|  9.30M|         X3 += X2;
   86|       |
   87|  9.30M|         X1 ^= X2;
   88|  9.30M|         X4 ^= X3;
   89|  9.30M|         X2 ^= T0;
   90|  9.30M|         X3 ^= T1;
   91|  9.30M|      }
   92|       |
   93|  1.16M|      X1 = mul(X1, K[48]);
   94|  1.16M|      X2 += K[50];
   95|  1.16M|      X3 += K[49];
   96|  1.16M|      X4 = mul(X4, K[51]);
   97|       |
   98|  1.16M|      store_be(out + BLOCK_SIZE * i, X1, X3, X2, X4);
   99|  1.16M|   }
  100|       |
  101|   727k|   CT::unpoison(in, blocks * 8);
  102|   727k|   CT::unpoison(out, blocks * 8);
  103|   727k|   CT::unpoison(K, 52);
  104|   727k|}
idea.cpp:_ZN5Botan12_GLOBAL__N_13mulEtt:
   24|  40.4M|inline uint16_t mul(uint16_t x, uint16_t y) {
   25|  40.4M|   uint32_t P = static_cast<uint32_t>(x) * y;
   26|  40.4M|   const uint16_t P_is_zero = static_cast<uint16_t>(ct_is_zero(P));
   27|       |
   28|  40.4M|   P = (P & 0xFFFF) - (P >> 16);
   29|  40.4M|   const uint16_t R1 = static_cast<uint16_t>(P - (P >> 16));
   30|  40.4M|   const uint16_t R0 = 1 - x - y;
   31|       |
   32|  40.4M|   return choose(P_is_zero, R0, R1);
   33|  40.4M|}
idea.cpp:_ZN5Botan12_GLOBAL__N_17mul_invEt:
   46|  29.5k|uint16_t mul_inv(uint16_t x) {
   47|  29.5k|   uint16_t y = x;
   48|       |
   49|   472k|   for(size_t i = 0; i != 15; ++i) {
  ------------------
  |  Branch (49:22): [True: 442k, False: 29.5k]
  ------------------
   50|   442k|      y = mul(y, y);  // square
   51|   442k|      y = mul(y, x);
   52|   442k|   }
   53|       |
   54|  29.5k|   return y;
   55|  29.5k|}

_ZNK5Botan3SM49encrypt_nEPKhPhm:
  159|   937k|void SM4::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  160|   937k|   assert_key_material_set();
  161|       |
  162|       |#if defined(BOTAN_HAS_SM4_ARMV8)
  163|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  164|       |      return sm4_armv8_encrypt(in, out, blocks);
  165|       |   }
  166|       |#endif
  167|       |
  168|       |#if defined(BOTAN_HAS_SM4_X86)
  169|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  170|       |      return sm4_x86_encrypt(in, out, blocks);
  171|       |   }
  172|       |#endif
  173|       |
  174|       |#if defined(BOTAN_HAS_SM4_AVX512_GFNI)
  175|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  176|       |      return sm4_avx512_gfni_encrypt(in, out, blocks);
  177|       |   }
  178|       |#endif
  179|       |
  180|       |#if defined(BOTAN_HAS_SM4_GFNI)
  181|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  182|       |      return sm4_gfni_encrypt(in, out, blocks);
  183|       |   }
  184|       |#endif
  185|       |
  186|       |#if defined(BOTAN_HAS_SM4_HWAES)
  187|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  188|       |      return sm4_hwaes_encrypt(in, out, blocks);
  189|       |   }
  190|       |#endif
  191|       |
  192|  1.41M|   while(blocks >= 2) {
  ------------------
  |  Branch (192:10): [True: 482k, False: 937k]
  ------------------
  193|   482k|      uint32_t B0 = load_be<uint32_t>(in, 0);
  194|   482k|      uint32_t B1 = load_be<uint32_t>(in, 1);
  195|   482k|      uint32_t B2 = load_be<uint32_t>(in, 2);
  196|   482k|      uint32_t B3 = load_be<uint32_t>(in, 3);
  197|       |
  198|   482k|      uint32_t C0 = load_be<uint32_t>(in, 4);
  199|   482k|      uint32_t C1 = load_be<uint32_t>(in, 5);
  200|   482k|      uint32_t C2 = load_be<uint32_t>(in, 6);
  201|   482k|      uint32_t C3 = load_be<uint32_t>(in, 7);
  202|       |
  203|   482k|      SM4_E<0>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T_slow);
  204|   482k|      SM4_E<1>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  205|   482k|      SM4_E<2>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  206|   482k|      SM4_E<3>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  207|   482k|      SM4_E<4>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  208|   482k|      SM4_E<5>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  209|   482k|      SM4_E<6>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  210|   482k|      SM4_E<7>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T_slow);
  211|       |
  212|   482k|      store_be(out, B3, B2, B1, B0, C3, C2, C1, C0);
  213|       |
  214|   482k|      in += 2 * BLOCK_SIZE;
  215|   482k|      out += 2 * BLOCK_SIZE;
  216|   482k|      blocks -= 2;
  217|   482k|   }
  218|       |
  219|  1.63M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (219:22): [True: 695k, False: 937k]
  ------------------
  220|   695k|      uint32_t B0 = load_be<uint32_t>(in, 0);
  221|   695k|      uint32_t B1 = load_be<uint32_t>(in, 1);
  222|   695k|      uint32_t B2 = load_be<uint32_t>(in, 2);
  223|   695k|      uint32_t B3 = load_be<uint32_t>(in, 3);
  224|       |
  225|   695k|      SM4_E<0>(B0, B1, B2, B3, m_RK, SM4_T_slow);
  226|   695k|      SM4_E<1>(B0, B1, B2, B3, m_RK, SM4_T);
  227|   695k|      SM4_E<2>(B0, B1, B2, B3, m_RK, SM4_T);
  228|   695k|      SM4_E<3>(B0, B1, B2, B3, m_RK, SM4_T);
  229|   695k|      SM4_E<4>(B0, B1, B2, B3, m_RK, SM4_T);
  230|   695k|      SM4_E<5>(B0, B1, B2, B3, m_RK, SM4_T);
  231|   695k|      SM4_E<6>(B0, B1, B2, B3, m_RK, SM4_T);
  232|   695k|      SM4_E<7>(B0, B1, B2, B3, m_RK, SM4_T_slow);
  233|       |
  234|   695k|      store_be(out, B3, B2, B1, B0);
  235|       |
  236|   695k|      in += BLOCK_SIZE;
  237|   695k|      out += BLOCK_SIZE;
  238|   695k|   }
  239|   937k|}
_ZNK5Botan3SM49decrypt_nEPKhPhm:
  244|  45.9k|void SM4::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  245|  45.9k|   assert_key_material_set();
  246|       |
  247|       |#if defined(BOTAN_HAS_SM4_ARMV8)
  248|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  249|       |      return sm4_armv8_decrypt(in, out, blocks);
  250|       |   }
  251|       |#endif
  252|       |
  253|       |#if defined(BOTAN_HAS_SM4_X86)
  254|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  255|       |      return sm4_x86_decrypt(in, out, blocks);
  256|       |   }
  257|       |#endif
  258|       |
  259|       |#if defined(BOTAN_HAS_SM4_AVX512_GFNI)
  260|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  261|       |      return sm4_avx512_gfni_decrypt(in, out, blocks);
  262|       |   }
  263|       |#endif
  264|       |
  265|       |#if defined(BOTAN_HAS_SM4_GFNI)
  266|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  267|       |      return sm4_gfni_decrypt(in, out, blocks);
  268|       |   }
  269|       |#endif
  270|       |
  271|       |#if defined(BOTAN_HAS_SM4_HWAES)
  272|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  273|       |      return sm4_hwaes_decrypt(in, out, blocks);
  274|       |   }
  275|       |#endif
  276|       |
  277|   137k|   while(blocks >= 2) {
  ------------------
  |  Branch (277:10): [True: 91.4k, False: 45.9k]
  ------------------
  278|  91.4k|      uint32_t B0 = load_be<uint32_t>(in, 0);
  279|  91.4k|      uint32_t B1 = load_be<uint32_t>(in, 1);
  280|  91.4k|      uint32_t B2 = load_be<uint32_t>(in, 2);
  281|  91.4k|      uint32_t B3 = load_be<uint32_t>(in, 3);
  282|       |
  283|  91.4k|      uint32_t C0 = load_be<uint32_t>(in, 4);
  284|  91.4k|      uint32_t C1 = load_be<uint32_t>(in, 5);
  285|  91.4k|      uint32_t C2 = load_be<uint32_t>(in, 6);
  286|  91.4k|      uint32_t C3 = load_be<uint32_t>(in, 7);
  287|       |
  288|  91.4k|      SM4_D<7>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T_slow);
  289|  91.4k|      SM4_D<6>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  290|  91.4k|      SM4_D<5>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  291|  91.4k|      SM4_D<4>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  292|  91.4k|      SM4_D<3>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  293|  91.4k|      SM4_D<2>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  294|  91.4k|      SM4_D<1>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T);
  295|  91.4k|      SM4_D<0>(B0, B1, B2, B3, C0, C1, C2, C3, m_RK, SM4_T_slow);
  296|       |
  297|  91.4k|      store_be(out, B3, B2, B1, B0, C3, C2, C1, C0);
  298|       |
  299|  91.4k|      in += 2 * BLOCK_SIZE;
  300|  91.4k|      out += 2 * BLOCK_SIZE;
  301|  91.4k|      blocks -= 2;
  302|  91.4k|   }
  303|       |
  304|  45.9k|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (304:22): [True: 92, False: 45.9k]
  ------------------
  305|     92|      uint32_t B0 = load_be<uint32_t>(in, 0);
  306|     92|      uint32_t B1 = load_be<uint32_t>(in, 1);
  307|     92|      uint32_t B2 = load_be<uint32_t>(in, 2);
  308|     92|      uint32_t B3 = load_be<uint32_t>(in, 3);
  309|       |
  310|     92|      SM4_D<7>(B0, B1, B2, B3, m_RK, SM4_T_slow);
  311|     92|      SM4_D<6>(B0, B1, B2, B3, m_RK, SM4_T);
  312|     92|      SM4_D<5>(B0, B1, B2, B3, m_RK, SM4_T);
  313|     92|      SM4_D<4>(B0, B1, B2, B3, m_RK, SM4_T);
  314|     92|      SM4_D<3>(B0, B1, B2, B3, m_RK, SM4_T);
  315|     92|      SM4_D<2>(B0, B1, B2, B3, m_RK, SM4_T);
  316|     92|      SM4_D<1>(B0, B1, B2, B3, m_RK, SM4_T);
  317|     92|      SM4_D<0>(B0, B1, B2, B3, m_RK, SM4_T_slow);
  318|       |
  319|     92|      store_be(out, B3, B2, B1, B0);
  320|       |
  321|     92|      in += BLOCK_SIZE;
  322|     92|      out += BLOCK_SIZE;
  323|     92|   }
  324|  45.9k|}
_ZNK5Botan3SM419has_keying_materialEv:
  326|  1.67M|bool SM4::has_keying_material() const {
  327|  1.67M|   return !m_RK.empty();
  328|  1.67M|}
_ZN5Botan3SM46SM4_TpEj:
  335|  65.5k|uint32_t SM4::SM4_Tp(uint32_t b) {
  336|       |#if defined(BOTAN_HAS_SM4_HWAES)
  337|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  338|       |      const uint32_t t = sm4_hwaes_sbox(b);
  339|       |      // L' linear transform
  340|       |      return t ^ rotl<13>(t) ^ rotl<23>(t);
  341|       |   }
  342|       |#endif
  343|       |
  344|  65.5k|   const uint8_t b0 = get_byte<0>(b);
  345|  65.5k|   const uint8_t b1 = get_byte<1>(b);
  346|  65.5k|   const uint8_t b2 = get_byte<2>(b);
  347|  65.5k|   const uint8_t b3 = get_byte<3>(b);
  348|       |
  349|  65.5k|   uint8_t t0 = 0;
  350|  65.5k|   uint8_t t1 = 0;
  351|  65.5k|   uint8_t t2 = 0;
  352|  65.5k|   uint8_t t3 = 0;
  353|  16.8M|   for(size_t i = 0; i != 256; ++i) {
  ------------------
  |  Branch (353:22): [True: 16.7M, False: 65.5k]
  ------------------
  354|  16.7M|      const uint8_t i8 = static_cast<uint8_t>(i);
  355|  16.7M|      const uint8_t s = SM4_SBOX[i];
  356|  16.7M|      t0 |= CT::Mask<uint8_t>::is_equal(i8, b0).if_set_return(s);
  357|  16.7M|      t1 |= CT::Mask<uint8_t>::is_equal(i8, b1).if_set_return(s);
  358|  16.7M|      t2 |= CT::Mask<uint8_t>::is_equal(i8, b2).if_set_return(s);
  359|  16.7M|      t3 |= CT::Mask<uint8_t>::is_equal(i8, b3).if_set_return(s);
  360|  16.7M|   }
  361|       |
  362|  65.5k|   const uint32_t t = make_uint32(t0, t1, t2, t3);
  363|       |   // L' linear transform
  364|  65.5k|   return t ^ rotl<13>(t) ^ rotl<23>(t);
  365|  65.5k|}
_ZN5Botan3SM412key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  367|  2.04k|void SM4::key_schedule(std::span<const uint8_t> key) {
  368|       |   // System parameter or family key
  369|  2.04k|   const uint32_t FK[4] = {0xa3b1bac6, 0x56aa3350, 0x677d9197, 0xb27022dc};
  370|       |
  371|  2.04k|   const uint32_t CK[32] = {0x00070E15, 0x1C232A31, 0x383F464D, 0x545B6269, 0x70777E85, 0x8C939AA1, 0xA8AFB6BD,
  372|  2.04k|                            0xC4CBD2D9, 0xE0E7EEF5, 0xFC030A11, 0x181F262D, 0x343B4249, 0x50575E65, 0x6C737A81,
  373|  2.04k|                            0x888F969D, 0xA4ABB2B9, 0xC0C7CED5, 0xDCE3EAF1, 0xF8FF060D, 0x141B2229, 0x30373E45,
  374|  2.04k|                            0x4C535A61, 0x686F767D, 0x848B9299, 0xA0A7AEB5, 0xBCC3CAD1, 0xD8DFE6ED, 0xF4FB0209,
  375|  2.04k|                            0x10171E25, 0x2C333A41, 0x484F565D, 0x646B7279};
  376|       |
  377|  2.04k|   uint32_t K0 = load_be<uint32_t>(key.data(), 0) ^ FK[0];
  378|  2.04k|   uint32_t K1 = load_be<uint32_t>(key.data(), 1) ^ FK[1];
  379|  2.04k|   uint32_t K2 = load_be<uint32_t>(key.data(), 2) ^ FK[2];
  380|  2.04k|   uint32_t K3 = load_be<uint32_t>(key.data(), 3) ^ FK[3];
  381|       |
  382|  2.04k|   m_RK.resize(32);
  383|       |
  384|  18.4k|   for(size_t i = 0; i != 32; i += 4) {
  ------------------
  |  Branch (384:22): [True: 16.3k, False: 2.04k]
  ------------------
  385|  16.3k|      K0 ^= SM4_Tp(K1 ^ K2 ^ K3 ^ CK[i + 0]);
  386|  16.3k|      K1 ^= SM4_Tp(K0 ^ K2 ^ K3 ^ CK[i + 1]);
  387|  16.3k|      K2 ^= SM4_Tp(K0 ^ K1 ^ K3 ^ CK[i + 2]);
  388|  16.3k|      K3 ^= SM4_Tp(K0 ^ K1 ^ K2 ^ CK[i + 3]);
  389|  16.3k|      m_RK[i + 0] = K0;
  390|  16.3k|      m_RK[i + 1] = K1;
  391|  16.3k|      m_RK[i + 2] = K2;
  392|  16.3k|      m_RK[i + 3] = K3;
  393|  16.3k|   }
  394|  2.04k|}
_ZN5Botan3SM45clearEv:
  396|    346|void SM4::clear() {
  397|    346|   zap(m_RK);
  398|    346|}
_ZNK5Botan3SM411parallelismEv:
  400|  4.05k|size_t SM4::parallelism() const {
  401|       |#if defined(BOTAN_HAS_SM4_ARMV8)
  402|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  403|       |      return 4;
  404|       |   }
  405|       |#endif
  406|       |
  407|       |#if defined(BOTAN_HAS_SM4_X86)
  408|       |   if(CPUID::has(CPUID::Feature::SM4)) {
  409|       |      return 8;
  410|       |   }
  411|       |#endif
  412|       |
  413|       |#if defined(BOTAN_HAS_SM4_AVX512_GFNI)
  414|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  415|       |      return 16;
  416|       |   }
  417|       |#endif
  418|       |
  419|       |#if defined(BOTAN_HAS_SM4_GFNI)
  420|       |   if(CPUID::has(CPUID::Feature::GFNI)) {
  421|       |      return 8;
  422|       |   }
  423|       |#endif
  424|       |
  425|       |#if defined(BOTAN_HAS_SM4_HWAES)
  426|       |   if(CPUID::has(CPUID::Feature::HW_AES)) {
  427|       |      return 4;
  428|       |   }
  429|       |#endif
  430|       |
  431|  4.05k|   return 1;
  432|  4.05k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_110SM4_T_slowEj:
   78|  14.7M|inline uint32_t SM4_T_slow(uint32_t b) {
   79|  14.7M|   const uint32_t t = make_uint32(
   80|  14.7M|      SM4_SBOX[get_byte<0>(b)], SM4_SBOX[get_byte<1>(b)], SM4_SBOX[get_byte<2>(b)], SM4_SBOX[get_byte<3>(b)]);
   81|       |
   82|       |   // L linear transform
   83|  14.7M|   return t ^ rotl<2>(t) ^ rotl<10>(t) ^ rotl<18>(t) ^ rotl<24>(t);
   84|  14.7M|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_TEj:
   86|  44.2M|inline uint32_t SM4_T(uint32_t b) {
   87|  44.2M|   const uint32_t s0 = SM4_SBOX_T[get_byte<0>(b)];
   88|  44.2M|   const uint32_t s1 = SM4_SBOX_T[get_byte<1>(b)];
   89|  44.2M|   const uint32_t s2 = SM4_SBOX_T[get_byte<2>(b)];
   90|  44.2M|   const uint32_t s3 = SM4_SBOX_T[get_byte<3>(b)];
   91|  44.2M|   return (s0) ^ rotr<8>(s1) ^ rotr<16>(s2) ^ rotr<24>(s3);
   92|  44.2M|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm0EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm1EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm2EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm3EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm4EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm5EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm6EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm7EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  113|   482k|                              F& f) {
  114|   482k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
  115|   482k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 0]);
  116|   482k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
  117|   482k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 1]);
  118|   482k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  119|   482k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 2]);
  120|   482k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  121|   482k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 3]);
  122|   482k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm0EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm1EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm2EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm3EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm4EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm5EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm6EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_EILm7EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
   96|   695k|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
   97|   695k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 0]);
   98|   695k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 1]);
   99|   695k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 2]);
  100|   695k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 3]);
  101|   695k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm7EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm6EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm5EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm4EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm3EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm2EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm1EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm0EFjjEEEvRjS3_S3_S3_S3_S3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  143|  91.4k|                              F& f) {
  144|  91.4k|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  145|  91.4k|   C0 ^= f(C1 ^ C2 ^ C3 ^ RK[4 * R + 3]);
  146|  91.4k|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  147|  91.4k|   C1 ^= f(C2 ^ C3 ^ C0 ^ RK[4 * R + 2]);
  148|  91.4k|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  149|  91.4k|   C2 ^= f(C3 ^ C0 ^ C1 ^ RK[4 * R + 1]);
  150|  91.4k|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  151|  91.4k|   C3 ^= f(C0 ^ C1 ^ C2 ^ RK[4 * R + 0]);
  152|  91.4k|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm7EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm6EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm5EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm4EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm3EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm2EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm1EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}
sm4.cpp:_ZN5Botan12_GLOBAL__N_15SM4_DILm0EFjjEEEvRjS3_S3_S3_RKNSt3__16vectorIjNS_16secure_allocatorIjEEEERT0_:
  126|     92|   uint32_t& B0, uint32_t& B1, uint32_t& B2, uint32_t& B3, const secure_vector<uint32_t>& RK, F& f) {
  127|     92|   B0 ^= f(B1 ^ B2 ^ B3 ^ RK[4 * R + 3]);
  128|     92|   B1 ^= f(B2 ^ B3 ^ B0 ^ RK[4 * R + 2]);
  129|     92|   B2 ^= f(B3 ^ B0 ^ B1 ^ RK[4 * R + 1]);
  130|     92|   B3 ^= f(B0 ^ B1 ^ B2 ^ RK[4 * R + 0]);
  131|     92|}

_ZNK5Botan7Twofish9encrypt_nEPKhPhm:
  173|   882k|void Twofish::encrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  174|   882k|   assert_key_material_set();
  175|       |
  176|       |#if defined(BOTAN_HAS_TWOFISH_AVX512)
  177|       |   if(!m_QS.empty()) {
  178|       |      while(blocks >= 16) {
  179|       |         avx512_encrypt_16(in, out);
  180|       |         in += 16 * BLOCK_SIZE;
  181|       |         out += 16 * BLOCK_SIZE;
  182|       |         blocks -= 16;
  183|       |      }
  184|       |   }
  185|       |#endif
  186|       |
  187|  1.25M|   while(blocks >= 2) {
  ------------------
  |  Branch (187:10): [True: 369k, False: 882k]
  ------------------
  188|   369k|      uint32_t A0 = 0;
  189|   369k|      uint32_t B0 = 0;
  190|   369k|      uint32_t C0 = 0;
  191|   369k|      uint32_t D0 = 0;
  192|   369k|      uint32_t A1 = 0;
  193|   369k|      uint32_t B1 = 0;
  194|   369k|      uint32_t C1 = 0;
  195|   369k|      uint32_t D1 = 0;
  196|   369k|      load_le(in, A0, B0, C0, D0, A1, B1, C1, D1);
  197|       |
  198|   369k|      A0 ^= m_RK[0];
  199|   369k|      A1 ^= m_RK[0];
  200|   369k|      B0 ^= m_RK[1];
  201|   369k|      B1 ^= m_RK[1];
  202|   369k|      C0 ^= m_RK[2];
  203|   369k|      C1 ^= m_RK[2];
  204|   369k|      D0 ^= m_RK[3];
  205|   369k|      D1 ^= m_RK[3];
  206|       |
  207|  3.32M|      for(size_t k = 8; k != 40; k += 4) {
  ------------------
  |  Branch (207:25): [True: 2.95M, False: 369k]
  ------------------
  208|  2.95M|         TF_E(A0, B0, C0, D0, m_RK[k + 0], m_RK[k + 1], m_SB);
  209|  2.95M|         TF_E(A1, B1, C1, D1, m_RK[k + 0], m_RK[k + 1], m_SB);
  210|       |
  211|  2.95M|         TF_E(C0, D0, A0, B0, m_RK[k + 2], m_RK[k + 3], m_SB);
  212|  2.95M|         TF_E(C1, D1, A1, B1, m_RK[k + 2], m_RK[k + 3], m_SB);
  213|  2.95M|      }
  214|       |
  215|   369k|      C0 ^= m_RK[4];
  216|   369k|      C1 ^= m_RK[4];
  217|   369k|      D0 ^= m_RK[5];
  218|   369k|      D1 ^= m_RK[5];
  219|   369k|      A0 ^= m_RK[6];
  220|   369k|      A1 ^= m_RK[6];
  221|   369k|      B0 ^= m_RK[7];
  222|   369k|      B1 ^= m_RK[7];
  223|       |
  224|   369k|      store_le(out, C0, D0, A0, B0, C1, D1, A1, B1);
  225|       |
  226|   369k|      blocks -= 2;
  227|   369k|      out += 2 * BLOCK_SIZE;
  228|   369k|      in += 2 * BLOCK_SIZE;
  229|   369k|   }
  230|       |
  231|   882k|   if(blocks > 0) {
  ------------------
  |  Branch (231:7): [True: 697k, False: 184k]
  ------------------
  232|   697k|      uint32_t A = 0;
  233|   697k|      uint32_t B = 0;
  234|   697k|      uint32_t C = 0;
  235|   697k|      uint32_t D = 0;
  236|   697k|      load_le(in, A, B, C, D);
  237|       |
  238|   697k|      A ^= m_RK[0];
  239|   697k|      B ^= m_RK[1];
  240|   697k|      C ^= m_RK[2];
  241|   697k|      D ^= m_RK[3];
  242|       |
  243|  6.28M|      for(size_t k = 8; k != 40; k += 4) {
  ------------------
  |  Branch (243:25): [True: 5.58M, False: 697k]
  ------------------
  244|  5.58M|         TF_E(A, B, C, D, m_RK[k], m_RK[k + 1], m_SB);
  245|  5.58M|         TF_E(C, D, A, B, m_RK[k + 2], m_RK[k + 3], m_SB);
  246|  5.58M|      }
  247|       |
  248|   697k|      C ^= m_RK[4];
  249|   697k|      D ^= m_RK[5];
  250|   697k|      A ^= m_RK[6];
  251|   697k|      B ^= m_RK[7];
  252|       |
  253|   697k|      store_le(out, C, D, A, B);
  254|   697k|   }
  255|   882k|}
_ZNK5Botan7Twofish9decrypt_nEPKhPhm:
  260|  71.7k|void Twofish::decrypt_n(const uint8_t in[], uint8_t out[], size_t blocks) const {
  261|  71.7k|   assert_key_material_set();
  262|       |
  263|       |#if defined(BOTAN_HAS_TWOFISH_AVX512)
  264|       |   if(!m_QS.empty()) {
  265|       |      while(blocks >= 16) {
  266|       |         avx512_decrypt_16(in, out);
  267|       |         in += 16 * BLOCK_SIZE;
  268|       |         out += 16 * BLOCK_SIZE;
  269|       |         blocks -= 16;
  270|       |      }
  271|       |   }
  272|       |#endif
  273|       |
  274|   215k|   while(blocks >= 2) {
  ------------------
  |  Branch (274:10): [True: 143k, False: 71.7k]
  ------------------
  275|   143k|      uint32_t A0 = 0;
  276|   143k|      uint32_t B0 = 0;
  277|   143k|      uint32_t C0 = 0;
  278|   143k|      uint32_t D0 = 0;
  279|   143k|      uint32_t A1 = 0;
  280|   143k|      uint32_t B1 = 0;
  281|   143k|      uint32_t C1 = 0;
  282|   143k|      uint32_t D1 = 0;
  283|   143k|      load_le(in, A0, B0, C0, D0, A1, B1, C1, D1);
  284|       |
  285|   143k|      A0 ^= m_RK[4];
  286|   143k|      A1 ^= m_RK[4];
  287|   143k|      B0 ^= m_RK[5];
  288|   143k|      B1 ^= m_RK[5];
  289|   143k|      C0 ^= m_RK[6];
  290|   143k|      C1 ^= m_RK[6];
  291|   143k|      D0 ^= m_RK[7];
  292|   143k|      D1 ^= m_RK[7];
  293|       |
  294|  1.29M|      for(size_t k = 40; k != 8; k -= 4) {
  ------------------
  |  Branch (294:26): [True: 1.14M, False: 143k]
  ------------------
  295|  1.14M|         TF_D(A0, B0, C0, D0, m_RK[k - 2], m_RK[k - 1], m_SB);
  296|  1.14M|         TF_D(A1, B1, C1, D1, m_RK[k - 2], m_RK[k - 1], m_SB);
  297|       |
  298|  1.14M|         TF_D(C0, D0, A0, B0, m_RK[k - 4], m_RK[k - 3], m_SB);
  299|  1.14M|         TF_D(C1, D1, A1, B1, m_RK[k - 4], m_RK[k - 3], m_SB);
  300|  1.14M|      }
  301|       |
  302|   143k|      C0 ^= m_RK[0];
  303|   143k|      C1 ^= m_RK[0];
  304|   143k|      D0 ^= m_RK[1];
  305|   143k|      D1 ^= m_RK[1];
  306|   143k|      A0 ^= m_RK[2];
  307|   143k|      A1 ^= m_RK[2];
  308|   143k|      B0 ^= m_RK[3];
  309|   143k|      B1 ^= m_RK[3];
  310|       |
  311|   143k|      store_le(out, C0, D0, A0, B0, C1, D1, A1, B1);
  312|       |
  313|   143k|      blocks -= 2;
  314|   143k|      out += 2 * BLOCK_SIZE;
  315|   143k|      in += 2 * BLOCK_SIZE;
  316|   143k|   }
  317|       |
  318|  71.7k|   if(blocks > 0) {
  ------------------
  |  Branch (318:7): [True: 69, False: 71.7k]
  ------------------
  319|     69|      uint32_t A = 0;
  320|     69|      uint32_t B = 0;
  321|     69|      uint32_t C = 0;
  322|     69|      uint32_t D = 0;
  323|     69|      load_le(in, A, B, C, D);
  324|       |
  325|     69|      A ^= m_RK[4];
  326|     69|      B ^= m_RK[5];
  327|     69|      C ^= m_RK[6];
  328|     69|      D ^= m_RK[7];
  329|       |
  330|    621|      for(size_t k = 40; k != 8; k -= 4) {
  ------------------
  |  Branch (330:26): [True: 552, False: 69]
  ------------------
  331|    552|         TF_D(A, B, C, D, m_RK[k - 2], m_RK[k - 1], m_SB);
  332|    552|         TF_D(C, D, A, B, m_RK[k - 4], m_RK[k - 3], m_SB);
  333|    552|      }
  334|       |
  335|     69|      C ^= m_RK[0];
  336|     69|      D ^= m_RK[1];
  337|     69|      A ^= m_RK[2];
  338|     69|      B ^= m_RK[3];
  339|       |
  340|     69|      store_le(out, C, D, A, B);
  341|     69|   }
  342|  71.7k|}
_ZNK5Botan7Twofish19has_keying_materialEv:
  344|  1.66M|bool Twofish::has_keying_material() const {
  345|  1.66M|   return !m_SB.empty();
  346|  1.66M|}
_ZNK5Botan7Twofish11parallelismEv:
  357|  3.20k|size_t Twofish::parallelism() const {
  358|       |#if defined(BOTAN_HAS_TWOFISH_AVX512)
  359|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  360|       |      return 16;
  361|       |   }
  362|       |#endif
  363|  3.20k|   return 1;
  364|  3.20k|}
_ZN5Botan7Twofish12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  369|  2.21k|void Twofish::key_schedule(std::span<const uint8_t> key) {
  370|  2.21k|   using namespace Twofish_KS;
  371|       |
  372|       |   // Reed-Solomon matrix for key schedule (Twofish paper Section 4.3)
  373|       |   // in column-major form
  374|       |
  375|       |   // clang-format off
  376|  2.21k|   constexpr uint32_t RS32[8] = {
  377|  2.21k|      0x01A402A4,
  378|  2.21k|      0xA456A155,
  379|  2.21k|      0x5582FC87,
  380|  2.21k|      0x87F3C15A,
  381|  2.21k|      0x5A1E4758,
  382|  2.21k|      0x58C6AEDB,
  383|  2.21k|      0xDB683D9E,
  384|  2.21k|      0x9EE51903
  385|  2.21k|   };
  386|       |   // clang-format on
  387|       |
  388|  2.21k|   m_RK.resize(40);
  389|       |
  390|  2.21k|   secure_vector<uint8_t> S(16);
  391|       |
  392|  73.1k|   for(size_t i = 0; i != key.size(); ++i) {
  ------------------
  |  Branch (392:22): [True: 70.9k, False: 2.21k]
  ------------------
  393|  70.9k|      const uint8_t ki = key[i];
  394|  70.9k|      const size_t s_off = 4 * (i / 8);
  395|       |
  396|  70.9k|      const uint32_t p = gf_mul_rs32(RS32[i % 8], ki);
  397|       |
  398|  70.9k|      S[s_off + 0] ^= get_byte<0>(p);
  399|  70.9k|      S[s_off + 1] ^= get_byte<1>(p);
  400|  70.9k|      S[s_off + 2] ^= get_byte<2>(p);
  401|  70.9k|      S[s_off + 3] ^= get_byte<3>(p);
  402|  70.9k|   }
  403|       |
  404|  2.21k|   secure_vector<uint8_t> QS(1024);
  405|       |
  406|  2.21k|   if(key.size() == 16) {
  ------------------
  |  Branch (406:7): [True: 0, False: 2.21k]
  ------------------
  407|      0|      for(size_t i = 0; i != 256; ++i) {
  ------------------
  |  Branch (407:25): [True: 0, False: 0]
  ------------------
  408|      0|         QS[i] = Q1[Q0[Q0[i] ^ S[0]] ^ S[4]];
  409|      0|         QS[256 + i] = Q0[Q0[Q1[i] ^ S[1]] ^ S[5]];
  410|      0|         QS[512 + i] = Q1[Q1[Q0[i] ^ S[2]] ^ S[6]];
  411|      0|         QS[768 + i] = Q0[Q1[Q1[i] ^ S[3]] ^ S[7]];
  412|      0|      }
  413|       |
  414|      0|      for(size_t i = 0; i < 40; i += 2) {
  ------------------
  |  Branch (414:25): [True: 0, False: 0]
  ------------------
  415|      0|         uint32_t X = mds0(Q1[Q0[Q0[i] ^ key[8]] ^ key[0]]) ^ mds1(Q0[Q0[Q1[i] ^ key[9]] ^ key[1]]) ^
  416|      0|                      mds2(Q1[Q1[Q0[i] ^ key[10]] ^ key[2]]) ^ mds3(Q0[Q1[Q1[i] ^ key[11]] ^ key[3]]);
  417|      0|         uint32_t Y = mds0(Q1[Q0[Q0[i + 1] ^ key[12]] ^ key[4]]) ^ mds1(Q0[Q0[Q1[i + 1] ^ key[13]] ^ key[5]]) ^
  418|      0|                      mds2(Q1[Q1[Q0[i + 1] ^ key[14]] ^ key[6]]) ^ mds3(Q0[Q1[Q1[i + 1] ^ key[15]] ^ key[7]]);
  419|      0|         Y = rotl<8>(Y);
  420|      0|         X += Y;
  421|      0|         Y += X;
  422|       |
  423|      0|         m_RK[i] = X;
  424|      0|         m_RK[i + 1] = rotl<9>(Y);
  425|      0|      }
  426|  2.21k|   } else if(key.size() == 24) {
  ------------------
  |  Branch (426:14): [True: 0, False: 2.21k]
  ------------------
  427|      0|      for(size_t i = 0; i != 256; ++i) {
  ------------------
  |  Branch (427:25): [True: 0, False: 0]
  ------------------
  428|      0|         QS[i] = Q1[Q0[Q0[Q1[i] ^ S[0]] ^ S[4]] ^ S[8]];
  429|      0|         QS[256 + i] = Q0[Q0[Q1[Q1[i] ^ S[1]] ^ S[5]] ^ S[9]];
  430|      0|         QS[512 + i] = Q1[Q1[Q0[Q0[i] ^ S[2]] ^ S[6]] ^ S[10]];
  431|      0|         QS[768 + i] = Q0[Q1[Q1[Q0[i] ^ S[3]] ^ S[7]] ^ S[11]];
  432|      0|      }
  433|       |
  434|      0|      for(size_t i = 0; i < 40; i += 2) {
  ------------------
  |  Branch (434:25): [True: 0, False: 0]
  ------------------
  435|      0|         uint32_t X =
  436|      0|            mds0(Q1[Q0[Q0[Q1[i] ^ key[16]] ^ key[8]] ^ key[0]]) ^ mds1(Q0[Q0[Q1[Q1[i] ^ key[17]] ^ key[9]] ^ key[1]]) ^
  437|      0|            mds2(Q1[Q1[Q0[Q0[i] ^ key[18]] ^ key[10]] ^ key[2]]) ^ mds3(Q0[Q1[Q1[Q0[i] ^ key[19]] ^ key[11]] ^ key[3]]);
  438|      0|         uint32_t Y = mds0(Q1[Q0[Q0[Q1[i + 1] ^ key[20]] ^ key[12]] ^ key[4]]) ^
  439|      0|                      mds1(Q0[Q0[Q1[Q1[i + 1] ^ key[21]] ^ key[13]] ^ key[5]]) ^
  440|      0|                      mds2(Q1[Q1[Q0[Q0[i + 1] ^ key[22]] ^ key[14]] ^ key[6]]) ^
  441|      0|                      mds3(Q0[Q1[Q1[Q0[i + 1] ^ key[23]] ^ key[15]] ^ key[7]]);
  442|      0|         Y = rotl<8>(Y);
  443|      0|         X += Y;
  444|      0|         Y += X;
  445|       |
  446|      0|         m_RK[i] = X;
  447|      0|         m_RK[i + 1] = rotl<9>(Y);
  448|      0|      }
  449|  2.21k|   } else if(key.size() == 32) {
  ------------------
  |  Branch (449:14): [True: 2.21k, False: 0]
  ------------------
  450|   569k|      for(size_t i = 0; i != 256; ++i) {
  ------------------
  |  Branch (450:25): [True: 567k, False: 2.21k]
  ------------------
  451|   567k|         QS[i] = Q1[Q0[Q0[Q1[Q1[i] ^ S[0]] ^ S[4]] ^ S[8]] ^ S[12]];
  452|   567k|         QS[256 + i] = Q0[Q0[Q1[Q1[Q0[i] ^ S[1]] ^ S[5]] ^ S[9]] ^ S[13]];
  453|   567k|         QS[512 + i] = Q1[Q1[Q0[Q0[Q0[i] ^ S[2]] ^ S[6]] ^ S[10]] ^ S[14]];
  454|   567k|         QS[768 + i] = Q0[Q1[Q1[Q0[Q1[i] ^ S[3]] ^ S[7]] ^ S[11]] ^ S[15]];
  455|   567k|      }
  456|       |
  457|  46.5k|      for(size_t i = 0; i < 40; i += 2) {
  ------------------
  |  Branch (457:25): [True: 44.3k, False: 2.21k]
  ------------------
  458|  44.3k|         uint32_t X = mds0(Q1[Q0[Q0[Q1[Q1[i] ^ key[24]] ^ key[16]] ^ key[8]] ^ key[0]]) ^
  459|  44.3k|                      mds1(Q0[Q0[Q1[Q1[Q0[i] ^ key[25]] ^ key[17]] ^ key[9]] ^ key[1]]) ^
  460|  44.3k|                      mds2(Q1[Q1[Q0[Q0[Q0[i] ^ key[26]] ^ key[18]] ^ key[10]] ^ key[2]]) ^
  461|  44.3k|                      mds3(Q0[Q1[Q1[Q0[Q1[i] ^ key[27]] ^ key[19]] ^ key[11]] ^ key[3]]);
  462|  44.3k|         uint32_t Y = mds0(Q1[Q0[Q0[Q1[Q1[i + 1] ^ key[28]] ^ key[20]] ^ key[12]] ^ key[4]]) ^
  463|  44.3k|                      mds1(Q0[Q0[Q1[Q1[Q0[i + 1] ^ key[29]] ^ key[21]] ^ key[13]] ^ key[5]]) ^
  464|  44.3k|                      mds2(Q1[Q1[Q0[Q0[Q0[i + 1] ^ key[30]] ^ key[22]] ^ key[14]] ^ key[6]]) ^
  465|  44.3k|                      mds3(Q0[Q1[Q1[Q0[Q1[i + 1] ^ key[31]] ^ key[23]] ^ key[15]] ^ key[7]]);
  466|  44.3k|         Y = rotl<8>(Y);
  467|  44.3k|         X += Y;
  468|  44.3k|         Y += X;
  469|       |
  470|  44.3k|         m_RK[i] = X;
  471|  44.3k|         m_RK[i + 1] = rotl<9>(Y);
  472|  44.3k|      }
  473|  2.21k|   }
  474|       |
  475|  2.21k|   m_SB.resize(1024);
  476|   569k|   for(size_t i = 0; i != 256; ++i) {
  ------------------
  |  Branch (476:22): [True: 567k, False: 2.21k]
  ------------------
  477|   567k|      m_SB[i] = mds0(QS[i]);
  478|   567k|      m_SB[256 + i] = mds1(QS[256 + i]);
  479|   567k|      m_SB[512 + i] = mds2(QS[512 + i]);
  480|   567k|      m_SB[768 + i] = mds3(QS[768 + i]);
  481|   567k|   }
  482|       |
  483|       |#if defined(BOTAN_HAS_TWOFISH_AVX512)
  484|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::GFNI)) {
  485|       |      m_QS = std::move(QS);
  486|       |   }
  487|       |#endif
  488|  2.21k|}
_ZN5Botan7Twofish5clearEv:
  493|    388|void Twofish::clear() {
  494|    388|   zap(m_SB);
  495|    388|   zap(m_RK);
  496|    388|   zap(m_QS);
  497|    388|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_14TF_EEjjRjS1_jjRKNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  139|  22.9M|   uint32_t A, uint32_t B, uint32_t& C, uint32_t& D, uint32_t RK1, uint32_t RK2, const secure_vector<uint32_t>& SB) {
  140|  22.9M|   uint32_t X = SB[get_byte<3>(A)] ^ SB[256 + get_byte<2>(A)] ^ SB[512 + get_byte<1>(A)] ^ SB[768 + get_byte<0>(A)];
  141|  22.9M|   uint32_t Y = SB[get_byte<0>(B)] ^ SB[256 + get_byte<3>(B)] ^ SB[512 + get_byte<2>(B)] ^ SB[768 + get_byte<1>(B)];
  142|       |
  143|  22.9M|   X += Y;
  144|  22.9M|   Y += X;
  145|       |
  146|  22.9M|   X += RK1;
  147|  22.9M|   Y += RK2;
  148|       |
  149|  22.9M|   C = rotr<1>(C ^ X);
  150|  22.9M|   D = rotl<1>(D) ^ Y;
  151|  22.9M|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_14TF_DEjjRjS1_jjRKNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  154|  4.58M|   uint32_t A, uint32_t B, uint32_t& C, uint32_t& D, uint32_t RK1, uint32_t RK2, const secure_vector<uint32_t>& SB) {
  155|  4.58M|   uint32_t X = SB[get_byte<3>(A)] ^ SB[256 + get_byte<2>(A)] ^ SB[512 + get_byte<1>(A)] ^ SB[768 + get_byte<0>(A)];
  156|  4.58M|   uint32_t Y = SB[get_byte<0>(B)] ^ SB[256 + get_byte<3>(B)] ^ SB[512 + get_byte<2>(B)] ^ SB[768 + get_byte<1>(B)];
  157|       |
  158|  4.58M|   X += Y;
  159|  4.58M|   Y += X;
  160|       |
  161|  4.58M|   X += RK1;
  162|  4.58M|   Y += RK2;
  163|       |
  164|  4.58M|   C = rotl<1>(C) ^ X;
  165|  4.58M|   D = rotr<1>(D ^ Y);
  166|  4.58M|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS11gf_mul_rs32Ejh:
  121|  70.9k|inline uint32_t gf_mul_rs32(uint32_t rs, uint8_t k) {
  122|  70.9k|   constexpr uint32_t lo_bit = 0x01010101;
  123|  70.9k|   constexpr uint32_t mask = 0x7F7F7F7F;
  124|  70.9k|   constexpr uint32_t poly = 0x4D;
  125|       |
  126|  70.9k|   uint32_t r = 0;
  127|   638k|   for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (127:22): [True: 567k, False: 70.9k]
  ------------------
  128|   567k|      const auto k_lo = CT::Mask<uint32_t>::expand(k & 1);
  129|   567k|      r ^= k_lo.if_set_return(rs);
  130|   567k|      rs = ((rs & mask) << 1) ^ (((rs >> 7) & lo_bit) * poly);
  131|   567k|      k >>= 1;
  132|   567k|   }
  133|  70.9k|   return r;
  134|  70.9k|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS4mds0Eh:
   92|   656k|inline uint32_t mds0(uint8_t q) {
   93|   656k|   const uint8_t q_div_x = mds_div_x(q);
   94|   656k|   const uint8_t q5b = q ^ mds_div_x(q_div_x);
   95|   656k|   const uint8_t qef = q5b ^ q_div_x;
   96|   656k|   return make_uint32(qef, qef, q5b, q);
   97|   656k|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS9mds_div_xEh:
   88|  5.24M|inline uint8_t mds_div_x(uint8_t q) {
   89|  5.24M|   return (q >> 1) ^ (CT::value_barrier<uint8_t>(q & 1) * 0xB4);
   90|  5.24M|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS4mds1Eh:
   99|   656k|inline uint32_t mds1(uint8_t q) {
  100|   656k|   const uint8_t q_div_x = mds_div_x(q);
  101|   656k|   const uint8_t q5b = q ^ mds_div_x(q_div_x);
  102|   656k|   const uint8_t qef = q5b ^ q_div_x;
  103|   656k|   return make_uint32(q, q5b, qef, qef);
  104|   656k|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS4mds2Eh:
  106|   656k|inline uint32_t mds2(uint8_t q) {
  107|   656k|   const uint8_t q_div_x = mds_div_x(q);
  108|   656k|   const uint8_t q5b = q ^ mds_div_x(q_div_x);
  109|   656k|   const uint8_t qef = q5b ^ q_div_x;
  110|   656k|   return make_uint32(qef, q, qef, q5b);
  111|   656k|}
twofish.cpp:_ZN5Botan12_GLOBAL__N_110Twofish_KS4mds3Eh:
  113|   656k|inline uint32_t mds3(uint8_t q) {
  114|   656k|   const uint8_t q_div_x = mds_div_x(q);
  115|   656k|   const uint8_t q5b = q ^ mds_div_x(q_div_x);
  116|   656k|   const uint8_t qef = q5b ^ q_div_x;
  117|   656k|   return make_uint32(q5b, qef, q, q5b);
  118|   656k|}

_ZN5Botan10hex_encodeEPcPKhmb:
   34|  55.3k|void hex_encode(char output[], const uint8_t input[], size_t input_length, bool uppercase) {
   35|  1.14M|   for(size_t i = 0; i != input_length; ++i) {
  ------------------
  |  Branch (35:22): [True: 1.08M, False: 55.3k]
  ------------------
   36|  1.08M|      const uint16_t h = hex_encode_2nibble(input[i], uppercase);
   37|  1.08M|      output[2 * i] = get_byte<0>(h);
   38|  1.08M|      output[2 * i + 1] = get_byte<1>(h);
   39|  1.08M|   }
   40|  55.3k|}
_ZN5Botan10hex_decodeEPhPKcmRmb:
   75|   134k|size_t hex_decode(uint8_t output[], const char input[], size_t input_length, size_t& input_consumed, bool ignore_ws) {
   76|   134k|   uint8_t* out_ptr = output;
   77|   134k|   bool top_nibble = true;
   78|   134k|   uint8_t next = 0;
   79|       |
   80|   134k|   input_consumed = 0;
   81|       |
   82|   134k|   clear_mem(output, input_length / 2);
   83|       |
   84|  7.60M|   for(size_t i = 0; i != input_length; ++i) {
  ------------------
  |  Branch (84:22): [True: 7.47M, False: 134k]
  ------------------
   85|  7.47M|      const uint8_t bin = hex_char_to_bin(input[i]);
   86|       |
   87|  7.47M|      if(bin >= 0x10) {
  ------------------
  |  Branch (87:10): [True: 0, False: 7.47M]
  ------------------
   88|      0|         if(bin == 0x80 && ignore_ws) {
  ------------------
  |  Branch (88:13): [True: 0, False: 0]
  |  Branch (88:28): [True: 0, False: 0]
  ------------------
   89|      0|            continue;
   90|      0|         }
   91|       |
   92|      0|         throw Invalid_Argument(fmt("hex_decode: invalid character '{}'", format_char_for_display(input[i])));
   93|      0|      }
   94|       |
   95|  7.47M|      if(top_nibble) {
  ------------------
  |  Branch (95:10): [True: 3.73M, False: 3.73M]
  ------------------
   96|  3.73M|         next = bin << 4;
   97|  3.73M|      } else {
   98|  3.73M|         next |= bin;
   99|  3.73M|         *out_ptr = next;
  100|  3.73M|      }
  101|       |
  102|  7.47M|      top_nibble = !top_nibble;
  103|  7.47M|      if(top_nibble) {
  ------------------
  |  Branch (103:10): [True: 3.73M, False: 3.73M]
  ------------------
  104|  3.73M|         ++out_ptr;
  105|  3.73M|         input_consumed = i + 1;
  106|  3.73M|      }
  107|  7.47M|   }
  108|       |
  109|       |   /*
  110|       |   * Consume trailing whitespace following the last full byte; a leftover
  111|       |   * unpaired nibble (if any) stops the scan and is left unconsumed.
  112|       |   */
  113|   134k|   while(input_consumed < input_length && hex_char_to_bin(input[input_consumed]) == 0x80) {
  ------------------
  |  Branch (113:10): [True: 0, False: 134k]
  |  Branch (113:43): [True: 0, False: 0]
  ------------------
  114|      0|      ++input_consumed;
  115|      0|   }
  116|       |
  117|   134k|   return (out_ptr - output);
  118|   134k|}
_ZN5Botan10hex_decodeEPhPKcmb:
  120|   134k|size_t hex_decode(uint8_t output[], const char input[], size_t input_length, bool ignore_ws) {
  121|   134k|   size_t consumed = 0;
  122|   134k|   const size_t written = hex_decode(output, input, input_length, consumed, ignore_ws);
  123|       |
  124|   134k|   if(consumed != input_length) {
  ------------------
  |  Branch (124:7): [True: 0, False: 134k]
  ------------------
  125|      0|      throw Invalid_Argument("hex_decode: input did not have full bytes");
  126|      0|   }
  127|       |
  128|   134k|   return written;
  129|   134k|}
_ZN5Botan17hex_decode_lockedEPKcmb:
  142|     18|secure_vector<uint8_t> hex_decode_locked(const char input[], size_t input_length, bool ignore_ws) {
  143|     18|   secure_vector<uint8_t> bin(1 + input_length / 2);
  144|       |
  145|     18|   const size_t written = hex_decode(bin.data(), input, input_length, ignore_ws);
  146|       |
  147|     18|   bin.resize(written);
  148|     18|   return bin;
  149|     18|}
_ZN5Botan17hex_decode_lockedENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEEb:
  151|     16|secure_vector<uint8_t> hex_decode_locked(std::string_view input, bool ignore_ws) {
  152|     16|   return hex_decode_locked(input.data(), input.size(), ignore_ws);
  153|     16|}
_ZN5Botan10hex_decodeEPKcmb:
  155|   134k|std::vector<uint8_t> hex_decode(const char input[], size_t input_length, bool ignore_ws) {
  156|   134k|   std::vector<uint8_t> bin(1 + input_length / 2);
  157|       |
  158|   134k|   const size_t written = hex_decode(bin.data(), input, input_length, ignore_ws);
  159|       |
  160|   134k|   bin.resize(written);
  161|   134k|   return bin;
  162|   134k|}
hex.cpp:_ZN5Botan12_GLOBAL__N_118hex_encode_2nibbleEhb:
   21|  1.08M|uint16_t hex_encode_2nibble(uint8_t n8, bool uppercase) {
   22|       |   // Offset for upper or lower case 'a' resp
   23|  1.08M|   const uint16_t a_mask = uppercase ? 0x0707 : 0x2727;
  ------------------
  |  Branch (23:28): [True: 739k, False: 345k]
  ------------------
   24|       |
   25|  1.08M|   const uint16_t n = (static_cast<uint16_t>(n8 & 0xF0) << 4) | (n8 & 0x0F);
   26|       |   // n >= 10? If so add offset
   27|  1.08M|   const uint16_t diff = swar_lt<uint16_t>(0x0909, n) & a_mask;
   28|       |   // Can't overflow between bytes, so don't need explicit SWAR addition:
   29|  1.08M|   return n + 0x3030 + diff;
   30|  1.08M|}
hex.cpp:_ZN5Botan12_GLOBAL__N_115hex_char_to_binEc:
   55|  7.47M|uint8_t hex_char_to_bin(char input) {
   56|       |   // Starts of valid value ranges (v_lo) and their lengths (v_range)
   57|  7.47M|   constexpr uint64_t v_lo = make_uint64(0, '0', 'a', 'A', ' ', '\n', '\t', '\r');
   58|  7.47M|   constexpr uint64_t v_range = make_uint64(0, 10, 6, 6, 1, 1, 1, 1);
   59|  7.47M|   constexpr uint64_t expand8 = 0x0101010101010101;
   60|  7.47M|   constexpr uint64_t top64 = 0x8000000000000000;
   61|       |
   62|  7.47M|   const uint8_t x = static_cast<uint8_t>(input);
   63|  7.47M|   const uint64_t x8 = x * expand8;
   64|       |
   65|  7.47M|   const uint64_t v_mask = swar_in_range<uint64_t>(x8, v_lo, v_range) ^ top64;
   66|       |
   67|       |   // This is the offset added to x to get the value we need
   68|  7.47M|   const uint64_t val_v = 0xd0a9c960767773 ^ static_cast<uint64_t>(0xFF - x) << 56;
   69|       |
   70|  7.47M|   return x + static_cast<uint8_t>(val_v >> (8 * index_of_first_set_byte(v_mask)));
   71|  7.47M|}

_ZN9Botan_FFI24ffi_clear_last_exceptionEv:
   85|  34.3M|void ffi_clear_last_exception() {
   86|  34.3M|   g_last_exception_what.clear();
   87|  34.3M|}
_ZN9Botan_FFI26ffi_error_exception_thrownEPKcS1_i:
   89|    481|int ffi_error_exception_thrown(const char* func_name, const char* exn, int rc) {
   90|    481|   g_last_exception_what.assign(exn);
   91|       |
   92|    481|#if defined(BOTAN_HAS_OS_UTILS)
   93|    481|   std::string val;
   94|    481|   if(Botan::OS::read_env_variable(val, "BOTAN_FFI_PRINT_EXCEPTIONS") && !val.empty()) {
  ------------------
  |  Branch (94:7): [True: 0, False: 481]
  |  Branch (94:74): [True: 0, False: 0]
  ------------------
   95|       |      // NOLINTNEXTLINE(*-vararg)
   96|      0|      static_cast<void>(std::fprintf(stderr, "in %s exception '%s' returning %d\n", func_name, exn, rc));
   97|      0|   }
   98|    481|#endif
   99|       |
  100|    481|   return rc;
  101|    481|}
_ZN9Botan_FFI26ffi_error_exception_thrownEPKcS1_N5Botan9ErrorTypeE:
  103|    481|int ffi_error_exception_thrown(const char* func_name, const char* exn, Botan::ErrorType err) {
  104|    481|   return ffi_error_exception_thrown(func_name, exn, ffi_map_error_type(err));
  105|    481|}
botan_scrub_mem:
  340|  3.52M|int botan_scrub_mem(void* mem, size_t bytes) {
  341|  3.52M|   if(bytes > 0 && mem == nullptr) {
  ------------------
  |  Branch (341:7): [True: 2.12M, False: 1.39M]
  |  Branch (341:20): [True: 0, False: 2.12M]
  ------------------
  342|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  343|      0|   }
  344|  3.52M|   Botan::secure_scrub_memory(mem, bytes);
  345|  3.52M|   return BOTAN_FFI_SUCCESS;
  346|  3.52M|}
botan_hex_encode:
  348|  55.3k|int botan_hex_encode(const uint8_t* in, size_t len, char* out, uint32_t flags) {
  349|  55.3k|   if(len > 0 && (in == nullptr || out == nullptr)) {
  ------------------
  |  Branch (349:7): [True: 55.3k, False: 0]
  |  Branch (349:19): [True: 0, False: 55.3k]
  |  Branch (349:36): [True: 0, False: 55.3k]
  ------------------
  350|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  351|      0|   }
  352|  55.3k|   return ffi_guard_thunk(__func__, [=]() -> int {
  353|  55.3k|      const bool uppercase = (flags & BOTAN_FFI_HEX_LOWER_CASE) == 0;
  354|  55.3k|      Botan::hex_encode(out, in, len, uppercase);
  355|  55.3k|      return BOTAN_FFI_SUCCESS;
  356|  55.3k|   });
  357|  55.3k|}
botan_hex_decode:
  359|   134k|int botan_hex_decode(const char* hex_str, size_t in_len, uint8_t* out, size_t* out_len) {
  360|   134k|   if(any_null_pointers(hex_str, out_len)) {
  ------------------
  |  Branch (360:7): [True: 0, False: 134k]
  ------------------
  361|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  362|      0|   }
  363|   134k|   return ffi_guard_thunk(__func__, [=]() -> int {
  364|   134k|      const std::vector<uint8_t> bin = Botan::hex_decode(hex_str, in_len);
  365|   134k|      return Botan_FFI::write_vec_output(out, out_len, bin);
  366|   134k|   });
  367|   134k|}
ffi.cpp:_ZN9Botan_FFI12_GLOBAL__N_118ffi_map_error_typeEN5Botan9ErrorTypeE:
   28|    481|int ffi_map_error_type(Botan::ErrorType err) {
   29|    481|   switch(err) {
  ------------------
  |  Branch (29:11): [True: 481, False: 0]
  ------------------
   30|      0|      case Botan::ErrorType::Unknown:
  ------------------
  |  Branch (30:7): [True: 0, False: 481]
  ------------------
   31|      0|         return BOTAN_FFI_ERROR_UNKNOWN_ERROR;
   32|       |
   33|      0|      case Botan::ErrorType::SystemError:
  ------------------
  |  Branch (33:7): [True: 0, False: 481]
  ------------------
   34|      0|      case Botan::ErrorType::IoError:
  ------------------
  |  Branch (34:7): [True: 0, False: 481]
  ------------------
   35|      0|      case Botan::ErrorType::Pkcs11Error:
  ------------------
  |  Branch (35:7): [True: 0, False: 481]
  ------------------
   36|      0|      case Botan::ErrorType::CommonCryptoError:
  ------------------
  |  Branch (36:7): [True: 0, False: 481]
  ------------------
   37|      0|      case Botan::ErrorType::ZlibError:
  ------------------
  |  Branch (37:7): [True: 0, False: 481]
  ------------------
   38|      0|      case Botan::ErrorType::Bzip2Error:
  ------------------
  |  Branch (38:7): [True: 0, False: 481]
  ------------------
   39|      0|      case Botan::ErrorType::LzmaError:
  ------------------
  |  Branch (39:7): [True: 0, False: 481]
  ------------------
   40|      0|      case Botan::ErrorType::DatabaseError:
  ------------------
  |  Branch (40:7): [True: 0, False: 481]
  ------------------
   41|      0|         return BOTAN_FFI_ERROR_SYSTEM_ERROR;
   42|       |
   43|      0|      case Botan::ErrorType::TPMError:
  ------------------
  |  Branch (43:7): [True: 0, False: 481]
  ------------------
   44|      0|         return BOTAN_FFI_ERROR_TPM_ERROR;
   45|       |
   46|      0|      case Botan::ErrorType::NotImplemented:
  ------------------
  |  Branch (46:7): [True: 0, False: 481]
  ------------------
   47|      0|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   48|      0|      case Botan::ErrorType::OutOfMemory:
  ------------------
  |  Branch (48:7): [True: 0, False: 481]
  ------------------
   49|      0|         return BOTAN_FFI_ERROR_OUT_OF_MEMORY;
   50|      0|      case Botan::ErrorType::InternalError:
  ------------------
  |  Branch (50:7): [True: 0, False: 481]
  ------------------
   51|      0|         return BOTAN_FFI_ERROR_INTERNAL_ERROR;
   52|      0|      case Botan::ErrorType::InvalidObjectState:
  ------------------
  |  Branch (52:7): [True: 0, False: 481]
  ------------------
   53|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT_STATE;
   54|      0|      case Botan::ErrorType::KeyNotSet:
  ------------------
  |  Branch (54:7): [True: 0, False: 481]
  ------------------
   55|      0|         return BOTAN_FFI_ERROR_KEY_NOT_SET;
   56|    400|      case Botan::ErrorType::InvalidArgument:
  ------------------
  |  Branch (56:7): [True: 400, False: 81]
  ------------------
   57|    400|      case Botan::ErrorType::InvalidNonceLength:
  ------------------
  |  Branch (57:7): [True: 0, False: 481]
  ------------------
   58|    400|         return BOTAN_FFI_ERROR_BAD_PARAMETER;
   59|       |
   60|      0|      case Botan::ErrorType::EncodingFailure:
  ------------------
  |  Branch (60:7): [True: 0, False: 481]
  ------------------
   61|     81|      case Botan::ErrorType::DecodingFailure:
  ------------------
  |  Branch (61:7): [True: 81, False: 400]
  ------------------
   62|     81|         return BOTAN_FFI_ERROR_INVALID_INPUT;
   63|       |
   64|      0|      case Botan::ErrorType::InvalidTag:
  ------------------
  |  Branch (64:7): [True: 0, False: 481]
  ------------------
   65|      0|         return BOTAN_FFI_ERROR_BAD_MAC;
   66|       |
   67|      0|      case Botan::ErrorType::InvalidKeyLength:
  ------------------
  |  Branch (67:7): [True: 0, False: 481]
  ------------------
   68|      0|         return BOTAN_FFI_ERROR_INVALID_KEY_LENGTH;
   69|      0|      case Botan::ErrorType::LookupError:
  ------------------
  |  Branch (69:7): [True: 0, False: 481]
  ------------------
   70|      0|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   71|       |
   72|      0|      case Botan::ErrorType::HttpError:
  ------------------
  |  Branch (72:7): [True: 0, False: 481]
  ------------------
   73|      0|         return BOTAN_FFI_ERROR_HTTP_ERROR;
   74|      0|      case Botan::ErrorType::TLSError:
  ------------------
  |  Branch (74:7): [True: 0, False: 481]
  ------------------
   75|      0|         return BOTAN_FFI_ERROR_TLS_ERROR;
   76|      0|      case Botan::ErrorType::RoughtimeError:
  ------------------
  |  Branch (76:7): [True: 0, False: 481]
  ------------------
   77|      0|         return BOTAN_FFI_ERROR_ROUGHTIME_ERROR;
   78|    481|   }
   79|       |
   80|      0|   return BOTAN_FFI_ERROR_UNKNOWN_ERROR;
   81|    481|}
ffi.cpp:_ZZ16botan_hex_encodeENK3$_0clEv:
  352|  55.3k|   return ffi_guard_thunk(__func__, [=]() -> int {
  353|  55.3k|      const bool uppercase = (flags & BOTAN_FFI_HEX_LOWER_CASE) == 0;
  ------------------
  |  |  247|  55.3k|#define BOTAN_FFI_HEX_LOWER_CASE 1
  ------------------
  354|  55.3k|      Botan::hex_encode(out, in, len, uppercase);
  355|  55.3k|      return BOTAN_FFI_SUCCESS;
  356|  55.3k|   });
ffi.cpp:_ZZ16botan_hex_decodeENK3$_0clEv:
  363|   134k|   return ffi_guard_thunk(__func__, [=]() -> int {
  364|   134k|      const std::vector<uint8_t> bin = Botan::hex_decode(hex_str, in_len);
  365|   134k|      return Botan_FFI::write_vec_output(out, out_len, bin);
  366|   134k|   });

botan_block_cipher_init:
   19|  12.3k|int botan_block_cipher_init(botan_block_cipher_t* bc, const char* bc_name) {
   20|  12.3k|   return ffi_guard_thunk(__func__, [=]() -> int {
   21|  12.3k|      if(bc == nullptr || bc_name == nullptr || *bc_name == 0) {
   22|  12.3k|         return BOTAN_FFI_ERROR_NULL_POINTER;
   23|  12.3k|      }
   24|       |
   25|  12.3k|      *bc = nullptr;
   26|       |
   27|  12.3k|      auto cipher = Botan::BlockCipher::create(bc_name);
   28|  12.3k|      if(cipher == nullptr) {
   29|  12.3k|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   30|  12.3k|      }
   31|       |
   32|  12.3k|      return ffi_new_object(bc, std::move(cipher));
   33|  12.3k|   });
   34|  12.3k|}
botan_block_cipher_destroy:
   39|  12.3k|int botan_block_cipher_destroy(botan_block_cipher_t bc) {
   40|  12.3k|   return BOTAN_FFI_CHECKED_DELETE(bc);
  ------------------
  |  |  188|  12.3k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
   41|  12.3k|}
botan_block_cipher_set_key:
   50|  12.3k|int botan_block_cipher_set_key(botan_block_cipher_t bc, const uint8_t key[], size_t len) {
   51|  12.3k|   if(key == nullptr) {
  ------------------
  |  Branch (51:7): [True: 0, False: 12.3k]
  ------------------
   52|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   53|      0|   }
   54|  12.3k|   return BOTAN_FFI_VISIT(bc, [=](auto& b) { b.set_key(key, len); });
  ------------------
  |  |  158|  12.3k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   55|  12.3k|}
botan_block_cipher_encrypt_blocks:
   76|  3.34M|int botan_block_cipher_encrypt_blocks(botan_block_cipher_t bc, const uint8_t in[], uint8_t out[], size_t blocks) {
   77|  3.34M|   if(any_null_pointers(in, out)) {
  ------------------
  |  Branch (77:7): [True: 0, False: 3.34M]
  ------------------
   78|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   79|      0|   }
   80|  3.34M|   return BOTAN_FFI_VISIT(bc, [=](const auto& b) { b.encrypt_n(in, out, blocks); });
  ------------------
  |  |  158|  3.34M|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   81|  3.34M|}
ffi_block.cpp:_ZZ23botan_block_cipher_initENK3$_0clEv:
   20|  12.3k|   return ffi_guard_thunk(__func__, [=]() -> int {
   21|  12.3k|      if(bc == nullptr || bc_name == nullptr || *bc_name == 0) {
  ------------------
  |  Branch (21:10): [True: 0, False: 12.3k]
  |  Branch (21:27): [True: 0, False: 12.3k]
  |  Branch (21:49): [True: 0, False: 12.3k]
  ------------------
   22|      0|         return BOTAN_FFI_ERROR_NULL_POINTER;
   23|      0|      }
   24|       |
   25|  12.3k|      *bc = nullptr;
   26|       |
   27|  12.3k|      auto cipher = Botan::BlockCipher::create(bc_name);
   28|  12.3k|      if(cipher == nullptr) {
  ------------------
  |  Branch (28:10): [True: 0, False: 12.3k]
  ------------------
   29|      0|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   30|      0|      }
   31|       |
   32|  12.3k|      return ffi_new_object(bc, std::move(cipher));
   33|  12.3k|   });

ffi_choose_update_size:
   61|  15.5k|size_t ffi_choose_update_size(Botan::Cipher_Mode& mode) {
   62|  15.5k|   const size_t update_granularity = mode.update_granularity();
   63|  15.5k|   const size_t ideal_update_granularity = mode.ideal_granularity();
   64|  15.5k|   const size_t minimum_final_size = mode.minimum_final_size();
   65|       |
   66|       |   // If the minimum final size is zero, or the update_granularity is
   67|       |   // already greater, just use that.
   68|  15.5k|   if(minimum_final_size == 0 || update_granularity > minimum_final_size) {
  ------------------
  |  Branch (68:7): [True: 7.72k, False: 7.77k]
  |  Branch (68:34): [True: 0, False: 7.77k]
  ------------------
   69|  7.72k|      BOTAN_ASSERT_NOMSG(update_granularity > 0);
  ------------------
  |  |   77|  7.72k|   do {                                                                     \
  |  |   78|  7.72k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  7.72k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 7.72k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  7.72k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 7.72k]
  |  |  ------------------
  ------------------
   70|  7.72k|      return update_granularity;
   71|  7.72k|   }
   72|       |
   73|       |   // If the ideal granularity is a multiple of the minimum final size, we
   74|       |   // might be able to use that if it stays within the ideal granularity.
   75|  7.77k|   if(ideal_update_granularity % minimum_final_size == 0 && minimum_final_size * 2 <= ideal_update_granularity) {
  ------------------
  |  Branch (75:7): [True: 7.77k, False: 0]
  |  Branch (75:61): [True: 7.77k, False: 0]
  ------------------
   76|  7.77k|      return minimum_final_size * 2;
   77|  7.77k|   }
   78|       |
   79|       |   // Otherwise, try to use the next power of two greater than the minimum
   80|       |   // final size, if the ideal granularity is a multiple of that.
   81|      0|   BOTAN_ASSERT_NOMSG(minimum_final_size <= std::numeric_limits<uint16_t>::max());
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
   82|      0|   const size_t b1 = size_t(1) << Botan::ceil_log2(static_cast<uint16_t>(minimum_final_size));
   83|      0|   if(ideal_update_granularity % b1 == 0) {
  ------------------
  |  Branch (83:7): [True: 0, False: 0]
  ------------------
   84|      0|      return b1;
   85|      0|   }
   86|       |
   87|       |   // Last resort: Find the next integer greater than the minimum final size
   88|       |   //              for which the ideal granularity is a multiple of.
   89|       |   //              Most sensible cipher modes should never reach this point.
   90|      0|   BOTAN_ASSERT_NOMSG(minimum_final_size < ideal_update_granularity);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
   91|      0|   size_t b2 = minimum_final_size + 1;
   92|      0|   for(; b2 < ideal_update_granularity && ideal_update_granularity % b2 != 0; ++b2) {}
  ------------------
  |  Branch (92:10): [True: 0, False: 0]
  |  Branch (92:43): [True: 0, False: 0]
  ------------------
   93|       |
   94|      0|   return b2;
   95|      0|}
botan_cipher_init:
   99|  15.8k|int botan_cipher_init(botan_cipher_t* cipher, const char* cipher_name, uint32_t flags) {
  100|  15.8k|   return ffi_guard_thunk(__func__, [=]() -> int {
  101|  15.8k|      if(any_null_pointers(cipher, cipher_name)) {
  102|  15.8k|         return BOTAN_FFI_ERROR_NULL_POINTER;
  103|  15.8k|      }
  104|  15.8k|      const bool encrypt_p = ((flags & BOTAN_CIPHER_INIT_FLAG_MASK_DIRECTION) == BOTAN_CIPHER_INIT_FLAG_ENCRYPT);
  105|  15.8k|      const Botan::Cipher_Dir dir = encrypt_p ? Botan::Cipher_Dir::Encryption : Botan::Cipher_Dir::Decryption;
  106|       |
  107|  15.8k|      std::unique_ptr<Botan::Cipher_Mode> mode(Botan::Cipher_Mode::create(cipher_name, dir));
  108|  15.8k|      if(!mode) {
  109|  15.8k|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  110|  15.8k|      }
  111|       |
  112|  15.8k|      const size_t update_size = ffi_choose_update_size(*mode);
  113|  15.8k|      const size_t ideal_update_size = std::max(mode->ideal_granularity(), update_size);
  114|       |
  115|  15.8k|      return ffi_new_object(cipher, std::move(mode), update_size, ideal_update_size);
  116|  15.8k|   });
  117|  15.8k|}
botan_cipher_destroy:
  119|  15.5k|int botan_cipher_destroy(botan_cipher_t cipher) {
  120|  15.5k|   return BOTAN_FFI_CHECKED_DELETE(cipher);
  ------------------
  |  |  188|  15.5k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
  121|  15.5k|}
botan_cipher_reset:
  130|   720k|int botan_cipher_reset(botan_cipher_t cipher) {
  131|   720k|   return BOTAN_FFI_VISIT(cipher, [=](auto& c) {
  ------------------
  |  |  158|   720k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  132|   720k|      cipher->buf().clear();
  133|   720k|      c.reset();
  134|   720k|   });
  135|   720k|}
botan_cipher_set_key:
  173|  15.5k|int botan_cipher_set_key(botan_cipher_t cipher, const uint8_t* key, size_t key_len) {
  174|  15.5k|   if(key_len > 0 && key == nullptr) {
  ------------------
  |  Branch (174:7): [True: 15.5k, False: 0]
  |  Branch (174:22): [True: 0, False: 15.5k]
  ------------------
  175|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  176|      0|   }
  177|  15.5k|   return BOTAN_FFI_VISIT(cipher, [=](auto& c) { c.set_key(key, key_len); });
  ------------------
  |  |  158|  15.5k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  178|  15.5k|}
botan_cipher_start:
  180|   721k|int botan_cipher_start(botan_cipher_t cipher_obj, const uint8_t* nonce, size_t nonce_len) {
  181|   721k|   if(nonce_len > 0 && nonce == nullptr) {
  ------------------
  |  Branch (181:7): [True: 721k, False: 0]
  |  Branch (181:24): [True: 0, False: 721k]
  ------------------
  182|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  183|      0|   }
  184|       |
  185|   721k|   return ffi_guard_thunk(__func__, [=]() -> int {
  186|   721k|      Botan::Cipher_Mode& cipher = safe_get(cipher_obj);
  187|   721k|      cipher.start(nonce, nonce_len);
  188|   721k|      return BOTAN_FFI_SUCCESS;
  189|   721k|   });
  190|   721k|}
botan_cipher_update:
  199|   727k|                        size_t* input_consumed) {
  200|   727k|   if(any_null_pointers(output_written, input_consumed)) {
  ------------------
  |  Branch (200:7): [True: 0, False: 727k]
  ------------------
  201|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  202|      0|   }
  203|   727k|   if(input_size > 0 && input == nullptr) {
  ------------------
  |  Branch (203:7): [True: 722k, False: 5.55k]
  |  Branch (203:25): [True: 0, False: 722k]
  ------------------
  204|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  205|      0|   }
  206|   727k|   if(output_size > 0 && output == nullptr) {
  ------------------
  |  Branch (206:7): [True: 724k, False: 3.22k]
  |  Branch (206:26): [True: 0, False: 724k]
  ------------------
  207|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  208|      0|   }
  209|       |
  210|   727k|   return ffi_guard_thunk(__func__, [=]() -> int {
  211|   727k|      using namespace Botan;
  212|   727k|      Cipher_Mode& cipher = safe_get(cipher_obj);
  213|   727k|      secure_vector<uint8_t>& mbuf = cipher_obj->buf();
  214|       |
  215|       |      // If the cipher object's internal buffer contains residual data from
  216|       |      // a previous invocation, we can be sure that botan_cipher_update() was
  217|       |      // called with the final flag set but not enough buffer space was provided
  218|       |      // to accommodate the final output.
  219|   727k|      const bool was_finished_before = !mbuf.empty();
  220|   727k|      const bool final_input = (flags & BOTAN_CIPHER_UPDATE_FLAG_FINAL) != 0;
  221|       |
  222|       |      // Bring the output variables into a defined state.
  223|   727k|      *output_written = 0;
  224|   727k|      *input_consumed = 0;
  225|       |
  226|       |      // Once the final flag was set once, it must always be set for
  227|       |      // consecutive invocations.
  228|   727k|      if(was_finished_before && !final_input) {
  229|   727k|         return BOTAN_FFI_ERROR_INVALID_OBJECT_STATE;
  230|   727k|      }
  231|       |
  232|       |      // If the final flag was set in a previous invocation, no more input
  233|       |      // data can be processed.
  234|   727k|      if(was_finished_before && input_size > 0) {
  235|   727k|         return BOTAN_FFI_ERROR_BAD_PARAMETER;
  236|   727k|      }
  237|       |
  238|       |      // Make sure that we always clear the internal buffer before returning
  239|       |      // or aborting this invocation due to an exception.
  240|   727k|      auto clean_buffer = scoped_cleanup([&mbuf] { mbuf.clear(); });
  241|       |
  242|   727k|      if(final_input) {
  243|       |         // If the final flag is set for the first time, we need to process the
  244|       |         // remaining input data and then finalize the cipher object.
  245|   727k|         if(!was_finished_before) {
  246|   727k|            *input_consumed = input_size;
  247|   727k|            mbuf.resize(input_size);
  248|   727k|            copy_mem(mbuf, std::span(input, input_size));
  249|       |
  250|   727k|            try {
  251|   727k|               cipher.finish(mbuf);
  252|   727k|            } catch(Invalid_Authentication_Tag&) {
  253|   727k|               return BOTAN_FFI_ERROR_BAD_MAC;
  254|   727k|            }
  255|   727k|         }
  256|       |
  257|       |         // At this point, the cipher object is finalized (potentially in a
  258|       |         // previous invocation) and we can copy the final output to the caller.
  259|   727k|         *output_written = mbuf.size();
  260|       |
  261|       |         // Not enough space to copy the final output out to the caller.
  262|       |         // Inform them how much space we need for a successful operation.
  263|   727k|         if(output_size < mbuf.size()) {
  264|       |            // This is the only place where mbuf is not cleared before returning.
  265|   727k|            clean_buffer.disengage();
  266|   727k|            return BOTAN_FFI_ERROR_INSUFFICIENT_BUFFER_SPACE;
  267|   727k|         }
  268|       |
  269|       |         // Copy the final output to the caller, mbuf is cleared afterwards.
  270|   727k|         copy_mem(std::span(output, mbuf.size()), mbuf);
  271|   727k|      } else {
  272|       |         // Process data in a streamed fashion without finalizing. No data is
  273|       |         // ever retained in the cipher object's internal buffer. If we run out
  274|       |         // of either input data or output capacity, we stop and report that not
  275|       |         // all bytes were processed via *output_written and *input_consumed.
  276|       |
  277|   727k|         BufferSlicer in({input, input_size});
  278|   727k|         BufferStuffer out({output, output_size});
  279|       |
  280|       |         // Helper function to do blockwise processing of data.
  281|   727k|         auto blockwise_update = [&](const size_t granularity) {
  282|   727k|            if(granularity == 0) {
  283|   727k|               return;
  284|   727k|            }
  285|       |
  286|   727k|            const size_t expected_output_per_iteration = cipher.requires_entire_message() ? 0 : granularity;
  287|   727k|            mbuf.resize(granularity);
  288|       |
  289|   727k|            while(in.remaining() >= granularity && out.remaining_capacity() >= expected_output_per_iteration) {
  290|   727k|               copy_mem(mbuf, in.take(granularity));
  291|   727k|               const auto written_bytes = cipher.process(mbuf);
  292|   727k|               BOTAN_DEBUG_ASSERT(written_bytes == expected_output_per_iteration);
  293|   727k|               if(written_bytes > 0) {
  294|   727k|                  BOTAN_ASSERT_NOMSG(written_bytes <= granularity);
  295|   727k|                  copy_mem(out.next(written_bytes), std::span(mbuf).first(written_bytes));
  296|   727k|               }
  297|   727k|            }
  298|   727k|         };
  299|       |
  300|       |         // First, process as much data as possible in chunks of ideal granularity
  301|   727k|         blockwise_update(cipher_obj->ideal_update_size());
  302|       |
  303|       |         // Then process the remaining bytes in chunks of update_size() or, in one go
  304|       |         // if update_size() is equal to 1 --> i.e. likely a stream cipher.
  305|   727k|         const bool is_stream_cipher = (cipher_obj->update_size() == 1);
  306|   727k|         const size_t tail_granularity =
  307|   727k|            is_stream_cipher ? std::min(in.remaining(), out.remaining_capacity()) : cipher_obj->update_size();
  308|   727k|         BOTAN_DEBUG_ASSERT(tail_granularity < cipher_obj->ideal_update_size());
  309|   727k|         blockwise_update(tail_granularity);
  310|       |
  311|       |         // Inform the caller about the amount of data processed.
  312|   727k|         *output_written = output_size - out.remaining_capacity();
  313|   727k|         *input_consumed = input_size - in.remaining();
  314|   727k|      }
  315|       |
  316|   727k|      return BOTAN_FFI_SUCCESS;
  317|   727k|   });
  318|   727k|}
botan_cipher_set_associated_data:
  320|   721k|int botan_cipher_set_associated_data(botan_cipher_t cipher, const uint8_t* ad, size_t ad_len) {
  321|   721k|   if(ad_len > 0 && ad == nullptr) {
  ------------------
  |  Branch (321:7): [True: 721k, False: 0]
  |  Branch (321:21): [True: 0, False: 721k]
  ------------------
  322|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  323|      0|   }
  324|       |
  325|   721k|   return BOTAN_FFI_VISIT(cipher, [=](auto& c) {
  ------------------
  |  |  158|   721k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  326|   721k|      if(Botan::AEAD_Mode* aead = dynamic_cast<Botan::AEAD_Mode*>(&c)) {
  327|   721k|         aead->set_associated_data(ad, ad_len);
  328|   721k|         return BOTAN_FFI_SUCCESS;
  329|   721k|      }
  330|   721k|      return BOTAN_FFI_ERROR_BAD_PARAMETER;
  331|   721k|   });
  332|   721k|}
botan_cipher_get_update_granularity:
  345|  15.5k|int botan_cipher_get_update_granularity(botan_cipher_t cipher, size_t* ug) {
  346|  15.5k|   if(ug == nullptr) {
  ------------------
  |  Branch (346:7): [True: 0, False: 15.5k]
  ------------------
  347|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  348|      0|   }
  349|  15.5k|   return BOTAN_FFI_VISIT(cipher, [=](const auto& /*c*/) { *ug = cipher->update_size(); });
  ------------------
  |  |  158|  15.5k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  350|  15.5k|}
ffi_cipher.cpp:_ZZ17botan_cipher_initENK3$_0clEv:
  100|  15.8k|   return ffi_guard_thunk(__func__, [=]() -> int {
  101|  15.8k|      if(any_null_pointers(cipher, cipher_name)) {
  ------------------
  |  Branch (101:10): [True: 0, False: 15.8k]
  ------------------
  102|      0|         return BOTAN_FFI_ERROR_NULL_POINTER;
  103|      0|      }
  104|  15.8k|      const bool encrypt_p = ((flags & BOTAN_CIPHER_INIT_FLAG_MASK_DIRECTION) == BOTAN_CIPHER_INIT_FLAG_ENCRYPT);
  ------------------
  |  |  676|  15.8k|#define BOTAN_CIPHER_INIT_FLAG_MASK_DIRECTION 1
  ------------------
                    const bool encrypt_p = ((flags & BOTAN_CIPHER_INIT_FLAG_MASK_DIRECTION) == BOTAN_CIPHER_INIT_FLAG_ENCRYPT);
  ------------------
  |  |  677|  15.8k|#define BOTAN_CIPHER_INIT_FLAG_ENCRYPT 0
  ------------------
  105|  15.8k|      const Botan::Cipher_Dir dir = encrypt_p ? Botan::Cipher_Dir::Encryption : Botan::Cipher_Dir::Decryption;
  ------------------
  |  Branch (105:37): [True: 7.88k, False: 7.98k]
  ------------------
  106|       |
  107|  15.8k|      std::unique_ptr<Botan::Cipher_Mode> mode(Botan::Cipher_Mode::create(cipher_name, dir));
  108|  15.8k|      if(!mode) {
  ------------------
  |  Branch (108:10): [True: 0, False: 15.8k]
  ------------------
  109|      0|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  110|      0|      }
  111|       |
  112|  15.8k|      const size_t update_size = ffi_choose_update_size(*mode);
  113|  15.8k|      const size_t ideal_update_size = std::max(mode->ideal_granularity(), update_size);
  114|       |
  115|  15.8k|      return ffi_new_object(cipher, std::move(mode), update_size, ideal_update_size);
  116|  15.8k|   });
_ZN19botan_cipher_structC2ENSt3__110unique_ptrIN5Botan11Cipher_ModeENS0_14default_deleteIS3_EEEEmm:
   28|  15.5k|            botan_struct(std::move(x)), m_update_size(update_size), m_ideal_update_size(ideal_update_size) {
   29|  15.5k|         BOTAN_DEBUG_ASSERT(ideal_update_size >= update_size);
  ------------------
  |  |  130|  15.5k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  15.5k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 15.5k]
  |  |  ------------------
  ------------------
   30|  15.5k|         m_buf.reserve(m_ideal_update_size);
   31|  15.5k|      }
_ZN19botan_cipher_struct3bufEv:
   33|  1.44M|      Botan::secure_vector<uint8_t>& buf() { return m_buf; }
ffi_cipher.cpp:_ZZ18botan_cipher_startENK3$_0clEv:
  185|   721k|   return ffi_guard_thunk(__func__, [=]() -> int {
  186|   721k|      Botan::Cipher_Mode& cipher = safe_get(cipher_obj);
  187|   721k|      cipher.start(nonce, nonce_len);
  188|   721k|      return BOTAN_FFI_SUCCESS;
  189|   721k|   });
ffi_cipher.cpp:_ZZ19botan_cipher_updateENK3$_0clEv:
  210|   727k|   return ffi_guard_thunk(__func__, [=]() -> int {
  211|   727k|      using namespace Botan;
  212|   727k|      Cipher_Mode& cipher = safe_get(cipher_obj);
  213|   727k|      secure_vector<uint8_t>& mbuf = cipher_obj->buf();
  214|       |
  215|       |      // If the cipher object's internal buffer contains residual data from
  216|       |      // a previous invocation, we can be sure that botan_cipher_update() was
  217|       |      // called with the final flag set but not enough buffer space was provided
  218|       |      // to accommodate the final output.
  219|   727k|      const bool was_finished_before = !mbuf.empty();
  220|   727k|      const bool final_input = (flags & BOTAN_CIPHER_UPDATE_FLAG_FINAL) != 0;
  ------------------
  |  |  771|   727k|#define BOTAN_CIPHER_UPDATE_FLAG_FINAL (1U << 0)
  ------------------
  221|       |
  222|       |      // Bring the output variables into a defined state.
  223|   727k|      *output_written = 0;
  224|   727k|      *input_consumed = 0;
  225|       |
  226|       |      // Once the final flag was set once, it must always be set for
  227|       |      // consecutive invocations.
  228|   727k|      if(was_finished_before && !final_input) {
  ------------------
  |  Branch (228:10): [True: 0, False: 727k]
  |  Branch (228:33): [True: 0, False: 0]
  ------------------
  229|      0|         return BOTAN_FFI_ERROR_INVALID_OBJECT_STATE;
  230|      0|      }
  231|       |
  232|       |      // If the final flag was set in a previous invocation, no more input
  233|       |      // data can be processed.
  234|   727k|      if(was_finished_before && input_size > 0) {
  ------------------
  |  Branch (234:10): [True: 0, False: 727k]
  |  Branch (234:33): [True: 0, False: 0]
  ------------------
  235|      0|         return BOTAN_FFI_ERROR_BAD_PARAMETER;
  236|      0|      }
  237|       |
  238|       |      // Make sure that we always clear the internal buffer before returning
  239|       |      // or aborting this invocation due to an exception.
  240|   727k|      auto clean_buffer = scoped_cleanup([&mbuf] { mbuf.clear(); });
  241|       |
  242|   727k|      if(final_input) {
  ------------------
  |  Branch (242:10): [True: 720k, False: 7.49k]
  ------------------
  243|       |         // If the final flag is set for the first time, we need to process the
  244|       |         // remaining input data and then finalize the cipher object.
  245|   720k|         if(!was_finished_before) {
  ------------------
  |  Branch (245:13): [True: 720k, False: 0]
  ------------------
  246|   720k|            *input_consumed = input_size;
  247|   720k|            mbuf.resize(input_size);
  248|   720k|            copy_mem(mbuf, std::span(input, input_size));
  249|       |
  250|   720k|            try {
  251|   720k|               cipher.finish(mbuf);
  252|   720k|            } catch(Invalid_Authentication_Tag&) {
  253|  1.03k|               return BOTAN_FFI_ERROR_BAD_MAC;
  254|  1.03k|            }
  255|   720k|         }
  256|       |
  257|       |         // At this point, the cipher object is finalized (potentially in a
  258|       |         // previous invocation) and we can copy the final output to the caller.
  259|   719k|         *output_written = mbuf.size();
  260|       |
  261|       |         // Not enough space to copy the final output out to the caller.
  262|       |         // Inform them how much space we need for a successful operation.
  263|   719k|         if(output_size < mbuf.size()) {
  ------------------
  |  Branch (263:13): [True: 0, False: 719k]
  ------------------
  264|       |            // This is the only place where mbuf is not cleared before returning.
  265|      0|            clean_buffer.disengage();
  266|      0|            return BOTAN_FFI_ERROR_INSUFFICIENT_BUFFER_SPACE;
  267|      0|         }
  268|       |
  269|       |         // Copy the final output to the caller, mbuf is cleared afterwards.
  270|   719k|         copy_mem(std::span(output, mbuf.size()), mbuf);
  271|   719k|      } else {
  272|       |         // Process data in a streamed fashion without finalizing. No data is
  273|       |         // ever retained in the cipher object's internal buffer. If we run out
  274|       |         // of either input data or output capacity, we stop and report that not
  275|       |         // all bytes were processed via *output_written and *input_consumed.
  276|       |
  277|  7.49k|         BufferSlicer in({input, input_size});
  278|  7.49k|         BufferStuffer out({output, output_size});
  279|       |
  280|       |         // Helper function to do blockwise processing of data.
  281|  7.49k|         auto blockwise_update = [&](const size_t granularity) {
  282|  7.49k|            if(granularity == 0) {
  283|  7.49k|               return;
  284|  7.49k|            }
  285|       |
  286|  7.49k|            const size_t expected_output_per_iteration = cipher.requires_entire_message() ? 0 : granularity;
  287|  7.49k|            mbuf.resize(granularity);
  288|       |
  289|  7.49k|            while(in.remaining() >= granularity && out.remaining_capacity() >= expected_output_per_iteration) {
  290|  7.49k|               copy_mem(mbuf, in.take(granularity));
  291|  7.49k|               const auto written_bytes = cipher.process(mbuf);
  292|  7.49k|               BOTAN_DEBUG_ASSERT(written_bytes == expected_output_per_iteration);
  293|  7.49k|               if(written_bytes > 0) {
  294|  7.49k|                  BOTAN_ASSERT_NOMSG(written_bytes <= granularity);
  295|  7.49k|                  copy_mem(out.next(written_bytes), std::span(mbuf).first(written_bytes));
  296|  7.49k|               }
  297|  7.49k|            }
  298|  7.49k|         };
  299|       |
  300|       |         // First, process as much data as possible in chunks of ideal granularity
  301|  7.49k|         blockwise_update(cipher_obj->ideal_update_size());
  302|       |
  303|       |         // Then process the remaining bytes in chunks of update_size() or, in one go
  304|       |         // if update_size() is equal to 1 --> i.e. likely a stream cipher.
  305|  7.49k|         const bool is_stream_cipher = (cipher_obj->update_size() == 1);
  306|  7.49k|         const size_t tail_granularity =
  307|  7.49k|            is_stream_cipher ? std::min(in.remaining(), out.remaining_capacity()) : cipher_obj->update_size();
  ------------------
  |  Branch (307:13): [True: 2.75k, False: 4.73k]
  ------------------
  308|  7.49k|         BOTAN_DEBUG_ASSERT(tail_granularity < cipher_obj->ideal_update_size());
  ------------------
  |  |  130|  7.49k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  7.49k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 7.49k]
  |  |  ------------------
  ------------------
  309|  7.49k|         blockwise_update(tail_granularity);
  310|       |
  311|       |         // Inform the caller about the amount of data processed.
  312|  7.49k|         *output_written = output_size - out.remaining_capacity();
  313|  7.49k|         *input_consumed = input_size - in.remaining();
  314|  7.49k|      }
  315|       |
  316|   726k|      return BOTAN_FFI_SUCCESS;
  317|   727k|   });
ffi_cipher.cpp:_ZZZ19botan_cipher_updateENK3$_0clEvENKUlmE_clEm:
  281|  14.9k|         auto blockwise_update = [&](const size_t granularity) {
  282|  14.9k|            if(granularity == 0) {
  ------------------
  |  Branch (282:16): [True: 604, False: 14.3k]
  ------------------
  283|    604|               return;
  284|    604|            }
  285|       |
  286|  14.3k|            const size_t expected_output_per_iteration = cipher.requires_entire_message() ? 0 : granularity;
  ------------------
  |  Branch (286:58): [True: 0, False: 14.3k]
  ------------------
  287|  14.3k|            mbuf.resize(granularity);
  288|       |
  289|  1.69M|            while(in.remaining() >= granularity && out.remaining_capacity() >= expected_output_per_iteration) {
  ------------------
  |  Branch (289:19): [True: 1.67M, False: 14.3k]
  |  Branch (289:52): [True: 1.67M, False: 0]
  ------------------
  290|  1.67M|               copy_mem(mbuf, in.take(granularity));
  291|  1.67M|               const auto written_bytes = cipher.process(mbuf);
  292|  1.67M|               BOTAN_DEBUG_ASSERT(written_bytes == expected_output_per_iteration);
  ------------------
  |  |  130|  1.67M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  1.67M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 1.67M]
  |  |  ------------------
  ------------------
  293|  1.67M|               if(written_bytes > 0) {
  ------------------
  |  Branch (293:19): [True: 1.67M, False: 0]
  ------------------
  294|  1.67M|                  BOTAN_ASSERT_NOMSG(written_bytes <= granularity);
  ------------------
  |  |   77|  1.67M|   do {                                                                     \
  |  |   78|  1.67M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.67M|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.67M]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.67M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.67M]
  |  |  ------------------
  ------------------
  295|  1.67M|                  copy_mem(out.next(written_bytes), std::span(mbuf).first(written_bytes));
  296|  1.67M|               }
  297|  1.67M|            }
  298|  14.3k|         };
_ZNK19botan_cipher_struct17ideal_update_sizeEv:
   37|  7.49k|      size_t ideal_update_size() const { return m_ideal_update_size; }
_ZNK19botan_cipher_struct11update_sizeEv:
   35|  27.7k|      size_t update_size() const { return m_update_size; }
ffi_cipher.cpp:_ZZZ19botan_cipher_updateENK3$_0clEvENKUlvE_clEv:
  240|   727k|      auto clean_buffer = scoped_cleanup([&mbuf] { mbuf.clear(); });

botan_hash_init:
   18|  40.5k|int botan_hash_init(botan_hash_t* hash, const char* hash_name, uint32_t flags) {
   19|  40.5k|   return ffi_guard_thunk(__func__, [=]() -> int {
   20|  40.5k|      if(hash == nullptr || hash_name == nullptr || *hash_name == 0) {
   21|  40.5k|         return BOTAN_FFI_ERROR_NULL_POINTER;
   22|  40.5k|      }
   23|  40.5k|      if(flags != 0) {
   24|  40.5k|         return BOTAN_FFI_ERROR_BAD_FLAG;
   25|  40.5k|      }
   26|       |
   27|  40.5k|      auto h = Botan::HashFunction::create(hash_name);
   28|  40.5k|      if(h == nullptr) {
   29|  40.5k|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   30|  40.5k|      }
   31|       |
   32|  40.5k|      ffi_new_object(hash, std::move(h));
   33|  40.5k|      return BOTAN_FFI_SUCCESS;
   34|  40.5k|   });
   35|  40.5k|}
botan_hash_destroy:
   37|  40.4k|int botan_hash_destroy(botan_hash_t hash) {
   38|  40.4k|   return BOTAN_FFI_CHECKED_DELETE(hash);
  ------------------
  |  |  188|  40.4k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
   39|  40.4k|}
botan_hash_output_length:
   41|  40.4k|int botan_hash_output_length(botan_hash_t hash, size_t* out) {
   42|  40.4k|   if(out == nullptr) {
  ------------------
  |  Branch (42:7): [True: 0, False: 40.4k]
  ------------------
   43|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   44|      0|   }
   45|  40.4k|   return BOTAN_FFI_VISIT(hash, [=](const auto& h) { *out = h.output_length(); });
  ------------------
  |  |  158|  40.4k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   46|  40.4k|}
botan_hash_update:
   66|  27.4M|int botan_hash_update(botan_hash_t hash, const uint8_t* buf, size_t len) {
   67|  27.4M|   if(len == 0) {
  ------------------
  |  Branch (67:7): [True: 2.37k, False: 27.4M]
  ------------------
   68|  2.37k|      return 0;
   69|  2.37k|   }
   70|       |
   71|  27.4M|   if(buf == nullptr) {
  ------------------
  |  Branch (71:7): [True: 0, False: 27.4M]
  ------------------
   72|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   73|      0|   }
   74|       |
   75|  27.4M|   return BOTAN_FFI_VISIT(hash, [=](auto& h) { h.update(buf, len); });
  ------------------
  |  |  158|  27.4M|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   76|  27.4M|}
botan_hash_final:
   78|  26.3k|int botan_hash_final(botan_hash_t hash, uint8_t out[]) {
   79|  26.3k|   if(out == nullptr) {
  ------------------
  |  Branch (79:7): [True: 0, False: 26.3k]
  ------------------
   80|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   81|      0|   }
   82|  26.3k|   return BOTAN_FFI_VISIT(hash, [=](auto& h) { h.final(out); });
  ------------------
  |  |  158|  26.3k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   83|  26.3k|}
ffi_hash.cpp:_ZZ15botan_hash_initENK3$_0clEv:
   19|  40.5k|   return ffi_guard_thunk(__func__, [=]() -> int {
   20|  40.5k|      if(hash == nullptr || hash_name == nullptr || *hash_name == 0) {
  ------------------
  |  Branch (20:10): [True: 0, False: 40.5k]
  |  Branch (20:29): [True: 0, False: 40.5k]
  |  Branch (20:53): [True: 0, False: 40.5k]
  ------------------
   21|      0|         return BOTAN_FFI_ERROR_NULL_POINTER;
   22|      0|      }
   23|  40.5k|      if(flags != 0) {
  ------------------
  |  Branch (23:10): [True: 0, False: 40.5k]
  ------------------
   24|      0|         return BOTAN_FFI_ERROR_BAD_FLAG;
   25|      0|      }
   26|       |
   27|  40.5k|      auto h = Botan::HashFunction::create(hash_name);
   28|  40.5k|      if(h == nullptr) {
  ------------------
  |  Branch (28:10): [True: 101, False: 40.4k]
  ------------------
   29|    101|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   30|    101|      }
   31|       |
   32|  40.4k|      ffi_new_object(hash, std::move(h));
   33|  40.4k|      return BOTAN_FFI_SUCCESS;
   34|  40.5k|   });

botan_pwdhash:
   63|  20.5k|                  size_t salt_len) {
   64|  20.5k|   if(any_null_pointers(algo, password)) {
  ------------------
  |  Branch (64:7): [True: 0, False: 20.5k]
  ------------------
   65|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   66|      0|   }
   67|  20.5k|   if(out_len > 0 && out == nullptr) {
  ------------------
  |  Branch (67:7): [True: 20.5k, False: 0]
  |  Branch (67:22): [True: 0, False: 20.5k]
  ------------------
   68|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   69|      0|   }
   70|  20.5k|   if(salt_len > 0 && salt == nullptr) {
  ------------------
  |  Branch (70:7): [True: 19.8k, False: 731]
  |  Branch (70:23): [True: 0, False: 19.8k]
  ------------------
   71|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   72|      0|   }
   73|       |
   74|  20.5k|   if(password_len == 0) {
  ------------------
  |  Branch (74:7): [True: 20.3k, False: 241]
  ------------------
   75|  20.3k|      password_len = std::strlen(password);
   76|  20.3k|   }
   77|       |
   78|  20.5k|   return ffi_guard_thunk(__func__, [=]() -> int {
   79|  20.5k|      auto pwdhash_fam = Botan::PasswordHashFamily::create(algo);
   80|       |
   81|  20.5k|      if(!pwdhash_fam) {
   82|  20.5k|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   83|  20.5k|      }
   84|       |
   85|  20.5k|      auto pwdhash = pwdhash_fam->from_params(param1, param2, param3);
   86|       |
   87|  20.5k|      pwdhash->derive_key(out, out_len, password, password_len, salt, salt_len);
   88|       |
   89|  20.5k|      return BOTAN_FFI_SUCCESS;
   90|  20.5k|   });
   91|  20.5k|}
botan_kdf:
  151|  6.79k|              size_t label_len) {
  152|  6.79k|   if(kdf_algo == nullptr) {
  ------------------
  |  Branch (152:7): [True: 0, False: 6.79k]
  ------------------
  153|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  154|      0|   }
  155|  6.79k|   if((out_len > 0 && out == nullptr) || (secret_len > 0 && secret == nullptr) || (salt_len > 0 && salt == nullptr) ||
  ------------------
  |  Branch (155:8): [True: 6.79k, False: 0]
  |  Branch (155:23): [True: 0, False: 6.79k]
  |  Branch (155:43): [True: 6.79k, False: 0]
  |  Branch (155:61): [True: 0, False: 6.79k]
  |  Branch (155:84): [True: 3.04k, False: 3.75k]
  |  Branch (155:100): [True: 0, False: 3.04k]
  ------------------
  156|  6.79k|      (label_len > 0 && label == nullptr)) {
  ------------------
  |  Branch (156:8): [True: 6.79k, False: 0]
  |  Branch (156:25): [True: 0, False: 6.79k]
  ------------------
  157|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  158|      0|   }
  159|  6.79k|   return ffi_guard_thunk(__func__, [=]() -> int {
  160|  6.79k|      auto kdf = Botan::KDF::create_or_throw(kdf_algo);
  161|  6.79k|      kdf->kdf(out, out_len, secret, secret_len, salt, salt_len, label, label_len);
  162|  6.79k|      return BOTAN_FFI_SUCCESS;
  163|  6.79k|   });
  164|  6.79k|}
ffi_kdf.cpp:_ZZ13botan_pwdhashENK3$_0clEv:
   78|  20.5k|   return ffi_guard_thunk(__func__, [=]() -> int {
   79|  20.5k|      auto pwdhash_fam = Botan::PasswordHashFamily::create(algo);
   80|       |
   81|  20.5k|      if(!pwdhash_fam) {
  ------------------
  |  Branch (81:10): [True: 386, False: 20.2k]
  ------------------
   82|    386|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   83|    386|      }
   84|       |
   85|  20.2k|      auto pwdhash = pwdhash_fam->from_params(param1, param2, param3);
   86|       |
   87|  20.2k|      pwdhash->derive_key(out, out_len, password, password_len, salt, salt_len);
   88|       |
   89|  20.2k|      return BOTAN_FFI_SUCCESS;
   90|  20.5k|   });
ffi_kdf.cpp:_ZZ9botan_kdfENK3$_0clEv:
  159|  6.79k|   return ffi_guard_thunk(__func__, [=]() -> int {
  160|  6.79k|      auto kdf = Botan::KDF::create_or_throw(kdf_algo);
  161|  6.79k|      kdf->kdf(out, out_len, secret, secret_len, salt, salt_len, label, label_len);
  162|  6.79k|      return BOTAN_FFI_SUCCESS;
  163|  6.79k|   });

botan_mp_init:
   24|  17.9k|int botan_mp_init(botan_mp_t* mp_out) {
   25|  17.9k|   return ffi_guard_thunk(__func__, [=]() -> int {
   26|  17.9k|      if(mp_out == nullptr) {
   27|  17.9k|         return BOTAN_FFI_ERROR_NULL_POINTER;
   28|  17.9k|      }
   29|       |
   30|  17.9k|      auto mp = std::make_unique<Botan::BigInt>();
   31|  17.9k|      return ffi_new_object(mp_out, std::move(mp));
   32|  17.9k|   });
   33|  17.9k|}
botan_mp_from_bin:
   84|  17.9k|int botan_mp_from_bin(botan_mp_t mp, const uint8_t bin[], size_t bin_len) {
   85|  17.9k|   if(bin_len > 0 && bin == nullptr) {
  ------------------
  |  Branch (85:7): [True: 17.9k, False: 0]
  |  Branch (85:22): [True: 0, False: 17.9k]
  ------------------
   86|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   87|      0|   }
   88|  17.9k|   return BOTAN_FFI_VISIT(mp, [=](auto& bn) { bn._assign_from_bytes({bin, bin_len}); });
  ------------------
  |  |  158|  17.9k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   89|  17.9k|}
botan_mp_destroy:
  157|  17.9k|int botan_mp_destroy(botan_mp_t mp) {
  158|  17.9k|   return BOTAN_FFI_CHECKED_DELETE(mp);
  ------------------
  |  |  188|  17.9k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
  159|  17.9k|}
ffi_mp.cpp:_ZZ13botan_mp_initENK3$_0clEv:
   25|  17.9k|   return ffi_guard_thunk(__func__, [=]() -> int {
   26|  17.9k|      if(mp_out == nullptr) {
  ------------------
  |  Branch (26:10): [True: 0, False: 17.9k]
  ------------------
   27|      0|         return BOTAN_FFI_ERROR_NULL_POINTER;
   28|      0|      }
   29|       |
   30|  17.9k|      auto mp = std::make_unique<Botan::BigInt>();
   31|  17.9k|      return ffi_new_object(mp_out, std::move(mp));
   32|  17.9k|   });

botan_pk_op_encrypt_create:
   28|     41|int botan_pk_op_encrypt_create(botan_pk_op_encrypt_t* op, botan_pubkey_t key_obj, const char* padding, uint32_t flags) {
   29|     41|   if(Botan::any_null_pointers(op, padding)) {
  ------------------
  |  Branch (29:7): [True: 0, False: 41]
  ------------------
   30|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   31|      0|   }
   32|       |
   33|     41|   if(flags != 0 && flags != BOTAN_PUBKEY_DER_FORMAT_SIGNATURE) {
  ------------------
  |  | 3123|      0|#define BOTAN_PUBKEY_DER_FORMAT_SIGNATURE 1
  ------------------
  |  Branch (33:7): [True: 0, False: 41]
  |  Branch (33:21): [True: 0, False: 0]
  ------------------
   34|      0|      return BOTAN_FFI_ERROR_BAD_FLAG;
   35|      0|   }
   36|       |
   37|     41|   return ffi_guard_thunk(__func__, [=]() -> int {
   38|     41|      *op = nullptr;
   39|       |
   40|     41|      auto pk = std::make_unique<Botan::PK_Encryptor_EME>(safe_get(key_obj), Botan::system_rng(), padding);
   41|     41|      return ffi_new_object(op, std::move(pk));
   42|     41|   });
   43|     41|}
botan_pk_op_encrypt_destroy:
   45|     41|int botan_pk_op_encrypt_destroy(botan_pk_op_encrypt_t op) {
   46|     41|   return BOTAN_FFI_CHECKED_DELETE(op);
  ------------------
  |  |  188|     41|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
   47|     41|}
botan_pk_op_encrypt:
   61|     41|                        size_t plaintext_len) {
   62|     41|   if(plaintext_len > 0 && plaintext == nullptr) {
  ------------------
  |  Branch (62:7): [True: 41, False: 0]
  |  Branch (62:28): [True: 0, False: 41]
  ------------------
   63|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
   64|      0|   }
   65|       |
   66|     41|   return BOTAN_FFI_VISIT(op, [=](const auto& o) {
  ------------------
  |  |  158|     41|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
   67|     41|      return write_vec_output(out, out_len, o.encrypt(plaintext, plaintext_len, safe_get(rng_obj)));
   68|     41|   });
   69|     41|}
botan_pk_op_verify_create:
  162|  10.7k|int botan_pk_op_verify_create(botan_pk_op_verify_t* op, botan_pubkey_t key_obj, const char* hash, uint32_t flags) {
  163|  10.7k|   if(Botan::any_null_pointers(op, hash)) {
  ------------------
  |  Branch (163:7): [True: 0, False: 10.7k]
  ------------------
  164|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  165|      0|   }
  166|       |
  167|  10.7k|   if(flags != 0 && flags != BOTAN_PUBKEY_DER_FORMAT_SIGNATURE) {
  ------------------
  |  | 3123|      0|#define BOTAN_PUBKEY_DER_FORMAT_SIGNATURE 1
  ------------------
  |  Branch (167:7): [True: 0, False: 10.7k]
  |  Branch (167:21): [True: 0, False: 0]
  ------------------
  168|      0|      return BOTAN_FFI_ERROR_BAD_FLAG;
  169|      0|   }
  170|       |
  171|  10.7k|   return ffi_guard_thunk(__func__, [=]() -> int {
  172|  10.7k|      *op = nullptr;
  173|  10.7k|      const bool use_der = (flags & BOTAN_PUBKEY_DER_FORMAT_SIGNATURE) != 0;
  174|  10.7k|      auto format = use_der ? Botan::Signature_Format::DerSequence : Botan::Signature_Format::Standard;
  175|  10.7k|      auto pk = std::make_unique<Botan::PK_Verifier>(safe_get(key_obj), hash, format);
  176|  10.7k|      return ffi_new_object(op, std::move(pk));
  177|  10.7k|   });
  178|  10.7k|}
botan_pk_op_verify_destroy:
  180|  10.7k|int botan_pk_op_verify_destroy(botan_pk_op_verify_t op) {
  181|  10.7k|   return BOTAN_FFI_CHECKED_DELETE(op);
  ------------------
  |  |  188|  10.7k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
  182|  10.7k|}
botan_pk_op_verify_update:
  184|  10.7k|int botan_pk_op_verify_update(botan_pk_op_verify_t op, const uint8_t in[], size_t in_len) {
  185|  10.7k|   if(in_len > 0 && in == nullptr) {
  ------------------
  |  Branch (185:7): [True: 10.7k, False: 0]
  |  Branch (185:21): [True: 0, False: 10.7k]
  ------------------
  186|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  187|      0|   }
  188|       |
  189|  10.7k|   return BOTAN_FFI_VISIT(op, [=](auto& o) { o.update(in, in_len); });
  ------------------
  |  |  158|  10.7k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  190|  10.7k|}
botan_pk_op_verify_finish:
  192|  10.7k|int botan_pk_op_verify_finish(botan_pk_op_verify_t op, const uint8_t sig[], size_t sig_len) {
  193|  10.7k|   if(sig_len > 0 && sig == nullptr) {
  ------------------
  |  Branch (193:7): [True: 10.7k, False: 0]
  |  Branch (193:22): [True: 0, False: 10.7k]
  ------------------
  194|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  195|      0|   }
  196|       |
  197|  10.7k|   return BOTAN_FFI_VISIT(op, [=](auto& o) {
  ------------------
  |  |  158|  10.7k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  198|  10.7k|      const bool legit = o.check_signature(sig, sig_len);
  199|       |
  200|  10.7k|      if(legit) {
  201|  10.7k|         return BOTAN_FFI_SUCCESS;
  202|  10.7k|      } else {
  203|  10.7k|         return BOTAN_FFI_INVALID_VERIFIER;
  204|  10.7k|      }
  205|  10.7k|   });
  206|  10.7k|}
ffi_pk_op.cpp:_ZZ26botan_pk_op_encrypt_createENK3$_0clEv:
   37|     41|   return ffi_guard_thunk(__func__, [=]() -> int {
   38|     41|      *op = nullptr;
   39|       |
   40|     41|      auto pk = std::make_unique<Botan::PK_Encryptor_EME>(safe_get(key_obj), Botan::system_rng(), padding);
   41|     41|      return ffi_new_object(op, std::move(pk));
   42|     41|   });
ffi_pk_op.cpp:_ZZ25botan_pk_op_verify_createENK3$_0clEv:
  171|  10.7k|   return ffi_guard_thunk(__func__, [=]() -> int {
  172|  10.7k|      *op = nullptr;
  173|  10.7k|      const bool use_der = (flags & BOTAN_PUBKEY_DER_FORMAT_SIGNATURE) != 0;
  ------------------
  |  | 3123|  10.7k|#define BOTAN_PUBKEY_DER_FORMAT_SIGNATURE 1
  ------------------
  174|  10.7k|      auto format = use_der ? Botan::Signature_Format::DerSequence : Botan::Signature_Format::Standard;
  ------------------
  |  Branch (174:21): [True: 0, False: 10.7k]
  ------------------
  175|  10.7k|      auto pk = std::make_unique<Botan::PK_Verifier>(safe_get(key_obj), hash, format);
  176|  10.7k|      return ffi_new_object(op, std::move(pk));
  177|  10.7k|   });

botan_pubkey_destroy:
  148|  10.9k|int botan_pubkey_destroy(botan_pubkey_t key) {
  149|  10.9k|   return BOTAN_FFI_CHECKED_DELETE(key);
  ------------------
  |  |  188|  10.9k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
  150|  10.9k|}

botan_pubkey_load_rsa:
  273|    429|int botan_pubkey_load_rsa(botan_pubkey_t* key, botan_mp_t n, botan_mp_t e) {
  274|    429|#if defined(BOTAN_HAS_RSA)
  275|    429|   if(key == nullptr) {
  ------------------
  |  Branch (275:7): [True: 0, False: 429]
  ------------------
  276|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  277|      0|   }
  278|    429|   *key = nullptr;
  279|    429|   return ffi_guard_thunk(__func__, [=]() -> int {
  280|    429|      auto rsa = std::make_unique<Botan::RSA_PublicKey>(safe_get(n), safe_get(e));
  281|    429|      return ffi_new_object(key, std::move(rsa));
  282|    429|   });
  283|       |#else
  284|       |   BOTAN_UNUSED(key, n, e);
  285|       |   return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  286|       |#endif
  287|    429|}
botan_pubkey_load_dsa:
  401|  1.08k|int botan_pubkey_load_dsa(botan_pubkey_t* key, botan_mp_t p, botan_mp_t q, botan_mp_t g, botan_mp_t y) {
  402|  1.08k|#if defined(BOTAN_HAS_DSA)
  403|  1.08k|   if(key == nullptr) {
  ------------------
  |  Branch (403:7): [True: 0, False: 1.08k]
  ------------------
  404|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  405|      0|   }
  406|  1.08k|   *key = nullptr;
  407|       |
  408|  1.08k|   return ffi_guard_thunk(__func__, [=]() -> int {
  409|  1.08k|      const Botan::DL_Group group(safe_get(p), safe_get(q), safe_get(g));
  410|  1.08k|      auto dsa = std::make_unique<Botan::DSA_PublicKey>(group, safe_get(y));
  411|  1.08k|      return ffi_new_object(key, std::move(dsa));
  412|  1.08k|   });
  413|       |#else
  414|       |   BOTAN_UNUSED(key, p, q, g, y);
  415|       |   return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  416|       |#endif
  417|  1.08k|}
botan_pubkey_load_ecdsa:
  468|  6.29k|                            const char* curve_name) {
  469|  6.29k|#if defined(BOTAN_HAS_ECDSA)
  470|  6.29k|   if(Botan::any_null_pointers(key, curve_name)) {
  ------------------
  |  Branch (470:7): [True: 0, False: 6.29k]
  ------------------
  471|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  472|      0|   }
  473|  6.29k|   *key = nullptr;
  474|       |
  475|  6.29k|   return ffi_guard_thunk(__func__, [=]() -> int {
  476|  6.29k|      std::unique_ptr<Botan::ECDSA_PublicKey> p_key;
  477|       |
  478|  6.29k|      const int rc = pubkey_load_ec(p_key, safe_get(public_x), safe_get(public_y), curve_name);
  479|  6.29k|      if(rc == BOTAN_FFI_SUCCESS) {
  480|  6.29k|         ffi_new_object(key, std::move(p_key));
  481|  6.29k|      }
  482|       |
  483|  6.29k|      return rc;
  484|  6.29k|   });
  485|       |#else
  486|       |   BOTAN_UNUSED(key, public_x, public_y, curve_name);
  487|       |   return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  488|       |#endif
  489|  6.29k|}
botan_pubkey_load_elgamal:
  562|     41|int botan_pubkey_load_elgamal(botan_pubkey_t* key, botan_mp_t p, botan_mp_t g, botan_mp_t y) {
  563|     41|#if defined(BOTAN_HAS_ELGAMAL)
  564|     41|   if(key == nullptr) {
  ------------------
  |  Branch (564:7): [True: 0, False: 41]
  ------------------
  565|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  566|      0|   }
  567|     41|   *key = nullptr;
  568|     41|   return ffi_guard_thunk(__func__, [=]() -> int {
  569|     41|      const Botan::DL_Group group(safe_get(p), safe_get(g));
  570|     41|      auto elg = std::make_unique<Botan::ElGamal_PublicKey>(group, safe_get(y));
  571|     41|      return ffi_new_object(key, std::move(elg));
  572|     41|   });
  573|       |#else
  574|       |   BOTAN_UNUSED(key, p, g, y);
  575|       |   return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  576|       |#endif
  577|     41|}
botan_pubkey_load_ed25519:
  915|  3.08k|int botan_pubkey_load_ed25519(botan_pubkey_t* key, const uint8_t pubkey[32]) {
  916|  3.08k|#if defined(BOTAN_HAS_ED25519)
  917|  3.08k|   if(any_null_pointers(key, pubkey)) {
  ------------------
  |  Branch (917:7): [True: 0, False: 3.08k]
  ------------------
  918|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  919|      0|   }
  920|  3.08k|   *key = nullptr;
  921|  3.08k|   return ffi_guard_thunk(__func__, [=]() -> int {
  922|  3.08k|      const std::vector<uint8_t> pubkey_vec(pubkey, pubkey + 32);
  923|  3.08k|      auto ed25519 = std::make_unique<Botan::Ed25519_PublicKey>(pubkey_vec);
  924|  3.08k|      return ffi_new_object(key, std::move(ed25519));
  925|  3.08k|   });
  926|       |#else
  927|       |   BOTAN_UNUSED(key, pubkey);
  928|       |   return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  929|       |#endif
  930|  3.08k|}
ffi_pkey_algs.cpp:_ZZ21botan_pubkey_load_rsaENK3$_0clEv:
  279|    429|   return ffi_guard_thunk(__func__, [=]() -> int {
  280|    429|      auto rsa = std::make_unique<Botan::RSA_PublicKey>(safe_get(n), safe_get(e));
  281|    429|      return ffi_new_object(key, std::move(rsa));
  282|    429|   });
ffi_pkey_algs.cpp:_ZZ21botan_pubkey_load_dsaENK3$_0clEv:
  408|  1.08k|   return ffi_guard_thunk(__func__, [=]() -> int {
  409|  1.08k|      const Botan::DL_Group group(safe_get(p), safe_get(q), safe_get(g));
  410|  1.08k|      auto dsa = std::make_unique<Botan::DSA_PublicKey>(group, safe_get(y));
  411|  1.08k|      return ffi_new_object(key, std::move(dsa));
  412|  1.08k|   });
ffi_pkey_algs.cpp:_ZZ23botan_pubkey_load_ecdsaENK3$_0clEv:
  475|  6.29k|   return ffi_guard_thunk(__func__, [=]() -> int {
  476|  6.29k|      std::unique_ptr<Botan::ECDSA_PublicKey> p_key;
  477|       |
  478|  6.29k|      const int rc = pubkey_load_ec(p_key, safe_get(public_x), safe_get(public_y), curve_name);
  479|  6.29k|      if(rc == BOTAN_FFI_SUCCESS) {
  ------------------
  |  Branch (479:10): [True: 6.25k, False: 41]
  ------------------
  480|  6.25k|         ffi_new_object(key, std::move(p_key));
  481|  6.25k|      }
  482|       |
  483|  6.29k|      return rc;
  484|  6.29k|   });
ffi_pkey_algs.cpp:_ZN12_GLOBAL__N_114pubkey_load_ecIN5Botan15ECDSA_PublicKeyEEEiRNSt3__110unique_ptrIT_NS3_14default_deleteIS5_EEEERKNS1_6BigIntESC_PKc:
  123|  6.29k|                   const char* curve_name) {
  124|  6.29k|   if(curve_name == nullptr) {
  ------------------
  |  Branch (124:7): [True: 0, False: 6.29k]
  ------------------
  125|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  126|      0|   }
  127|       |
  128|  6.29k|   if(!Botan::EC_Group::supports_named_group(curve_name)) {
  ------------------
  |  Branch (128:7): [True: 0, False: 6.29k]
  ------------------
  129|      0|      return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
  130|      0|   }
  131|       |
  132|  6.29k|   const auto group = Botan::EC_Group::from_name(curve_name);
  133|       |
  134|  6.29k|   if(auto pt = Botan::EC_AffinePoint::from_bigint_xy(group, public_x, public_y)) {
  ------------------
  |  Branch (134:12): [True: 6.25k, False: 41]
  ------------------
  135|  6.25k|      key.reset(new ECPublicKey_t(group, pt.value()));
  136|  6.25k|      return BOTAN_FFI_SUCCESS;
  137|  6.25k|   } else {
  138|     41|      return BOTAN_FFI_ERROR_BAD_PARAMETER;
  139|     41|   }
  140|  6.29k|}
ffi_pkey_algs.cpp:_ZZ25botan_pubkey_load_elgamalENK3$_0clEv:
  568|     41|   return ffi_guard_thunk(__func__, [=]() -> int {
  569|     41|      const Botan::DL_Group group(safe_get(p), safe_get(g));
  570|     41|      auto elg = std::make_unique<Botan::ElGamal_PublicKey>(group, safe_get(y));
  571|     41|      return ffi_new_object(key, std::move(elg));
  572|     41|   });
ffi_pkey_algs.cpp:_ZZ25botan_pubkey_load_ed25519ENK3$_0clEv:
  921|  3.08k|   return ffi_guard_thunk(__func__, [=]() -> int {
  922|  3.08k|      const std::vector<uint8_t> pubkey_vec(pubkey, pubkey + 32);
  923|  3.08k|      auto ed25519 = std::make_unique<Botan::Ed25519_PublicKey>(pubkey_vec);
  924|  3.08k|      return ffi_new_object(key, std::move(ed25519));
  925|  3.08k|   });

botan_rng_init:
   38|  12.7k|int botan_rng_init(botan_rng_t* rng_out, const char* rng_type) {
   39|  12.7k|   return ffi_guard_thunk(__func__, [=]() -> int {
   40|  12.7k|      if(rng_out == nullptr) {
   41|  12.7k|         return BOTAN_FFI_ERROR_NULL_POINTER;
   42|  12.7k|      }
   43|       |
   44|  12.7k|      const std::string rng_type_s(rng_type != nullptr ? rng_type : "system");
   45|       |
   46|  12.7k|      std::unique_ptr<Botan::RandomNumberGenerator> rng;
   47|       |
   48|  12.7k|      if(rng_type_s == "system") {
   49|  12.7k|         rng = std::make_unique<Botan::System_RNG>();
   50|  12.7k|      } else if(rng_type_s == "user" || rng_type_s == "user-threadsafe") {
   51|  12.7k|         rng = std::make_unique<Botan::AutoSeeded_RNG>();
   52|  12.7k|      } else if(rng_type_s == "null") {
   53|  12.7k|         rng = std::make_unique<Botan::Null_RNG>();
   54|  12.7k|      }
   55|       |#if defined(BOTAN_HAS_PROCESSOR_RNG)
   56|       |      else if((rng_type_s == "rdrand" || rng_type_s == "hwrng") && Botan::Processor_RNG::available()) {
   57|       |         rng = std::make_unique<Botan::Processor_RNG>();
   58|       |      }
   59|       |#endif
   60|       |#if defined(BOTAN_HAS_JITTER_RNG)
   61|       |      else if(rng_type_s == "jitter") {
   62|       |         rng = std::make_unique<Botan::Jitter_RNG>();
   63|       |      }
   64|       |#endif
   65|       |#if defined(BOTAN_HAS_ESDM_RNG)
   66|       |      else if(rng_type_s == "esdm-full") {
   67|       |         rng = std::make_unique<Botan::ESDM_RNG>(false);
   68|       |      } else if(rng_type_s == "esdm-pr") {
   69|       |         rng = std::make_unique<Botan::ESDM_RNG>(true);
   70|       |      }
   71|       |#endif
   72|       |
   73|  12.7k|      if(!rng) {
   74|  12.7k|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   75|  12.7k|      }
   76|       |
   77|  12.7k|      return ffi_new_object(rng_out, std::move(rng));
   78|  12.7k|   });
   79|  12.7k|}
botan_rng_destroy:
  164|  12.7k|int botan_rng_destroy(botan_rng_t rng) {
  165|  12.7k|   return BOTAN_FFI_CHECKED_DELETE(rng);
  ------------------
  |  |  188|  12.7k|#define BOTAN_FFI_CHECKED_DELETE(o) ffi_delete_object(o, __func__)
  ------------------
  166|  12.7k|}
botan_rng_get:
  168|  26.4k|int botan_rng_get(botan_rng_t rng, uint8_t* out, size_t out_len) {
  169|  26.4k|   if(out_len > 0 && out == nullptr) {
  ------------------
  |  Branch (169:7): [True: 26.4k, False: 0]
  |  Branch (169:22): [True: 0, False: 26.4k]
  ------------------
  170|      0|      return BOTAN_FFI_ERROR_NULL_POINTER;
  171|      0|   }
  172|  26.4k|   return BOTAN_FFI_VISIT(rng, [=](auto& r) { r.randomize(out, out_len); });
  ------------------
  |  |  158|  26.4k|#define BOTAN_FFI_VISIT(obj, lambda) botan_ffi_visit(obj, lambda, __func__)
  ------------------
  173|  26.4k|}
ffi_rng.cpp:_ZZ14botan_rng_initENK3$_0clEv:
   39|  12.7k|   return ffi_guard_thunk(__func__, [=]() -> int {
   40|  12.7k|      if(rng_out == nullptr) {
  ------------------
  |  Branch (40:10): [True: 0, False: 12.7k]
  ------------------
   41|      0|         return BOTAN_FFI_ERROR_NULL_POINTER;
   42|      0|      }
   43|       |
   44|  12.7k|      const std::string rng_type_s(rng_type != nullptr ? rng_type : "system");
  ------------------
  |  Branch (44:36): [True: 12.7k, False: 0]
  ------------------
   45|       |
   46|  12.7k|      std::unique_ptr<Botan::RandomNumberGenerator> rng;
   47|       |
   48|  12.7k|      if(rng_type_s == "system") {
  ------------------
  |  Branch (48:10): [True: 0, False: 12.7k]
  ------------------
   49|      0|         rng = std::make_unique<Botan::System_RNG>();
   50|  12.7k|      } else if(rng_type_s == "user" || rng_type_s == "user-threadsafe") {
  ------------------
  |  Branch (50:17): [True: 12.7k, False: 0]
  |  Branch (50:41): [True: 0, False: 0]
  ------------------
   51|  12.7k|         rng = std::make_unique<Botan::AutoSeeded_RNG>();
   52|  12.7k|      } else if(rng_type_s == "null") {
  ------------------
  |  Branch (52:17): [True: 0, False: 0]
  ------------------
   53|      0|         rng = std::make_unique<Botan::Null_RNG>();
   54|      0|      }
   55|       |#if defined(BOTAN_HAS_PROCESSOR_RNG)
   56|       |      else if((rng_type_s == "rdrand" || rng_type_s == "hwrng") && Botan::Processor_RNG::available()) {
   57|       |         rng = std::make_unique<Botan::Processor_RNG>();
   58|       |      }
   59|       |#endif
   60|       |#if defined(BOTAN_HAS_JITTER_RNG)
   61|       |      else if(rng_type_s == "jitter") {
   62|       |         rng = std::make_unique<Botan::Jitter_RNG>();
   63|       |      }
   64|       |#endif
   65|       |#if defined(BOTAN_HAS_ESDM_RNG)
   66|       |      else if(rng_type_s == "esdm-full") {
   67|       |         rng = std::make_unique<Botan::ESDM_RNG>(false);
   68|       |      } else if(rng_type_s == "esdm-pr") {
   69|       |         rng = std::make_unique<Botan::ESDM_RNG>(true);
   70|       |      }
   71|       |#endif
   72|       |
   73|  12.7k|      if(!rng) {
  ------------------
  |  Branch (73:10): [True: 0, False: 12.7k]
  ------------------
   74|      0|         return BOTAN_FFI_ERROR_NOT_IMPLEMENTED;
   75|      0|      }
   76|       |
   77|  12.7k|      return ffi_new_object(rng_out, std::move(rng));
   78|  12.7k|   });

_ZN5Botan7BLAKE2bC2Em:
   34|    422|BLAKE2b::BLAKE2b(size_t output_bits) : m_output_bits(output_bits), m_H(blake2b_IV.size()), m_T(), m_F(), m_key_size(0) {
   35|    422|   if(output_bits == 0 || output_bits > 512 || output_bits % 8 != 0) {
  ------------------
  |  Branch (35:7): [True: 0, False: 422]
  |  Branch (35:27): [True: 0, False: 422]
  |  Branch (35:48): [True: 0, False: 422]
  ------------------
   36|      0|      throw Invalid_Argument("Bad output bits size for BLAKE2b");
   37|      0|   }
   38|       |
   39|    422|   state_init();
   40|    422|}
_ZN5Botan7BLAKE2b10state_initEv:
   42|   426k|void BLAKE2b::state_init() {
   43|   426k|   copy_mem(m_H.data(), blake2b_IV.data(), blake2b_IV.size());
   44|   426k|   m_H[0] ^= (0x01010000 | (static_cast<uint8_t>(m_key_size) << 8) | static_cast<uint8_t>(output_length()));
   45|   426k|   m_T[0] = m_T[1] = 0;
   46|   426k|   m_F = 0;
   47|       |
   48|   426k|   m_buffer.clear();
   49|   426k|   if(m_key_size > 0) {
  ------------------
  |  Branch (49:7): [True: 0, False: 426k]
  ------------------
   50|      0|      m_buffer.append(m_padded_key_buffer);
   51|      0|   }
   52|   426k|}
_ZN5Botan7BLAKE2b8compressEPKhmm:
   96|   427k|void BLAKE2b::compress(const uint8_t* input, size_t blocks, uint64_t increment) {
   97|   855k|   for(size_t b = 0; b != blocks; ++b) {
  ------------------
  |  Branch (97:22): [True: 427k, False: 427k]
  ------------------
   98|   427k|      m_T[0] += increment;
   99|   427k|      if(m_T[0] < increment) {
  ------------------
  |  Branch (99:10): [True: 0, False: 427k]
  ------------------
  100|      0|         m_T[1]++;
  101|      0|      }
  102|       |
  103|   427k|      uint64_t M[16];
  104|   427k|      uint64_t v[16];
  105|   427k|      load_le(M, input, 16);
  106|       |
  107|   427k|      input += BLAKE2B_BLOCKBYTES;
  108|       |
  109|  3.84M|      for(size_t i = 0; i < 8; i++) {
  ------------------
  |  Branch (109:25): [True: 3.42M, False: 427k]
  ------------------
  110|  3.42M|         v[i] = m_H[i];
  111|  3.42M|      }
  112|  3.84M|      for(size_t i = 0; i != 8; ++i) {
  ------------------
  |  Branch (112:25): [True: 3.42M, False: 427k]
  ------------------
  113|  3.42M|         v[i + 8] = blake2b_IV[i];
  114|  3.42M|      }
  115|       |
  116|   427k|      v[12] ^= m_T[0];
  117|   427k|      v[13] ^= m_T[1];
  118|   427k|      v[14] ^= m_F;
  119|       |
  120|   427k|      ROUND<0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15>(v, M);
  121|   427k|      ROUND<14, 10, 4, 8, 9, 15, 13, 6, 1, 12, 0, 2, 11, 7, 5, 3>(v, M);
  122|   427k|      ROUND<11, 8, 12, 0, 5, 2, 15, 13, 10, 14, 3, 6, 7, 1, 9, 4>(v, M);
  123|   427k|      ROUND<7, 9, 3, 1, 13, 12, 11, 14, 2, 6, 5, 10, 4, 0, 15, 8>(v, M);
  124|   427k|      ROUND<9, 0, 5, 7, 2, 4, 10, 15, 14, 1, 11, 12, 6, 8, 3, 13>(v, M);
  125|   427k|      ROUND<2, 12, 6, 10, 0, 11, 8, 3, 4, 13, 7, 5, 15, 14, 1, 9>(v, M);
  126|   427k|      ROUND<12, 5, 1, 15, 14, 13, 4, 10, 0, 7, 6, 3, 9, 2, 8, 11>(v, M);
  127|   427k|      ROUND<13, 11, 7, 14, 12, 1, 3, 9, 5, 0, 15, 4, 8, 6, 2, 10>(v, M);
  128|   427k|      ROUND<6, 15, 14, 9, 11, 3, 0, 8, 12, 2, 13, 7, 1, 4, 10, 5>(v, M);
  129|   427k|      ROUND<10, 2, 8, 4, 7, 6, 1, 5, 15, 11, 9, 14, 3, 12, 13, 0>(v, M);
  130|   427k|      ROUND<0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15>(v, M);
  131|   427k|      ROUND<14, 10, 4, 8, 9, 15, 13, 6, 1, 12, 0, 2, 11, 7, 5, 3>(v, M);
  132|       |
  133|  3.84M|      for(size_t i = 0; i < 8; i++) {
  ------------------
  |  Branch (133:25): [True: 3.42M, False: 427k]
  ------------------
  134|  3.42M|         m_H[i] ^= v[i] ^ v[i + 8];
  135|  3.42M|      }
  136|   427k|   }
  137|   427k|}
_ZN5Botan7BLAKE2b8add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  139|   496k|void BLAKE2b::add_data(std::span<const uint8_t> input) {
  140|   496k|   BufferSlicer in(input);
  141|       |
  142|   994k|   while(!in.empty()) {
  ------------------
  |  Branch (142:10): [True: 498k, False: 496k]
  ------------------
  143|   498k|      if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (143:21): [True: 1.68k, False: 496k]
  ------------------
  144|  1.68k|         compress(one_block->data(), 1, BLAKE2B_BLOCKBYTES);
  145|  1.68k|      }
  146|       |
  147|   498k|      if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (147:10): [True: 1.68k, False: 496k]
  ------------------
  148|  1.68k|         const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
  149|  1.68k|         if(full_blocks > 0) {
  ------------------
  |  Branch (149:13): [True: 0, False: 1.68k]
  ------------------
  150|      0|            compress(aligned_data.data(), full_blocks, BLAKE2B_BLOCKBYTES);
  151|      0|         }
  152|  1.68k|      }
  153|   498k|   }
  154|   496k|}
_ZN5Botan7BLAKE2b12final_resultENSt3__14spanIhLm18446744073709551615EEE:
  156|   425k|void BLAKE2b::final_result(std::span<uint8_t> output) {
  157|   425k|   const auto pos = m_buffer.elements_in_buffer();
  158|   425k|   m_buffer.fill_up_with_zeros();
  159|       |
  160|   425k|   m_F = 0xFFFFFFFFFFFFFFFF;
  161|   425k|   compress(m_buffer.consume().data(), 1, pos);
  162|   425k|   copy_out_le(output.first(output_length()), m_H);
  163|   425k|   state_init();
  164|   425k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm0ELm1ELm2ELm3ELm4ELm5ELm6ELm7ELm8ELm9ELm10ELm11ELm12ELm13ELm14ELm15EEEvPmPKm:
   83|   855k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   855k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   855k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   855k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   855k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   855k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   855k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   855k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   855k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   855k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_11GERmS1_S1_S1_mm:
   56|  41.0M|BOTAN_FORCE_INLINE void G(uint64_t& a, uint64_t& b, uint64_t& c, uint64_t& d, uint64_t M0, uint64_t M1) {
   57|  41.0M|   a = a + b + M0;
   58|  41.0M|   d = rotr<32>(d ^ a);
   59|  41.0M|   c = c + d;
   60|  41.0M|   b = rotr<24>(b ^ c);
   61|  41.0M|   a = a + b + M1;
   62|  41.0M|   d = rotr<16>(d ^ a);
   63|  41.0M|   c = c + d;
   64|  41.0M|   b = rotr<63>(b ^ c);
   65|  41.0M|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm14ELm10ELm4ELm8ELm9ELm15ELm13ELm6ELm1ELm12ELm0ELm2ELm11ELm7ELm5ELm3EEEvPmPKm:
   83|   855k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   855k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   855k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   855k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   855k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   855k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   855k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   855k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   855k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   855k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm11ELm8ELm12ELm0ELm5ELm2ELm15ELm13ELm10ELm14ELm3ELm6ELm7ELm1ELm9ELm4EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm7ELm9ELm3ELm1ELm13ELm12ELm11ELm14ELm2ELm6ELm5ELm10ELm4ELm0ELm15ELm8EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm9ELm0ELm5ELm7ELm2ELm4ELm10ELm15ELm14ELm1ELm11ELm12ELm6ELm8ELm3ELm13EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm2ELm12ELm6ELm10ELm0ELm11ELm8ELm3ELm4ELm13ELm7ELm5ELm15ELm14ELm1ELm9EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm12ELm5ELm1ELm15ELm14ELm13ELm4ELm10ELm0ELm7ELm6ELm3ELm9ELm2ELm8ELm11EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm13ELm11ELm7ELm14ELm12ELm1ELm3ELm9ELm5ELm0ELm15ELm4ELm8ELm6ELm2ELm10EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm6ELm15ELm14ELm9ELm11ELm3ELm0ELm8ELm12ELm2ELm13ELm7ELm1ELm4ELm10ELm5EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}
blake2b.cpp:_ZN5Botan12_GLOBAL__N_15ROUNDILm10ELm2ELm8ELm4ELm7ELm6ELm1ELm5ELm15ELm11ELm9ELm14ELm3ELm12ELm13ELm0EEEvPmPKm:
   83|   427k|BOTAN_FORCE_INLINE void ROUND(uint64_t* v, const uint64_t* M) {
   84|   427k|   G(v[0], v[4], v[8], v[12], M[i0], M[i1]);
   85|   427k|   G(v[1], v[5], v[9], v[13], M[i2], M[i3]);
   86|   427k|   G(v[2], v[6], v[10], v[14], M[i4], M[i5]);
   87|   427k|   G(v[3], v[7], v[11], v[15], M[i6], M[i7]);
   88|   427k|   G(v[0], v[5], v[10], v[15], M[i8], M[i9]);
   89|   427k|   G(v[1], v[6], v[11], v[12], M[iA], M[iB]);
   90|   427k|   G(v[2], v[7], v[8], v[13], M[iC], M[iD]);
   91|   427k|   G(v[3], v[4], v[9], v[14], M[iE], M[iF]);
   92|   427k|}

_ZN5Botan5CRC248add_dataENSt3__14spanIKhLm18446744073709551615EEE:
   85|  16.3k|void CRC24::add_data(std::span<const uint8_t> input) {
   86|  16.3k|   uint32_t tmp = m_crc;
   87|       |
   88|       |   // Input is word aligned if WA & input == 0
   89|  16.3k|   static const uint8_t WA = sizeof(size_t) - 1;
   90|       |
   91|       |   // Ensure input is word aligned before processing in parallel
   92|  18.0k|   for(; !input.empty() && (reinterpret_cast<uintptr_t>(input.data()) & WA) > 0; input = input.last(input.size() - 1)) {
  ------------------
  |  Branch (92:10): [True: 16.9k, False: 1.06k]
  |  Branch (92:28): [True: 1.63k, False: 15.3k]
  ------------------
   93|  1.63k|      tmp = process8(tmp, input.front());
   94|  1.63k|   }
   95|       |
   96|  7.23M|   while(input.size() >= 16) {
  ------------------
  |  Branch (96:10): [True: 7.22M, False: 16.3k]
  ------------------
   97|  7.22M|      uint32_t d[4];
   98|  7.22M|      load_le(d, input.data(), 4);
   99|  7.22M|      tmp = process32(tmp, d[0]);
  100|  7.22M|      tmp = process32(tmp, d[1]);
  101|  7.22M|      tmp = process32(tmp, d[2]);
  102|  7.22M|      tmp = process32(tmp, d[3]);
  103|       |
  104|  7.22M|      input = input.last(input.size() - 16);
  105|  7.22M|   }
  106|       |
  107|   100k|   for(; !input.empty(); input = input.last(input.size() - 1)) {
  ------------------
  |  Branch (107:10): [True: 83.8k, False: 16.3k]
  ------------------
  108|  83.8k|      tmp = process8(tmp, input.front());
  109|  83.8k|   }
  110|       |
  111|  16.3k|   m_crc = tmp;
  112|  16.3k|}
_ZN5Botan5CRC2412final_resultENSt3__14spanIhLm18446744073709551615EEE:
  117|  8.15k|void CRC24::final_result(std::span<uint8_t> output) {
  118|  8.15k|   output[0] = get_byte<3>(m_crc);
  119|  8.15k|   output[1] = get_byte<2>(m_crc);
  120|  8.15k|   output[2] = get_byte<1>(m_crc);
  121|  8.15k|   clear();
  122|  8.15k|}
crc24.cpp:_ZN5Botan12_GLOBAL__N_18process8Ejh:
   59|  85.5k|inline uint32_t process8(uint32_t crc, uint8_t data) {
   60|  85.5k|   return (crc >> 8) ^ CRC24_T0[get_byte<3>(crc) ^ data];
   61|  85.5k|}
crc24.cpp:_ZN5Botan12_GLOBAL__N_19process32Ejj:
   63|  28.8M|inline uint32_t process32(uint32_t crc, uint32_t word) {
   64|  28.8M|   const uint32_t sum = crc ^ word;
   65|       |
   66|  28.8M|   return CRC24_T3[get_byte<3>(sum)] ^ CRC24_T2[get_byte<2>(sum)] ^ CRC24_T1[get_byte<1>(sum)] ^
   67|  28.8M|          CRC24_T0[get_byte<0>(sum)];
   68|  28.8M|}

_ZN5Botan12HashFunction6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  111|  97.8k|std::unique_ptr<HashFunction> HashFunction::create(std::string_view algo_spec, std::string_view provider) {
  112|       |#if defined(BOTAN_HAS_COMMONCRYPTO)
  113|       |   if(provider.empty() || provider == "commoncrypto") {
  114|       |      if(auto hash = make_commoncrypto_hash(algo_spec))
  115|       |         return hash;
  116|       |
  117|       |      if(!provider.empty())
  118|       |         return nullptr;
  119|       |   }
  120|       |#endif
  121|       |
  122|  97.8k|   if(provider.empty() == false && provider != "base") {
  ------------------
  |  Branch (122:7): [True: 0, False: 97.8k]
  |  Branch (122:36): [True: 0, False: 0]
  ------------------
  123|      0|      return nullptr;  // unknown provider
  124|      0|   }
  125|       |
  126|  97.8k|#if defined(BOTAN_HAS_SHA1)
  127|  97.8k|   if(algo_spec == "SHA-1") {
  ------------------
  |  Branch (127:7): [True: 2.57k, False: 95.2k]
  ------------------
  128|  2.57k|      return std::make_unique<SHA_1>();
  129|  2.57k|   }
  130|  95.2k|#endif
  131|       |
  132|  95.2k|#if defined(BOTAN_HAS_SHA2_32)
  133|  95.2k|   if(algo_spec == "SHA-224") {
  ------------------
  |  Branch (133:7): [True: 770, False: 94.4k]
  ------------------
  134|    770|      return std::make_unique<SHA_224>();
  135|    770|   }
  136|       |
  137|  94.4k|   if(algo_spec == "SHA-256") {
  ------------------
  |  Branch (137:7): [True: 23.0k, False: 71.3k]
  ------------------
  138|  23.0k|      return std::make_unique<SHA_256>();
  139|  23.0k|   }
  140|  71.3k|#endif
  141|       |
  142|  71.3k|#if defined(BOTAN_HAS_SHA2_64)
  143|  71.3k|   if(algo_spec == "SHA-384") {
  ------------------
  |  Branch (143:7): [True: 2.59k, False: 68.7k]
  ------------------
  144|  2.59k|      return std::make_unique<SHA_384>();
  145|  2.59k|   }
  146|       |
  147|  68.7k|   if(algo_spec == "SHA-512") {
  ------------------
  |  Branch (147:7): [True: 22.6k, False: 46.1k]
  ------------------
  148|  22.6k|      return std::make_unique<SHA_512>();
  149|  22.6k|   }
  150|       |
  151|  46.1k|   if(algo_spec == "SHA-512-256") {
  ------------------
  |  Branch (151:7): [True: 0, False: 46.1k]
  ------------------
  152|      0|      return std::make_unique<SHA_512_256>();
  153|      0|   }
  154|  46.1k|#endif
  155|       |
  156|  46.1k|#if defined(BOTAN_HAS_RIPEMD_160)
  157|  46.1k|   if(algo_spec == "RIPEMD-160") {
  ------------------
  |  Branch (157:7): [True: 3.22k, False: 42.9k]
  ------------------
  158|  3.22k|      return std::make_unique<RIPEMD_160>();
  159|  3.22k|   }
  160|  42.9k|#endif
  161|       |
  162|       |#if defined(BOTAN_HAS_WHIRLPOOL)
  163|       |   if(algo_spec == "Whirlpool") {
  164|       |      return std::make_unique<Whirlpool>();
  165|       |   }
  166|       |#endif
  167|       |
  168|  42.9k|#if defined(BOTAN_HAS_MD5)
  169|  42.9k|   if(algo_spec == "MD5") {
  ------------------
  |  Branch (169:7): [True: 12.6k, False: 30.3k]
  ------------------
  170|  12.6k|      return std::make_unique<MD5>();
  171|  12.6k|   }
  172|  30.3k|#endif
  173|       |
  174|       |#if defined(BOTAN_HAS_MD4)
  175|       |   if(algo_spec == "MD4") {
  176|       |      return std::make_unique<MD4>();
  177|       |   }
  178|       |#endif
  179|       |
  180|       |#if defined(BOTAN_HAS_GOST_34_11)
  181|       |   if(algo_spec == "GOST-R-34.11-94" || algo_spec == "GOST-34.11") {
  182|       |      return std::make_unique<GOST_34_11>();
  183|       |   }
  184|       |#endif
  185|       |
  186|       |#if defined(BOTAN_HAS_ADLER32)
  187|       |   if(algo_spec == "Adler32") {
  188|       |      return std::make_unique<Adler32>();
  189|       |   }
  190|       |#endif
  191|       |
  192|       |#if defined(BOTAN_HAS_ASCON_HASH256)
  193|       |   if(algo_spec == "Ascon-Hash256") {
  194|       |      return std::make_unique<Ascon_Hash256>();
  195|       |   }
  196|       |#endif
  197|       |
  198|  30.3k|#if defined(BOTAN_HAS_CRC24)
  199|  30.3k|   if(algo_spec == "CRC24") {
  ------------------
  |  Branch (199:7): [True: 16.3k, False: 13.9k]
  ------------------
  200|  16.3k|      return std::make_unique<CRC24>();
  201|  16.3k|   }
  202|  13.9k|#endif
  203|       |
  204|       |#if defined(BOTAN_HAS_CRC32)
  205|       |   if(algo_spec == "CRC32") {
  206|       |      return std::make_unique<CRC32>();
  207|       |   }
  208|       |#endif
  209|       |
  210|       |#if defined(BOTAN_HAS_STREEBOG)
  211|       |   if(algo_spec == "Streebog-256") {
  212|       |      return std::make_unique<Streebog>(256);
  213|       |   }
  214|       |   if(algo_spec == "Streebog-512") {
  215|       |      return std::make_unique<Streebog>(512);
  216|       |   }
  217|       |#endif
  218|       |
  219|  13.9k|#if defined(BOTAN_HAS_SM3)
  220|  13.9k|   if(algo_spec == "SM3") {
  ------------------
  |  Branch (220:7): [True: 245, False: 13.6k]
  ------------------
  221|    245|      return std::make_unique<SM3>();
  222|    245|   }
  223|  13.6k|#endif
  224|       |
  225|  13.6k|   const SCAN_Name req(algo_spec);
  226|       |
  227|       |#if defined(BOTAN_HAS_SKEIN_512)
  228|       |   if(req.algo_name() == "Skein-512") {
  229|       |      return std::make_unique<Skein_512>(req.arg_as_integer(0, 512), req.arg(1, ""));
  230|       |   }
  231|       |#endif
  232|       |
  233|  13.6k|#if defined(BOTAN_HAS_BLAKE2B)
  234|  13.6k|   if(req.algo_name() == "Blake2b" || req.algo_name() == "BLAKE2b") {
  ------------------
  |  Branch (234:7): [True: 0, False: 13.6k]
  |  Branch (234:39): [True: 422, False: 13.2k]
  ------------------
  235|    422|      return std::make_unique<BLAKE2b>(req.arg_as_integer(0, 512));
  236|    422|   }
  237|  13.2k|#endif
  238|       |
  239|       |#if defined(BOTAN_HAS_BLAKE2S)
  240|       |   if(req.algo_name() == "Blake2s" || req.algo_name() == "BLAKE2s") {
  241|       |      return std::make_unique<BLAKE2s>(req.arg_as_integer(0, 256));
  242|       |   }
  243|       |#endif
  244|       |
  245|       |#if defined(BOTAN_HAS_KECCAK)
  246|       |   if(req.algo_name() == "Keccak-1600") {
  247|       |      return std::make_unique<Keccak_1600>(req.arg_as_integer(0, 512));
  248|       |   }
  249|       |#endif
  250|       |
  251|  13.2k|#if defined(BOTAN_HAS_SHA3)
  252|  13.2k|   if(req.algo_name() == "SHA-3") {
  ------------------
  |  Branch (252:7): [True: 5.43k, False: 7.82k]
  ------------------
  253|  5.43k|      return std::make_unique<SHA_3>(req.arg_as_integer(0, 512));
  254|  5.43k|   }
  255|  7.82k|#endif
  256|       |
  257|  7.82k|#if defined(BOTAN_HAS_SHAKE)
  258|  7.82k|   if(req.algo_name() == "SHAKE-128" && req.arg_count() == 1) {
  ------------------
  |  Branch (258:7): [True: 0, False: 7.82k]
  |  Branch (258:41): [True: 0, False: 0]
  ------------------
  259|      0|      return std::make_unique<SHAKE_128>(req.arg_as_integer(0));
  260|      0|   }
  261|  7.82k|   if(req.algo_name() == "SHAKE-256" && req.arg_count() == 1) {
  ------------------
  |  Branch (261:7): [True: 0, False: 7.82k]
  |  Branch (261:41): [True: 0, False: 0]
  ------------------
  262|      0|      return std::make_unique<SHAKE_256>(req.arg_as_integer(0));
  263|      0|   }
  264|  7.82k|#endif
  265|       |
  266|       |#if defined(BOTAN_HAS_PARALLEL_HASH)
  267|       |   if(req.algo_name() == "Parallel") {
  268|       |      std::vector<std::unique_ptr<HashFunction>> hashes;
  269|       |
  270|       |      for(size_t i = 0; i != req.arg_count(); ++i) {
  271|       |         auto h = HashFunction::create(req.arg(i));
  272|       |         if(!h) {
  273|       |            return nullptr;
  274|       |         }
  275|       |         hashes.push_back(std::move(h));
  276|       |      }
  277|       |
  278|       |      return std::make_unique<Parallel>(hashes);
  279|       |   }
  280|       |#endif
  281|       |
  282|  7.82k|#if defined(BOTAN_HAS_TRUNCATED_HASH)
  283|  7.82k|   if(req.algo_name() == "Truncated" && req.arg_count() == 2) {
  ------------------
  |  Branch (283:7): [True: 0, False: 7.82k]
  |  Branch (283:41): [True: 0, False: 0]
  ------------------
  284|      0|      auto hash = HashFunction::create(req.arg(0));
  285|      0|      if(!hash) {
  ------------------
  |  Branch (285:10): [True: 0, False: 0]
  ------------------
  286|      0|         return nullptr;
  287|      0|      }
  288|       |
  289|      0|      return std::make_unique<Truncated_Hash>(std::move(hash), req.arg_as_integer(1));
  290|      0|   }
  291|  7.82k|#endif
  292|       |
  293|       |#if defined(BOTAN_HAS_COMB4P)
  294|       |   if(req.algo_name() == "Comb4P" && req.arg_count() == 2) {
  295|       |      auto h1 = HashFunction::create(req.arg(0));
  296|       |      auto h2 = HashFunction::create(req.arg(1));
  297|       |
  298|       |      if(h1 && h2) {
  299|       |         return std::make_unique<Comb4P>(std::move(h1), std::move(h2));
  300|       |      }
  301|       |   }
  302|       |#endif
  303|       |
  304|  7.82k|   return nullptr;
  305|  7.82k|}
_ZN5Botan12HashFunction15create_or_throwENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  308|  3.80k|std::unique_ptr<HashFunction> HashFunction::create_or_throw(std::string_view algo, std::string_view provider) {
  309|  3.80k|   if(auto hash = HashFunction::create(algo, provider)) {
  ------------------
  |  Branch (309:12): [True: 3.80k, False: 0]
  ------------------
  310|  3.80k|      return hash;
  311|  3.80k|   }
  312|      0|   throw Lookup_Error("Hash", algo, provider);
  313|  3.80k|}

_ZN5Botan3MD510compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
   62|  3.45M|void MD5::compress_n(MD5::digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
   63|  3.45M|   uint32_t A = digest[0];
   64|  3.45M|   uint32_t B = digest[1];
   65|  3.45M|   uint32_t C = digest[2];
   66|  3.45M|   uint32_t D = digest[3];
   67|  3.45M|   std::array<uint32_t, 16> M{};
   68|       |
   69|  3.45M|   BufferSlicer in(input);
   70|       |
   71|  7.25M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (71:22): [True: 3.80M, False: 3.45M]
  ------------------
   72|  3.80M|      load_le(M, in.take<block_bytes>());
   73|       |
   74|       |      // clang-format off
   75|       |
   76|  3.80M|      FF< 7>(A, B, C, D, M[ 0] + 0xD76AA478);
   77|  3.80M|      FF<12>(D, A, B, C, M[ 1] + 0xE8C7B756);
   78|  3.80M|      FF<17>(C, D, A, B, M[ 2] + 0x242070DB);
   79|  3.80M|      FF<22>(B, C, D, A, M[ 3] + 0xC1BDCEEE);
   80|  3.80M|      FF< 7>(A, B, C, D, M[ 4] + 0xF57C0FAF);
   81|  3.80M|      FF<12>(D, A, B, C, M[ 5] + 0x4787C62A);
   82|  3.80M|      FF<17>(C, D, A, B, M[ 6] + 0xA8304613);
   83|  3.80M|      FF<22>(B, C, D, A, M[ 7] + 0xFD469501);
   84|  3.80M|      FF< 7>(A, B, C, D, M[ 8] + 0x698098D8);
   85|  3.80M|      FF<12>(D, A, B, C, M[ 9] + 0x8B44F7AF);
   86|  3.80M|      FF<17>(C, D, A, B, M[10] + 0xFFFF5BB1);
   87|  3.80M|      FF<22>(B, C, D, A, M[11] + 0x895CD7BE);
   88|  3.80M|      FF< 7>(A, B, C, D, M[12] + 0x6B901122);
   89|  3.80M|      FF<12>(D, A, B, C, M[13] + 0xFD987193);
   90|  3.80M|      FF<17>(C, D, A, B, M[14] + 0xA679438E);
   91|  3.80M|      FF<22>(B, C, D, A, M[15] + 0x49B40821);
   92|       |
   93|  3.80M|      GG< 5>(A, B, C, D, M[ 1] + 0xF61E2562);
   94|  3.80M|      GG< 9>(D, A, B, C, M[ 6] + 0xC040B340);
   95|  3.80M|      GG<14>(C, D, A, B, M[11] + 0x265E5A51);
   96|  3.80M|      GG<20>(B, C, D, A, M[ 0] + 0xE9B6C7AA);
   97|  3.80M|      GG< 5>(A, B, C, D, M[ 5] + 0xD62F105D);
   98|  3.80M|      GG< 9>(D, A, B, C, M[10] + 0x02441453);
   99|  3.80M|      GG<14>(C, D, A, B, M[15] + 0xD8A1E681);
  100|  3.80M|      GG<20>(B, C, D, A, M[ 4] + 0xE7D3FBC8);
  101|  3.80M|      GG< 5>(A, B, C, D, M[ 9] + 0x21E1CDE6);
  102|  3.80M|      GG< 9>(D, A, B, C, M[14] + 0xC33707D6);
  103|  3.80M|      GG<14>(C, D, A, B, M[ 3] + 0xF4D50D87);
  104|  3.80M|      GG<20>(B, C, D, A, M[ 8] + 0x455A14ED);
  105|  3.80M|      GG< 5>(A, B, C, D, M[13] + 0xA9E3E905);
  106|  3.80M|      GG< 9>(D, A, B, C, M[ 2] + 0xFCEFA3F8);
  107|  3.80M|      GG<14>(C, D, A, B, M[ 7] + 0x676F02D9);
  108|  3.80M|      GG<20>(B, C, D, A, M[12] + 0x8D2A4C8A);
  109|       |
  110|  3.80M|      HH< 4>(A, B, C, D, M[ 5] + 0xFFFA3942);
  111|  3.80M|      HH<11>(D, A, B, C, M[ 8] + 0x8771F681);
  112|  3.80M|      HH<16>(C, D, A, B, M[11] + 0x6D9D6122);
  113|  3.80M|      HH<23>(B, C, D, A, M[14] + 0xFDE5380C);
  114|  3.80M|      HH< 4>(A, B, C, D, M[ 1] + 0xA4BEEA44);
  115|  3.80M|      HH<11>(D, A, B, C, M[ 4] + 0x4BDECFA9);
  116|  3.80M|      HH<16>(C, D, A, B, M[ 7] + 0xF6BB4B60);
  117|  3.80M|      HH<23>(B, C, D, A, M[10] + 0xBEBFBC70);
  118|  3.80M|      HH< 4>(A, B, C, D, M[13] + 0x289B7EC6);
  119|  3.80M|      HH<11>(D, A, B, C, M[ 0] + 0xEAA127FA);
  120|  3.80M|      HH<16>(C, D, A, B, M[ 3] + 0xD4EF3085);
  121|  3.80M|      HH<23>(B, C, D, A, M[ 6] + 0x04881D05);
  122|  3.80M|      HH< 4>(A, B, C, D, M[ 9] + 0xD9D4D039);
  123|  3.80M|      HH<11>(D, A, B, C, M[12] + 0xE6DB99E5);
  124|  3.80M|      HH<16>(C, D, A, B, M[15] + 0x1FA27CF8);
  125|  3.80M|      HH<23>(B, C, D, A, M[ 2] + 0xC4AC5665);
  126|       |
  127|  3.80M|      II< 6>(A, B, C, D, M[ 0] + 0xF4292244);
  128|  3.80M|      II<10>(D, A, B, C, M[ 7] + 0x432AFF97);
  129|  3.80M|      II<15>(C, D, A, B, M[14] + 0xAB9423A7);
  130|  3.80M|      II<21>(B, C, D, A, M[ 5] + 0xFC93A039);
  131|  3.80M|      II< 6>(A, B, C, D, M[12] + 0x655B59C3);
  132|  3.80M|      II<10>(D, A, B, C, M[ 3] + 0x8F0CCC92);
  133|  3.80M|      II<15>(C, D, A, B, M[10] + 0xFFEFF47D);
  134|  3.80M|      II<21>(B, C, D, A, M[ 1] + 0x85845DD1);
  135|  3.80M|      II< 6>(A, B, C, D, M[ 8] + 0x6FA87E4F);
  136|  3.80M|      II<10>(D, A, B, C, M[15] + 0xFE2CE6E0);
  137|  3.80M|      II<15>(C, D, A, B, M[ 6] + 0xA3014314);
  138|  3.80M|      II<21>(B, C, D, A, M[13] + 0x4E0811A1);
  139|  3.80M|      II< 6>(A, B, C, D, M[ 4] + 0xF7537E82);
  140|  3.80M|      II<10>(D, A, B, C, M[11] + 0xBD3AF235);
  141|  3.80M|      II<15>(C, D, A, B, M[ 2] + 0x2AD7D2BB);
  142|  3.80M|      II<21>(B, C, D, A, M[ 9] + 0xEB86D391);
  143|       |
  144|       |      // clang-format off
  145|       |
  146|  3.80M|      A = (digest[0] += A);
  147|  3.80M|      B = (digest[1] += B);
  148|  3.80M|      C = (digest[2] += C);
  149|  3.80M|      D = (digest[3] += D);
  150|  3.80M|   }
  151|  3.45M|}
_ZN5Botan3MD54initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  153|  34.6k|void MD5::init(digest_type& digest) {
  154|  34.6k|   digest.assign({0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476});
  155|  34.6k|}
_ZNK5Botan3MD510new_objectEv:
  157|  5.61k|std::unique_ptr<HashFunction> MD5::new_object() const {
  158|  5.61k|   return std::make_unique<MD5>();
  159|  5.61k|}
_ZN5Botan3MD58add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  165|  13.3M|void MD5::add_data(std::span<const uint8_t> input) {
  166|  13.3M|   m_md.update(input);
  167|  13.3M|}
_ZN5Botan3MD512final_resultENSt3__14spanIhLm18446744073709551615EEE:
  169|  16.4k|void MD5::final_result(std::span<uint8_t> output) {
  170|  16.4k|   m_md.final(output);
  171|  16.4k|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12FFILm7EEEvRjjjjj:
   24|  15.2M|inline void FF(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   25|  15.2M|   A += choose(B, C, D) + M;
   26|  15.2M|   A = rotl<S>(A) + B;
   27|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12FFILm12EEEvRjjjjj:
   24|  15.2M|inline void FF(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   25|  15.2M|   A += choose(B, C, D) + M;
   26|  15.2M|   A = rotl<S>(A) + B;
   27|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12FFILm17EEEvRjjjjj:
   24|  15.2M|inline void FF(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   25|  15.2M|   A += choose(B, C, D) + M;
   26|  15.2M|   A = rotl<S>(A) + B;
   27|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12FFILm22EEEvRjjjjj:
   24|  15.2M|inline void FF(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   25|  15.2M|   A += choose(B, C, D) + M;
   26|  15.2M|   A = rotl<S>(A) + B;
   27|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12GGILm5EEEvRjjjjj:
   33|  15.2M|inline void GG(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   34|  15.2M|   A += choose(D, B, C) + M;
   35|  15.2M|   A = rotl<S>(A) + B;
   36|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12GGILm9EEEvRjjjjj:
   33|  15.2M|inline void GG(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   34|  15.2M|   A += choose(D, B, C) + M;
   35|  15.2M|   A = rotl<S>(A) + B;
   36|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12GGILm14EEEvRjjjjj:
   33|  15.2M|inline void GG(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   34|  15.2M|   A += choose(D, B, C) + M;
   35|  15.2M|   A = rotl<S>(A) + B;
   36|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12GGILm20EEEvRjjjjj:
   33|  15.2M|inline void GG(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   34|  15.2M|   A += choose(D, B, C) + M;
   35|  15.2M|   A = rotl<S>(A) + B;
   36|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12HHILm4EEEvRjjjjj:
   42|  15.2M|inline void HH(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   43|  15.2M|   A += (B ^ C ^ D) + M;
   44|  15.2M|   A = rotl<S>(A) + B;
   45|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12HHILm11EEEvRjjjjj:
   42|  15.2M|inline void HH(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   43|  15.2M|   A += (B ^ C ^ D) + M;
   44|  15.2M|   A = rotl<S>(A) + B;
   45|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12HHILm16EEEvRjjjjj:
   42|  15.2M|inline void HH(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   43|  15.2M|   A += (B ^ C ^ D) + M;
   44|  15.2M|   A = rotl<S>(A) + B;
   45|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12HHILm23EEEvRjjjjj:
   42|  15.2M|inline void HH(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   43|  15.2M|   A += (B ^ C ^ D) + M;
   44|  15.2M|   A = rotl<S>(A) + B;
   45|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12IIILm6EEEvRjjjjj:
   51|  15.2M|inline void II(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   52|       |   // This expr is choose(D, B ^ C, ~C), but that is slower
   53|  15.2M|   A += (C ^ (B | ~D)) + M;
   54|  15.2M|   A = rotl<S>(A) + B;
   55|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12IIILm10EEEvRjjjjj:
   51|  15.2M|inline void II(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   52|       |   // This expr is choose(D, B ^ C, ~C), but that is slower
   53|  15.2M|   A += (C ^ (B | ~D)) + M;
   54|  15.2M|   A = rotl<S>(A) + B;
   55|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12IIILm15EEEvRjjjjj:
   51|  15.2M|inline void II(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   52|       |   // This expr is choose(D, B ^ C, ~C), but that is slower
   53|  15.2M|   A += (C ^ (B | ~D)) + M;
   54|  15.2M|   A = rotl<S>(A) + B;
   55|  15.2M|}
md5.cpp:_ZN5Botan12_GLOBAL__N_12IIILm21EEEvRjjjjj:
   51|  15.2M|inline void II(uint32_t& A, uint32_t B, uint32_t C, uint32_t D, uint32_t M) {
   52|       |   // This expr is choose(D, B ^ C, ~C), but that is slower
   53|  15.2M|   A += (C ^ (B | ~D)) + M;
   54|  15.2M|   A = rotl<S>(A) + B;
   55|  15.2M|}

_ZN5Botan10RIPEMD_16010compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
   76|  1.00M|void RIPEMD_160::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
   77|  1.00M|   constexpr uint32_t MAGIC2 = 0x5A827999;
   78|  1.00M|   constexpr uint32_t MAGIC3 = 0x6ED9EBA1;
   79|  1.00M|   constexpr uint32_t MAGIC4 = 0x8F1BBCDC;
   80|  1.00M|   constexpr uint32_t MAGIC5 = 0xA953FD4E;
   81|  1.00M|   constexpr uint32_t MAGIC6 = 0x50A28BE6;
   82|  1.00M|   constexpr uint32_t MAGIC7 = 0x5C4DD124;
   83|  1.00M|   constexpr uint32_t MAGIC8 = 0x6D703EF3;
   84|  1.00M|   constexpr uint32_t MAGIC9 = 0x7A6D76E9;
   85|       |
   86|  1.00M|   std::array<uint32_t, 16> M{};
   87|       |
   88|  1.00M|   BufferSlicer in(input);
   89|       |
   90|  2.02M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (90:22): [True: 1.02M, False: 1.00M]
  ------------------
   91|  1.02M|      load_le(M, in.take<block_bytes>());
   92|       |
   93|  1.02M|      uint32_t A1 = digest[0];
   94|  1.02M|      uint32_t B1 = digest[1];
   95|  1.02M|      uint32_t C1 = digest[2];
   96|  1.02M|      uint32_t D1 = digest[3];
   97|  1.02M|      uint32_t E1 = digest[4];
   98|       |
   99|  1.02M|      uint32_t A2 = A1;
  100|  1.02M|      uint32_t B2 = B1;
  101|  1.02M|      uint32_t C2 = C1;
  102|  1.02M|      uint32_t D2 = D1;
  103|  1.02M|      uint32_t E2 = E1;
  104|       |
  105|       |      // clang-format off
  106|       |
  107|  1.02M|      F1<11>(A1, B1, C1, D1, E1, M[ 0]);
  108|  1.02M|      F5< 8>(A2, B2, C2, D2, E2, M[ 5] + MAGIC6);
  109|  1.02M|      F1<14>(E1, A1, B1, C1, D1, M[ 1]);
  110|  1.02M|      F5< 9>(E2, A2, B2, C2, D2, M[14] + MAGIC6);
  111|  1.02M|      F1<15>(D1, E1, A1, B1, C1, M[ 2]);
  112|  1.02M|      F5< 9>(D2, E2, A2, B2, C2, M[ 7] + MAGIC6);
  113|  1.02M|      F1<12>(C1, D1, E1, A1, B1, M[ 3]);
  114|  1.02M|      F5<11>(C2, D2, E2, A2, B2, M[ 0] + MAGIC6);
  115|  1.02M|      F1< 5>(B1, C1, D1, E1, A1, M[ 4]);
  116|  1.02M|      F5<13>(B2, C2, D2, E2, A2, M[ 9] + MAGIC6);
  117|  1.02M|      F1< 8>(A1, B1, C1, D1, E1, M[ 5]);
  118|  1.02M|      F5<15>(A2, B2, C2, D2, E2, M[ 2] + MAGIC6);
  119|  1.02M|      F1< 7>(E1, A1, B1, C1, D1, M[ 6]);
  120|  1.02M|      F5<15>(E2, A2, B2, C2, D2, M[11] + MAGIC6);
  121|  1.02M|      F1< 9>(D1, E1, A1, B1, C1, M[ 7]);
  122|  1.02M|      F5< 5>(D2, E2, A2, B2, C2, M[ 4] + MAGIC6);
  123|  1.02M|      F1<11>(C1, D1, E1, A1, B1, M[ 8]);
  124|  1.02M|      F5< 7>(C2, D2, E2, A2, B2, M[13] + MAGIC6);
  125|  1.02M|      F1<13>(B1, C1, D1, E1, A1, M[ 9]);
  126|  1.02M|      F5< 7>(B2, C2, D2, E2, A2, M[ 6] + MAGIC6);
  127|  1.02M|      F1<14>(A1, B1, C1, D1, E1, M[10]);
  128|  1.02M|      F5< 8>(A2, B2, C2, D2, E2, M[15] + MAGIC6);
  129|  1.02M|      F1<15>(E1, A1, B1, C1, D1, M[11]);
  130|  1.02M|      F5<11>(E2, A2, B2, C2, D2, M[ 8] + MAGIC6);
  131|  1.02M|      F1< 6>(D1, E1, A1, B1, C1, M[12]);
  132|  1.02M|      F5<14>(D2, E2, A2, B2, C2, M[ 1] + MAGIC6);
  133|  1.02M|      F1< 7>(C1, D1, E1, A1, B1, M[13]);
  134|  1.02M|      F5<14>(C2, D2, E2, A2, B2, M[10] + MAGIC6);
  135|  1.02M|      F1< 9>(B1, C1, D1, E1, A1, M[14]);
  136|  1.02M|      F5<12>(B2, C2, D2, E2, A2, M[ 3] + MAGIC6);
  137|  1.02M|      F1< 8>(A1, B1, C1, D1, E1, M[15]);
  138|  1.02M|      F5< 6>(A2, B2, C2, D2, E2, M[12] + MAGIC6);
  139|       |
  140|  1.02M|      F2< 7>(E1, A1, B1, C1, D1, M[ 7] + MAGIC2);
  141|  1.02M|      F4< 9>(E2, A2, B2, C2, D2, M[ 6] + MAGIC7);
  142|  1.02M|      F2< 6>(D1, E1, A1, B1, C1, M[ 4] + MAGIC2);
  143|  1.02M|      F4<13>(D2, E2, A2, B2, C2, M[11] + MAGIC7);
  144|  1.02M|      F2< 8>(C1, D1, E1, A1, B1, M[13] + MAGIC2);
  145|  1.02M|      F4<15>(C2, D2, E2, A2, B2, M[ 3] + MAGIC7);
  146|  1.02M|      F2<13>(B1, C1, D1, E1, A1, M[ 1] + MAGIC2);
  147|  1.02M|      F4< 7>(B2, C2, D2, E2, A2, M[ 7] + MAGIC7);
  148|  1.02M|      F2<11>(A1, B1, C1, D1, E1, M[10] + MAGIC2);
  149|  1.02M|      F4<12>(A2, B2, C2, D2, E2, M[ 0] + MAGIC7);
  150|  1.02M|      F2< 9>(E1, A1, B1, C1, D1, M[ 6] + MAGIC2);
  151|  1.02M|      F4< 8>(E2, A2, B2, C2, D2, M[13] + MAGIC7);
  152|  1.02M|      F2< 7>(D1, E1, A1, B1, C1, M[15] + MAGIC2);
  153|  1.02M|      F4< 9>(D2, E2, A2, B2, C2, M[ 5] + MAGIC7);
  154|  1.02M|      F2<15>(C1, D1, E1, A1, B1, M[ 3] + MAGIC2);
  155|  1.02M|      F4<11>(C2, D2, E2, A2, B2, M[10] + MAGIC7);
  156|  1.02M|      F2< 7>(B1, C1, D1, E1, A1, M[12] + MAGIC2);
  157|  1.02M|      F4< 7>(B2, C2, D2, E2, A2, M[14] + MAGIC7);
  158|  1.02M|      F2<12>(A1, B1, C1, D1, E1, M[ 0] + MAGIC2);
  159|  1.02M|      F4< 7>(A2, B2, C2, D2, E2, M[15] + MAGIC7);
  160|  1.02M|      F2<15>(E1, A1, B1, C1, D1, M[ 9] + MAGIC2);
  161|  1.02M|      F4<12>(E2, A2, B2, C2, D2, M[ 8] + MAGIC7);
  162|  1.02M|      F2< 9>(D1, E1, A1, B1, C1, M[ 5] + MAGIC2);
  163|  1.02M|      F4< 7>(D2, E2, A2, B2, C2, M[12] + MAGIC7);
  164|  1.02M|      F2<11>(C1, D1, E1, A1, B1, M[ 2] + MAGIC2);
  165|  1.02M|      F4< 6>(C2, D2, E2, A2, B2, M[ 4] + MAGIC7);
  166|  1.02M|      F2< 7>(B1, C1, D1, E1, A1, M[14] + MAGIC2);
  167|  1.02M|      F4<15>(B2, C2, D2, E2, A2, M[ 9] + MAGIC7);
  168|  1.02M|      F2<13>(A1, B1, C1, D1, E1, M[11] + MAGIC2);
  169|  1.02M|      F4<13>(A2, B2, C2, D2, E2, M[ 1] + MAGIC7);
  170|  1.02M|      F2<12>(E1, A1, B1, C1, D1, M[ 8] + MAGIC2);
  171|  1.02M|      F4<11>(E2, A2, B2, C2, D2, M[ 2] + MAGIC7);
  172|       |
  173|  1.02M|      F3<11>(D1, E1, A1, B1, C1, M[ 3] + MAGIC3);
  174|  1.02M|      F3< 9>(D2, E2, A2, B2, C2, M[15] + MAGIC8);
  175|  1.02M|      F3<13>(C1, D1, E1, A1, B1, M[10] + MAGIC3);
  176|  1.02M|      F3< 7>(C2, D2, E2, A2, B2, M[ 5] + MAGIC8);
  177|  1.02M|      F3< 6>(B1, C1, D1, E1, A1, M[14] + MAGIC3);
  178|  1.02M|      F3<15>(B2, C2, D2, E2, A2, M[ 1] + MAGIC8);
  179|  1.02M|      F3< 7>(A1, B1, C1, D1, E1, M[ 4] + MAGIC3);
  180|  1.02M|      F3<11>(A2, B2, C2, D2, E2, M[ 3] + MAGIC8);
  181|  1.02M|      F3<14>(E1, A1, B1, C1, D1, M[ 9] + MAGIC3);
  182|  1.02M|      F3< 8>(E2, A2, B2, C2, D2, M[ 7] + MAGIC8);
  183|  1.02M|      F3< 9>(D1, E1, A1, B1, C1, M[15] + MAGIC3);
  184|  1.02M|      F3< 6>(D2, E2, A2, B2, C2, M[14] + MAGIC8);
  185|  1.02M|      F3<13>(C1, D1, E1, A1, B1, M[ 8] + MAGIC3);
  186|  1.02M|      F3< 6>(C2, D2, E2, A2, B2, M[ 6] + MAGIC8);
  187|  1.02M|      F3<15>(B1, C1, D1, E1, A1, M[ 1] + MAGIC3);
  188|  1.02M|      F3<14>(B2, C2, D2, E2, A2, M[ 9] + MAGIC8);
  189|  1.02M|      F3<14>(A1, B1, C1, D1, E1, M[ 2] + MAGIC3);
  190|  1.02M|      F3<12>(A2, B2, C2, D2, E2, M[11] + MAGIC8);
  191|  1.02M|      F3< 8>(E1, A1, B1, C1, D1, M[ 7] + MAGIC3);
  192|  1.02M|      F3<13>(E2, A2, B2, C2, D2, M[ 8] + MAGIC8);
  193|  1.02M|      F3<13>(D1, E1, A1, B1, C1, M[ 0] + MAGIC3);
  194|  1.02M|      F3< 5>(D2, E2, A2, B2, C2, M[12] + MAGIC8);
  195|  1.02M|      F3< 6>(C1, D1, E1, A1, B1, M[ 6] + MAGIC3);
  196|  1.02M|      F3<14>(C2, D2, E2, A2, B2, M[ 2] + MAGIC8);
  197|  1.02M|      F3< 5>(B1, C1, D1, E1, A1, M[13] + MAGIC3);
  198|  1.02M|      F3<13>(B2, C2, D2, E2, A2, M[10] + MAGIC8);
  199|  1.02M|      F3<12>(A1, B1, C1, D1, E1, M[11] + MAGIC3);
  200|  1.02M|      F3<13>(A2, B2, C2, D2, E2, M[ 0] + MAGIC8);
  201|  1.02M|      F3< 7>(E1, A1, B1, C1, D1, M[ 5] + MAGIC3);
  202|  1.02M|      F3< 7>(E2, A2, B2, C2, D2, M[ 4] + MAGIC8);
  203|  1.02M|      F3< 5>(D1, E1, A1, B1, C1, M[12] + MAGIC3);
  204|  1.02M|      F3< 5>(D2, E2, A2, B2, C2, M[13] + MAGIC8);
  205|       |
  206|  1.02M|      F4<11>(C1, D1, E1, A1, B1, M[ 1] + MAGIC4);
  207|  1.02M|      F2<15>(C2, D2, E2, A2, B2, M[ 8] + MAGIC9);
  208|  1.02M|      F4<12>(B1, C1, D1, E1, A1, M[ 9] + MAGIC4);
  209|  1.02M|      F2< 5>(B2, C2, D2, E2, A2, M[ 6] + MAGIC9);
  210|  1.02M|      F4<14>(A1, B1, C1, D1, E1, M[11] + MAGIC4);
  211|  1.02M|      F2< 8>(A2, B2, C2, D2, E2, M[ 4] + MAGIC9);
  212|  1.02M|      F4<15>(E1, A1, B1, C1, D1, M[10] + MAGIC4);
  213|  1.02M|      F2<11>(E2, A2, B2, C2, D2, M[ 1] + MAGIC9);
  214|  1.02M|      F4<14>(D1, E1, A1, B1, C1, M[ 0] + MAGIC4);
  215|  1.02M|      F2<14>(D2, E2, A2, B2, C2, M[ 3] + MAGIC9);
  216|  1.02M|      F4<15>(C1, D1, E1, A1, B1, M[ 8] + MAGIC4);
  217|  1.02M|      F2<14>(C2, D2, E2, A2, B2, M[11] + MAGIC9);
  218|  1.02M|      F4< 9>(B1, C1, D1, E1, A1, M[12] + MAGIC4);
  219|  1.02M|      F2< 6>(B2, C2, D2, E2, A2, M[15] + MAGIC9);
  220|  1.02M|      F4< 8>(A1, B1, C1, D1, E1, M[ 4] + MAGIC4);
  221|  1.02M|      F2<14>(A2, B2, C2, D2, E2, M[ 0] + MAGIC9);
  222|  1.02M|      F4< 9>(E1, A1, B1, C1, D1, M[13] + MAGIC4);
  223|  1.02M|      F2< 6>(E2, A2, B2, C2, D2, M[ 5] + MAGIC9);
  224|  1.02M|      F4<14>(D1, E1, A1, B1, C1, M[ 3] + MAGIC4);
  225|  1.02M|      F2< 9>(D2, E2, A2, B2, C2, M[12] + MAGIC9);
  226|  1.02M|      F4< 5>(C1, D1, E1, A1, B1, M[ 7] + MAGIC4);
  227|  1.02M|      F2<12>(C2, D2, E2, A2, B2, M[ 2] + MAGIC9);
  228|  1.02M|      F4< 6>(B1, C1, D1, E1, A1, M[15] + MAGIC4);
  229|  1.02M|      F2< 9>(B2, C2, D2, E2, A2, M[13] + MAGIC9);
  230|  1.02M|      F4< 8>(A1, B1, C1, D1, E1, M[14] + MAGIC4);
  231|  1.02M|      F2<12>(A2, B2, C2, D2, E2, M[ 9] + MAGIC9);
  232|  1.02M|      F4< 6>(E1, A1, B1, C1, D1, M[ 5] + MAGIC4);
  233|  1.02M|      F2< 5>(E2, A2, B2, C2, D2, M[ 7] + MAGIC9);
  234|  1.02M|      F4< 5>(D1, E1, A1, B1, C1, M[ 6] + MAGIC4);
  235|  1.02M|      F2<15>(D2, E2, A2, B2, C2, M[10] + MAGIC9);
  236|  1.02M|      F4<12>(C1, D1, E1, A1, B1, M[ 2] + MAGIC4);
  237|  1.02M|      F2< 8>(C2, D2, E2, A2, B2, M[14] + MAGIC9);
  238|       |
  239|  1.02M|      F5< 9>(B1, C1, D1, E1, A1, M[ 4] + MAGIC5);
  240|  1.02M|      F1< 8>(B2, C2, D2, E2, A2, M[12]);
  241|  1.02M|      F5<15>(A1, B1, C1, D1, E1, M[ 0] + MAGIC5);
  242|  1.02M|      F1< 5>(A2, B2, C2, D2, E2, M[15]);
  243|  1.02M|      F5< 5>(E1, A1, B1, C1, D1, M[ 5] + MAGIC5);
  244|  1.02M|      F1<12>(E2, A2, B2, C2, D2, M[10]);
  245|  1.02M|      F5<11>(D1, E1, A1, B1, C1, M[ 9] + MAGIC5);
  246|  1.02M|      F1< 9>(D2, E2, A2, B2, C2, M[ 4]);
  247|  1.02M|      F5< 6>(C1, D1, E1, A1, B1, M[ 7] + MAGIC5);
  248|  1.02M|      F1<12>(C2, D2, E2, A2, B2, M[ 1]);
  249|  1.02M|      F5< 8>(B1, C1, D1, E1, A1, M[12] + MAGIC5);
  250|  1.02M|      F1< 5>(B2, C2, D2, E2, A2, M[ 5]);
  251|  1.02M|      F5<13>(A1, B1, C1, D1, E1, M[ 2] + MAGIC5);
  252|  1.02M|      F1<14>(A2, B2, C2, D2, E2, M[ 8]);
  253|  1.02M|      F5<12>(E1, A1, B1, C1, D1, M[10] + MAGIC5);
  254|  1.02M|      F1< 6>(E2, A2, B2, C2, D2, M[ 7]);
  255|  1.02M|      F5< 5>(D1, E1, A1, B1, C1, M[14] + MAGIC5);
  256|  1.02M|      F1< 8>(D2, E2, A2, B2, C2, M[ 6]);
  257|  1.02M|      F5<12>(C1, D1, E1, A1, B1, M[ 1] + MAGIC5);
  258|  1.02M|      F1<13>(C2, D2, E2, A2, B2, M[ 2]);
  259|  1.02M|      F5<13>(B1, C1, D1, E1, A1, M[ 3] + MAGIC5);
  260|  1.02M|      F1< 6>(B2, C2, D2, E2, A2, M[13]);
  261|  1.02M|      F5<14>(A1, B1, C1, D1, E1, M[ 8] + MAGIC5);
  262|  1.02M|      F1< 5>(A2, B2, C2, D2, E2, M[14]);
  263|  1.02M|      F5<11>(E1, A1, B1, C1, D1, M[11] + MAGIC5);
  264|  1.02M|      F1<15>(E2, A2, B2, C2, D2, M[ 0]);
  265|  1.02M|      F5< 8>(D1, E1, A1, B1, C1, M[ 6] + MAGIC5);
  266|  1.02M|      F1<13>(D2, E2, A2, B2, C2, M[ 3]);
  267|  1.02M|      F5< 5>(C1, D1, E1, A1, B1, M[15] + MAGIC5);
  268|  1.02M|      F1<11>(C2, D2, E2, A2, B2, M[ 9]);
  269|  1.02M|      F5< 6>(B1, C1, D1, E1, A1, M[13] + MAGIC5);
  270|  1.02M|      F1<11>(B2, C2, D2, E2, A2, M[11]);
  271|       |
  272|       |      // clang-format on
  273|       |
  274|  1.02M|      C1 = digest[1] + C1 + D2;
  275|  1.02M|      digest[1] = digest[2] + D1 + E2;
  276|  1.02M|      digest[2] = digest[3] + E1 + A2;
  277|  1.02M|      digest[3] = digest[4] + A1 + B2;
  278|  1.02M|      digest[4] = digest[0] + B1 + C2;
  279|  1.02M|      digest[0] = C1;
  280|  1.02M|   }
  281|  1.00M|}
_ZN5Botan10RIPEMD_1604initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  283|  10.0k|void RIPEMD_160::init(digest_type& digest) {
  284|  10.0k|   digest.assign({0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476, 0xC3D2E1F0});
  285|  10.0k|}
_ZNK5Botan10RIPEMD_16010new_objectEv:
  287|  2.70k|std::unique_ptr<HashFunction> RIPEMD_160::new_object() const {
  288|  2.70k|   return std::make_unique<RIPEMD_160>();
  289|  2.70k|}
_ZN5Botan10RIPEMD_1608add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  295|  3.43M|void RIPEMD_160::add_data(std::span<const uint8_t> input) {
  296|  3.43M|   m_md.update(input);
  297|  3.43M|}
_ZN5Botan10RIPEMD_16012final_resultENSt3__14spanIhLm18446744073709551615EEE:
  299|  4.17k|void RIPEMD_160::final_result(std::span<uint8_t> output) {
  300|  4.17k|   m_md.final(output);
  301|  4.17k|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm11EEEvRjjS2_jjj:
   25|  4.08M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  4.08M|   A += (B ^ C ^ D) + M;
   27|  4.08M|   A = rotl<S>(A) + E;
   28|  4.08M|   C = rotl<10>(C);
   29|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm8EEEvRjjS2_jjj:
   65|  4.08M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  4.08M|   A += (B ^ (C | ~D)) + M;
   67|  4.08M|   A = rotl<S>(A) + E;
   68|  4.08M|   C = rotl<10>(C);
   69|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm14EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm9EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm15EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm12EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm11EEEvRjjS2_jjj:
   65|  4.08M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  4.08M|   A += (B ^ (C | ~D)) + M;
   67|  4.08M|   A = rotl<S>(A) + E;
   68|  4.08M|   C = rotl<10>(C);
   69|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm5EEEvRjjS2_jjj:
   25|  4.08M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  4.08M|   A += (B ^ C ^ D) + M;
   27|  4.08M|   A = rotl<S>(A) + E;
   28|  4.08M|   C = rotl<10>(C);
   29|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm13EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm8EEEvRjjS2_jjj:
   25|  4.08M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  4.08M|   A += (B ^ C ^ D) + M;
   27|  4.08M|   A = rotl<S>(A) + E;
   28|  4.08M|   C = rotl<10>(C);
   29|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm15EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm7EEEvRjjS2_jjj:
   25|  2.04M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  2.04M|   A += (B ^ C ^ D) + M;
   27|  2.04M|   A = rotl<S>(A) + E;
   28|  2.04M|   C = rotl<10>(C);
   29|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm9EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm5EEEvRjjS2_jjj:
   65|  4.08M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  4.08M|   A += (B ^ (C | ~D)) + M;
   67|  4.08M|   A = rotl<S>(A) + E;
   68|  4.08M|   C = rotl<10>(C);
   69|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm7EEEvRjjS2_jjj:
   65|  2.04M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  2.04M|   A += (B ^ (C | ~D)) + M;
   67|  2.04M|   A = rotl<S>(A) + E;
   68|  2.04M|   C = rotl<10>(C);
   69|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm13EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F1ILm6EEEvRjjS2_jjj:
   25|  3.06M|inline void F1(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   26|  3.06M|   A += (B ^ C ^ D) + M;
   27|  3.06M|   A = rotl<S>(A) + E;
   28|  3.06M|   C = rotl<10>(C);
   29|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm14EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm12EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F5ILm6EEEvRjjS2_jjj:
   65|  3.06M|inline void F5(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   66|  3.06M|   A += (B ^ (C | ~D)) + M;
   67|  3.06M|   A = rotl<S>(A) + E;
   68|  3.06M|   C = rotl<10>(C);
   69|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm7EEEvRjjS2_jjj:
   35|  4.08M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  4.08M|   A += choose(B, C, D) + M;
   37|  4.08M|   A = rotl<S>(A) + E;
   38|  4.08M|   C = rotl<10>(C);
   39|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm9EEEvRjjS2_jjj:
   55|  4.08M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  4.08M|   A += choose(D, B, C) + M;
   57|  4.08M|   A = rotl<S>(A) + E;
   58|  4.08M|   C = rotl<10>(C);
   59|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm6EEEvRjjS2_jjj:
   35|  3.06M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  3.06M|   A += choose(B, C, D) + M;
   37|  3.06M|   A = rotl<S>(A) + E;
   38|  3.06M|   C = rotl<10>(C);
   39|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm13EEEvRjjS2_jjj:
   55|  2.04M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  2.04M|   A += choose(D, B, C) + M;
   57|  2.04M|   A = rotl<S>(A) + E;
   58|  2.04M|   C = rotl<10>(C);
   59|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm8EEEvRjjS2_jjj:
   35|  3.06M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  3.06M|   A += choose(B, C, D) + M;
   37|  3.06M|   A = rotl<S>(A) + E;
   38|  3.06M|   C = rotl<10>(C);
   39|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm15EEEvRjjS2_jjj:
   55|  4.08M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  4.08M|   A += choose(D, B, C) + M;
   57|  4.08M|   A = rotl<S>(A) + E;
   58|  4.08M|   C = rotl<10>(C);
   59|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm13EEEvRjjS2_jjj:
   35|  2.04M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  2.04M|   A += choose(B, C, D) + M;
   37|  2.04M|   A = rotl<S>(A) + E;
   38|  2.04M|   C = rotl<10>(C);
   39|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm7EEEvRjjS2_jjj:
   55|  4.08M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  4.08M|   A += choose(D, B, C) + M;
   57|  4.08M|   A = rotl<S>(A) + E;
   58|  4.08M|   C = rotl<10>(C);
   59|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm11EEEvRjjS2_jjj:
   35|  3.06M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  3.06M|   A += choose(B, C, D) + M;
   37|  3.06M|   A = rotl<S>(A) + E;
   38|  3.06M|   C = rotl<10>(C);
   39|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm12EEEvRjjS2_jjj:
   55|  4.08M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  4.08M|   A += choose(D, B, C) + M;
   57|  4.08M|   A = rotl<S>(A) + E;
   58|  4.08M|   C = rotl<10>(C);
   59|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm9EEEvRjjS2_jjj:
   35|  4.08M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  4.08M|   A += choose(B, C, D) + M;
   37|  4.08M|   A = rotl<S>(A) + E;
   38|  4.08M|   C = rotl<10>(C);
   39|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm8EEEvRjjS2_jjj:
   55|  3.06M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  3.06M|   A += choose(D, B, C) + M;
   57|  3.06M|   A = rotl<S>(A) + E;
   58|  3.06M|   C = rotl<10>(C);
   59|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm15EEEvRjjS2_jjj:
   35|  4.08M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  4.08M|   A += choose(B, C, D) + M;
   37|  4.08M|   A = rotl<S>(A) + E;
   38|  4.08M|   C = rotl<10>(C);
   39|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm11EEEvRjjS2_jjj:
   55|  3.06M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  3.06M|   A += choose(D, B, C) + M;
   57|  3.06M|   A = rotl<S>(A) + E;
   58|  3.06M|   C = rotl<10>(C);
   59|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm12EEEvRjjS2_jjj:
   35|  4.08M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  4.08M|   A += choose(B, C, D) + M;
   37|  4.08M|   A = rotl<S>(A) + E;
   38|  4.08M|   C = rotl<10>(C);
   39|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm6EEEvRjjS2_jjj:
   55|  3.06M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  3.06M|   A += choose(D, B, C) + M;
   57|  3.06M|   A = rotl<S>(A) + E;
   58|  3.06M|   C = rotl<10>(C);
   59|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm11EEEvRjjS2_jjj:
   45|  2.04M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  2.04M|   A += (D ^ (B | ~C)) + M;
   47|  2.04M|   A = rotl<S>(A) + E;
   48|  2.04M|   C = rotl<10>(C);
   49|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm9EEEvRjjS2_jjj:
   45|  2.04M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  2.04M|   A += (D ^ (B | ~C)) + M;
   47|  2.04M|   A = rotl<S>(A) + E;
   48|  2.04M|   C = rotl<10>(C);
   49|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm13EEEvRjjS2_jjj:
   45|  6.12M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  6.12M|   A += (D ^ (B | ~C)) + M;
   47|  6.12M|   A = rotl<S>(A) + E;
   48|  6.12M|   C = rotl<10>(C);
   49|  6.12M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm7EEEvRjjS2_jjj:
   45|  4.08M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  4.08M|   A += (D ^ (B | ~C)) + M;
   47|  4.08M|   A = rotl<S>(A) + E;
   48|  4.08M|   C = rotl<10>(C);
   49|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm6EEEvRjjS2_jjj:
   45|  4.08M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  4.08M|   A += (D ^ (B | ~C)) + M;
   47|  4.08M|   A = rotl<S>(A) + E;
   48|  4.08M|   C = rotl<10>(C);
   49|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm15EEEvRjjS2_jjj:
   45|  2.04M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  2.04M|   A += (D ^ (B | ~C)) + M;
   47|  2.04M|   A = rotl<S>(A) + E;
   48|  2.04M|   C = rotl<10>(C);
   49|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm14EEEvRjjS2_jjj:
   45|  4.08M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  4.08M|   A += (D ^ (B | ~C)) + M;
   47|  4.08M|   A = rotl<S>(A) + E;
   48|  4.08M|   C = rotl<10>(C);
   49|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm8EEEvRjjS2_jjj:
   45|  2.04M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  2.04M|   A += (D ^ (B | ~C)) + M;
   47|  2.04M|   A = rotl<S>(A) + E;
   48|  2.04M|   C = rotl<10>(C);
   49|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm12EEEvRjjS2_jjj:
   45|  2.04M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  2.04M|   A += (D ^ (B | ~C)) + M;
   47|  2.04M|   A = rotl<S>(A) + E;
   48|  2.04M|   C = rotl<10>(C);
   49|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F3ILm5EEEvRjjS2_jjj:
   45|  4.08M|inline void F3(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   46|  4.08M|   A += (D ^ (B | ~C)) + M;
   47|  4.08M|   A = rotl<S>(A) + E;
   48|  4.08M|   C = rotl<10>(C);
   49|  4.08M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm5EEEvRjjS2_jjj:
   35|  2.04M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  2.04M|   A += choose(B, C, D) + M;
   37|  2.04M|   A = rotl<S>(A) + E;
   38|  2.04M|   C = rotl<10>(C);
   39|  2.04M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm14EEEvRjjS2_jjj:
   55|  3.06M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  3.06M|   A += choose(D, B, C) + M;
   57|  3.06M|   A = rotl<S>(A) + E;
   58|  3.06M|   C = rotl<10>(C);
   59|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F2ILm14EEEvRjjS2_jjj:
   35|  3.06M|inline void F2(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   36|  3.06M|   A += choose(B, C, D) + M;
   37|  3.06M|   A = rotl<S>(A) + E;
   38|  3.06M|   C = rotl<10>(C);
   39|  3.06M|}
rmd160.cpp:_ZN5Botan12_GLOBAL__N_12F4ILm5EEEvRjjS2_jjj:
   55|  2.04M|inline void F4(uint32_t& A, uint32_t B, uint32_t& C, uint32_t D, uint32_t E, uint32_t M) {
   56|  2.04M|   A += choose(D, B, C) + M;
   57|  2.04M|   A = rotl<S>(A) + E;
   58|  2.04M|   C = rotl<10>(C);
   59|  2.04M|}

_ZN5Botan5SHA_110compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
   24|  23.4M|void SHA_1::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
   25|  23.4M|   using namespace SHA1_F;
   26|       |
   27|       |#if defined(BOTAN_HAS_SHA1_X86_SHA_NI)
   28|       |   if(CPUID::has(CPUID::Feature::SHA)) {
   29|       |      return sha1_compress_x86(digest, input, blocks);
   30|       |   }
   31|       |#endif
   32|       |
   33|       |#if defined(BOTAN_HAS_SHA1_ARMV8)
   34|       |   if(CPUID::has(CPUID::Feature::SHA1)) {
   35|       |      return sha1_armv8_compress_n(digest, input, blocks);
   36|       |   }
   37|       |#endif
   38|       |
   39|       |#if defined(BOTAN_HAS_SHA1_AVX2)
   40|       |   if(CPUID::has(CPUID::Feature::AVX2, CPUID::Feature::BMI)) {
   41|       |      return avx2_compress_n(digest, input, blocks);
   42|       |   }
   43|       |#endif
   44|       |
   45|       |#if defined(BOTAN_HAS_SHA1_SIMD_4X32)
   46|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
   47|       |      return simd_compress_n(digest, input, blocks);
   48|       |   }
   49|       |#endif
   50|       |
   51|  23.4M|   uint32_t A = digest[0];
   52|  23.4M|   uint32_t B = digest[1];
   53|  23.4M|   uint32_t C = digest[2];
   54|  23.4M|   uint32_t D = digest[3];
   55|  23.4M|   uint32_t E = digest[4];
   56|  23.4M|   std::array<uint32_t, 80> W{};
   57|  23.4M|   auto W_in = std::span{W}.first<block_bytes / sizeof(uint32_t)>();
   58|       |
   59|  23.4M|   BufferSlicer in(input);
   60|       |
   61|  46.9M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (61:22): [True: 23.4M, False: 23.4M]
  ------------------
   62|  23.4M|      load_be(W_in, in.take<block_bytes>());
   63|       |
   64|       |      // clang-format off
   65|       |
   66|   211M|      for(size_t j = 16; j != 80; j += 8) {
  ------------------
  |  Branch (66:26): [True: 187M, False: 23.4M]
  ------------------
   67|   187M|         W[j + 0] = rotl<1>(W[j - 3] ^ W[j - 8] ^ W[j - 14] ^ W[j - 16]);
   68|   187M|         W[j + 1] = rotl<1>(W[j - 2] ^ W[j - 7] ^ W[j - 13] ^ W[j - 15]);
   69|   187M|         W[j + 2] = rotl<1>(W[j - 1] ^ W[j - 6] ^ W[j - 12] ^ W[j - 14]);
   70|   187M|         W[j + 3] = rotl<1>(W[j    ] ^ W[j - 5] ^ W[j - 11] ^ W[j - 13]);
   71|   187M|         W[j + 4] = rotl<1>(W[j + 1] ^ W[j - 4] ^ W[j - 10] ^ W[j - 12]);
   72|   187M|         W[j + 5] = rotl<1>(W[j + 2] ^ W[j - 3] ^ W[j -  9] ^ W[j - 11]);
   73|   187M|         W[j + 6] = rotl<1>(W[j + 3] ^ W[j - 2] ^ W[j -  8] ^ W[j - 10]);
   74|   187M|         W[j + 7] = rotl<1>(W[j + 4] ^ W[j - 1] ^ W[j -  7] ^ W[j -  9]);
   75|   187M|      }
   76|       |
   77|       |      // clang-format on
   78|       |
   79|  23.4M|      F1(A, B, C, D, E, W[0] + K1);
   80|  23.4M|      F1(E, A, B, C, D, W[1] + K1);
   81|  23.4M|      F1(D, E, A, B, C, W[2] + K1);
   82|  23.4M|      F1(C, D, E, A, B, W[3] + K1);
   83|  23.4M|      F1(B, C, D, E, A, W[4] + K1);
   84|  23.4M|      F1(A, B, C, D, E, W[5] + K1);
   85|  23.4M|      F1(E, A, B, C, D, W[6] + K1);
   86|  23.4M|      F1(D, E, A, B, C, W[7] + K1);
   87|  23.4M|      F1(C, D, E, A, B, W[8] + K1);
   88|  23.4M|      F1(B, C, D, E, A, W[9] + K1);
   89|  23.4M|      F1(A, B, C, D, E, W[10] + K1);
   90|  23.4M|      F1(E, A, B, C, D, W[11] + K1);
   91|  23.4M|      F1(D, E, A, B, C, W[12] + K1);
   92|  23.4M|      F1(C, D, E, A, B, W[13] + K1);
   93|  23.4M|      F1(B, C, D, E, A, W[14] + K1);
   94|  23.4M|      F1(A, B, C, D, E, W[15] + K1);
   95|  23.4M|      F1(E, A, B, C, D, W[16] + K1);
   96|  23.4M|      F1(D, E, A, B, C, W[17] + K1);
   97|  23.4M|      F1(C, D, E, A, B, W[18] + K1);
   98|  23.4M|      F1(B, C, D, E, A, W[19] + K1);
   99|       |
  100|  23.4M|      F2(A, B, C, D, E, W[20] + K2);
  101|  23.4M|      F2(E, A, B, C, D, W[21] + K2);
  102|  23.4M|      F2(D, E, A, B, C, W[22] + K2);
  103|  23.4M|      F2(C, D, E, A, B, W[23] + K2);
  104|  23.4M|      F2(B, C, D, E, A, W[24] + K2);
  105|  23.4M|      F2(A, B, C, D, E, W[25] + K2);
  106|  23.4M|      F2(E, A, B, C, D, W[26] + K2);
  107|  23.4M|      F2(D, E, A, B, C, W[27] + K2);
  108|  23.4M|      F2(C, D, E, A, B, W[28] + K2);
  109|  23.4M|      F2(B, C, D, E, A, W[29] + K2);
  110|  23.4M|      F2(A, B, C, D, E, W[30] + K2);
  111|  23.4M|      F2(E, A, B, C, D, W[31] + K2);
  112|  23.4M|      F2(D, E, A, B, C, W[32] + K2);
  113|  23.4M|      F2(C, D, E, A, B, W[33] + K2);
  114|  23.4M|      F2(B, C, D, E, A, W[34] + K2);
  115|  23.4M|      F2(A, B, C, D, E, W[35] + K2);
  116|  23.4M|      F2(E, A, B, C, D, W[36] + K2);
  117|  23.4M|      F2(D, E, A, B, C, W[37] + K2);
  118|  23.4M|      F2(C, D, E, A, B, W[38] + K2);
  119|  23.4M|      F2(B, C, D, E, A, W[39] + K2);
  120|       |
  121|  23.4M|      F3(A, B, C, D, E, W[40] + K3);
  122|  23.4M|      F3(E, A, B, C, D, W[41] + K3);
  123|  23.4M|      F3(D, E, A, B, C, W[42] + K3);
  124|  23.4M|      F3(C, D, E, A, B, W[43] + K3);
  125|  23.4M|      F3(B, C, D, E, A, W[44] + K3);
  126|  23.4M|      F3(A, B, C, D, E, W[45] + K3);
  127|  23.4M|      F3(E, A, B, C, D, W[46] + K3);
  128|  23.4M|      F3(D, E, A, B, C, W[47] + K3);
  129|  23.4M|      F3(C, D, E, A, B, W[48] + K3);
  130|  23.4M|      F3(B, C, D, E, A, W[49] + K3);
  131|  23.4M|      F3(A, B, C, D, E, W[50] + K3);
  132|  23.4M|      F3(E, A, B, C, D, W[51] + K3);
  133|  23.4M|      F3(D, E, A, B, C, W[52] + K3);
  134|  23.4M|      F3(C, D, E, A, B, W[53] + K3);
  135|  23.4M|      F3(B, C, D, E, A, W[54] + K3);
  136|  23.4M|      F3(A, B, C, D, E, W[55] + K3);
  137|  23.4M|      F3(E, A, B, C, D, W[56] + K3);
  138|  23.4M|      F3(D, E, A, B, C, W[57] + K3);
  139|  23.4M|      F3(C, D, E, A, B, W[58] + K3);
  140|  23.4M|      F3(B, C, D, E, A, W[59] + K3);
  141|       |
  142|  23.4M|      F4(A, B, C, D, E, W[60] + K4);
  143|  23.4M|      F4(E, A, B, C, D, W[61] + K4);
  144|  23.4M|      F4(D, E, A, B, C, W[62] + K4);
  145|  23.4M|      F4(C, D, E, A, B, W[63] + K4);
  146|  23.4M|      F4(B, C, D, E, A, W[64] + K4);
  147|  23.4M|      F4(A, B, C, D, E, W[65] + K4);
  148|  23.4M|      F4(E, A, B, C, D, W[66] + K4);
  149|  23.4M|      F4(D, E, A, B, C, W[67] + K4);
  150|  23.4M|      F4(C, D, E, A, B, W[68] + K4);
  151|  23.4M|      F4(B, C, D, E, A, W[69] + K4);
  152|  23.4M|      F4(A, B, C, D, E, W[70] + K4);
  153|  23.4M|      F4(E, A, B, C, D, W[71] + K4);
  154|  23.4M|      F4(D, E, A, B, C, W[72] + K4);
  155|  23.4M|      F4(C, D, E, A, B, W[73] + K4);
  156|  23.4M|      F4(B, C, D, E, A, W[74] + K4);
  157|  23.4M|      F4(A, B, C, D, E, W[75] + K4);
  158|  23.4M|      F4(E, A, B, C, D, W[76] + K4);
  159|  23.4M|      F4(D, E, A, B, C, W[77] + K4);
  160|  23.4M|      F4(C, D, E, A, B, W[78] + K4);
  161|  23.4M|      F4(B, C, D, E, A, W[79] + K4);
  162|       |
  163|  23.4M|      A = (digest[0] += A);
  164|  23.4M|      B = (digest[1] += B);
  165|  23.4M|      C = (digest[2] += C);
  166|  23.4M|      D = (digest[3] += D);
  167|  23.4M|      E = (digest[4] += E);
  168|  23.4M|   }
  169|  23.4M|}
_ZN5Botan5SHA_14initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  174|  8.66k|void SHA_1::init(digest_type& digest) {
  175|  8.66k|   digest.assign({0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476, 0xC3D2E1F0});
  176|  8.66k|}
_ZNK5Botan5SHA_110new_objectEv:
  206|  2.23k|std::unique_ptr<HashFunction> SHA_1::new_object() const {
  207|  2.23k|   return std::make_unique<SHA_1>();
  208|  2.23k|}
_ZN5Botan5SHA_18add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  214|   115M|void SHA_1::add_data(std::span<const uint8_t> input) {
  215|   115M|   m_md.update(input);
  216|   115M|}
_ZN5Botan5SHA_112final_resultENSt3__14spanIhLm18446744073709551615EEE:
  218|  3.86k|void SHA_1::final_result(std::span<uint8_t> output) {
  219|  3.86k|   m_md.final(output);
  220|  3.86k|}

_ZN5Botan7SHA_25615compress_digestERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
   59|  6.32M|                                                             size_t blocks) {
   60|       |#if defined(BOTAN_HAS_SHA2_32_X86)
   61|       |   if(CPUID::has(CPUID::Feature::SHA)) {
   62|       |      return SHA_256::compress_digest_x86(digest, input, blocks);
   63|       |   }
   64|       |#endif
   65|       |
   66|       |#if defined(BOTAN_HAS_SHA2_32_ARMV8)
   67|       |   if(CPUID::has(CPUID::Feature::SHA2)) {
   68|       |      return SHA_256::compress_digest_armv8(digest, input, blocks);
   69|       |   }
   70|       |#endif
   71|       |
   72|       |#if defined(BOTAN_HAS_SHA2_32_X86_AVX2)
   73|       |   if(CPUID::has(CPUID::Feature::AVX2, CPUID::Feature::BMI)) {
   74|       |      return SHA_256::compress_digest_x86_avx2(digest, input, blocks);
   75|       |   }
   76|       |#endif
   77|       |
   78|       |#if defined(BOTAN_HAS_SHA2_32_SIMD)
   79|       |   if(CPUID::has(CPUID::Feature::SIMD_4X32)) {
   80|       |      return SHA_256::compress_digest_x86_simd(digest, input, blocks);
   81|       |   }
   82|       |#endif
   83|       |
   84|  6.32M|   uint32_t A = digest[0];
   85|  6.32M|   uint32_t B = digest[1];
   86|  6.32M|   uint32_t C = digest[2];
   87|  6.32M|   uint32_t D = digest[3];
   88|  6.32M|   uint32_t E = digest[4];
   89|  6.32M|   uint32_t F = digest[5];
   90|  6.32M|   uint32_t G = digest[6];
   91|  6.32M|   uint32_t H = digest[7];
   92|       |
   93|  6.32M|   std::array<uint32_t, 16> W{};
   94|       |
   95|  6.32M|   BufferSlicer in(input);
   96|       |
   97|  12.7M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (97:22): [True: 6.44M, False: 6.32M]
  ------------------
   98|  6.44M|      load_be(W, in.take<block_bytes>());
   99|       |
  100|       |      // clang-format off
  101|       |
  102|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x428A2F98);
  103|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x71374491);
  104|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0xB5C0FBCF);
  105|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0xE9B5DBA5);
  106|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x3956C25B);
  107|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x59F111F1);
  108|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x923F82A4);
  109|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0xAB1C5ED5);
  110|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0xD807AA98);
  111|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0x12835B01);
  112|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0x243185BE);
  113|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0x550C7DC3);
  114|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0x72BE5D74);
  115|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0x80DEB1FE);
  116|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0x9BDC06A7);
  117|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0xC19BF174);
  118|       |
  119|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0xE49B69C1);
  120|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0xEFBE4786);
  121|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x0FC19DC6);
  122|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x240CA1CC);
  123|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x2DE92C6F);
  124|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x4A7484AA);
  125|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x5CB0A9DC);
  126|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x76F988DA);
  127|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0x983E5152);
  128|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0xA831C66D);
  129|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0xB00327C8);
  130|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0xBF597FC7);
  131|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0xC6E00BF3);
  132|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xD5A79147);
  133|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0x06CA6351);
  134|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0x14292967);
  135|       |
  136|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x27B70A85);
  137|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x2E1B2138);
  138|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x4D2C6DFC);
  139|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x53380D13);
  140|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x650A7354);
  141|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x766A0ABB);
  142|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x81C2C92E);
  143|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x92722C85);
  144|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0xA2BFE8A1);
  145|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0xA81A664B);
  146|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0xC24B8B70);
  147|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0xC76C51A3);
  148|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0xD192E819);
  149|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xD6990624);
  150|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0xF40E3585);
  151|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0x106AA070);
  152|       |
  153|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x19A4C116);
  154|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x1E376C08);
  155|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x2748774C);
  156|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x34B0BCB5);
  157|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x391C0CB3);
  158|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x4ED8AA4A);
  159|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x5B9CCA4F);
  160|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x682E6FF3);
  161|  6.44M|      SHA2_32_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0x748F82EE);
  162|  6.44M|      SHA2_32_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0x78A5636F);
  163|  6.44M|      SHA2_32_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0x84C87814);
  164|  6.44M|      SHA2_32_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0x8CC70208);
  165|  6.44M|      SHA2_32_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0x90BEFFFA);
  166|  6.44M|      SHA2_32_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xA4506CEB);
  167|  6.44M|      SHA2_32_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0xBEF9A3F7);
  168|  6.44M|      SHA2_32_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0xC67178F2);
  169|       |
  170|       |      // clang-format on
  171|       |
  172|  6.44M|      A = (digest[0] += A);
  173|  6.44M|      B = (digest[1] += B);
  174|  6.44M|      C = (digest[2] += C);
  175|  6.44M|      D = (digest[3] += D);
  176|  6.44M|      E = (digest[4] += E);
  177|  6.44M|      F = (digest[5] += F);
  178|  6.44M|      G = (digest[6] += G);
  179|  6.44M|      H = (digest[7] += H);
  180|  6.44M|   }
  181|  6.32M|}
_ZN5Botan7SHA_22410compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
  187|  1.93M|void SHA_224::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
  188|  1.93M|   SHA_256::compress_digest(digest, input, blocks);
  189|  1.93M|}
_ZN5Botan7SHA_2244initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  191|  1.66k|void SHA_224::init(digest_type& digest) {
  192|  1.66k|   digest.assign({0xC1059ED8, 0x367CD507, 0x3070DD17, 0xF70E5939, 0xFFC00B31, 0x68581511, 0x64F98FA7, 0xBEFA4FA4});
  193|  1.66k|}
_ZNK5Botan7SHA_22410new_objectEv:
  195|    300|std::unique_ptr<HashFunction> SHA_224::new_object() const {
  196|    300|   return std::make_unique<SHA_224>();
  197|    300|}
_ZN5Botan7SHA_2248add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  203|  5.67M|void SHA_224::add_data(std::span<const uint8_t> input) {
  204|  5.67M|   m_md.update(input);
  205|  5.67M|}
_ZN5Botan7SHA_22412final_resultENSt3__14spanIhLm18446744073709551615EEE:
  207|    594|void SHA_224::final_result(std::span<uint8_t> output) {
  208|    594|   m_md.final(output);
  209|    594|}
_ZN5Botan7SHA_25610compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
  215|  4.39M|void SHA_256::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
  216|  4.39M|   SHA_256::compress_digest(digest, input, blocks);
  217|  4.39M|}
_ZN5Botan7SHA_2564initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  219|  96.9k|void SHA_256::init(digest_type& digest) {
  220|  96.9k|   digest.assign({0x6A09E667, 0xBB67AE85, 0x3C6EF372, 0xA54FF53A, 0x510E527F, 0x9B05688C, 0x1F83D9AB, 0x5BE0CD19});
  221|  96.9k|}
_ZNK5Botan7SHA_25610new_objectEv:
  223|  16.6k|std::unique_ptr<HashFunction> SHA_256::new_object() const {
  224|  16.6k|   return std::make_unique<SHA_256>();
  225|  16.6k|}
_ZN5Botan7SHA_2568add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  231|  18.8M|void SHA_256::add_data(std::span<const uint8_t> input) {
  232|  18.8M|   m_md.update(input);
  233|  18.8M|}
_ZN5Botan7SHA_25612final_resultENSt3__14spanIhLm18446744073709551615EEE:
  235|  43.5k|void SHA_256::final_result(std::span<uint8_t> output) {
  236|  43.5k|   m_md.final(output);
  237|  43.5k|}

_ZN5Botan7SHA_51215compress_digestERNSt3__16vectorImNS_16secure_allocatorImEEEENS1_4spanIKhLm18446744073709551615EEEm:
   56|  5.26M|void SHA_512::compress_digest(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
   57|       |#if defined(BOTAN_HAS_SHA2_64_X86)
   58|       |   if(CPUID::has(CPUID::Feature::SHA512)) {
   59|       |      return compress_digest_x86(digest, input, blocks);
   60|       |   }
   61|       |#endif
   62|       |
   63|       |#if defined(BOTAN_HAS_SHA2_64_ARMV8)
   64|       |   if(CPUID::has(CPUID::Feature::SHA2_512)) {
   65|       |      return compress_digest_armv8(digest, input, blocks);
   66|       |   }
   67|       |#endif
   68|       |
   69|       |#if defined(BOTAN_HAS_SHA2_64_X86_AVX512)
   70|       |   if(CPUID::has(CPUID::Feature::AVX512, CPUID::Feature::BMI)) {
   71|       |      return compress_digest_x86_avx512(digest, input, blocks);
   72|       |   }
   73|       |#endif
   74|       |
   75|       |#if defined(BOTAN_HAS_SHA2_64_X86_AVX2)
   76|       |   if(CPUID::has(CPUID::Feature::AVX2, CPUID::Feature::BMI)) {
   77|       |      return compress_digest_x86_avx2(digest, input, blocks);
   78|       |   }
   79|       |#endif
   80|       |
   81|  5.26M|   uint64_t A = digest[0];
   82|  5.26M|   uint64_t B = digest[1];
   83|  5.26M|   uint64_t C = digest[2];
   84|  5.26M|   uint64_t D = digest[3];
   85|  5.26M|   uint64_t E = digest[4];
   86|  5.26M|   uint64_t F = digest[5];
   87|  5.26M|   uint64_t G = digest[6];
   88|  5.26M|   uint64_t H = digest[7];
   89|       |
   90|  5.26M|   std::array<uint64_t, 16> W{};
   91|       |
   92|  5.26M|   BufferSlicer in(input);
   93|       |
   94|  14.4M|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (94:22): [True: 9.21M, False: 5.26M]
  ------------------
   95|  9.21M|      load_be(W, in.take<block_bytes>());
   96|       |
   97|       |      // clang-format off
   98|       |
   99|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x428A2F98D728AE22);
  100|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x7137449123EF65CD);
  101|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0xB5C0FBCFEC4D3B2F);
  102|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0xE9B5DBA58189DBBC);
  103|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x3956C25BF348B538);
  104|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x59F111F1B605D019);
  105|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x923F82A4AF194F9B);
  106|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0xAB1C5ED5DA6D8118);
  107|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0xD807AA98A3030242);
  108|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0x12835B0145706FBE);
  109|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0x243185BE4EE4B28C);
  110|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0x550C7DC3D5FFB4E2);
  111|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0x72BE5D74F27B896F);
  112|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0x80DEB1FE3B1696B1);
  113|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0x9BDC06A725C71235);
  114|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0xC19BF174CF692694);
  115|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0xE49B69C19EF14AD2);
  116|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0xEFBE4786384F25E3);
  117|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x0FC19DC68B8CD5B5);
  118|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x240CA1CC77AC9C65);
  119|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x2DE92C6F592B0275);
  120|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x4A7484AA6EA6E483);
  121|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x5CB0A9DCBD41FBD4);
  122|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x76F988DA831153B5);
  123|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0x983E5152EE66DFAB);
  124|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0xA831C66D2DB43210);
  125|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0xB00327C898FB213F);
  126|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0xBF597FC7BEEF0EE4);
  127|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0xC6E00BF33DA88FC2);
  128|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xD5A79147930AA725);
  129|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0x06CA6351E003826F);
  130|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0x142929670A0E6E70);
  131|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x27B70A8546D22FFC);
  132|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x2E1B21385C26C926);
  133|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x4D2C6DFC5AC42AED);
  134|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x53380D139D95B3DF);
  135|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x650A73548BAF63DE);
  136|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x766A0ABB3C77B2A8);
  137|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x81C2C92E47EDAEE6);
  138|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x92722C851482353B);
  139|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0xA2BFE8A14CF10364);
  140|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0xA81A664BBC423001);
  141|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0xC24B8B70D0F89791);
  142|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0xC76C51A30654BE30);
  143|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0xD192E819D6EF5218);
  144|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xD69906245565A910);
  145|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0xF40E35855771202A);
  146|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0x106AA07032BBD1B8);
  147|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0x19A4C116B8D2D0C8);
  148|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0x1E376C085141AB53);
  149|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0x2748774CDF8EEB99);
  150|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0x34B0BCB5E19B48A8);
  151|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x391C0CB3C5C95A63);
  152|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x4ED8AA4AE3418ACB);
  153|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x5B9CCA4F7763E373);
  154|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x682E6FF3D6B2B8A3);
  155|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0x748F82EE5DEFB2FC);
  156|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0x78A5636F43172F60);
  157|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0x84C87814A1F0AB72);
  158|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0x8CC702081A6439EC);
  159|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0x90BEFFFA23631E28);
  160|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0xA4506CEBDE82BDE9);
  161|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0xBEF9A3F7B2C67915);
  162|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0xC67178F2E372532B);
  163|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 0], W[14], W[ 9], W[ 1], 0xCA273ECEEA26619C);
  164|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 1], W[15], W[10], W[ 2], 0xD186B8C721C0C207);
  165|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[ 2], W[ 0], W[11], W[ 3], 0xEADA7DD6CDE0EB1E);
  166|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[ 3], W[ 1], W[12], W[ 4], 0xF57D4F7FEE6ED178);
  167|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[ 4], W[ 2], W[13], W[ 5], 0x06F067AA72176FBA);
  168|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[ 5], W[ 3], W[14], W[ 6], 0x0A637DC5A2C898A6);
  169|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[ 6], W[ 4], W[15], W[ 7], 0x113F9804BEF90DAE);
  170|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[ 7], W[ 5], W[ 0], W[ 8], 0x1B710B35131C471B);
  171|  9.21M|      SHA2_64_F(A, B, C, D, E, F, G, H, W[ 8], W[ 6], W[ 1], W[ 9], 0x28DB77F523047D84);
  172|  9.21M|      SHA2_64_F(H, A, B, C, D, E, F, G, W[ 9], W[ 7], W[ 2], W[10], 0x32CAAB7B40C72493);
  173|  9.21M|      SHA2_64_F(G, H, A, B, C, D, E, F, W[10], W[ 8], W[ 3], W[11], 0x3C9EBE0A15C9BEBC);
  174|  9.21M|      SHA2_64_F(F, G, H, A, B, C, D, E, W[11], W[ 9], W[ 4], W[12], 0x431D67C49C100D4C);
  175|  9.21M|      SHA2_64_F(E, F, G, H, A, B, C, D, W[12], W[10], W[ 5], W[13], 0x4CC5D4BECB3E42B6);
  176|  9.21M|      SHA2_64_F(D, E, F, G, H, A, B, C, W[13], W[11], W[ 6], W[14], 0x597F299CFC657E2A);
  177|  9.21M|      SHA2_64_F(C, D, E, F, G, H, A, B, W[14], W[12], W[ 7], W[15], 0x5FCB6FAB3AD6FAEC);
  178|  9.21M|      SHA2_64_F(B, C, D, E, F, G, H, A, W[15], W[13], W[ 8], W[ 0], 0x6C44198C4A475817);
  179|       |
  180|       |      // clang-format on
  181|       |
  182|  9.21M|      A = (digest[0] += A);
  183|  9.21M|      B = (digest[1] += B);
  184|  9.21M|      C = (digest[2] += C);
  185|  9.21M|      D = (digest[3] += D);
  186|  9.21M|      E = (digest[4] += E);
  187|  9.21M|      F = (digest[5] += F);
  188|  9.21M|      G = (digest[6] += G);
  189|  9.21M|      H = (digest[7] += H);
  190|  9.21M|   }
  191|  5.26M|}
_ZN5Botan7SHA_38410compress_nERNSt3__16vectorImNS_16secure_allocatorImEEEENS1_4spanIKhLm18446744073709551615EEEm:
  209|  49.2k|void SHA_384::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
  210|  49.2k|   SHA_512::compress_digest(digest, input, blocks);
  211|  49.2k|}
_ZN5Botan7SHA_51210compress_nERNSt3__16vectorImNS_16secure_allocatorImEEEENS1_4spanIKhLm18446744073709551615EEEm:
  213|  5.22M|void SHA_512::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
  214|  5.22M|   SHA_512::compress_digest(digest, input, blocks);
  215|  5.22M|}
_ZN5Botan7SHA_3844initERNSt3__16vectorImNS_16secure_allocatorImEEEE:
  228|  4.96k|void SHA_384::init(digest_type& digest) {
  229|  4.96k|   digest.assign({0xCBBB9D5DC1059ED8,
  230|  4.96k|                  0x629A292A367CD507,
  231|  4.96k|                  0x9159015A3070DD17,
  232|  4.96k|                  0x152FECD8F70E5939,
  233|  4.96k|                  0x67332667FFC00B31,
  234|  4.96k|                  0x8EB44A8768581511,
  235|  4.96k|                  0xDB0C2E0D64F98FA7,
  236|  4.96k|                  0x47B5481DBEFA4FA4});
  237|  4.96k|}
_ZN5Botan7SHA_5124initERNSt3__16vectorImNS_16secure_allocatorImEEEE:
  239|  2.49M|void SHA_512::init(digest_type& digest) {
  240|  2.49M|   digest.assign({0x6A09E667F3BCC908,
  241|  2.49M|                  0xBB67AE8584CAA73B,
  242|  2.49M|                  0x3C6EF372FE94F82B,
  243|  2.49M|                  0xA54FF53A5F1D36F1,
  244|  2.49M|                  0x510E527FADE682D1,
  245|  2.49M|                  0x9B05688C2B3E6C1F,
  246|  2.49M|                  0x1F83D9ABFB41BD6B,
  247|  2.49M|                  0x5BE0CD19137E2179});
  248|  2.49M|}
_ZNK5Botan7SHA_38410new_objectEv:
  250|  1.16k|std::unique_ptr<HashFunction> SHA_384::new_object() const {
  251|  1.16k|   return std::make_unique<SHA_384>();
  252|  1.16k|}
_ZNK5Botan7SHA_51210new_objectEv:
  254|    696|std::unique_ptr<HashFunction> SHA_512::new_object() const {
  255|    696|   return std::make_unique<SHA_512>();
  256|    696|}
_ZN5Botan7SHA_3848add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  274|   978k|void SHA_384::add_data(std::span<const uint8_t> input) {
  275|   978k|   m_md.update(input);
  276|   978k|}
_ZN5Botan7SHA_5128add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  278|  30.9M|void SHA_512::add_data(std::span<const uint8_t> input) {
  279|  30.9M|   m_md.update(input);
  280|  30.9M|}
_ZN5Botan7SHA_38412final_resultENSt3__14spanIhLm18446744073709551615EEE:
  286|  1.21k|void SHA_384::final_result(std::span<uint8_t> output) {
  287|  1.21k|   m_md.final(output);
  288|  1.21k|}
_ZN5Botan7SHA_51212final_resultENSt3__14spanIhLm18446744073709551615EEE:
  290|  2.29M|void SHA_512::final_result(std::span<uint8_t> output) {
  291|  2.29M|   m_md.final(output);
  292|  2.29M|}

_ZN5Botan5SHA_3C2Em:
   17|  9.53k|      m_keccak({.capacity_bits = output_bits * 2, .padding = KeccakPadding::sha3()}), m_output_length(output_bits / 8) {
   18|       |   // We only support the parameters for SHA-3 in this constructor
   19|       |
   20|  9.53k|   if(output_bits != 224 && output_bits != 256 && output_bits != 384 && output_bits != 512) {
  ------------------
  |  Branch (20:7): [True: 9.53k, False: 0]
  |  Branch (20:29): [True: 3.35k, False: 6.17k]
  |  Branch (20:51): [True: 3.35k, False: 0]
  |  Branch (20:73): [True: 0, False: 3.35k]
  ------------------
   21|      0|      throw Invalid_Argument(fmt("SHA_3: Invalid output length {}", output_bits));
   22|      0|   }
   23|  9.53k|}
_ZNK5Botan5SHA_34nameEv:
   25|    360|std::string SHA_3::name() const {
   26|    360|   return fmt("SHA-3({})", m_output_length * 8);
   27|    360|}
_ZNK5Botan5SHA_310new_objectEv:
   37|  4.10k|std::unique_ptr<HashFunction> SHA_3::new_object() const {
   38|  4.10k|   return std::make_unique<SHA_3>(m_output_length * 8);
   39|  4.10k|}
_ZN5Botan5SHA_38add_dataENSt3__14spanIKhLm18446744073709551615EEE:
   45|  4.36M|void SHA_3::add_data(std::span<const uint8_t> input) {
   46|  4.36M|   m_keccak.absorb(input);
   47|  4.36M|}
_ZN5Botan5SHA_312final_resultENSt3__14spanIhLm18446744073709551615EEE:
   49|  4.48k|void SHA_3::final_result(std::span<uint8_t> output) {
   50|  4.48k|   m_keccak.finish();
   51|  4.48k|   m_keccak.squeeze(output);
   52|  4.48k|   m_keccak.clear();
   53|  4.48k|}

_ZN5Botan3SM310compress_nERNSt3__16vectorIjNS_16secure_allocatorIjEEEENS1_4spanIKhLm18446744073709551615EEEm:
   24|  59.3k|void SM3::compress_n(digest_type& digest, std::span<const uint8_t> input, size_t blocks) {
   25|       |#if defined(BOTAN_HAS_SM3_ARMV8)
   26|       |   if(CPUID::has(CPUID::Feature::SM3)) {
   27|       |      return compress_digest_armv8(digest, input, blocks);
   28|       |   }
   29|       |#endif
   30|       |
   31|       |#if defined(BOTAN_HAS_SM3_X86)
   32|       |   if(CPUID::has(CPUID::Feature::SM3, CPUID::Feature::AVX2)) {
   33|       |      return compress_digest_x86(digest, input, blocks);
   34|       |   }
   35|       |#endif
   36|       |
   37|       |#if defined(BOTAN_HAS_SM3_X86_AVX2_BMI2)
   38|       |   if(CPUID::has(CPUID::Feature::AVX2, CPUID::Feature::BMI)) {
   39|       |      return compress_digest_x86_avx2(digest, input, blocks);
   40|       |   }
   41|       |#endif
   42|       |
   43|  59.3k|   uint32_t A = digest[0];
   44|  59.3k|   uint32_t B = digest[1];
   45|  59.3k|   uint32_t C = digest[2];
   46|  59.3k|   uint32_t D = digest[3];
   47|  59.3k|   uint32_t E = digest[4];
   48|  59.3k|   uint32_t F = digest[5];
   49|  59.3k|   uint32_t G = digest[6];
   50|  59.3k|   uint32_t H = digest[7];
   51|  59.3k|   std::array<uint32_t, 16> W{};
   52|       |
   53|  59.3k|   BufferSlicer in(input);
   54|       |
   55|   130k|   for(size_t i = 0; i != blocks; ++i) {
  ------------------
  |  Branch (55:22): [True: 71.0k, False: 59.3k]
  ------------------
   56|  71.0k|      load_be(W, in.take<block_bytes>());
   57|       |
   58|       |      // clang-format off
   59|       |
   60|  71.0k|      R1(A, B, C, D, E, F, G, H, 0x79CC4519, W[ 0], W[ 4]);
   61|  71.0k|      W[ 0] = SM3_E(W[ 0], W[ 7], W[13], W[ 3], W[10]);
   62|  71.0k|      R1(D, A, B, C, H, E, F, G, 0xF3988A32, W[ 1], W[ 5]);
   63|  71.0k|      W[ 1] = SM3_E(W[ 1], W[ 8], W[14], W[ 4], W[11]);
   64|  71.0k|      R1(C, D, A, B, G, H, E, F, 0xE7311465, W[ 2], W[ 6]);
   65|  71.0k|      W[ 2] = SM3_E(W[ 2], W[ 9], W[15], W[ 5], W[12]);
   66|  71.0k|      R1(B, C, D, A, F, G, H, E, 0xCE6228CB, W[ 3], W[ 7]);
   67|  71.0k|      W[ 3] = SM3_E(W[ 3], W[10], W[ 0], W[ 6], W[13]);
   68|  71.0k|      R1(A, B, C, D, E, F, G, H, 0x9CC45197, W[ 4], W[ 8]);
   69|  71.0k|      W[ 4] = SM3_E(W[ 4], W[11], W[ 1], W[ 7], W[14]);
   70|  71.0k|      R1(D, A, B, C, H, E, F, G, 0x3988A32F, W[ 5], W[ 9]);
   71|  71.0k|      W[ 5] = SM3_E(W[ 5], W[12], W[ 2], W[ 8], W[15]);
   72|  71.0k|      R1(C, D, A, B, G, H, E, F, 0x7311465E, W[ 6], W[10]);
   73|  71.0k|      W[ 6] = SM3_E(W[ 6], W[13], W[ 3], W[ 9], W[ 0]);
   74|  71.0k|      R1(B, C, D, A, F, G, H, E, 0xE6228CBC, W[ 7], W[11]);
   75|  71.0k|      W[ 7] = SM3_E(W[ 7], W[14], W[ 4], W[10], W[ 1]);
   76|  71.0k|      R1(A, B, C, D, E, F, G, H, 0xCC451979, W[ 8], W[12]);
   77|  71.0k|      W[ 8] = SM3_E(W[ 8], W[15], W[ 5], W[11], W[ 2]);
   78|  71.0k|      R1(D, A, B, C, H, E, F, G, 0x988A32F3, W[ 9], W[13]);
   79|  71.0k|      W[ 9] = SM3_E(W[ 9], W[ 0], W[ 6], W[12], W[ 3]);
   80|  71.0k|      R1(C, D, A, B, G, H, E, F, 0x311465E7, W[10], W[14]);
   81|  71.0k|      W[10] = SM3_E(W[10], W[ 1], W[ 7], W[13], W[ 4]);
   82|  71.0k|      R1(B, C, D, A, F, G, H, E, 0x6228CBCE, W[11], W[15]);
   83|  71.0k|      W[11] = SM3_E(W[11], W[ 2], W[ 8], W[14], W[ 5]);
   84|  71.0k|      R1(A, B, C, D, E, F, G, H, 0xC451979C, W[12], W[ 0]);
   85|  71.0k|      W[12] = SM3_E(W[12], W[ 3], W[ 9], W[15], W[ 6]);
   86|  71.0k|      R1(D, A, B, C, H, E, F, G, 0x88A32F39, W[13], W[ 1]);
   87|  71.0k|      W[13] = SM3_E(W[13], W[ 4], W[10], W[ 0], W[ 7]);
   88|  71.0k|      R1(C, D, A, B, G, H, E, F, 0x11465E73, W[14], W[ 2]);
   89|  71.0k|      W[14] = SM3_E(W[14], W[ 5], W[11], W[ 1], W[ 8]);
   90|  71.0k|      R1(B, C, D, A, F, G, H, E, 0x228CBCE6, W[15], W[ 3]);
   91|  71.0k|      W[15] = SM3_E(W[15], W[ 6], W[12], W[ 2], W[ 9]);
   92|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x9D8A7A87, W[ 0], W[ 4]);
   93|  71.0k|      W[ 0] = SM3_E(W[ 0], W[ 7], W[13], W[ 3], W[10]);
   94|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x3B14F50F, W[ 1], W[ 5]);
   95|  71.0k|      W[ 1] = SM3_E(W[ 1], W[ 8], W[14], W[ 4], W[11]);
   96|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x7629EA1E, W[ 2], W[ 6]);
   97|  71.0k|      W[ 2] = SM3_E(W[ 2], W[ 9], W[15], W[ 5], W[12]);
   98|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xEC53D43C, W[ 3], W[ 7]);
   99|  71.0k|      W[ 3] = SM3_E(W[ 3], W[10], W[ 0], W[ 6], W[13]);
  100|  71.0k|      R2(A, B, C, D, E, F, G, H, 0xD8A7A879, W[ 4], W[ 8]);
  101|  71.0k|      W[ 4] = SM3_E(W[ 4], W[11], W[ 1], W[ 7], W[14]);
  102|  71.0k|      R2(D, A, B, C, H, E, F, G, 0xB14F50F3, W[ 5], W[ 9]);
  103|  71.0k|      W[ 5] = SM3_E(W[ 5], W[12], W[ 2], W[ 8], W[15]);
  104|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x629EA1E7, W[ 6], W[10]);
  105|  71.0k|      W[ 6] = SM3_E(W[ 6], W[13], W[ 3], W[ 9], W[ 0]);
  106|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xC53D43CE, W[ 7], W[11]);
  107|  71.0k|      W[ 7] = SM3_E(W[ 7], W[14], W[ 4], W[10], W[ 1]);
  108|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x8A7A879D, W[ 8], W[12]);
  109|  71.0k|      W[ 8] = SM3_E(W[ 8], W[15], W[ 5], W[11], W[ 2]);
  110|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x14F50F3B, W[ 9], W[13]);
  111|  71.0k|      W[ 9] = SM3_E(W[ 9], W[ 0], W[ 6], W[12], W[ 3]);
  112|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x29EA1E76, W[10], W[14]);
  113|  71.0k|      W[10] = SM3_E(W[10], W[ 1], W[ 7], W[13], W[ 4]);
  114|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x53D43CEC, W[11], W[15]);
  115|  71.0k|      W[11] = SM3_E(W[11], W[ 2], W[ 8], W[14], W[ 5]);
  116|  71.0k|      R2(A, B, C, D, E, F, G, H, 0xA7A879D8, W[12], W[ 0]);
  117|  71.0k|      W[12] = SM3_E(W[12], W[ 3], W[ 9], W[15], W[ 6]);
  118|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x4F50F3B1, W[13], W[ 1]);
  119|  71.0k|      W[13] = SM3_E(W[13], W[ 4], W[10], W[ 0], W[ 7]);
  120|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x9EA1E762, W[14], W[ 2]);
  121|  71.0k|      W[14] = SM3_E(W[14], W[ 5], W[11], W[ 1], W[ 8]);
  122|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x3D43CEC5, W[15], W[ 3]);
  123|  71.0k|      W[15] = SM3_E(W[15], W[ 6], W[12], W[ 2], W[ 9]);
  124|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x7A879D8A, W[ 0], W[ 4]);
  125|  71.0k|      W[ 0] = SM3_E(W[ 0], W[ 7], W[13], W[ 3], W[10]);
  126|  71.0k|      R2(D, A, B, C, H, E, F, G, 0xF50F3B14, W[ 1], W[ 5]);
  127|  71.0k|      W[ 1] = SM3_E(W[ 1], W[ 8], W[14], W[ 4], W[11]);
  128|  71.0k|      R2(C, D, A, B, G, H, E, F, 0xEA1E7629, W[ 2], W[ 6]);
  129|  71.0k|      W[ 2] = SM3_E(W[ 2], W[ 9], W[15], W[ 5], W[12]);
  130|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xD43CEC53, W[ 3], W[ 7]);
  131|  71.0k|      W[ 3] = SM3_E(W[ 3], W[10], W[ 0], W[ 6], W[13]);
  132|  71.0k|      R2(A, B, C, D, E, F, G, H, 0xA879D8A7, W[ 4], W[ 8]);
  133|  71.0k|      W[ 4] = SM3_E(W[ 4], W[11], W[ 1], W[ 7], W[14]);
  134|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x50F3B14F, W[ 5], W[ 9]);
  135|  71.0k|      W[ 5] = SM3_E(W[ 5], W[12], W[ 2], W[ 8], W[15]);
  136|  71.0k|      R2(C, D, A, B, G, H, E, F, 0xA1E7629E, W[ 6], W[10]);
  137|  71.0k|      W[ 6] = SM3_E(W[ 6], W[13], W[ 3], W[ 9], W[ 0]);
  138|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x43CEC53D, W[ 7], W[11]);
  139|  71.0k|      W[ 7] = SM3_E(W[ 7], W[14], W[ 4], W[10], W[ 1]);
  140|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x879D8A7A, W[ 8], W[12]);
  141|  71.0k|      W[ 8] = SM3_E(W[ 8], W[15], W[ 5], W[11], W[ 2]);
  142|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x0F3B14F5, W[ 9], W[13]);
  143|  71.0k|      W[ 9] = SM3_E(W[ 9], W[ 0], W[ 6], W[12], W[ 3]);
  144|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x1E7629EA, W[10], W[14]);
  145|  71.0k|      W[10] = SM3_E(W[10], W[ 1], W[ 7], W[13], W[ 4]);
  146|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x3CEC53D4, W[11], W[15]);
  147|  71.0k|      W[11] = SM3_E(W[11], W[ 2], W[ 8], W[14], W[ 5]);
  148|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x79D8A7A8, W[12], W[ 0]);
  149|  71.0k|      W[12] = SM3_E(W[12], W[ 3], W[ 9], W[15], W[ 6]);
  150|  71.0k|      R2(D, A, B, C, H, E, F, G, 0xF3B14F50, W[13], W[ 1]);
  151|  71.0k|      W[13] = SM3_E(W[13], W[ 4], W[10], W[ 0], W[ 7]);
  152|  71.0k|      R2(C, D, A, B, G, H, E, F, 0xE7629EA1, W[14], W[ 2]);
  153|  71.0k|      W[14] = SM3_E(W[14], W[ 5], W[11], W[ 1], W[ 8]);
  154|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xCEC53D43, W[15], W[ 3]);
  155|  71.0k|      W[15] = SM3_E(W[15], W[ 6], W[12], W[ 2], W[ 9]);
  156|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x9D8A7A87, W[ 0], W[ 4]);
  157|  71.0k|      W[ 0] = SM3_E(W[ 0], W[ 7], W[13], W[ 3], W[10]);
  158|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x3B14F50F, W[ 1], W[ 5]);
  159|  71.0k|      W[ 1] = SM3_E(W[ 1], W[ 8], W[14], W[ 4], W[11]);
  160|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x7629EA1E, W[ 2], W[ 6]);
  161|  71.0k|      W[ 2] = SM3_E(W[ 2], W[ 9], W[15], W[ 5], W[12]);
  162|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xEC53D43C, W[ 3], W[ 7]);
  163|  71.0k|      W[ 3] = SM3_E(W[ 3], W[10], W[ 0], W[ 6], W[13]);
  164|  71.0k|      R2(A, B, C, D, E, F, G, H, 0xD8A7A879, W[ 4], W[ 8]);
  165|  71.0k|      R2(D, A, B, C, H, E, F, G, 0xB14F50F3, W[ 5], W[ 9]);
  166|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x629EA1E7, W[ 6], W[10]);
  167|  71.0k|      R2(B, C, D, A, F, G, H, E, 0xC53D43CE, W[ 7], W[11]);
  168|  71.0k|      R2(A, B, C, D, E, F, G, H, 0x8A7A879D, W[ 8], W[12]);
  169|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x14F50F3B, W[ 9], W[13]);
  170|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x29EA1E76, W[10], W[14]);
  171|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x53D43CEC, W[11], W[15]);
  172|  71.0k|      R2(A, B, C, D, E, F, G, H, 0xA7A879D8, W[12], W[ 0]);
  173|  71.0k|      R2(D, A, B, C, H, E, F, G, 0x4F50F3B1, W[13], W[ 1]);
  174|  71.0k|      R2(C, D, A, B, G, H, E, F, 0x9EA1E762, W[14], W[ 2]);
  175|  71.0k|      R2(B, C, D, A, F, G, H, E, 0x3D43CEC5, W[15], W[ 3]);
  176|       |
  177|       |      // clang-format on
  178|       |
  179|  71.0k|      A = (digest[0] ^= A);
  180|  71.0k|      B = (digest[1] ^= B);
  181|  71.0k|      C = (digest[2] ^= C);
  182|  71.0k|      D = (digest[3] ^= D);
  183|  71.0k|      E = (digest[4] ^= E);
  184|  71.0k|      F = (digest[5] ^= F);
  185|  71.0k|      G = (digest[6] ^= G);
  186|  71.0k|      H = (digest[7] ^= H);
  187|  71.0k|   }
  188|  59.3k|}
_ZN5Botan3SM34initERNSt3__16vectorIjNS_16secure_allocatorIjEEEE:
  190|    491|void SM3::init(digest_type& digest) {
  191|    491|   digest.assign(
  192|    491|      {0x7380166fUL, 0x4914b2b9UL, 0x172442d7UL, 0xda8a0600UL, 0xa96f30bcUL, 0x163138aaUL, 0xe38dee4dUL, 0xb0fb0e4eUL});
  193|    491|}
_ZNK5Botan3SM310new_objectEv:
  195|    120|std::unique_ptr<HashFunction> SM3::new_object() const {
  196|    120|   return std::make_unique<SM3>();
  197|    120|}
_ZN5Botan3SM38add_dataENSt3__14spanIKhLm18446744073709551615EEE:
  203|   244k|void SM3::add_data(std::span<const uint8_t> input) {
  204|   244k|   m_md.update(input);
  205|   244k|}
_ZN5Botan3SM312final_resultENSt3__14spanIhLm18446744073709551615EEE:
  207|    126|void SM3::final_result(std::span<uint8_t> output) {
  208|    126|   m_md.final(output);
  209|    126|}

_ZNK5Botan4HKDF11perform_kdfENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEES5_S5_:
   31|  6.79k|                       std::span<const uint8_t> label) const {
   32|  6.79k|   const HKDF_Extract extract(m_prf->new_object());
   33|  6.79k|   const HKDF_Expand expand(m_prf->new_object());
   34|  6.79k|   secure_vector<uint8_t> prk(m_prf->output_length());
   35|       |
   36|  6.79k|   extract.derive_key(prk, secret, salt, {});
   37|  6.79k|   expand.derive_key(key, prk, {}, label);
   38|  6.79k|}
_ZNK5Botan12HKDF_Extract11perform_kdfENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEES5_S5_:
   51|  6.79k|                               std::span<const uint8_t> label) const {
   52|  6.79k|   const size_t prf_output_len = m_prf->output_length();
   53|  6.79k|   BOTAN_ARG_CHECK(key.size() <= prf_output_len, "HKDF-Extract maximum output length exceeded");
  ------------------
  |  |   35|  6.79k|   do {                                                          \
  |  |   36|  6.79k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.79k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.79k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.79k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.79k]
  |  |  ------------------
  ------------------
   54|  6.79k|   BOTAN_ARG_CHECK(label.empty(), "HKDF-Extract does not support a label input");
  ------------------
  |  |   35|  6.79k|   do {                                                          \
  |  |   36|  6.79k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.79k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.79k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.79k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.79k]
  |  |  ------------------
  ------------------
   55|       |
   56|  6.79k|   if(key.empty()) {
  ------------------
  |  Branch (56:7): [True: 0, False: 6.79k]
  ------------------
   57|      0|      return;
   58|      0|   }
   59|       |
   60|  6.79k|   if(salt.empty()) {
  ------------------
  |  Branch (60:7): [True: 3.75k, False: 3.04k]
  ------------------
   61|  3.75k|      m_prf->set_key(std::vector<uint8_t>(prf_output_len));
   62|  3.75k|   } else {
   63|  3.04k|      m_prf->set_key(salt);
   64|  3.04k|   }
   65|       |
   66|  6.79k|   m_prf->update(secret);
   67|       |
   68|  6.79k|   if(key.size() == prf_output_len) {
  ------------------
  |  Branch (68:7): [True: 6.79k, False: 0]
  ------------------
   69|  6.79k|      m_prf->final(key);
   70|  6.79k|   } else {
   71|      0|      const auto prk = m_prf->final();
   72|      0|      copy_mem(key, std::span{prk}.first(key.size()));
   73|      0|   }
   74|  6.79k|}
_ZNK5Botan11HKDF_Expand11perform_kdfENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEES5_S5_:
   87|  6.79k|                              std::span<const uint8_t> label) const {
   88|  6.79k|   const auto prf_output_length = m_prf->output_length();
   89|  6.79k|   BOTAN_ARG_CHECK(key.size() <= prf_output_length * 255, "HKDF-Expand maximum output length exceeded");
  ------------------
  |  |   35|  6.79k|   do {                                                          \
  |  |   36|  6.79k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.79k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.79k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.79k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.79k]
  |  |  ------------------
  ------------------
   90|       |
   91|  6.79k|   if(key.empty()) {
  ------------------
  |  Branch (91:7): [True: 0, False: 6.79k]
  ------------------
   92|      0|      return;
   93|      0|   }
   94|       |
   95|       |   // Keep a reference to the previous PRF output (empty by default).
   96|  6.79k|   std::span<uint8_t> h = {};
   97|       |
   98|  6.79k|   BufferStuffer k(key);
   99|  6.79k|   m_prf->set_key(secret);
  100|  16.4k|   for(uint8_t counter = 1; !k.full(); ++counter) {
  ------------------
  |  Branch (100:29): [True: 9.68k, False: 6.79k]
  ------------------
  101|  9.68k|      m_prf->update(h);
  102|  9.68k|      m_prf->update(label);
  103|  9.68k|      m_prf->update(salt);
  104|  9.68k|      m_prf->update(counter);
  105|       |
  106|       |      // Write straight into the output buffer, except if the PRF output needs
  107|       |      // a truncation in the final iteration.
  108|  9.68k|      if(k.remaining_capacity() >= prf_output_length) {
  ------------------
  |  Branch (108:10): [True: 3.62k, False: 6.05k]
  ------------------
  109|  3.62k|         h = k.next(prf_output_length);
  110|  3.62k|         m_prf->final(h);
  111|  6.05k|      } else {
  112|  6.05k|         const auto full_prf_output = m_prf->final();
  113|  6.05k|         h = {};  // this is the final iteration!
  114|  6.05k|         k.append(std::span{full_prf_output}.first(k.remaining_capacity()));
  115|  6.05k|      }
  116|  9.68k|   }
  117|  6.79k|}

_ZN5Botan3KDF6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
   73|  6.79k|std::unique_ptr<KDF> KDF::create(std::string_view algo_spec, std::string_view provider) {
   74|  6.79k|   const SCAN_Name req(algo_spec);
   75|       |
   76|  6.79k|#if defined(BOTAN_HAS_HKDF)
   77|  6.79k|   if(req.algo_name() == "HKDF" && req.arg_count() == 1) {
  ------------------
  |  Branch (77:7): [True: 6.79k, False: 0]
  |  Branch (77:36): [True: 6.79k, False: 0]
  ------------------
   78|  6.79k|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (78:10): [True: 6.79k, False: 0]
  |  Branch (78:30): [True: 0, False: 0]
  ------------------
   79|  6.79k|         return kdf_create_mac_or_hash<HKDF>(req.arg(0));
   80|  6.79k|      }
   81|  6.79k|   }
   82|       |
   83|      0|   if(req.algo_name() == "HKDF-Extract" && req.arg_count() == 1) {
  ------------------
  |  Branch (83:7): [True: 0, False: 0]
  |  Branch (83:44): [True: 0, False: 0]
  ------------------
   84|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (84:10): [True: 0, False: 0]
  |  Branch (84:30): [True: 0, False: 0]
  ------------------
   85|      0|         return kdf_create_mac_or_hash<HKDF_Extract>(req.arg(0));
   86|      0|      }
   87|      0|   }
   88|       |
   89|      0|   if(req.algo_name() == "HKDF-Expand" && req.arg_count() == 1) {
  ------------------
  |  Branch (89:7): [True: 0, False: 0]
  |  Branch (89:43): [True: 0, False: 0]
  ------------------
   90|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (90:10): [True: 0, False: 0]
  |  Branch (90:30): [True: 0, False: 0]
  ------------------
   91|      0|         return kdf_create_mac_or_hash<HKDF_Expand>(req.arg(0));
   92|      0|      }
   93|      0|   }
   94|      0|#endif
   95|       |
   96|      0|#if defined(BOTAN_HAS_KDF2)
   97|      0|   if(req.algo_name() == "KDF2" && req.arg_count() == 1) {
  ------------------
  |  Branch (97:7): [True: 0, False: 0]
  |  Branch (97:36): [True: 0, False: 0]
  ------------------
   98|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (98:10): [True: 0, False: 0]
  |  Branch (98:30): [True: 0, False: 0]
  ------------------
   99|      0|         if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (99:18): [True: 0, False: 0]
  ------------------
  100|      0|            return std::make_unique<KDF2>(std::move(hash));
  101|      0|         }
  102|      0|      }
  103|      0|   }
  104|      0|#endif
  105|       |
  106|       |#if defined(BOTAN_HAS_KDF1_18033)
  107|       |   if(req.algo_name() == "KDF1-18033" && req.arg_count() == 1) {
  108|       |      if(provider.empty() || provider == "base") {
  109|       |         if(auto hash = HashFunction::create(req.arg(0))) {
  110|       |            return std::make_unique<KDF1_18033>(std::move(hash));
  111|       |         }
  112|       |      }
  113|       |   }
  114|       |#endif
  115|       |
  116|       |#if defined(BOTAN_HAS_KDF1)
  117|       |   if(req.algo_name() == "KDF1" && req.arg_count() == 1) {
  118|       |      if(provider.empty() || provider == "base") {
  119|       |         if(auto hash = HashFunction::create(req.arg(0))) {
  120|       |            return std::make_unique<KDF1>(std::move(hash));
  121|       |         }
  122|       |      }
  123|       |   }
  124|       |#endif
  125|       |
  126|       |#if defined(BOTAN_HAS_TLS_V12_PRF)
  127|       |   if(req.algo_name() == "TLS-12-PRF" && req.arg_count() == 1) {
  128|       |      if(provider.empty() || provider == "base") {
  129|       |         return kdf_create_mac_or_hash<TLS_12_PRF>(req.arg(0));
  130|       |      }
  131|       |   }
  132|       |#endif
  133|       |
  134|       |#if defined(BOTAN_HAS_X942_PRF)
  135|       |   if(req.algo_name() == "X9.42-PRF" && req.arg_count() == 1) {
  136|       |      if(provider.empty() || provider == "base") {
  137|       |         return std::make_unique<X942_PRF>(req.arg(0));
  138|       |      }
  139|       |   }
  140|       |#endif
  141|       |
  142|       |#if defined(BOTAN_HAS_SP800_108)
  143|       |   if(req.algo_name() == "SP800-108-Counter" && req.arg_count_between(1, 3)) {
  144|       |      if(provider.empty() || provider == "base") {
  145|       |         return kdf_create_mac_or_hash<SP800_108_Counter>(
  146|       |            req.arg(0), req.arg_as_integer(1, 32), req.arg_as_integer(2, 32));
  147|       |      }
  148|       |   }
  149|       |
  150|       |   if(req.algo_name() == "SP800-108-Feedback" && req.arg_count_between(1, 3)) {
  151|       |      if(provider.empty() || provider == "base") {
  152|       |         return kdf_create_mac_or_hash<SP800_108_Feedback>(
  153|       |            req.arg(0), req.arg_as_integer(1, 32), req.arg_as_integer(2, 32));
  154|       |      }
  155|       |   }
  156|       |
  157|       |   if(req.algo_name() == "SP800-108-Pipeline" && req.arg_count_between(1, 3)) {
  158|       |      if(provider.empty() || provider == "base") {
  159|       |         return kdf_create_mac_or_hash<SP800_108_Pipeline>(
  160|       |            req.arg(0), req.arg_as_integer(1, 32), req.arg_as_integer(2, 32));
  161|       |      }
  162|       |   }
  163|       |#endif
  164|       |
  165|      0|#if defined(BOTAN_HAS_SP800_56A)
  166|      0|   if(req.algo_name() == "SP800-56A" && req.arg_count() == 1) {
  ------------------
  |  Branch (166:7): [True: 0, False: 0]
  |  Branch (166:41): [True: 0, False: 0]
  ------------------
  167|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (167:10): [True: 0, False: 0]
  |  Branch (167:30): [True: 0, False: 0]
  ------------------
  168|      0|         if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (168:18): [True: 0, False: 0]
  ------------------
  169|      0|            return std::make_unique<SP800_56C_One_Step_Hash>(std::move(hash));
  170|      0|         }
  171|      0|         if(req.arg(0) == "KMAC-128") {
  ------------------
  |  Branch (171:13): [True: 0, False: 0]
  ------------------
  172|      0|            return std::make_unique<SP800_56C_One_Step_KMAC128>();
  173|      0|         }
  174|      0|         if(req.arg(0) == "KMAC-256") {
  ------------------
  |  Branch (174:13): [True: 0, False: 0]
  ------------------
  175|      0|            return std::make_unique<SP800_56C_One_Step_KMAC256>();
  176|      0|         }
  177|      0|         if(auto mac = MessageAuthenticationCode::create(req.arg(0))) {
  ------------------
  |  Branch (177:18): [True: 0, False: 0]
  ------------------
  178|      0|            return std::make_unique<SP800_56C_One_Step_HMAC>(std::move(mac));
  179|      0|         }
  180|      0|      }
  181|      0|   }
  182|      0|#endif
  183|       |
  184|       |#if defined(BOTAN_HAS_SP800_56C)
  185|       |   if(req.algo_name() == "SP800-56C" && req.arg_count() == 1) {
  186|       |      if(provider.empty() || provider == "base") {
  187|       |         std::unique_ptr<KDF> exp(kdf_create_mac_or_hash<SP800_108_Feedback>(req.arg(0), 32, 32));
  188|       |         if(exp) {
  189|       |            if(auto mac = MessageAuthenticationCode::create(fmt("HMAC({})", req.arg(0)))) {
  190|       |               return std::make_unique<SP800_56C_Two_Step>(std::move(mac), std::move(exp));
  191|       |            }
  192|       |
  193|       |            if(auto mac = MessageAuthenticationCode::create(req.arg(0))) {
  194|       |               return std::make_unique<SP800_56C_Two_Step>(std::move(mac), std::move(exp));
  195|       |            }
  196|       |         }
  197|       |      }
  198|       |   }
  199|       |#endif
  200|       |
  201|      0|   BOTAN_UNUSED(req);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  202|      0|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  203|       |
  204|      0|   return nullptr;
  205|      0|}
_ZN5Botan3KDF15create_or_throwENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  208|  6.79k|std::unique_ptr<KDF> KDF::create_or_throw(std::string_view algo, std::string_view provider) {
  209|  6.79k|   if(auto kdf = KDF::create(algo, provider)) {
  ------------------
  |  Branch (209:12): [True: 6.79k, False: 0]
  ------------------
  210|  6.79k|      return kdf;
  211|  6.79k|   }
  212|      0|   throw Lookup_Error("KDF", algo, provider);
  213|  6.79k|}
kdf.cpp:_ZN5Botan12_GLOBAL__N_122kdf_create_mac_or_hashINS_4HKDFEJEEENSt3__110unique_ptrINS_3KDFENS3_14default_deleteIS5_EEEENS3_17basic_string_viewIcNS3_11char_traitsIcEEEEDpOT0_:
   59|  6.79k|std::unique_ptr<KDF> kdf_create_mac_or_hash(std::string_view nm, ParamTs&&... params) {
   60|  6.79k|   if(auto mac = MessageAuthenticationCode::create(fmt("HMAC({})", nm))) {
  ------------------
  |  Branch (60:12): [True: 6.79k, False: 0]
  ------------------
   61|  6.79k|      return std::make_unique<KDF_Type>(std::move(mac), std::forward<ParamTs>(params)...);
   62|  6.79k|   }
   63|       |
   64|      0|   if(auto mac = MessageAuthenticationCode::create(nm)) {
  ------------------
  |  Branch (64:12): [True: 0, False: 0]
  ------------------
   65|      0|      return std::make_unique<KDF_Type>(std::move(mac), std::forward<ParamTs>(params)...);
   66|      0|   }
   67|       |
   68|      0|   return nullptr;
   69|      0|}

_ZN5Botan4CMAC8add_dataENSt3__14spanIKhLm18446744073709551615EEE:
   21|  12.8M|void CMAC::add_data(std::span<const uint8_t> input) {
   22|  12.8M|   assert_key_material_set();
   23|       |
   24|  12.8M|   const size_t bs = output_length();
   25|       |
   26|  12.8M|   const size_t initial_fill = std::min(m_buffer.size() - m_position, input.size());
   27|  12.8M|   copy_mem(m_buffer.data() + m_position, input.data(), initial_fill);
   28|       |
   29|  12.8M|   if(m_position + input.size() > bs) {
  ------------------
  |  Branch (29:7): [True: 1.40M, False: 11.4M]
  ------------------
   30|  1.40M|      xor_buf(m_state, m_buffer, bs);
   31|  1.40M|      m_cipher->encrypt(m_state);
   32|       |
   33|  1.40M|      BufferSlicer in(input);
   34|  1.40M|      in.skip(bs - m_position);
   35|  6.81M|      while(in.remaining() > bs) {
  ------------------
  |  Branch (35:13): [True: 5.41M, False: 1.40M]
  ------------------
   36|  5.41M|         xor_buf(m_state, in.take(bs), bs);
   37|  5.41M|         m_cipher->encrypt(m_state);
   38|  5.41M|      }
   39|       |
   40|  1.40M|      const auto remaining = in.take(in.remaining());
   41|  1.40M|      copy_mem(m_buffer.data(), remaining.data(), remaining.size());
   42|  1.40M|      m_position = remaining.size();
   43|  11.4M|   } else {
   44|  11.4M|      m_position += input.size();
   45|  11.4M|   }
   46|  12.8M|}
_ZN5Botan4CMAC12final_resultENSt3__14spanIhLm18446744073709551615EEE:
   51|   962k|void CMAC::final_result(std::span<uint8_t> mac) {
   52|   962k|   xor_buf(m_state, m_buffer, m_position);
   53|       |
   54|   962k|   if(m_position == output_length()) {
  ------------------
  |  Branch (54:7): [True: 478k, False: 484k]
  ------------------
   55|   478k|      xor_buf(m_state, m_B, output_length());
   56|   484k|   } else {
   57|   484k|      m_state[m_position] ^= 0x80;
   58|   484k|      xor_buf(m_state, m_P, output_length());
   59|   484k|   }
   60|       |
   61|   962k|   m_cipher->encrypt(m_state);
   62|       |
   63|   962k|   copy_mem(mac.data(), m_state.data(), output_length());
   64|       |
   65|   962k|   zeroise(m_state);
   66|   962k|   zeroise(m_buffer);
   67|   962k|   m_position = 0;
   68|   962k|}
_ZNK5Botan4CMAC19has_keying_materialEv:
   81|  12.8M|bool CMAC::has_keying_material() const {
   82|  12.8M|   return m_cipher->has_keying_material();
   83|  12.8M|}
_ZN5Botan4CMAC12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
   88|  4.86k|void CMAC::key_schedule(std::span<const uint8_t> key) {
   89|  4.86k|   clear();
   90|  4.86k|   m_cipher->set_key(key);
   91|  4.86k|   m_cipher->encrypt(m_B);
   92|  4.86k|   poly_double_n(m_B.data(), m_B.size());
   93|  4.86k|   poly_double_n(m_P.data(), m_B.data(), m_P.size());
   94|  4.86k|}
_ZN5Botan4CMAC5clearEv:
   99|  4.86k|void CMAC::clear() {
  100|  4.86k|   m_cipher->clear();
  101|  4.86k|   zeroise(m_state);
  102|  4.86k|   zeroise(m_buffer);
  103|  4.86k|   zeroise(m_B);
  104|  4.86k|   zeroise(m_P);
  105|  4.86k|   m_position = 0;
  106|  4.86k|}
_ZN5Botan4CMACC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEE:
  125|  4.86k|CMAC::CMAC(std::unique_ptr<BlockCipher> cipher) : m_cipher(std::move(cipher)), m_block_size(m_cipher->block_size()) {
  126|  4.86k|   if(!poly_double_supported_size(m_block_size)) {
  ------------------
  |  Branch (126:7): [True: 0, False: 4.86k]
  ------------------
  127|      0|      throw Invalid_Argument(fmt("CMAC cannot use the {} bit cipher {}", m_block_size * 8, m_cipher->name()));
  128|      0|   }
  129|       |
  130|  4.86k|   m_state.resize(output_length());
  131|  4.86k|   m_buffer.resize(output_length());
  132|  4.86k|   m_B.resize(output_length());
  133|  4.86k|   m_P.resize(output_length());
  134|  4.86k|   m_position = 0;
  135|  4.86k|}

_ZN5Botan4HMAC8add_dataENSt3__14spanIKhLm18446744073709551615EEE:
   21|  1.49M|void HMAC::add_data(std::span<const uint8_t> input) {
   22|  1.49M|   assert_key_material_set();
   23|  1.49M|   m_hash->update(input);
   24|  1.49M|}
_ZN5Botan4HMAC12final_resultENSt3__14spanIhLm18446744073709551615EEE:
   29|  1.16M|void HMAC::final_result(std::span<uint8_t> mac) {
   30|  1.16M|   assert_key_material_set();
   31|  1.16M|   m_hash->final(mac);
   32|  1.16M|   m_hash->update(m_okey);
   33|  1.16M|   m_hash->update(mac.first(m_hash_output_length));
   34|  1.16M|   m_hash->final(mac);
   35|  1.16M|   m_hash->update(m_ikey);
   36|  1.16M|}
_ZNK5Botan4HMAC8key_specEv:
   48|   187k|Key_Length_Specification HMAC::key_spec() const {
   49|       |   // Support very long lengths for things like PBKDF2 and the TLS PRF
   50|   187k|   return Key_Length_Specification(0, 8192);
   51|   187k|}
_ZNK5Botan4HMAC13output_lengthEv:
   53|  1.21M|size_t HMAC::output_length() const {
   54|  1.21M|   return m_hash_output_length;
   55|  1.21M|}
_ZNK5Botan4HMAC19has_keying_materialEv:
   57|  2.66M|bool HMAC::has_keying_material() const {
   58|  2.66M|   return !m_okey.empty();
   59|  2.66M|}
_ZN5Botan4HMAC12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
   64|   187k|void HMAC::key_schedule(std::span<const uint8_t> key) {
   65|   187k|   const uint8_t ipad = 0x36;
   66|   187k|   const uint8_t opad = 0x5C;
   67|       |
   68|   187k|   m_hash->clear();
   69|       |
   70|   187k|   m_ikey.resize(m_hash_block_size);
   71|   187k|   m_okey.resize(m_hash_block_size);
   72|       |
   73|   187k|   clear_mem(m_ikey.data(), m_ikey.size());
   74|   187k|   clear_mem(m_okey.data(), m_okey.size());
   75|       |
   76|       |   /*
   77|       |   * Sometimes the HMAC key length itself is sensitive, as with PBKDF2 where it
   78|       |   * reveals the length of the passphrase. Make some attempt to hide this to
   79|       |   * side channels. Clearly if the secret is longer than the block size then the
   80|       |   * branch to hash first reveals that. In addition, counting the number of
   81|       |   * compression functions executed reveals the size at the granularity of the
   82|       |   * hash function's block size.
   83|       |   *
   84|       |   * The greater concern is for smaller keys; being able to detect when a
   85|       |   * passphrase is say 4 bytes may assist choosing weaker targets. Even though
   86|       |   * the loop bounds are constant, we can only actually read key[0..length] so
   87|       |   * it doesn't seem possible to make this computation truly constant time.
   88|       |   *
   89|       |   * We don't mind leaking if the length is exactly zero since that's
   90|       |   * trivial to simply check.
   91|       |   */
   92|       |
   93|   187k|   if(key.size() > m_hash_block_size) {
  ------------------
  |  Branch (93:7): [True: 0, False: 187k]
  ------------------
   94|      0|      m_hash->update(key);
   95|      0|      m_hash->final(m_ikey.data());
   96|   187k|   } else if(key.size() >= 20) {
  ------------------
  |  Branch (96:14): [True: 187k, False: 0]
  ------------------
   97|       |      // For long keys we just leak the length either it is a cryptovariable
   98|       |      // or a long enough password that just the length is not a useful signal
   99|   187k|      copy_mem(std::span{m_ikey}.first(key.size()), key);
  100|   187k|   } else if(!key.empty()) {
  ------------------
  |  Branch (100:14): [True: 0, False: 0]
  ------------------
  101|      0|      for(size_t i = 0, i_mod_length = 0; i != m_hash_block_size; ++i) {
  ------------------
  |  Branch (101:43): [True: 0, False: 0]
  ------------------
  102|       |         /*
  103|       |         access key[i % length] but avoiding division due to variable
  104|       |         time computation on some processors.
  105|       |         */
  106|      0|         auto needs_reduction = CT::Mask<size_t>::is_lte(key.size(), i_mod_length);
  107|      0|         i_mod_length = needs_reduction.select(0, i_mod_length);
  108|      0|         const uint8_t kb = key[i_mod_length];
  109|       |
  110|      0|         auto in_range = CT::Mask<size_t>::is_lt(i, key.size());
  111|      0|         m_ikey[i] = static_cast<uint8_t>(in_range.if_set_return(kb));
  112|      0|         i_mod_length += 1;
  113|      0|      }
  114|      0|   }
  115|       |
  116|  23.2M|   for(size_t i = 0; i != m_hash_block_size; ++i) {
  ------------------
  |  Branch (116:22): [True: 23.0M, False: 187k]
  ------------------
  117|  23.0M|      m_ikey[i] ^= ipad;
  118|  23.0M|      m_okey[i] = m_ikey[i] ^ ipad ^ opad;
  119|  23.0M|   }
  120|       |
  121|   187k|   m_hash->update(m_ikey);
  122|   187k|}
_ZNK5Botan4HMAC10new_objectEv:
  143|  13.5k|std::unique_ptr<MessageAuthenticationCode> HMAC::new_object() const {
  144|  13.5k|   return std::make_unique<HMAC>(m_hash->new_object());
  145|  13.5k|}
_ZN5Botan4HMACC2ENSt3__110unique_ptrINS_12HashFunctionENS1_14default_deleteIS3_EEEE:
  151|  33.1k|      m_hash(std::move(hash)),
  152|  33.1k|      m_hash_output_length(m_hash->output_length()),
  153|  33.1k|      m_hash_block_size(m_hash->hash_block_size()) {
  154|  33.1k|   BOTAN_ARG_CHECK(m_hash_output_length >= 8, "HMAC is not compatible with this hash function");
  ------------------
  |  |   35|  33.1k|   do {                                                          \
  |  |   36|  33.1k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  33.1k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 33.1k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  33.1k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 33.1k]
  |  |  ------------------
  ------------------
  155|  33.1k|   BOTAN_ARG_CHECK(m_hash_block_size >= m_hash_output_length, "HMAC is not compatible with this hash function");
  ------------------
  |  |   35|  33.1k|   do {                                                          \
  |  |   36|  33.1k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  33.1k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 33.1k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  33.1k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 33.1k]
  |  |  ------------------
  ------------------
  156|  33.1k|}

_ZN5Botan25MessageAuthenticationCode6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
   51|  19.5k|                                                                             std::string_view provider) {
   52|  19.5k|   const SCAN_Name req(algo_spec);
   53|       |
   54|       |#if defined(BOTAN_HAS_BLAKE2BMAC)
   55|       |   if(req.algo_name() == "Blake2b" || req.algo_name() == "BLAKE2b") {
   56|       |      if(provider.empty() || provider == "base") {
   57|       |         return std::make_unique<BLAKE2bMAC>(req.arg_as_integer(0, 512));
   58|       |      }
   59|       |   }
   60|       |#endif
   61|       |
   62|       |#if defined(BOTAN_HAS_GMAC)
   63|       |   if(req.algo_name() == "GMAC" && req.arg_count() == 1) {
   64|       |      if(provider.empty() || provider == "base") {
   65|       |         if(auto bc = BlockCipher::create(req.arg(0))) {
   66|       |            return std::make_unique<GMAC>(std::move(bc));
   67|       |         }
   68|       |      }
   69|       |   }
   70|       |#endif
   71|       |
   72|  19.5k|#if defined(BOTAN_HAS_HMAC)
   73|  19.5k|   if(req.algo_name() == "HMAC" && req.arg_count() == 1) {
  ------------------
  |  Branch (73:7): [True: 19.5k, False: 0]
  |  Branch (73:36): [True: 19.5k, False: 0]
  ------------------
   74|  19.5k|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (74:10): [True: 19.5k, False: 0]
  |  Branch (74:30): [True: 0, False: 0]
  ------------------
   75|  19.5k|         if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (75:18): [True: 19.5k, False: 0]
  ------------------
   76|  19.5k|            return std::make_unique<HMAC>(std::move(hash));
   77|  19.5k|         }
   78|  19.5k|      }
   79|  19.5k|   }
   80|      0|#endif
   81|       |
   82|       |#if defined(BOTAN_HAS_POLY1305)
   83|       |   if(req.algo_name() == "Poly1305" && req.arg_count() == 0) {
   84|       |      if(provider.empty() || provider == "base") {
   85|       |         return std::make_unique<Poly1305>();
   86|       |      }
   87|       |   }
   88|       |#endif
   89|       |
   90|       |#if defined(BOTAN_HAS_SIPHASH)
   91|       |   if(req.algo_name() == "SipHash") {
   92|       |      if(provider.empty() || provider == "base") {
   93|       |         return std::make_unique<SipHash>(req.arg_as_integer(0, 2), req.arg_as_integer(1, 4));
   94|       |      }
   95|       |   }
   96|       |#endif
   97|       |
   98|      0|#if defined(BOTAN_HAS_CMAC)
   99|      0|   if((req.algo_name() == "CMAC" || req.algo_name() == "OMAC") && req.arg_count() == 1) {
  ------------------
  |  Branch (99:8): [True: 0, False: 0]
  |  Branch (99:37): [True: 0, False: 0]
  |  Branch (99:67): [True: 0, False: 0]
  ------------------
  100|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (100:10): [True: 0, False: 0]
  |  Branch (100:30): [True: 0, False: 0]
  ------------------
  101|      0|         if(auto bc = BlockCipher::create(req.arg(0))) {
  ------------------
  |  Branch (101:18): [True: 0, False: 0]
  ------------------
  102|      0|            return std::make_unique<CMAC>(std::move(bc));
  103|      0|         }
  104|      0|      }
  105|      0|   }
  106|      0|#endif
  107|       |
  108|       |#if defined(BOTAN_HAS_ANSI_X919_MAC)
  109|       |   if(req.algo_name() == "X9.19-MAC") {
  110|       |      if(provider.empty() || provider == "base") {
  111|       |         return std::make_unique<ANSI_X919_MAC>();
  112|       |      }
  113|       |   }
  114|       |#endif
  115|       |
  116|      0|#if defined(BOTAN_HAS_KMAC)
  117|      0|   if(req.algo_name() == "KMAC-128") {
  ------------------
  |  Branch (117:7): [True: 0, False: 0]
  ------------------
  118|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (118:10): [True: 0, False: 0]
  |  Branch (118:30): [True: 0, False: 0]
  ------------------
  119|      0|         if(req.arg_count() != 1) {
  ------------------
  |  Branch (119:13): [True: 0, False: 0]
  ------------------
  120|      0|            throw Invalid_Argument(
  121|      0|               "invalid algorithm specification for KMAC-128: need exactly one argument for output bit length");
  122|      0|         }
  123|      0|         return std::make_unique<KMAC128>(req.arg_as_integer(0));
  124|      0|      }
  125|      0|   }
  126|       |
  127|      0|   if(req.algo_name() == "KMAC-256") {
  ------------------
  |  Branch (127:7): [True: 0, False: 0]
  ------------------
  128|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (128:10): [True: 0, False: 0]
  |  Branch (128:30): [True: 0, False: 0]
  ------------------
  129|      0|         if(req.arg_count() != 1) {
  ------------------
  |  Branch (129:13): [True: 0, False: 0]
  ------------------
  130|      0|            throw Invalid_Argument(
  131|      0|               "invalid algorithm specification for KMAC-256: need exactly one argument for output bit length");
  132|      0|         }
  133|      0|         return std::make_unique<KMAC256>(req.arg_as_integer(0));
  134|      0|      }
  135|      0|   }
  136|      0|#endif
  137|       |
  138|      0|   BOTAN_UNUSED(req);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  139|      0|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  140|       |
  141|      0|   return nullptr;
  142|      0|}

_ZN5Botan6BigInt17from_radix_digitsENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEm:
  125|     18|BigInt BigInt::from_radix_digits(std::string_view digits, size_t radix) {
  126|     18|   if(radix == 16) {
  ------------------
  |  Branch (126:7): [True: 18, False: 0]
  ------------------
  127|     18|      secure_vector<uint8_t> binary;
  128|       |
  129|     18|      if(digits.size() % 2 == 1) {
  ------------------
  |  Branch (129:10): [True: 2, False: 16]
  ------------------
  130|       |         // Handle lack of leading 0
  131|      2|         const char buf0_with_leading_0[2] = {'0', digits[0]};
  132|       |
  133|      2|         binary = hex_decode_locked(buf0_with_leading_0, 2);
  134|       |
  135|      2|         if(digits.size() > 1) {
  ------------------
  |  Branch (135:13): [True: 0, False: 2]
  ------------------
  136|      0|            binary += hex_decode_locked(&digits[1], digits.size() - 1, false);
  137|      0|         }
  138|     16|      } else {
  139|     16|         binary = hex_decode_locked(digits, false);
  140|     16|      }
  141|       |
  142|     18|      return BigInt::from_bytes(binary);
  143|     18|   } else if(radix == 10) {
  ------------------
  |  Branch (143:14): [True: 0, False: 0]
  ------------------
  144|       |      // Use the largest power of 10 that fits in a word, accumulating
  145|       |      // groups of digits into word-sized chunks to minimize the number
  146|       |      // of multiprecision multiplications.
  147|      0|      constexpr word conversion_radix = decimal_conversion_radix();
  148|      0|      constexpr size_t radix_digits = decimal_conversion_radix_digits();
  149|       |
  150|      0|      BigInt r;
  151|       |
  152|       |      // Handle the initial partial block (if digit count is not a multiple of radix_digits)
  153|      0|      const size_t partial_block = digits.size() % radix_digits;
  154|       |
  155|      0|      if(partial_block > 0) {
  ------------------
  |  Branch (155:10): [True: 0, False: 0]
  ------------------
  156|      0|         word acc = 0;
  157|      0|         for(size_t i = 0; i < partial_block; ++i) {
  ------------------
  |  Branch (157:28): [True: 0, False: 0]
  ------------------
  158|      0|            const char c = digits[i];
  159|      0|            BOTAN_ARG_CHECK(c >= '0' && c <= '9', "Invalid decimal character");
  ------------------
  |  |   35|      0|   do {                                                          \
  |  |   36|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|      0|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 0, False: 0]
  |  |  |  Branch (37:12): [True: 0, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  160|      0|            acc = acc * 10 + static_cast<word>(c - '0');
  161|      0|         }
  162|      0|         r += acc;
  163|      0|      }
  164|       |
  165|       |      // Process full blocks of radix_digits
  166|      0|      for(size_t i = partial_block; i != digits.size(); i += radix_digits) {
  ------------------
  |  Branch (166:37): [True: 0, False: 0]
  ------------------
  167|      0|         word acc = 0;
  168|      0|         for(size_t j = 0; j < radix_digits; ++j) {
  ------------------
  |  Branch (168:28): [True: 0, False: 0]
  ------------------
  169|      0|            const char c = digits[i + j];
  170|      0|            BOTAN_ARG_CHECK(c >= '0' && c <= '9', "Invalid decimal character");
  ------------------
  |  |   35|      0|   do {                                                          \
  |  |   36|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|      0|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 0, False: 0]
  |  |  |  Branch (37:12): [True: 0, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  171|      0|            acc = acc * 10 + static_cast<word>(c - '0');
  172|      0|         }
  173|      0|         r *= conversion_radix;
  174|      0|         r += acc;
  175|      0|      }
  176|       |
  177|      0|      return r;
  178|      0|   } else {
  179|      0|      throw Invalid_Argument("BigInt::from_radix_digits unknown radix");
  180|      0|   }
  181|     18|}

_ZN5Botan6BigIntmIERKS0_:
   23|  45.2k|BigInt& BigInt::operator-=(const BigInt& y) {
   24|  45.2k|   if(&y == this) {
  ------------------
  |  Branch (24:7): [True: 0, False: 45.2k]
  ------------------
   25|      0|      this->clear();
   26|      0|      this->set_sign(Positive);
   27|      0|      return *this;
   28|      0|   }
   29|  45.2k|   return sub(y._data(), y.sig_words(), y.sign());
   30|  45.2k|}
_ZN5Botan6BigInt3addEPKmmNS0_4SignE:
   32|  45.2k|BigInt& BigInt::add(const word y[], size_t y_words, Sign y_sign) {
   33|  45.2k|   const size_t x_sw = sig_words();
   34|       |
   35|  45.2k|   grow_to(std::max(x_sw, y_words) + 1);
   36|       |
   37|  45.2k|   if(sign() == y_sign) {
  ------------------
  |  Branch (37:7): [True: 0, False: 45.2k]
  ------------------
   38|      0|      const word carry = bigint_add2(mutable_data(), size() - 1, y, y_words);
   39|      0|      mutable_data()[size() - 1] += carry;
   40|  45.2k|   } else {
   41|  45.2k|      const int32_t relative_size = bigint_cmp(_data(), x_sw, y, y_words);
   42|       |
   43|  45.2k|      if(relative_size >= 0) {
  ------------------
  |  Branch (43:10): [True: 45.2k, False: 0]
  ------------------
   44|       |         // *this >= y
   45|  45.2k|         bigint_sub2(mutable_data(), x_sw, y, y_words);
   46|  45.2k|      } else {
   47|       |         // *this < y: compute *this = y - *this
   48|      0|         bigint_sub2_rev(mutable_data(), y, y_words);
   49|      0|      }
   50|       |
   51|  45.2k|      if(relative_size < 0) {
  ------------------
  |  Branch (51:10): [True: 0, False: 45.2k]
  ------------------
   52|      0|         set_sign(y_sign);
   53|  45.2k|      } else if(relative_size == 0) {
  ------------------
  |  Branch (53:17): [True: 0, False: 45.2k]
  ------------------
   54|      0|         set_sign(Positive);
   55|      0|      }
   56|  45.2k|   }
   57|       |
   58|  45.2k|   return (*this);
   59|  45.2k|}
_ZN5Botan6BigIntlSEm:
  269|  3.14k|BigInt& BigInt::operator<<=(size_t shift) {
  270|  3.14k|   if(shift >= 65536) {
  ------------------
  |  Branch (270:7): [True: 0, False: 3.14k]
  ------------------
  271|      0|      throw Invalid_Argument("BigInt left shift count too large");
  272|      0|   }
  273|       |
  274|  3.14k|   const size_t sw = sig_words();
  275|  3.14k|   const size_t new_size = sw + (shift + WordInfo<word>::bits - 1) / WordInfo<word>::bits;
  276|       |
  277|  3.14k|   m_data.grow_to(new_size);
  278|       |
  279|  3.14k|   bigint_shl1(m_data.mutable_data(), new_size, sw, shift);
  280|       |
  281|  3.14k|   return (*this);
  282|  3.14k|}
_ZN5Botan6BigIntrSEm:
  287|  45.8k|BigInt& BigInt::operator>>=(size_t shift) {
  288|  45.8k|   bigint_shr1(m_data.mutable_data(), m_data.size(), shift);
  289|       |
  290|  45.8k|   if(sig_words() == 0 && m_signedness == Negative) {
  ------------------
  |  Branch (290:7): [True: 0, False: 45.8k]
  |  Branch (290:27): [True: 0, False: 0]
  ------------------
  291|      0|      m_signedness = Positive;
  292|      0|   }
  293|       |
  294|  45.8k|   return (*this);
  295|  45.8k|}

_ZN5Botan6BigInt4add2ERKS0_PKmmNS0_4SignE:
   20|      9|BigInt BigInt::add2(const BigInt& x, const word y[], size_t y_size, BigInt::Sign y_sign) {
   21|      9|   const size_t x_sw = x.sig_words();
   22|       |
   23|      9|   BigInt z = BigInt::with_capacity(std::max(x_sw, y_size) + 1);
   24|       |
   25|      9|   if(x.sign() == y_sign) {
  ------------------
  |  Branch (25:7): [True: 6, False: 3]
  ------------------
   26|      6|      const word carry = bigint_add3(z.mutable_data(), x._data(), x_sw, y, y_size);
   27|      6|      z.mutable_data()[std::max(x_sw, y_size)] += carry;
   28|      6|      z.set_sign(x.sign());
   29|      6|   } else {
   30|      3|      const int32_t relative_size = bigint_cmp(x.data(), x_sw, y, y_size);
   31|       |
   32|      3|      if(relative_size < 0) {
  ------------------
  |  Branch (32:10): [True: 0, False: 3]
  ------------------
   33|       |         // x < y so z = abs(y - x)
   34|       |         // NOLINTNEXTLINE(*-suspicious-call-argument) intentionally swapping x and y here
   35|      0|         bigint_sub3(z.mutable_data(), y, y_size, x.data(), x_sw);
   36|      0|         z.set_sign(y_sign);
   37|      3|      } else if(relative_size == 0) {
  ------------------
  |  Branch (37:17): [True: 0, False: 3]
  ------------------
   38|       |         // Positive zero (nothing to do in this case)
   39|      3|      } else {
   40|       |         /*
   41|       |         * We know at this point that x >= y so if y_size is larger than
   42|       |         * x_sw, we are guaranteed they are just leading zeros which can
   43|       |         * be ignored
   44|       |         */
   45|      3|         y_size = std::min(x_sw, y_size);
   46|      3|         bigint_sub3(z.mutable_data(), x.data(), x_sw, y, y_size);
   47|      3|         z.set_sign(x.sign());
   48|      3|      }
   49|      3|   }
   50|       |
   51|      9|   return z;
   52|      9|}
_ZN5BotanmlERKNS_6BigIntEm:
   90|  43.2k|BigInt operator*(const BigInt& x, word y) {
   91|  43.2k|   const size_t x_sw = x.sig_words();
   92|       |
   93|  43.2k|   BigInt z = BigInt::with_capacity(x_sw + 1);
   94|       |
   95|  43.2k|   if(x_sw > 0 && y > 0) {
  ------------------
  |  Branch (95:7): [True: 43.2k, False: 0]
  |  Branch (95:19): [True: 43.2k, False: 0]
  ------------------
   96|  43.2k|      bigint_linmul3(z.mutable_data(), x._data(), x_sw, y);
   97|  43.2k|      z.set_sign(x.sign());
   98|  43.2k|   }
   99|       |
  100|  43.2k|   return z;
  101|  43.2k|}
_ZN5BotanrmERKNS_6BigIntES2_:
  134|  1.02k|BigInt operator%(const BigInt& n, const BigInt& mod) {
  135|  1.02k|   if(mod.is_zero()) {
  ------------------
  |  Branch (135:7): [True: 0, False: 1.02k]
  ------------------
  136|      0|      throw Invalid_Argument("BigInt::operator% divide by zero");
  137|      0|   }
  138|  1.02k|   if(mod.signum() < 0) {
  ------------------
  |  Branch (138:7): [True: 0, False: 1.02k]
  ------------------
  139|      0|      throw Invalid_Argument("BigInt::operator% modulus must be > 0");
  140|      0|   }
  141|  1.02k|   if(n.signum() >= 0 && mod.signum() >= 0 && n < mod) {
  ------------------
  |  Branch (141:7): [True: 1.02k, False: 0]
  |  Branch (141:26): [True: 1.02k, False: 0]
  |  Branch (141:47): [True: 0, False: 1.02k]
  ------------------
  142|      0|      return n;
  143|      0|   }
  144|       |
  145|  1.02k|   if(mod.sig_words() == 1) {
  ------------------
  |  Branch (145:7): [True: 0, False: 1.02k]
  ------------------
  146|      0|      return BigInt::from_word(n % mod.word_at(0));
  147|      0|   }
  148|       |
  149|  1.02k|   BigInt q;
  150|  1.02k|   BigInt r;
  151|  1.02k|   vartime_divide(n, mod, q, r);
  152|  1.02k|   return r;
  153|  1.02k|}
_ZN5BotanlsERKNS_6BigIntEm:
  188|  3.59k|BigInt operator<<(const BigInt& x, size_t shift) {
  189|  3.59k|   if(shift >= 65536) {
  ------------------
  |  Branch (189:7): [True: 0, False: 3.59k]
  ------------------
  190|      0|      throw Invalid_Argument("BigInt left shift count too large");
  191|      0|   }
  192|       |
  193|  3.59k|   if(x.is_zero()) {
  ------------------
  |  Branch (193:7): [True: 0, False: 3.59k]
  ------------------
  194|      0|      return BigInt::zero();
  195|      0|   }
  196|       |
  197|  3.59k|   const size_t x_sw = x.sig_words();
  198|       |
  199|  3.59k|   const size_t new_size = x_sw + shift / WordInfo<word>::bits + 1;
  200|  3.59k|   BigInt y = BigInt::with_capacity(new_size);
  201|  3.59k|   bigint_shl2(y.mutable_data(), new_size, x._data(), x_sw, shift);
  202|  3.59k|   y.set_sign(x.sign());
  203|  3.59k|   return y;
  204|  3.59k|}

_ZN5Botan6BigInt9randomizeERNS_21RandomNumberGeneratorEmb:
   19|     41|void BigInt::randomize(RandomNumberGenerator& rng, size_t bitsize, bool set_high_bit) {
   20|     41|   set_sign(Positive);
   21|       |
   22|     41|   if(bitsize == 0) {
  ------------------
  |  Branch (22:7): [True: 0, False: 41]
  ------------------
   23|      0|      clear();
   24|     41|   } else {
   25|     41|      secure_vector<uint8_t> array = rng.random_vec(round_up(bitsize, 8) / 8);
   26|       |
   27|       |      // Always cut unwanted bits
   28|     41|      if(bitsize % 8 > 0) {
  ------------------
  |  Branch (28:10): [True: 41, False: 0]
  ------------------
   29|     41|         array[0] &= 0xFF >> (8 - (bitsize % 8));
   30|     41|      }
   31|       |
   32|       |      // Set the highest bit if wanted
   33|     41|      if(set_high_bit) {
  ------------------
  |  Branch (33:10): [True: 0, False: 41]
  ------------------
   34|      0|         array[0] |= 0x80 >> ((bitsize % 8) > 0 ? (8 - bitsize % 8) : 0);
  ------------------
  |  Branch (34:31): [True: 0, False: 0]
  ------------------
   35|      0|      }
   36|       |
   37|     41|      assign_from_bytes(array);
   38|     41|   }
   39|     41|}

_ZN5Botan6BigIntC2Em:
   20|      3|BigInt::BigInt(uint64_t n) {
   21|      3|   if constexpr(sizeof(word) == 8) {
   22|      3|      m_data.set_word_at(0, static_cast<word>(n));
   23|       |   } else {
   24|       |      m_data.set_word_at(1, static_cast<word>(n >> 32));
   25|       |      m_data.set_word_at(0, static_cast<word>(n));
   26|       |   }
   27|      3|}
_ZN5Botan6BigInt13with_capacityEm:
   51|  46.8k|BigInt BigInt::with_capacity(size_t size) {
   52|  46.8k|   BigInt bn;
   53|  46.8k|   bn.grow_to(size);
   54|  46.8k|   return bn;
   55|  46.8k|}
_ZN5Botan6BigInt11from_stringENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   57|     18|BigInt BigInt::from_string(std::string_view str) {
   58|     18|   size_t prefix_bytes = 0;
   59|     18|   bool negative = false;
   60|     18|   size_t radix = 10;
   61|       |
   62|     18|   if(!str.empty() && str[0] == '-') {
  ------------------
  |  Branch (62:7): [True: 18, False: 0]
  |  Branch (62:23): [True: 0, False: 18]
  ------------------
   63|      0|      prefix_bytes += 1;
   64|      0|      negative = true;
   65|      0|   }
   66|       |
   67|     18|   if(str.length() > prefix_bytes + 2 && str[prefix_bytes] == '0' && str[prefix_bytes + 1] == 'x') {
  ------------------
  |  Branch (67:7): [True: 18, False: 0]
  |  Branch (67:42): [True: 18, False: 0]
  |  Branch (67:70): [True: 18, False: 0]
  ------------------
   68|     18|      prefix_bytes += 2;
   69|     18|      radix = 16;
   70|     18|   }
   71|       |
   72|     18|   BigInt r = BigInt::from_radix_digits(str.substr(prefix_bytes), radix);
   73|       |
   74|     18|   if(negative) {
  ------------------
  |  Branch (74:7): [True: 0, False: 18]
  ------------------
   75|      0|      r.set_sign(Negative);
   76|     18|   } else {
   77|     18|      r.set_sign(Positive);
   78|     18|   }
   79|       |
   80|     18|   return r;
   81|     18|}
_ZN5Botan6BigInt10from_bytesENSt3__14spanIKhLm18446744073709551615EEE:
   83|  13.5k|BigInt BigInt::from_bytes(std::span<const uint8_t> input) {
   84|  13.5k|   BigInt r;
   85|  13.5k|   r.assign_from_bytes(input);
   86|  13.5k|   return r;
   87|  13.5k|}
_ZN5Botan6BigInt24from_bytes_with_max_bitsEPKhmm:
   97|  1.02k|BigInt BigInt::from_bytes_with_max_bits(const uint8_t input[], size_t length, size_t max_bits) {
   98|  1.02k|   const size_t input_bits = 8 * length;
   99|       |
  100|  1.02k|   auto bn = BigInt::from_bytes(std::span{input, length});
  101|       |
  102|  1.02k|   if(input_bits > max_bits) {
  ------------------
  |  Branch (102:7): [True: 0, False: 1.02k]
  ------------------
  103|      0|      const size_t bits_to_shift = input_bits - max_bits;
  104|       |
  105|      0|      bn >>= bits_to_shift;
  106|      0|   }
  107|       |
  108|  1.02k|   return bn;
  109|  1.02k|}
_ZN5Botan6BigIntC2ERNS_21RandomNumberGeneratorEmb:
  114|     41|BigInt::BigInt(RandomNumberGenerator& rng, size_t bits, bool set_high_bit) {
  115|     41|   randomize(rng, bits, set_high_bit);
  116|     41|}
_ZNK5Botan6BigInt8cmp_wordEm:
  122|  20.8k|int32_t BigInt::cmp_word(word other) const {
  123|  20.8k|   if(signum() < 0) {
  ------------------
  |  Branch (123:7): [True: 0, False: 20.8k]
  ------------------
  124|      0|      return -1;  // other is positive ...
  125|      0|   }
  126|       |
  127|  20.8k|   const size_t sw = this->sig_words();
  128|  20.8k|   if(sw > 1) {
  ------------------
  |  Branch (128:7): [True: 20.4k, False: 393]
  ------------------
  129|  20.4k|      return 1;  // must be larger since other is just one word ...
  130|  20.4k|   }
  131|       |
  132|    393|   return bigint_cmp(this->_data(), sw, &other, 1);
  133|  20.8k|}
_ZNK5Botan6BigInt3cmpERKS0_b:
  138|  30.1k|int32_t BigInt::cmp(const BigInt& other, bool check_signs) const {
  139|  30.1k|   if(check_signs) {
  ------------------
  |  Branch (139:7): [True: 30.1k, False: 0]
  ------------------
  140|  30.1k|      if(other.signum() >= 0 && this->signum() < 0) {
  ------------------
  |  Branch (140:10): [True: 30.1k, False: 0]
  |  Branch (140:33): [True: 0, False: 30.1k]
  ------------------
  141|      0|         return -1;
  142|      0|      }
  143|       |
  144|  30.1k|      if(other.signum() < 0 && this->signum() >= 0) {
  ------------------
  |  Branch (144:10): [True: 0, False: 30.1k]
  |  Branch (144:32): [True: 0, False: 0]
  ------------------
  145|      0|         return 1;
  146|      0|      }
  147|       |
  148|  30.1k|      if(other.signum() < 0 && this->signum() < 0) {
  ------------------
  |  Branch (148:10): [True: 0, False: 30.1k]
  |  Branch (148:32): [True: 0, False: 0]
  ------------------
  149|      0|         return (-bigint_cmp(this->_data(), this->size(), other._data(), other.size()));
  150|      0|      }
  151|  30.1k|   }
  152|       |
  153|  30.1k|   return bigint_cmp(this->_data(), this->size(), other._data(), other.size());
  154|  30.1k|}
_ZNK5Botan6BigInt8is_equalERKS0_:
  156|  1.03k|bool BigInt::is_equal(const BigInt& other) const {
  157|  1.03k|   if(this->sign() != other.sign()) {
  ------------------
  |  Branch (157:7): [True: 0, False: 1.03k]
  ------------------
  158|      0|      return false;
  159|      0|   }
  160|       |
  161|  1.03k|   return bigint_ct_is_eq(this->_data(), this->size(), other._data(), other.size()).as_bool();
  162|  1.03k|}
_ZNK5Botan6BigInt12is_less_thanERKS0_:
  164|  11.7k|bool BigInt::is_less_than(const BigInt& other) const {
  165|  11.7k|   if(this->signum() < 0 && other.signum() >= 0) {
  ------------------
  |  Branch (165:7): [True: 0, False: 11.7k]
  |  Branch (165:29): [True: 0, False: 0]
  ------------------
  166|      0|      return true;
  167|      0|   }
  168|       |
  169|  11.7k|   if(this->signum() >= 0 && other.signum() < 0) {
  ------------------
  |  Branch (169:7): [True: 11.7k, False: 0]
  |  Branch (169:30): [True: 0, False: 11.7k]
  ------------------
  170|      0|      return false;
  171|      0|   }
  172|       |
  173|  11.7k|   if(other.signum() < 0 && this->signum() < 0) {
  ------------------
  |  Branch (173:7): [True: 0, False: 11.7k]
  |  Branch (173:29): [True: 0, False: 0]
  ------------------
  174|      0|      return bigint_ct_is_lt(other._data(), other.size(), this->_data(), this->size()).as_bool();
  175|      0|   }
  176|       |
  177|  11.7k|   return bigint_ct_is_lt(this->_data(), this->size(), other._data(), other.size()).as_bool();
  178|  11.7k|}
_ZN5Botan6BigInt4Data11set_to_zeroEv:
  191|  34.0k|void BigInt::Data::set_to_zero() {
  192|  34.0k|   m_reg.resize(m_reg.capacity());
  193|  34.0k|   clear_mem(m_reg.data(), m_reg.size());
  194|  34.0k|   m_sig_words = 0;
  195|  34.0k|}
_ZNK5Botan6BigInt4Data14calc_sig_wordsEv:
  215|   189k|size_t BigInt::Data::calc_sig_words() const {
  216|   189k|   const size_t sz = m_reg.size();
  217|   189k|   size_t sig = sz;
  218|       |
  219|   189k|   word sub = 1;
  220|       |
  221|  5.31M|   for(size_t i = 0; i != sz; ++i) {
  ------------------
  |  Branch (221:22): [True: 5.12M, False: 189k]
  ------------------
  222|  5.12M|      const word w = m_reg[sz - i - 1];
  223|  5.12M|      sub &= ct_is_zero(w);
  224|  5.12M|      sig -= sub;
  225|  5.12M|   }
  226|       |
  227|       |   /*
  228|       |   * This depends on the data so is poisoned, but unpoison it here as
  229|       |   * later conditionals are made on the size.
  230|       |   */
  231|   189k|   CT::unpoison(sig);
  232|       |
  233|   189k|   return sig;
  234|   189k|}
_ZNK5Botan6BigInt13get_substringEmm:
  239|   190k|uint32_t BigInt::get_substring(size_t offset, size_t length) const {
  240|   190k|   if(length == 0 || length > 32) {
  ------------------
  |  Branch (240:7): [True: 0, False: 190k]
  |  Branch (240:22): [True: 0, False: 190k]
  ------------------
  241|      0|      throw Invalid_Argument("BigInt::get_substring invalid substring length");
  242|      0|   }
  243|       |
  244|   190k|   const uint32_t mask = 0xFFFFFFFF >> (32 - length);
  245|       |
  246|   190k|   const size_t word_offset = offset / WordInfo<word>::bits;
  247|   190k|   const size_t wshift = (offset % WordInfo<word>::bits);
  248|       |
  249|       |   /*
  250|       |   * The substring is contained within one or at most two words. The
  251|       |   * offset and length are not secret, so we can perform conditional
  252|       |   * operations on those values.
  253|       |   */
  254|   190k|   const word w0 = word_at(word_offset);
  255|       |
  256|   190k|   if(wshift == 0 || (offset + length) / WordInfo<word>::bits == word_offset) {
  ------------------
  |  Branch (256:7): [True: 7.80k, False: 182k]
  |  Branch (256:22): [True: 177k, False: 5.42k]
  ------------------
  257|   184k|      return static_cast<uint32_t>(w0 >> wshift) & mask;
  258|   184k|   } else {
  259|  5.42k|      const word w1 = word_at(word_offset + 1);
  260|  5.42k|      return static_cast<uint32_t>((w0 >> wshift) | (w1 << (WordInfo<word>::bits - wshift))) & mask;
  261|  5.42k|   }
  262|   190k|}
_ZNK5Botan6BigInt5bytesEv:
  294|  14.7k|size_t BigInt::bytes() const {
  295|  14.7k|   return round_up(bits(), 8) / 8;
  296|  14.7k|}
_ZNK5Botan6BigInt13top_bits_freeEv:
  298|  32.3k|size_t BigInt::top_bits_free() const {
  299|  32.3k|   const size_t words = sig_words();
  300|       |
  301|  32.3k|   const word top_word = word_at(words - 1);
  302|  32.3k|   const size_t bits_used = high_bit(CT::value_barrier(top_word));
  303|  32.3k|   CT::unpoison(bits_used);
  304|  32.3k|   return WordInfo<word>::bits - bits_used;
  305|  32.3k|}
_ZNK5Botan6BigInt4bitsEv:
  307|  28.7k|size_t BigInt::bits() const {
  308|  28.7k|   const size_t words = sig_words();
  309|       |
  310|  28.7k|   if(words == 0) {
  ------------------
  |  Branch (310:7): [True: 0, False: 28.7k]
  ------------------
  311|      0|      return 0;
  312|      0|   }
  313|       |
  314|  28.7k|   const size_t full_words = (words - 1) * WordInfo<word>::bits;
  315|  28.7k|   const size_t top_bits = WordInfo<word>::bits - top_bits_free();
  316|       |
  317|  28.7k|   return full_words + top_bits;
  318|  28.7k|}
_ZN5Botan6BigInt12reduce_belowERKS0_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
  329|  3.59k|size_t BigInt::reduce_below(const BigInt& p, secure_vector<word>& ws) {
  330|  3.59k|   if(p.signum() < 0 || this->signum() < 0) {
  ------------------
  |  Branch (330:7): [True: 0, False: 3.59k]
  |  Branch (330:25): [True: 0, False: 3.59k]
  ------------------
  331|      0|      throw Invalid_Argument("BigInt::reduce_below both values must be positive");
  332|      0|   }
  333|       |
  334|  3.59k|   const size_t p_words = p.sig_words();
  335|       |
  336|  3.59k|   if(size() < p_words + 1) {
  ------------------
  |  Branch (336:7): [True: 0, False: 3.59k]
  ------------------
  337|      0|      grow_to(p_words + 1);
  338|      0|   }
  339|       |
  340|  3.59k|   if(ws.size() < p_words + 1) {
  ------------------
  |  Branch (340:7): [True: 3.59k, False: 0]
  ------------------
  341|  3.59k|      ws.resize(p_words + 1);
  342|  3.59k|   }
  343|       |
  344|  3.59k|   clear_mem(ws.data(), ws.size());
  345|       |
  346|  3.59k|   size_t reductions = 0;
  347|       |
  348|  3.59k|   for(;;) {
  349|  3.59k|      const word borrow = bigint_sub3(ws.data(), _data(), p_words + 1, p._data(), p_words);
  350|  3.59k|      if(borrow > 0) {
  ------------------
  |  Branch (350:10): [True: 3.59k, False: 0]
  ------------------
  351|  3.59k|         break;
  352|  3.59k|      }
  353|       |
  354|      0|      ++reductions;
  355|      0|      swap_reg(ws);
  356|      0|   }
  357|       |
  358|  3.59k|   return reductions;
  359|  3.59k|}
_ZNK5Botan6BigInt12serialize_toENSt3__14spanIhLm18446744073709551615EEE:
  395|  12.9k|void BigInt::serialize_to(std::span<uint8_t> output) const {
  396|  12.9k|   BOTAN_ARG_CHECK(this->bytes() <= output.size(), "Insufficient output space");
  ------------------
  |  |   35|  12.9k|   do {                                                          \
  |  |   36|  12.9k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  12.9k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 12.9k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  12.9k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 12.9k]
  |  |  ------------------
  ------------------
  397|       |
  398|  12.9k|   this->binary_encode(output.data(), output.size());
  399|  12.9k|}
_ZNK5Botan6BigInt13binary_encodeEPhm:
  404|  12.9k|void BigInt::binary_encode(uint8_t output[], size_t len) const {
  405|  12.9k|   const size_t full_words = len / sizeof(word);
  406|  12.9k|   const size_t extra_bytes = len % sizeof(word);
  407|       |
  408|  70.6k|   for(size_t i = 0; i != full_words; ++i) {
  ------------------
  |  Branch (408:22): [True: 57.6k, False: 12.9k]
  ------------------
  409|  57.6k|      const word w = word_at(i);
  410|  57.6k|      store_be(w, output + (len - (i + 1) * sizeof(word)));
  411|  57.6k|   }
  412|       |
  413|  12.9k|   if(extra_bytes > 0) {
  ------------------
  |  Branch (413:7): [True: 43, False: 12.9k]
  ------------------
  414|     43|      const word w = word_at(full_words);
  415|       |
  416|    343|      for(size_t i = 0; i != extra_bytes; ++i) {
  ------------------
  |  Branch (416:25): [True: 300, False: 43]
  ------------------
  417|    300|         output[extra_bytes - i - 1] = get_byte_var(sizeof(word) - i - 1, w);
  418|    300|      }
  419|     43|   }
  420|  12.9k|}
_ZN5Botan6BigInt17assign_from_bytesENSt3__14spanIKhLm18446744073709551615EEE:
  425|  34.0k|void BigInt::assign_from_bytes(std::span<const uint8_t> bytes) {
  426|  34.0k|   clear();
  427|       |
  428|  34.0k|   const size_t length = bytes.size();
  429|  34.0k|   const size_t full_words = length / sizeof(word);
  430|  34.0k|   const size_t extra_bytes = length % sizeof(word);
  431|       |
  432|  34.0k|   secure_vector<word> reg((round_up(full_words + (extra_bytes > 0 ? 1 : 0), 8)));
  ------------------
  |  Branch (432:52): [True: 4.87k, False: 29.1k]
  ------------------
  433|       |
  434|   210k|   for(size_t i = 0; i != full_words; ++i) {
  ------------------
  |  Branch (434:22): [True: 176k, False: 34.0k]
  ------------------
  435|   176k|      reg[i] = load_be<word>(bytes.last<sizeof(word)>());
  436|   176k|      bytes = bytes.first(bytes.size() - sizeof(word));
  437|   176k|   }
  438|       |
  439|  34.0k|   if(!bytes.empty()) {
  ------------------
  |  Branch (439:7): [True: 4.87k, False: 29.1k]
  ------------------
  440|  4.87k|      BOTAN_ASSERT_NOMSG(extra_bytes == bytes.size());
  ------------------
  |  |   77|  4.87k|   do {                                                                     \
  |  |   78|  4.87k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  4.87k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 4.87k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  4.87k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 4.87k]
  |  |  ------------------
  ------------------
  441|  4.87k|      std::array<uint8_t, sizeof(word)> last_partial_word = {0};
  442|  4.87k|      copy_mem(std::span{last_partial_word}.last(extra_bytes), bytes);
  443|  4.87k|      reg[full_words] = load_be<word>(last_partial_word);
  444|  4.87k|   }
  445|       |
  446|  34.0k|   m_data.swap(reg);
  447|  34.0k|}
_ZN5Botan6BigInt14cond_flip_signEb:
  521|  1.02k|void BigInt::cond_flip_sign(bool predicate) {
  522|       |   // This code is assuming Negative == 0, Positive == 1
  523|       |
  524|  1.02k|   const auto mask = CT::Mask<uint8_t>::expand_bool(predicate);
  525|       |
  526|  1.02k|   const uint8_t current_sign = static_cast<uint8_t>(sign());
  527|       |
  528|  1.02k|   const uint8_t new_sign = mask.select(current_sign ^ 1, current_sign);
  529|       |
  530|  1.02k|   set_sign(static_cast<Sign>(new_sign));
  531|  1.02k|}
_ZNK5Botan6BigInt20_const_time_unpoisonEv:
  559|   161k|void BigInt::_const_time_unpoison() const {
  560|   161k|   CT::unpoison(m_data.const_data(), m_data.size());
  561|   161k|}

_ZN5Botan20vartime_divide_pow2kEmRKNS_6BigIntE:
  232|  2.57k|BigInt vartime_divide_pow2k(size_t k, const BigInt& y_arg) {
  233|  2.57k|   constexpr size_t WB = WordInfo<word>::bits;
  234|       |
  235|  2.57k|   BOTAN_ARG_CHECK(y_arg.signum() != 0, "Cannot divide by zero");
  ------------------
  |  |   35|  2.57k|   do {                                                          \
  |  |   36|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.57k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  236|  2.57k|   BOTAN_ARG_CHECK(y_arg.signum() >= 0, "Negative divisor not supported");
  ------------------
  |  |   35|  2.57k|   do {                                                          \
  |  |   36|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.57k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  237|  2.57k|   BOTAN_ARG_CHECK(k > 1, "Invalid k");
  ------------------
  |  |   35|  2.57k|   do {                                                          \
  |  |   36|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.57k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  238|       |
  239|  2.57k|   BigInt y = y_arg;
  240|       |
  241|  2.57k|   const size_t y_words = y.sig_words();
  242|       |
  243|  2.57k|   BOTAN_ASSERT_NOMSG(y_words > 0);
  ------------------
  |  |   77|  2.57k|   do {                                                                     \
  |  |   78|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.57k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  244|       |
  245|       |   // Calculate shifts needed to normalize y with high bit set
  246|  2.57k|   const size_t shifts = y.top_bits_free();
  247|       |
  248|  2.57k|   if(shifts > 0) {
  ------------------
  |  Branch (248:7): [True: 1.08k, False: 1.48k]
  ------------------
  249|  1.08k|      y <<= shifts;
  250|  1.08k|   }
  251|       |
  252|  2.57k|   BigInt r;
  253|  2.57k|   r.set_bit(k + shifts);  // (2^k) << shifts
  254|       |
  255|       |   // we know y has not changed size, since we only shifted up to set high bit
  256|  2.57k|   const size_t t = y_words - 1;
  257|  2.57k|   const size_t n = std::max(y_words, r.sig_words()) - 1;
  258|       |
  259|  2.57k|   BOTAN_ASSERT_NOMSG(n >= t);
  ------------------
  |  |   77|  2.57k|   do {                                                                     \
  |  |   78|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.57k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  260|       |
  261|  2.57k|   BigInt q = BigInt::zero();
  262|  2.57k|   q.grow_to(n - t + 1);
  263|       |
  264|  2.57k|   word* q_words = q.mutable_data();
  265|       |
  266|  2.57k|   BigInt shifted_y = y << (WB * (n - t));
  267|       |
  268|       |   // Set q_{n-t} to number of times r > shifted_y
  269|  2.57k|   secure_vector<word> ws;
  270|  2.57k|   q_words[n - t] = r.reduce_below(shifted_y, ws);
  271|       |
  272|  2.57k|   const word y_t0 = y.word_at(t);
  273|  2.57k|   const word y_t1 = y.word_at(t - 1);
  274|  2.57k|   BOTAN_DEBUG_ASSERT((y_t0 >> (WB - 1)) == 1);
  ------------------
  |  |  130|  2.57k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  2.57k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
  275|       |
  276|  2.57k|   const divide_precomp div_y_t0(y_t0);
  277|       |
  278|  32.9k|   for(size_t i = n; i != t; --i) {
  ------------------
  |  Branch (278:22): [True: 30.3k, False: 2.57k]
  ------------------
  279|  30.3k|      const word x_i0 = r.word_at(i);
  280|  30.3k|      const word x_i1 = r.word_at(i - 1);
  281|  30.3k|      const word x_i2 = r.word_at(i - 2);
  282|       |
  283|  30.3k|      word qit = (x_i0 == y_t0) ? WordInfo<word>::max : div_y_t0.vartime_div_2to1(x_i0, x_i1);
  ------------------
  |  Branch (283:18): [True: 0, False: 30.3k]
  ------------------
  284|       |
  285|       |      // Per HAC 14.23, this operation is required at most twice
  286|  35.8k|      for(size_t j = 0; j != 2; ++j) {
  ------------------
  |  Branch (286:25): [True: 35.6k, False: 198]
  ------------------
  287|  35.6k|         if(division_check_vartime(qit, y_t0, y_t1, x_i0, x_i1, x_i2)) {
  ------------------
  |  Branch (287:13): [True: 5.48k, False: 30.1k]
  ------------------
  288|  5.48k|            BOTAN_ASSERT_NOMSG(qit > 0);
  ------------------
  |  |   77|  5.48k|   do {                                                                     \
  |  |   78|  5.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  5.48k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 5.48k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  5.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 5.48k]
  |  |  ------------------
  ------------------
  289|  5.48k|            qit--;
  290|  30.1k|         } else {
  291|  30.1k|            break;
  292|  30.1k|         }
  293|  35.6k|      }
  294|       |
  295|  30.3k|      shifted_y >>= WB;
  296|       |      // Now shifted_y == y << (WB * (i-t-1))
  297|       |
  298|       |      /*
  299|       |      * Special case qit == 0 and qit == 1 which occurs relatively often here due to a
  300|       |      * combination of the fixed 2^k and in many cases the typical structure of
  301|       |      * public moduli (as this function is called by Barrett_Reduction::for_public_modulus).
  302|       |      *
  303|       |      * Over the test suite, about 5% of loop iterations have qit == 1 and 10% have qit == 0
  304|       |      */
  305|       |
  306|  30.3k|      if(qit != 0) {
  ------------------
  |  Branch (306:10): [True: 30.3k, False: 7]
  ------------------
  307|  30.3k|         if(qit == 1) {
  ------------------
  |  Branch (307:13): [True: 1.48k, False: 28.9k]
  ------------------
  308|  1.48k|            r -= shifted_y;
  309|  28.9k|         } else {
  310|  28.9k|            r -= qit * shifted_y;
  311|  28.9k|         }
  312|       |
  313|  30.3k|         if(r.signum() < 0) {
  ------------------
  |  Branch (313:13): [True: 0, False: 30.3k]
  ------------------
  314|      0|            BOTAN_ASSERT_NOMSG(qit > 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  315|      0|            qit--;
  316|      0|            r += shifted_y;
  317|      0|            BOTAN_ASSERT_NOMSG(r.signum() >= 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  318|      0|         }
  319|  30.3k|      }
  320|       |
  321|  30.3k|      q_words[i - t - 1] = qit;
  322|  30.3k|   }
  323|       |
  324|  2.57k|   return q;
  325|  2.57k|}
_ZN5Botan14vartime_divideERKNS_6BigIntES2_RS0_S3_:
  332|  1.02k|void vartime_divide(const BigInt& x, const BigInt& y_arg, BigInt& q_out, BigInt& r_out) {
  333|  1.02k|   constexpr size_t WB = WordInfo<word>::bits;
  334|       |
  335|  1.02k|   if(y_arg.is_zero()) {
  ------------------
  |  Branch (335:7): [True: 0, False: 1.02k]
  ------------------
  336|      0|      throw Invalid_Argument("vartime_divide: cannot divide by zero");
  337|      0|   }
  338|       |
  339|  1.02k|   const size_t y_words = y_arg.sig_words();
  340|       |
  341|  1.02k|   BOTAN_ASSERT_NOMSG(y_words > 0);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  342|       |
  343|  1.02k|   BigInt y = y_arg;
  344|       |
  345|  1.02k|   BigInt r = x;
  346|  1.02k|   BigInt q = BigInt::zero();
  347|  1.02k|   secure_vector<word> ws;
  348|       |
  349|  1.02k|   r.set_sign(BigInt::Positive);
  350|  1.02k|   y.set_sign(BigInt::Positive);
  351|       |
  352|       |   // Calculate shifts needed to normalize y with high bit set
  353|  1.02k|   const size_t shifts = y.top_bits_free();
  354|       |
  355|  1.02k|   if(shifts > 0) {
  ------------------
  |  Branch (355:7): [True: 1.02k, False: 0]
  ------------------
  356|  1.02k|      y <<= shifts;
  357|  1.02k|      r <<= shifts;
  358|  1.02k|   }
  359|       |
  360|       |   // we know y has not changed size, since we only shifted up to set high bit
  361|  1.02k|   const size_t t = y_words - 1;
  362|  1.02k|   const size_t n = std::max(y_words, r.sig_words()) - 1;  // r may have changed size however
  363|       |
  364|  1.02k|   BOTAN_ASSERT_NOMSG(n >= t);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  365|       |
  366|  1.02k|   q.grow_to(n - t + 1);
  367|       |
  368|  1.02k|   word* q_words = q.mutable_data();
  369|       |
  370|  1.02k|   BigInt shifted_y = y << (WB * (n - t));
  371|       |
  372|       |   // Set q_{n-t} to number of times r > shifted_y
  373|  1.02k|   q_words[n - t] = r.reduce_below(shifted_y, ws);
  374|       |
  375|  1.02k|   const word y_t0 = y.word_at(t);
  376|  1.02k|   const word y_t1 = y.word_at(t - 1);
  377|  1.02k|   BOTAN_DEBUG_ASSERT((y_t0 >> (WB - 1)) == 1);
  ------------------
  |  |  130|  1.02k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  1.02k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  378|       |
  379|  1.02k|   const divide_precomp div_y_t0(y_t0);
  380|       |
  381|  15.4k|   for(size_t i = n; i != t; --i) {
  ------------------
  |  Branch (381:22): [True: 14.3k, False: 1.02k]
  ------------------
  382|  14.3k|      const word x_i0 = r.word_at(i);
  383|  14.3k|      const word x_i1 = r.word_at(i - 1);
  384|  14.3k|      const word x_i2 = r.word_at(i - 2);
  385|       |
  386|  14.3k|      word qit = (x_i0 == y_t0) ? WordInfo<word>::max : div_y_t0.vartime_div_2to1(x_i0, x_i1);
  ------------------
  |  Branch (386:18): [True: 0, False: 14.3k]
  ------------------
  387|       |
  388|       |      // Per HAC 14.23, this operation is required at most twice
  389|  22.8k|      for(size_t j = 0; j != 2; ++j) {
  ------------------
  |  Branch (389:25): [True: 22.5k, False: 364]
  ------------------
  390|  22.5k|         if(division_check_vartime(qit, y_t0, y_t1, x_i0, x_i1, x_i2)) {
  ------------------
  |  Branch (390:13): [True: 8.48k, False: 14.0k]
  ------------------
  391|  8.48k|            BOTAN_ASSERT_NOMSG(qit > 0);
  ------------------
  |  |   77|  8.48k|   do {                                                                     \
  |  |   78|  8.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  8.48k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 8.48k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  8.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 8.48k]
  |  |  ------------------
  ------------------
  392|  8.48k|            qit--;
  393|  14.0k|         } else {
  394|  14.0k|            break;
  395|  14.0k|         }
  396|  22.5k|      }
  397|       |
  398|  14.3k|      shifted_y >>= WB;
  399|       |      // Now shifted_y == y << (WB * (i-t-1))
  400|       |
  401|  14.3k|      if(qit != 0) {
  ------------------
  |  Branch (401:10): [True: 14.3k, False: 0]
  ------------------
  402|  14.3k|         r -= qit * shifted_y;
  403|  14.3k|         if(r.signum() < 0) {
  ------------------
  |  Branch (403:13): [True: 0, False: 14.3k]
  ------------------
  404|      0|            BOTAN_ASSERT_NOMSG(qit > 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  405|      0|            qit--;
  406|      0|            r += shifted_y;
  407|      0|            BOTAN_ASSERT_NOMSG(r.signum() >= 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  408|      0|         }
  409|  14.3k|      }
  410|       |
  411|  14.3k|      q_words[i - t - 1] = qit;
  412|  14.3k|   }
  413|       |
  414|  1.02k|   if(shifts > 0) {
  ------------------
  |  Branch (414:7): [True: 1.02k, False: 0]
  ------------------
  415|  1.02k|      r >>= shifts;
  416|  1.02k|   }
  417|       |
  418|  1.02k|   sign_fixup(x, y_arg, q, r);
  419|       |
  420|  1.02k|   r_out = r;
  421|  1.02k|   q_out = q;
  422|  1.02k|}
divide.cpp:_ZN5Botan12_GLOBAL__N_110sign_fixupERKNS_6BigIntES3_RS1_S4_:
   21|  1.02k|void sign_fixup(const BigInt& x, const BigInt& y, BigInt& q, BigInt& r) {
   22|  1.02k|   q.cond_flip_sign(x.sign() != y.sign());
   23|       |
   24|  1.02k|   if(x.signum() < 0 && r.signum() != 0) {
  ------------------
  |  Branch (24:7): [True: 0, False: 1.02k]
  |  Branch (24:25): [True: 0, False: 0]
  ------------------
   25|      0|      if(y.signum() > 0) {
  ------------------
  |  Branch (25:10): [True: 0, False: 0]
  ------------------
   26|      0|         q -= 1;
   27|      0|      } else {
   28|      0|         q += 1;
   29|      0|      }
   30|      0|      r = y.abs() - r;
   31|      0|   }
   32|  1.02k|}
divide.cpp:_ZN5Botan12_GLOBAL__N_122division_check_vartimeEmmmmmm:
   34|  58.1k|inline bool division_check_vartime(word q, word y2, word y1, word x3, word x2, word x1) {
   35|       |   /*
   36|       |   Compute (y3,y2,y1) = (y2,y1) * q
   37|       |   and return true if (y3,y2,y1) > (x3,x2,x1)
   38|       |   */
   39|       |
   40|  58.1k|   word y3 = 0;
   41|  58.1k|   y1 = word_madd2(q, y1, &y3);
   42|  58.1k|   y2 = word_madd2(q, y2, &y3);
   43|       |
   44|  58.1k|   if(x3 != y3) {
  ------------------
  |  Branch (44:7): [True: 20.7k, False: 37.4k]
  ------------------
   45|  20.7k|      return (y3 > x3);
   46|  20.7k|   }
   47|  37.4k|   if(x2 != y2) {
  ------------------
  |  Branch (47:7): [True: 37.4k, False: 4]
  ------------------
   48|  37.4k|      return (y2 > x2);
   49|  37.4k|   }
   50|      4|   return (y1 > x1);
   51|  37.4k|}

_ZN5Botan17bigint_comba_sqr4EPmPKm:
   17|  10.4M|void bigint_comba_sqr4(word z[8], const word x[4]) {
   18|  10.4M|   word3<word> accum;
   19|       |
   20|  10.4M|   accum.mul(x[0], x[0]);
   21|  10.4M|   z[0] = accum.extract();
   22|  10.4M|   accum.mul_x2(x[0], x[1]);
   23|  10.4M|   z[1] = accum.extract();
   24|  10.4M|   accum.mul_x2(x[0], x[2]);
   25|  10.4M|   accum.mul(x[1], x[1]);
   26|  10.4M|   z[2] = accum.extract();
   27|  10.4M|   accum.mul_x2(x[0], x[3]);
   28|  10.4M|   accum.mul_x2(x[1], x[2]);
   29|  10.4M|   z[3] = accum.extract();
   30|  10.4M|   accum.mul_x2(x[1], x[3]);
   31|  10.4M|   accum.mul(x[2], x[2]);
   32|  10.4M|   z[4] = accum.extract();
   33|  10.4M|   accum.mul_x2(x[2], x[3]);
   34|  10.4M|   z[5] = accum.extract();
   35|  10.4M|   accum.mul(x[3], x[3]);
   36|  10.4M|   z[6] = accum.extract();
   37|  10.4M|   z[7] = accum.extract();
   38|  10.4M|}
_ZN5Botan17bigint_comba_mul4EPmPKmS2_:
   43|  15.4M|void bigint_comba_mul4(word z[8], const word x[4], const word y[4]) {
   44|  15.4M|   word3<word> accum;
   45|       |
   46|  15.4M|   accum.mul(x[0], y[0]);
   47|  15.4M|   z[0] = accum.extract();
   48|  15.4M|   accum.mul(x[0], y[1]);
   49|  15.4M|   accum.mul(x[1], y[0]);
   50|  15.4M|   z[1] = accum.extract();
   51|  15.4M|   accum.mul(x[0], y[2]);
   52|  15.4M|   accum.mul(x[1], y[1]);
   53|  15.4M|   accum.mul(x[2], y[0]);
   54|  15.4M|   z[2] = accum.extract();
   55|  15.4M|   accum.mul(x[0], y[3]);
   56|  15.4M|   accum.mul(x[1], y[2]);
   57|  15.4M|   accum.mul(x[2], y[1]);
   58|  15.4M|   accum.mul(x[3], y[0]);
   59|  15.4M|   z[3] = accum.extract();
   60|  15.4M|   accum.mul(x[1], y[3]);
   61|  15.4M|   accum.mul(x[2], y[2]);
   62|  15.4M|   accum.mul(x[3], y[1]);
   63|  15.4M|   z[4] = accum.extract();
   64|  15.4M|   accum.mul(x[2], y[3]);
   65|  15.4M|   accum.mul(x[3], y[2]);
   66|  15.4M|   z[5] = accum.extract();
   67|  15.4M|   accum.mul(x[3], y[3]);
   68|  15.4M|   z[6] = accum.extract();
   69|  15.4M|   z[7] = accum.extract();
   70|  15.4M|}
_ZN5Botan17bigint_comba_mul6EPmPKmS2_:
  116|     48|void bigint_comba_mul6(word z[12], const word x[6], const word y[6]) {
  117|     48|   word3<word> accum;
  118|       |
  119|     48|   accum.mul(x[0], y[0]);
  120|     48|   z[0] = accum.extract();
  121|     48|   accum.mul(x[0], y[1]);
  122|     48|   accum.mul(x[1], y[0]);
  123|     48|   z[1] = accum.extract();
  124|     48|   accum.mul(x[0], y[2]);
  125|     48|   accum.mul(x[1], y[1]);
  126|     48|   accum.mul(x[2], y[0]);
  127|     48|   z[2] = accum.extract();
  128|     48|   accum.mul(x[0], y[3]);
  129|     48|   accum.mul(x[1], y[2]);
  130|     48|   accum.mul(x[2], y[1]);
  131|     48|   accum.mul(x[3], y[0]);
  132|     48|   z[3] = accum.extract();
  133|     48|   accum.mul(x[0], y[4]);
  134|     48|   accum.mul(x[1], y[3]);
  135|     48|   accum.mul(x[2], y[2]);
  136|     48|   accum.mul(x[3], y[1]);
  137|     48|   accum.mul(x[4], y[0]);
  138|     48|   z[4] = accum.extract();
  139|     48|   accum.mul(x[0], y[5]);
  140|     48|   accum.mul(x[1], y[4]);
  141|     48|   accum.mul(x[2], y[3]);
  142|     48|   accum.mul(x[3], y[2]);
  143|     48|   accum.mul(x[4], y[1]);
  144|     48|   accum.mul(x[5], y[0]);
  145|     48|   z[5] = accum.extract();
  146|     48|   accum.mul(x[1], y[5]);
  147|     48|   accum.mul(x[2], y[4]);
  148|     48|   accum.mul(x[3], y[3]);
  149|     48|   accum.mul(x[4], y[2]);
  150|     48|   accum.mul(x[5], y[1]);
  151|     48|   z[6] = accum.extract();
  152|     48|   accum.mul(x[2], y[5]);
  153|     48|   accum.mul(x[3], y[4]);
  154|     48|   accum.mul(x[4], y[3]);
  155|     48|   accum.mul(x[5], y[2]);
  156|     48|   z[7] = accum.extract();
  157|     48|   accum.mul(x[3], y[5]);
  158|     48|   accum.mul(x[4], y[4]);
  159|     48|   accum.mul(x[5], y[3]);
  160|     48|   z[8] = accum.extract();
  161|     48|   accum.mul(x[4], y[5]);
  162|     48|   accum.mul(x[5], y[4]);
  163|     48|   z[9] = accum.extract();
  164|     48|   accum.mul(x[5], y[5]);
  165|     48|   z[10] = accum.extract();
  166|     48|   z[11] = accum.extract();
  167|     48|}
_ZN5Botan18bigint_comba_sqr16EPmPKm:
  619|   264k|void bigint_comba_sqr16(word z[32], const word x[16]) {
  620|   264k|   word3<word> accum;
  621|       |
  622|   264k|   accum.mul(x[0], x[0]);
  623|   264k|   z[0] = accum.extract();
  624|   264k|   accum.mul_x2(x[0], x[1]);
  625|   264k|   z[1] = accum.extract();
  626|   264k|   accum.mul_x2(x[0], x[2]);
  627|   264k|   accum.mul(x[1], x[1]);
  628|   264k|   z[2] = accum.extract();
  629|   264k|   accum.mul_x2(x[0], x[3]);
  630|   264k|   accum.mul_x2(x[1], x[2]);
  631|   264k|   z[3] = accum.extract();
  632|   264k|   accum.mul_x2(x[0], x[4]);
  633|   264k|   accum.mul_x2(x[1], x[3]);
  634|   264k|   accum.mul(x[2], x[2]);
  635|   264k|   z[4] = accum.extract();
  636|   264k|   accum.mul_x2(x[0], x[5]);
  637|   264k|   accum.mul_x2(x[1], x[4]);
  638|   264k|   accum.mul_x2(x[2], x[3]);
  639|   264k|   z[5] = accum.extract();
  640|   264k|   accum.mul_x2(x[0], x[6]);
  641|   264k|   accum.mul_x2(x[1], x[5]);
  642|   264k|   accum.mul_x2(x[2], x[4]);
  643|   264k|   accum.mul(x[3], x[3]);
  644|   264k|   z[6] = accum.extract();
  645|   264k|   accum.mul_x2(x[0], x[7]);
  646|   264k|   accum.mul_x2(x[1], x[6]);
  647|   264k|   accum.mul_x2(x[2], x[5]);
  648|   264k|   accum.mul_x2(x[3], x[4]);
  649|   264k|   z[7] = accum.extract();
  650|   264k|   accum.mul_x2(x[0], x[8]);
  651|   264k|   accum.mul_x2(x[1], x[7]);
  652|   264k|   accum.mul_x2(x[2], x[6]);
  653|   264k|   accum.mul_x2(x[3], x[5]);
  654|   264k|   accum.mul(x[4], x[4]);
  655|   264k|   z[8] = accum.extract();
  656|   264k|   accum.mul_x2(x[0], x[9]);
  657|   264k|   accum.mul_x2(x[1], x[8]);
  658|   264k|   accum.mul_x2(x[2], x[7]);
  659|   264k|   accum.mul_x2(x[3], x[6]);
  660|   264k|   accum.mul_x2(x[4], x[5]);
  661|   264k|   z[9] = accum.extract();
  662|   264k|   accum.mul_x2(x[0], x[10]);
  663|   264k|   accum.mul_x2(x[1], x[9]);
  664|   264k|   accum.mul_x2(x[2], x[8]);
  665|   264k|   accum.mul_x2(x[3], x[7]);
  666|   264k|   accum.mul_x2(x[4], x[6]);
  667|   264k|   accum.mul(x[5], x[5]);
  668|   264k|   z[10] = accum.extract();
  669|   264k|   accum.mul_x2(x[0], x[11]);
  670|   264k|   accum.mul_x2(x[1], x[10]);
  671|   264k|   accum.mul_x2(x[2], x[9]);
  672|   264k|   accum.mul_x2(x[3], x[8]);
  673|   264k|   accum.mul_x2(x[4], x[7]);
  674|   264k|   accum.mul_x2(x[5], x[6]);
  675|   264k|   z[11] = accum.extract();
  676|   264k|   accum.mul_x2(x[0], x[12]);
  677|   264k|   accum.mul_x2(x[1], x[11]);
  678|   264k|   accum.mul_x2(x[2], x[10]);
  679|   264k|   accum.mul_x2(x[3], x[9]);
  680|   264k|   accum.mul_x2(x[4], x[8]);
  681|   264k|   accum.mul_x2(x[5], x[7]);
  682|   264k|   accum.mul(x[6], x[6]);
  683|   264k|   z[12] = accum.extract();
  684|   264k|   accum.mul_x2(x[0], x[13]);
  685|   264k|   accum.mul_x2(x[1], x[12]);
  686|   264k|   accum.mul_x2(x[2], x[11]);
  687|   264k|   accum.mul_x2(x[3], x[10]);
  688|   264k|   accum.mul_x2(x[4], x[9]);
  689|   264k|   accum.mul_x2(x[5], x[8]);
  690|   264k|   accum.mul_x2(x[6], x[7]);
  691|   264k|   z[13] = accum.extract();
  692|   264k|   accum.mul_x2(x[0], x[14]);
  693|   264k|   accum.mul_x2(x[1], x[13]);
  694|   264k|   accum.mul_x2(x[2], x[12]);
  695|   264k|   accum.mul_x2(x[3], x[11]);
  696|   264k|   accum.mul_x2(x[4], x[10]);
  697|   264k|   accum.mul_x2(x[5], x[9]);
  698|   264k|   accum.mul_x2(x[6], x[8]);
  699|   264k|   accum.mul(x[7], x[7]);
  700|   264k|   z[14] = accum.extract();
  701|   264k|   accum.mul_x2(x[0], x[15]);
  702|   264k|   accum.mul_x2(x[1], x[14]);
  703|   264k|   accum.mul_x2(x[2], x[13]);
  704|   264k|   accum.mul_x2(x[3], x[12]);
  705|   264k|   accum.mul_x2(x[4], x[11]);
  706|   264k|   accum.mul_x2(x[5], x[10]);
  707|   264k|   accum.mul_x2(x[6], x[9]);
  708|   264k|   accum.mul_x2(x[7], x[8]);
  709|   264k|   z[15] = accum.extract();
  710|   264k|   accum.mul_x2(x[1], x[15]);
  711|   264k|   accum.mul_x2(x[2], x[14]);
  712|   264k|   accum.mul_x2(x[3], x[13]);
  713|   264k|   accum.mul_x2(x[4], x[12]);
  714|   264k|   accum.mul_x2(x[5], x[11]);
  715|   264k|   accum.mul_x2(x[6], x[10]);
  716|   264k|   accum.mul_x2(x[7], x[9]);
  717|   264k|   accum.mul(x[8], x[8]);
  718|   264k|   z[16] = accum.extract();
  719|   264k|   accum.mul_x2(x[2], x[15]);
  720|   264k|   accum.mul_x2(x[3], x[14]);
  721|   264k|   accum.mul_x2(x[4], x[13]);
  722|   264k|   accum.mul_x2(x[5], x[12]);
  723|   264k|   accum.mul_x2(x[6], x[11]);
  724|   264k|   accum.mul_x2(x[7], x[10]);
  725|   264k|   accum.mul_x2(x[8], x[9]);
  726|   264k|   z[17] = accum.extract();
  727|   264k|   accum.mul_x2(x[3], x[15]);
  728|   264k|   accum.mul_x2(x[4], x[14]);
  729|   264k|   accum.mul_x2(x[5], x[13]);
  730|   264k|   accum.mul_x2(x[6], x[12]);
  731|   264k|   accum.mul_x2(x[7], x[11]);
  732|   264k|   accum.mul_x2(x[8], x[10]);
  733|   264k|   accum.mul(x[9], x[9]);
  734|   264k|   z[18] = accum.extract();
  735|   264k|   accum.mul_x2(x[4], x[15]);
  736|   264k|   accum.mul_x2(x[5], x[14]);
  737|   264k|   accum.mul_x2(x[6], x[13]);
  738|   264k|   accum.mul_x2(x[7], x[12]);
  739|   264k|   accum.mul_x2(x[8], x[11]);
  740|   264k|   accum.mul_x2(x[9], x[10]);
  741|   264k|   z[19] = accum.extract();
  742|   264k|   accum.mul_x2(x[5], x[15]);
  743|   264k|   accum.mul_x2(x[6], x[14]);
  744|   264k|   accum.mul_x2(x[7], x[13]);
  745|   264k|   accum.mul_x2(x[8], x[12]);
  746|   264k|   accum.mul_x2(x[9], x[11]);
  747|   264k|   accum.mul(x[10], x[10]);
  748|   264k|   z[20] = accum.extract();
  749|   264k|   accum.mul_x2(x[6], x[15]);
  750|   264k|   accum.mul_x2(x[7], x[14]);
  751|   264k|   accum.mul_x2(x[8], x[13]);
  752|   264k|   accum.mul_x2(x[9], x[12]);
  753|   264k|   accum.mul_x2(x[10], x[11]);
  754|   264k|   z[21] = accum.extract();
  755|   264k|   accum.mul_x2(x[7], x[15]);
  756|   264k|   accum.mul_x2(x[8], x[14]);
  757|   264k|   accum.mul_x2(x[9], x[13]);
  758|   264k|   accum.mul_x2(x[10], x[12]);
  759|   264k|   accum.mul(x[11], x[11]);
  760|   264k|   z[22] = accum.extract();
  761|   264k|   accum.mul_x2(x[8], x[15]);
  762|   264k|   accum.mul_x2(x[9], x[14]);
  763|   264k|   accum.mul_x2(x[10], x[13]);
  764|   264k|   accum.mul_x2(x[11], x[12]);
  765|   264k|   z[23] = accum.extract();
  766|   264k|   accum.mul_x2(x[9], x[15]);
  767|   264k|   accum.mul_x2(x[10], x[14]);
  768|   264k|   accum.mul_x2(x[11], x[13]);
  769|   264k|   accum.mul(x[12], x[12]);
  770|   264k|   z[24] = accum.extract();
  771|   264k|   accum.mul_x2(x[10], x[15]);
  772|   264k|   accum.mul_x2(x[11], x[14]);
  773|   264k|   accum.mul_x2(x[12], x[13]);
  774|   264k|   z[25] = accum.extract();
  775|   264k|   accum.mul_x2(x[11], x[15]);
  776|   264k|   accum.mul_x2(x[12], x[14]);
  777|   264k|   accum.mul(x[13], x[13]);
  778|   264k|   z[26] = accum.extract();
  779|   264k|   accum.mul_x2(x[12], x[15]);
  780|   264k|   accum.mul_x2(x[13], x[14]);
  781|   264k|   z[27] = accum.extract();
  782|   264k|   accum.mul_x2(x[13], x[15]);
  783|   264k|   accum.mul(x[14], x[14]);
  784|   264k|   z[28] = accum.extract();
  785|   264k|   accum.mul_x2(x[14], x[15]);
  786|   264k|   z[29] = accum.extract();
  787|   264k|   accum.mul(x[15], x[15]);
  788|   264k|   z[30] = accum.extract();
  789|   264k|   z[31] = accum.extract();
  790|   264k|}
_ZN5Botan18bigint_comba_mul16EPmPKmS2_:
  795|   122k|void bigint_comba_mul16(word z[32], const word x[16], const word y[16]) {
  796|   122k|   word3<word> accum;
  797|       |
  798|   122k|   accum.mul(x[0], y[0]);
  799|   122k|   z[0] = accum.extract();
  800|   122k|   accum.mul(x[0], y[1]);
  801|   122k|   accum.mul(x[1], y[0]);
  802|   122k|   z[1] = accum.extract();
  803|   122k|   accum.mul(x[0], y[2]);
  804|   122k|   accum.mul(x[1], y[1]);
  805|   122k|   accum.mul(x[2], y[0]);
  806|   122k|   z[2] = accum.extract();
  807|   122k|   accum.mul(x[0], y[3]);
  808|   122k|   accum.mul(x[1], y[2]);
  809|   122k|   accum.mul(x[2], y[1]);
  810|   122k|   accum.mul(x[3], y[0]);
  811|   122k|   z[3] = accum.extract();
  812|   122k|   accum.mul(x[0], y[4]);
  813|   122k|   accum.mul(x[1], y[3]);
  814|   122k|   accum.mul(x[2], y[2]);
  815|   122k|   accum.mul(x[3], y[1]);
  816|   122k|   accum.mul(x[4], y[0]);
  817|   122k|   z[4] = accum.extract();
  818|   122k|   accum.mul(x[0], y[5]);
  819|   122k|   accum.mul(x[1], y[4]);
  820|   122k|   accum.mul(x[2], y[3]);
  821|   122k|   accum.mul(x[3], y[2]);
  822|   122k|   accum.mul(x[4], y[1]);
  823|   122k|   accum.mul(x[5], y[0]);
  824|   122k|   z[5] = accum.extract();
  825|   122k|   accum.mul(x[0], y[6]);
  826|   122k|   accum.mul(x[1], y[5]);
  827|   122k|   accum.mul(x[2], y[4]);
  828|   122k|   accum.mul(x[3], y[3]);
  829|   122k|   accum.mul(x[4], y[2]);
  830|   122k|   accum.mul(x[5], y[1]);
  831|   122k|   accum.mul(x[6], y[0]);
  832|   122k|   z[6] = accum.extract();
  833|   122k|   accum.mul(x[0], y[7]);
  834|   122k|   accum.mul(x[1], y[6]);
  835|   122k|   accum.mul(x[2], y[5]);
  836|   122k|   accum.mul(x[3], y[4]);
  837|   122k|   accum.mul(x[4], y[3]);
  838|   122k|   accum.mul(x[5], y[2]);
  839|   122k|   accum.mul(x[6], y[1]);
  840|   122k|   accum.mul(x[7], y[0]);
  841|   122k|   z[7] = accum.extract();
  842|   122k|   accum.mul(x[0], y[8]);
  843|   122k|   accum.mul(x[1], y[7]);
  844|   122k|   accum.mul(x[2], y[6]);
  845|   122k|   accum.mul(x[3], y[5]);
  846|   122k|   accum.mul(x[4], y[4]);
  847|   122k|   accum.mul(x[5], y[3]);
  848|   122k|   accum.mul(x[6], y[2]);
  849|   122k|   accum.mul(x[7], y[1]);
  850|   122k|   accum.mul(x[8], y[0]);
  851|   122k|   z[8] = accum.extract();
  852|   122k|   accum.mul(x[0], y[9]);
  853|   122k|   accum.mul(x[1], y[8]);
  854|   122k|   accum.mul(x[2], y[7]);
  855|   122k|   accum.mul(x[3], y[6]);
  856|   122k|   accum.mul(x[4], y[5]);
  857|   122k|   accum.mul(x[5], y[4]);
  858|   122k|   accum.mul(x[6], y[3]);
  859|   122k|   accum.mul(x[7], y[2]);
  860|   122k|   accum.mul(x[8], y[1]);
  861|   122k|   accum.mul(x[9], y[0]);
  862|   122k|   z[9] = accum.extract();
  863|   122k|   accum.mul(x[0], y[10]);
  864|   122k|   accum.mul(x[1], y[9]);
  865|   122k|   accum.mul(x[2], y[8]);
  866|   122k|   accum.mul(x[3], y[7]);
  867|   122k|   accum.mul(x[4], y[6]);
  868|   122k|   accum.mul(x[5], y[5]);
  869|   122k|   accum.mul(x[6], y[4]);
  870|   122k|   accum.mul(x[7], y[3]);
  871|   122k|   accum.mul(x[8], y[2]);
  872|   122k|   accum.mul(x[9], y[1]);
  873|   122k|   accum.mul(x[10], y[0]);
  874|   122k|   z[10] = accum.extract();
  875|   122k|   accum.mul(x[0], y[11]);
  876|   122k|   accum.mul(x[1], y[10]);
  877|   122k|   accum.mul(x[2], y[9]);
  878|   122k|   accum.mul(x[3], y[8]);
  879|   122k|   accum.mul(x[4], y[7]);
  880|   122k|   accum.mul(x[5], y[6]);
  881|   122k|   accum.mul(x[6], y[5]);
  882|   122k|   accum.mul(x[7], y[4]);
  883|   122k|   accum.mul(x[8], y[3]);
  884|   122k|   accum.mul(x[9], y[2]);
  885|   122k|   accum.mul(x[10], y[1]);
  886|   122k|   accum.mul(x[11], y[0]);
  887|   122k|   z[11] = accum.extract();
  888|   122k|   accum.mul(x[0], y[12]);
  889|   122k|   accum.mul(x[1], y[11]);
  890|   122k|   accum.mul(x[2], y[10]);
  891|   122k|   accum.mul(x[3], y[9]);
  892|   122k|   accum.mul(x[4], y[8]);
  893|   122k|   accum.mul(x[5], y[7]);
  894|   122k|   accum.mul(x[6], y[6]);
  895|   122k|   accum.mul(x[7], y[5]);
  896|   122k|   accum.mul(x[8], y[4]);
  897|   122k|   accum.mul(x[9], y[3]);
  898|   122k|   accum.mul(x[10], y[2]);
  899|   122k|   accum.mul(x[11], y[1]);
  900|   122k|   accum.mul(x[12], y[0]);
  901|   122k|   z[12] = accum.extract();
  902|   122k|   accum.mul(x[0], y[13]);
  903|   122k|   accum.mul(x[1], y[12]);
  904|   122k|   accum.mul(x[2], y[11]);
  905|   122k|   accum.mul(x[3], y[10]);
  906|   122k|   accum.mul(x[4], y[9]);
  907|   122k|   accum.mul(x[5], y[8]);
  908|   122k|   accum.mul(x[6], y[7]);
  909|   122k|   accum.mul(x[7], y[6]);
  910|   122k|   accum.mul(x[8], y[5]);
  911|   122k|   accum.mul(x[9], y[4]);
  912|   122k|   accum.mul(x[10], y[3]);
  913|   122k|   accum.mul(x[11], y[2]);
  914|   122k|   accum.mul(x[12], y[1]);
  915|   122k|   accum.mul(x[13], y[0]);
  916|   122k|   z[13] = accum.extract();
  917|   122k|   accum.mul(x[0], y[14]);
  918|   122k|   accum.mul(x[1], y[13]);
  919|   122k|   accum.mul(x[2], y[12]);
  920|   122k|   accum.mul(x[3], y[11]);
  921|   122k|   accum.mul(x[4], y[10]);
  922|   122k|   accum.mul(x[5], y[9]);
  923|   122k|   accum.mul(x[6], y[8]);
  924|   122k|   accum.mul(x[7], y[7]);
  925|   122k|   accum.mul(x[8], y[6]);
  926|   122k|   accum.mul(x[9], y[5]);
  927|   122k|   accum.mul(x[10], y[4]);
  928|   122k|   accum.mul(x[11], y[3]);
  929|   122k|   accum.mul(x[12], y[2]);
  930|   122k|   accum.mul(x[13], y[1]);
  931|   122k|   accum.mul(x[14], y[0]);
  932|   122k|   z[14] = accum.extract();
  933|   122k|   accum.mul(x[0], y[15]);
  934|   122k|   accum.mul(x[1], y[14]);
  935|   122k|   accum.mul(x[2], y[13]);
  936|   122k|   accum.mul(x[3], y[12]);
  937|   122k|   accum.mul(x[4], y[11]);
  938|   122k|   accum.mul(x[5], y[10]);
  939|   122k|   accum.mul(x[6], y[9]);
  940|   122k|   accum.mul(x[7], y[8]);
  941|   122k|   accum.mul(x[8], y[7]);
  942|   122k|   accum.mul(x[9], y[6]);
  943|   122k|   accum.mul(x[10], y[5]);
  944|   122k|   accum.mul(x[11], y[4]);
  945|   122k|   accum.mul(x[12], y[3]);
  946|   122k|   accum.mul(x[13], y[2]);
  947|   122k|   accum.mul(x[14], y[1]);
  948|   122k|   accum.mul(x[15], y[0]);
  949|   122k|   z[15] = accum.extract();
  950|   122k|   accum.mul(x[1], y[15]);
  951|   122k|   accum.mul(x[2], y[14]);
  952|   122k|   accum.mul(x[3], y[13]);
  953|   122k|   accum.mul(x[4], y[12]);
  954|   122k|   accum.mul(x[5], y[11]);
  955|   122k|   accum.mul(x[6], y[10]);
  956|   122k|   accum.mul(x[7], y[9]);
  957|   122k|   accum.mul(x[8], y[8]);
  958|   122k|   accum.mul(x[9], y[7]);
  959|   122k|   accum.mul(x[10], y[6]);
  960|   122k|   accum.mul(x[11], y[5]);
  961|   122k|   accum.mul(x[12], y[4]);
  962|   122k|   accum.mul(x[13], y[3]);
  963|   122k|   accum.mul(x[14], y[2]);
  964|   122k|   accum.mul(x[15], y[1]);
  965|   122k|   z[16] = accum.extract();
  966|   122k|   accum.mul(x[2], y[15]);
  967|   122k|   accum.mul(x[3], y[14]);
  968|   122k|   accum.mul(x[4], y[13]);
  969|   122k|   accum.mul(x[5], y[12]);
  970|   122k|   accum.mul(x[6], y[11]);
  971|   122k|   accum.mul(x[7], y[10]);
  972|   122k|   accum.mul(x[8], y[9]);
  973|   122k|   accum.mul(x[9], y[8]);
  974|   122k|   accum.mul(x[10], y[7]);
  975|   122k|   accum.mul(x[11], y[6]);
  976|   122k|   accum.mul(x[12], y[5]);
  977|   122k|   accum.mul(x[13], y[4]);
  978|   122k|   accum.mul(x[14], y[3]);
  979|   122k|   accum.mul(x[15], y[2]);
  980|   122k|   z[17] = accum.extract();
  981|   122k|   accum.mul(x[3], y[15]);
  982|   122k|   accum.mul(x[4], y[14]);
  983|   122k|   accum.mul(x[5], y[13]);
  984|   122k|   accum.mul(x[6], y[12]);
  985|   122k|   accum.mul(x[7], y[11]);
  986|   122k|   accum.mul(x[8], y[10]);
  987|   122k|   accum.mul(x[9], y[9]);
  988|   122k|   accum.mul(x[10], y[8]);
  989|   122k|   accum.mul(x[11], y[7]);
  990|   122k|   accum.mul(x[12], y[6]);
  991|   122k|   accum.mul(x[13], y[5]);
  992|   122k|   accum.mul(x[14], y[4]);
  993|   122k|   accum.mul(x[15], y[3]);
  994|   122k|   z[18] = accum.extract();
  995|   122k|   accum.mul(x[4], y[15]);
  996|   122k|   accum.mul(x[5], y[14]);
  997|   122k|   accum.mul(x[6], y[13]);
  998|   122k|   accum.mul(x[7], y[12]);
  999|   122k|   accum.mul(x[8], y[11]);
 1000|   122k|   accum.mul(x[9], y[10]);
 1001|   122k|   accum.mul(x[10], y[9]);
 1002|   122k|   accum.mul(x[11], y[8]);
 1003|   122k|   accum.mul(x[12], y[7]);
 1004|   122k|   accum.mul(x[13], y[6]);
 1005|   122k|   accum.mul(x[14], y[5]);
 1006|   122k|   accum.mul(x[15], y[4]);
 1007|   122k|   z[19] = accum.extract();
 1008|   122k|   accum.mul(x[5], y[15]);
 1009|   122k|   accum.mul(x[6], y[14]);
 1010|   122k|   accum.mul(x[7], y[13]);
 1011|   122k|   accum.mul(x[8], y[12]);
 1012|   122k|   accum.mul(x[9], y[11]);
 1013|   122k|   accum.mul(x[10], y[10]);
 1014|   122k|   accum.mul(x[11], y[9]);
 1015|   122k|   accum.mul(x[12], y[8]);
 1016|   122k|   accum.mul(x[13], y[7]);
 1017|   122k|   accum.mul(x[14], y[6]);
 1018|   122k|   accum.mul(x[15], y[5]);
 1019|   122k|   z[20] = accum.extract();
 1020|   122k|   accum.mul(x[6], y[15]);
 1021|   122k|   accum.mul(x[7], y[14]);
 1022|   122k|   accum.mul(x[8], y[13]);
 1023|   122k|   accum.mul(x[9], y[12]);
 1024|   122k|   accum.mul(x[10], y[11]);
 1025|   122k|   accum.mul(x[11], y[10]);
 1026|   122k|   accum.mul(x[12], y[9]);
 1027|   122k|   accum.mul(x[13], y[8]);
 1028|   122k|   accum.mul(x[14], y[7]);
 1029|   122k|   accum.mul(x[15], y[6]);
 1030|   122k|   z[21] = accum.extract();
 1031|   122k|   accum.mul(x[7], y[15]);
 1032|   122k|   accum.mul(x[8], y[14]);
 1033|   122k|   accum.mul(x[9], y[13]);
 1034|   122k|   accum.mul(x[10], y[12]);
 1035|   122k|   accum.mul(x[11], y[11]);
 1036|   122k|   accum.mul(x[12], y[10]);
 1037|   122k|   accum.mul(x[13], y[9]);
 1038|   122k|   accum.mul(x[14], y[8]);
 1039|   122k|   accum.mul(x[15], y[7]);
 1040|   122k|   z[22] = accum.extract();
 1041|   122k|   accum.mul(x[8], y[15]);
 1042|   122k|   accum.mul(x[9], y[14]);
 1043|   122k|   accum.mul(x[10], y[13]);
 1044|   122k|   accum.mul(x[11], y[12]);
 1045|   122k|   accum.mul(x[12], y[11]);
 1046|   122k|   accum.mul(x[13], y[10]);
 1047|   122k|   accum.mul(x[14], y[9]);
 1048|   122k|   accum.mul(x[15], y[8]);
 1049|   122k|   z[23] = accum.extract();
 1050|   122k|   accum.mul(x[9], y[15]);
 1051|   122k|   accum.mul(x[10], y[14]);
 1052|   122k|   accum.mul(x[11], y[13]);
 1053|   122k|   accum.mul(x[12], y[12]);
 1054|   122k|   accum.mul(x[13], y[11]);
 1055|   122k|   accum.mul(x[14], y[10]);
 1056|   122k|   accum.mul(x[15], y[9]);
 1057|   122k|   z[24] = accum.extract();
 1058|   122k|   accum.mul(x[10], y[15]);
 1059|   122k|   accum.mul(x[11], y[14]);
 1060|   122k|   accum.mul(x[12], y[13]);
 1061|   122k|   accum.mul(x[13], y[12]);
 1062|   122k|   accum.mul(x[14], y[11]);
 1063|   122k|   accum.mul(x[15], y[10]);
 1064|   122k|   z[25] = accum.extract();
 1065|   122k|   accum.mul(x[11], y[15]);
 1066|   122k|   accum.mul(x[12], y[14]);
 1067|   122k|   accum.mul(x[13], y[13]);
 1068|   122k|   accum.mul(x[14], y[12]);
 1069|   122k|   accum.mul(x[15], y[11]);
 1070|   122k|   z[26] = accum.extract();
 1071|   122k|   accum.mul(x[12], y[15]);
 1072|   122k|   accum.mul(x[13], y[14]);
 1073|   122k|   accum.mul(x[14], y[13]);
 1074|   122k|   accum.mul(x[15], y[12]);
 1075|   122k|   z[27] = accum.extract();
 1076|   122k|   accum.mul(x[13], y[15]);
 1077|   122k|   accum.mul(x[14], y[14]);
 1078|   122k|   accum.mul(x[15], y[13]);
 1079|   122k|   z[28] = accum.extract();
 1080|   122k|   accum.mul(x[14], y[15]);
 1081|   122k|   accum.mul(x[15], y[14]);
 1082|   122k|   z[29] = accum.extract();
 1083|   122k|   accum.mul(x[15], y[15]);
 1084|   122k|   z[30] = accum.extract();
 1085|   122k|   z[31] = accum.extract();
 1086|   122k|}

_ZN5Botan12basecase_mulEPmmPKmmS2_m:
   20|  11.2k|void basecase_mul(word z[], size_t z_size, const word x[], size_t x_size, const word y[], size_t y_size) {
   21|  11.2k|   if(z_size < x_size + y_size) {
  ------------------
  |  Branch (21:7): [True: 0, False: 11.2k]
  ------------------
   22|      0|      throw Invalid_Argument("basecase_mul z_size too small");
   23|      0|   }
   24|       |
   25|  11.2k|   const size_t x_size_8 = x_size - (x_size % 8);
   26|       |
   27|  11.2k|   zeroize_buffer(z, z_size);
   28|       |
   29|   174k|   for(size_t i = 0; i != y_size; ++i) {
  ------------------
  |  Branch (29:22): [True: 163k, False: 11.2k]
  ------------------
   30|   163k|      const word y_i = y[i];
   31|       |
   32|   163k|      word carry = 0;
   33|       |
   34|   499k|      for(size_t j = 0; j != x_size_8; j += 8) {
  ------------------
  |  Branch (34:25): [True: 336k, False: 163k]
  ------------------
   35|   336k|         carry = word8_madd3(z + i + j, x + j, y_i, carry);
   36|   336k|      }
   37|       |
   38|   338k|      for(size_t j = x_size_8; j != x_size; ++j) {
  ------------------
  |  Branch (38:32): [True: 175k, False: 163k]
  ------------------
   39|   175k|         z[i + j] = word_madd3(x[j], y_i, z[i + j], &carry);
   40|   175k|      }
   41|       |
   42|   163k|      z[x_size + i] = carry;
   43|   163k|   }
   44|  11.2k|}
_ZN5Botan10bigint_mulEPmmPKmmmS2_mmS0_m:
  292|   150k|                size_t ws_size) {
  293|   150k|   zeroize_buffer(z, z_size);
  294|       |
  295|   150k|   if(x_sw == 1) {
  ------------------
  |  Branch (295:7): [True: 0, False: 150k]
  ------------------
  296|      0|      bigint_linmul3(z, y, y_sw, x[0]);
  297|   150k|   } else if(y_sw == 1) {
  ------------------
  |  Branch (297:14): [True: 0, False: 150k]
  ------------------
  298|      0|      bigint_linmul3(z, x, x_sw, y[0]);
  299|   150k|   } else if(sized_for_comba_mul<4>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (299:14): [True: 16.6k, False: 133k]
  ------------------
  300|  16.6k|      bigint_comba_mul4(z, x, y);
  301|   133k|   } else if(sized_for_comba_mul<6>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (301:14): [True: 48, False: 133k]
  ------------------
  302|     48|      bigint_comba_mul6(z, x, y);
  303|   133k|   } else if(sized_for_comba_mul<8>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (303:14): [True: 0, False: 133k]
  ------------------
  304|      0|      bigint_comba_mul8(z, x, y);
  305|   133k|   } else if(sized_for_comba_mul<9>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (305:14): [True: 0, False: 133k]
  ------------------
  306|      0|      bigint_comba_mul9(z, x, y);
  307|   133k|   } else if(sized_for_comba_mul<16>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (307:14): [True: 122k, False: 11.0k]
  ------------------
  308|   122k|      bigint_comba_mul16(z, x, y);
  309|   122k|   } else if(sized_for_comba_mul<24>(x_sw, x_size, y_sw, y_size, z_size)) {
  ------------------
  |  Branch (309:14): [True: 0, False: 11.0k]
  ------------------
  310|      0|      bigint_comba_mul24(z, x, y);
  311|  11.0k|   } else if(x_sw < KARATSUBA_MULTIPLY_THRESHOLD || y_sw < KARATSUBA_MULTIPLY_THRESHOLD || workspace == nullptr) {
  ------------------
  |  Branch (311:14): [True: 10.8k, False: 167]
  |  Branch (311:53): [True: 0, False: 167]
  |  Branch (311:92): [True: 0, False: 167]
  ------------------
  312|  10.8k|      basecase_mul(z, z_size, x, x_sw, y, y_sw);
  313|  10.8k|   } else {
  314|    167|      const size_t N = karatsuba_size(z_size, x_size, x_sw, y_size, y_sw);
  315|       |
  316|    167|      if(N > 0 && z_size >= 2 * N && ws_size >= 2 * N) {
  ------------------
  |  Branch (316:10): [True: 167, False: 0]
  |  Branch (316:19): [True: 167, False: 0]
  |  Branch (316:38): [True: 167, False: 0]
  ------------------
  317|    167|         karatsuba_mul(z, x, y, N, workspace);
  318|    167|      } else {
  319|      0|         basecase_mul(z, z_size, x, x_sw, y, y_sw);
  320|      0|      }
  321|    167|   }
  322|   150k|}
_ZN5Botan10bigint_sqrEPmmPKmmmS0_m:
  327|   262k|void bigint_sqr(word z[], size_t z_size, const word x[], size_t x_size, size_t x_sw, word workspace[], size_t ws_size) {
  328|   262k|   zeroize_buffer(z, z_size);
  329|       |
  330|   262k|   BOTAN_ASSERT(z_size / 2 >= x_sw, "Output size is sufficient");
  ------------------
  |  |   64|   262k|   do {                                                                                 \
  |  |   65|   262k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|   262k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 262k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|   262k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 262k]
  |  |  ------------------
  ------------------
  331|       |
  332|   262k|   if(x_sw == 1) {
  ------------------
  |  Branch (332:7): [True: 0, False: 262k]
  ------------------
  333|      0|      bigint_linmul3(z, x, x_sw, x[0]);
  334|   262k|   } else if(sized_for_comba_sqr<4>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (334:14): [True: 9, False: 262k]
  ------------------
  335|      9|      bigint_comba_sqr4(z, x);
  336|   262k|   } else if(sized_for_comba_sqr<6>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (336:14): [True: 0, False: 262k]
  ------------------
  337|      0|      bigint_comba_sqr6(z, x);
  338|   262k|   } else if(sized_for_comba_sqr<8>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (338:14): [True: 0, False: 262k]
  ------------------
  339|      0|      bigint_comba_sqr8(z, x);
  340|   262k|   } else if(sized_for_comba_sqr<9>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (340:14): [True: 0, False: 262k]
  ------------------
  341|      0|      bigint_comba_sqr9(z, x);
  342|   262k|   } else if(sized_for_comba_sqr<16>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (342:14): [True: 262k, False: 291]
  ------------------
  343|   262k|      bigint_comba_sqr16(z, x);
  344|   262k|   } else if(sized_for_comba_sqr<24>(x_sw, x_size, z_size)) {
  ------------------
  |  Branch (344:14): [True: 0, False: 291]
  ------------------
  345|      0|      bigint_comba_sqr24(z, x);
  346|    291|   } else if(x_size < KARATSUBA_SQUARE_THRESHOLD || workspace == nullptr) {
  ------------------
  |  Branch (346:14): [True: 0, False: 291]
  |  Branch (346:53): [True: 0, False: 291]
  ------------------
  347|      0|      basecase_sqr(z, z_size, x, x_sw);
  348|    291|   } else {
  349|    291|      const size_t N = karatsuba_size(z_size, x_size, x_sw);
  350|       |
  351|    291|      if(N > 0 && z_size >= 2 * N && ws_size >= 2 * N) {
  ------------------
  |  Branch (351:10): [True: 291, False: 0]
  |  Branch (351:19): [True: 291, False: 0]
  |  Branch (351:38): [True: 291, False: 0]
  ------------------
  352|    291|         karatsuba_sqr(z, x, N, workspace);
  353|    291|      } else {
  354|      0|         basecase_sqr(z, z_size, x, x_sw);
  355|      0|      }
  356|    291|   }
  357|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_114karatsuba_sizeEmmmmm:
  203|    167|size_t karatsuba_size(size_t z_size, size_t x_size, size_t x_sw, size_t y_size, size_t y_sw) {
  204|    167|   if(x_sw > x_size || x_sw > y_size || y_sw > x_size || y_sw > y_size) {
  ------------------
  |  Branch (204:7): [True: 0, False: 167]
  |  Branch (204:24): [True: 0, False: 167]
  |  Branch (204:41): [True: 0, False: 167]
  |  Branch (204:58): [True: 0, False: 167]
  ------------------
  205|      0|      return 0;
  206|      0|   }
  207|       |
  208|    167|   if(((x_size == x_sw) && (x_size % 2 != 0)) || ((y_size == y_sw) && (y_size % 2 != 0))) {
  ------------------
  |  Branch (208:8): [True: 34, False: 133]
  |  Branch (208:28): [True: 0, False: 34]
  |  Branch (208:51): [True: 34, False: 133]
  |  Branch (208:71): [True: 0, False: 34]
  ------------------
  209|      0|      return 0;
  210|      0|   }
  211|       |
  212|    167|   const size_t start = (x_sw > y_sw) ? x_sw : y_sw;
  ------------------
  |  Branch (212:25): [True: 57, False: 110]
  ------------------
  213|    167|   const size_t end = (x_size < y_size) ? x_size : y_size;
  ------------------
  |  Branch (213:23): [True: 57, False: 110]
  ------------------
  214|       |
  215|    167|   if(start == end) {
  ------------------
  |  Branch (215:7): [True: 34, False: 133]
  ------------------
  216|     34|      if(start % 2 != 0) {
  ------------------
  |  Branch (216:10): [True: 0, False: 34]
  ------------------
  217|      0|         return 0;
  218|      0|      }
  219|     34|      return start;
  220|     34|   }
  221|       |
  222|    247|   for(size_t j = start; j <= end; ++j) {
  ------------------
  |  Branch (222:26): [True: 247, False: 0]
  ------------------
  223|    247|      if(j % 2 != 0) {
  ------------------
  |  Branch (223:10): [True: 114, False: 133]
  ------------------
  224|    114|         continue;
  225|    114|      }
  226|       |
  227|    133|      if(2 * j > z_size) {
  ------------------
  |  Branch (227:10): [True: 0, False: 133]
  ------------------
  228|      0|         return 0;
  229|      0|      }
  230|       |
  231|    133|      if(x_sw <= j && j <= x_size && y_sw <= j && j <= y_size) {
  ------------------
  |  Branch (231:10): [True: 133, False: 0]
  |  Branch (231:23): [True: 133, False: 0]
  |  Branch (231:38): [True: 133, False: 0]
  |  Branch (231:51): [True: 133, False: 0]
  ------------------
  232|    133|         if(j % 4 == 2 && (j + 2) <= x_size && (j + 2) <= y_size && 2 * (j + 2) <= z_size) {
  ------------------
  |  Branch (232:13): [True: 114, False: 19]
  |  Branch (232:27): [True: 57, False: 57]
  |  Branch (232:48): [True: 57, False: 0]
  |  Branch (232:69): [True: 0, False: 57]
  ------------------
  233|      0|            return j + 2;
  234|      0|         }
  235|    133|         return j;
  236|    133|      }
  237|    133|   }
  238|       |
  239|      0|   return 0;
  240|    133|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_113karatsuba_mulEPmPKmS3_mS1_:
   80|  1.14k|void karatsuba_mul(word z[], const word x[], const word y[], size_t N, word workspace[]) {
   81|  1.14k|   if(N < KARATSUBA_MULTIPLY_THRESHOLD || N % 2 != 0) {
  ------------------
  |  Branch (81:7): [True: 477, False: 668]
  |  Branch (81:43): [True: 342, False: 326]
  ------------------
   82|    819|      switch(N) {
   83|      0|         case 6:
  ------------------
  |  Branch (83:10): [True: 0, False: 819]
  ------------------
   84|      0|            return bigint_comba_mul6(z, x, y);
   85|      0|         case 8:
  ------------------
  |  Branch (85:10): [True: 0, False: 819]
  ------------------
   86|      0|            return bigint_comba_mul8(z, x, y);
   87|      0|         case 9:
  ------------------
  |  Branch (87:10): [True: 0, False: 819]
  ------------------
   88|      0|            return bigint_comba_mul9(z, x, y);
   89|    477|         case 16:
  ------------------
  |  Branch (89:10): [True: 477, False: 342]
  ------------------
   90|    477|            return bigint_comba_mul16(z, x, y);
   91|      0|         case 24:
  ------------------
  |  Branch (91:10): [True: 0, False: 819]
  ------------------
   92|      0|            return bigint_comba_mul24(z, x, y);
   93|    342|         default:
  ------------------
  |  Branch (93:10): [True: 342, False: 477]
  ------------------
   94|    342|            return basecase_mul(z, 2 * N, x, N, y, N);
   95|    819|      }
   96|    819|   }
   97|       |
   98|    326|   const size_t N2 = N / 2;
   99|       |
  100|    326|   const word* x0 = x;
  101|    326|   const word* x1 = x + N2;
  102|    326|   const word* y0 = y;
  103|    326|   const word* y1 = y + N2;
  104|    326|   word* z0 = z;
  105|    326|   word* z1 = z + N;
  106|       |
  107|    326|   word* ws0 = workspace;
  108|    326|   word* ws1 = workspace + N;
  109|       |
  110|    326|   zeroize_buffer(workspace, 2 * N);
  111|       |
  112|       |   /*
  113|       |   * If either of cmp0 or cmp1 is zero then z0 or z1 resp is zero here,
  114|       |   * resulting in a no-op - z0*z1 will be equal to zero so we don't need to do
  115|       |   * anything, zeroize_buffer above already set the correct result.
  116|       |   *
  117|       |   * However we ignore the result of the comparisons and always perform the
  118|       |   * subtractions and recursively multiply to avoid the timing channel.
  119|       |   */
  120|       |
  121|       |   // First compute (X_lo - X_hi)*(Y_hi - Y_lo)
  122|    326|   const auto cmp0 = bigint_sub_abs(z0, x0, x1, N2, workspace);
  123|    326|   const auto cmp1 = bigint_sub_abs(z1, y1, y0, N2, workspace);
  124|    326|   const auto neg_mask = ~(cmp0 ^ cmp1);
  125|       |
  126|    326|   karatsuba_mul(ws0, z0, z1, N2, ws1);
  127|       |
  128|       |   // Compute X_lo * Y_lo
  129|    326|   karatsuba_mul(z0, x0, y0, N2, ws1);
  130|       |
  131|       |   // Compute X_hi * Y_hi
  132|    326|   karatsuba_mul(z1, x1, y1, N2, ws1);
  133|       |
  134|    326|   const word ws_carry = bigint_add3(ws1, z0, N, z1, N);
  135|    326|   word z_carry = bigint_add2(z + N2, N, ws1, N);
  136|       |
  137|    326|   z_carry += bigint_add2(z + N + N2, N2, &ws_carry, 1);
  138|    326|   bigint_add2(z + N + N2, N2, &z_carry, 1);
  139|       |
  140|    326|   zeroize_buffer(workspace + N, N2);
  141|       |
  142|    326|   bigint_cnd_add(neg_mask.value(), z + N2, workspace, 2 * N - N2);
  143|    326|   bigint_cnd_sub((~neg_mask).value(), z + N2, workspace, 2 * N - N2);
  144|    326|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_114karatsuba_sizeEmmm:
  245|    291|size_t karatsuba_size(size_t z_size, size_t x_size, size_t x_sw) {
  246|    291|   if(x_sw == x_size) {
  ------------------
  |  Branch (246:7): [True: 272, False: 19]
  ------------------
  247|    272|      if(x_sw % 2 != 0) {
  ------------------
  |  Branch (247:10): [True: 0, False: 272]
  ------------------
  248|      0|         return 0;
  249|      0|      }
  250|    272|      return x_sw;
  251|    272|   }
  252|       |
  253|     19|   for(size_t j = x_sw; j <= x_size; ++j) {
  ------------------
  |  Branch (253:25): [True: 19, False: 0]
  ------------------
  254|     19|      if(j % 2 != 0) {
  ------------------
  |  Branch (254:10): [True: 0, False: 19]
  ------------------
  255|      0|         continue;
  256|      0|      }
  257|       |
  258|     19|      if(2 * j > z_size) {
  ------------------
  |  Branch (258:10): [True: 0, False: 19]
  ------------------
  259|      0|         return 0;
  260|      0|      }
  261|       |
  262|     19|      if(j % 4 == 2 && (j + 2) <= x_size && 2 * (j + 2) <= z_size) {
  ------------------
  |  Branch (262:10): [True: 0, False: 19]
  |  Branch (262:24): [True: 0, False: 0]
  |  Branch (262:45): [True: 0, False: 0]
  ------------------
  263|      0|         return j + 2;
  264|      0|      }
  265|     19|      return j;
  266|     19|   }
  267|       |
  268|      0|   return 0;
  269|     19|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_113karatsuba_sqrEPmPKmmS1_:
  149|  3.78k|void karatsuba_sqr(word z[], const word x[], size_t N, word workspace[]) {
  150|  3.78k|   if(N < KARATSUBA_SQUARE_THRESHOLD || N % 2 != 0) {
  ------------------
  |  Branch (150:7): [True: 2.61k, False: 1.16k]
  |  Branch (150:41): [True: 0, False: 1.16k]
  ------------------
  151|  2.61k|      switch(N) {
  152|      0|         case 6:
  ------------------
  |  Branch (152:10): [True: 0, False: 2.61k]
  ------------------
  153|      0|            return bigint_comba_sqr6(z, x);
  154|      0|         case 8:
  ------------------
  |  Branch (154:10): [True: 0, False: 2.61k]
  ------------------
  155|      0|            return bigint_comba_sqr8(z, x);
  156|      0|         case 9:
  ------------------
  |  Branch (156:10): [True: 0, False: 2.61k]
  ------------------
  157|      0|            return bigint_comba_sqr9(z, x);
  158|  2.61k|         case 16:
  ------------------
  |  Branch (158:10): [True: 2.61k, False: 0]
  ------------------
  159|  2.61k|            return bigint_comba_sqr16(z, x);
  160|      0|         case 24:
  ------------------
  |  Branch (160:10): [True: 0, False: 2.61k]
  ------------------
  161|      0|            return bigint_comba_sqr24(z, x);
  162|      0|         default:
  ------------------
  |  Branch (162:10): [True: 0, False: 2.61k]
  ------------------
  163|      0|            return basecase_sqr(z, 2 * N, x, N);
  164|  2.61k|      }
  165|  2.61k|   }
  166|       |
  167|  1.16k|   const size_t N2 = N / 2;
  168|       |
  169|  1.16k|   const word* x0 = x;
  170|  1.16k|   const word* x1 = x + N2;
  171|  1.16k|   word* z0 = z;
  172|  1.16k|   word* z1 = z + N;
  173|       |
  174|  1.16k|   word* ws0 = workspace;
  175|  1.16k|   word* ws1 = workspace + N;
  176|       |
  177|  1.16k|   zeroize_buffer(workspace, 2 * N);
  178|       |
  179|       |   // See comment in karatsuba_mul
  180|  1.16k|   bigint_sub_abs(z0, x0, x1, N2, workspace);
  181|  1.16k|   karatsuba_sqr(ws0, z0, N2, ws1);
  182|       |
  183|  1.16k|   karatsuba_sqr(z0, x0, N2, ws1);
  184|  1.16k|   karatsuba_sqr(z1, x1, N2, ws1);
  185|       |
  186|  1.16k|   const word ws_carry = bigint_add3(ws1, z0, N, z1, N);
  187|  1.16k|   word z_carry = bigint_add2(z + N2, N, ws1, N);
  188|       |
  189|  1.16k|   z_carry += bigint_add2(z + N + N2, N2, &ws_carry, 1);
  190|  1.16k|   bigint_add2(z + N + N2, N2, &z_carry, 1);
  191|       |
  192|       |   /*
  193|       |   * This is only actually required if cmp (result of bigint_sub_abs) is != 0,
  194|       |   * however if cmp==0 then ws0[0:N] == 0 and avoiding the jump hides a
  195|       |   * timing channel.
  196|       |   */
  197|  1.16k|   bigint_sub2(z + N2, 2 * N - N2, ws0, N);
  198|  1.16k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm4EEEbmmmmm:
  272|   150k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|   150k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 18.6k, False: 131k]
  |  Branch (273:26): [True: 18.6k, False: 0]
  |  Branch (273:42): [True: 18.6k, False: 0]
  |  Branch (273:56): [True: 18.6k, False: 0]
  |  Branch (273:72): [True: 16.6k, False: 2.05k]
  ------------------
  274|   150k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm6EEEbmmmmm:
  272|   133k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|   133k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 2.10k, False: 131k]
  |  Branch (273:26): [True: 2.10k, False: 0]
  |  Branch (273:42): [True: 2.10k, False: 0]
  |  Branch (273:56): [True: 2.10k, False: 0]
  |  Branch (273:72): [True: 48, False: 2.05k]
  ------------------
  274|   133k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm8EEEbmmmmm:
  272|   133k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|   133k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 2.05k, False: 131k]
  |  Branch (273:26): [True: 2.05k, False: 0]
  |  Branch (273:42): [True: 2.05k, False: 0]
  |  Branch (273:56): [True: 2.05k, False: 0]
  |  Branch (273:72): [True: 0, False: 2.05k]
  ------------------
  274|   133k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm9EEEbmmmmm:
  272|   133k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|   133k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 2.05k, False: 131k]
  |  Branch (273:26): [True: 2.05k, False: 0]
  |  Branch (273:42): [True: 2.05k, False: 0]
  |  Branch (273:56): [True: 0, False: 2.05k]
  |  Branch (273:72): [True: 0, False: 0]
  ------------------
  274|   133k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm16EEEbmmmmm:
  272|   133k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|   133k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 124k, False: 8.99k]
  |  Branch (273:26): [True: 122k, False: 2.05k]
  |  Branch (273:42): [True: 122k, False: 0]
  |  Branch (273:56): [True: 122k, False: 0]
  |  Branch (273:72): [True: 122k, False: 0]
  ------------------
  274|   133k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_mulILm24EEEbmmmmm:
  272|  11.0k|inline bool sized_for_comba_mul(size_t x_sw, size_t x_size, size_t y_sw, size_t y_size, size_t z_size) {
  273|  11.0k|   return (x_sw <= SZ && x_size >= SZ && y_sw <= SZ && y_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (273:12): [True: 10.8k, False: 167]
  |  Branch (273:26): [True: 4.41k, False: 6.46k]
  |  Branch (273:42): [True: 4.41k, False: 0]
  |  Branch (273:56): [True: 4.41k, False: 0]
  |  Branch (273:72): [True: 0, False: 4.41k]
  ------------------
  274|  11.0k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm4EEEbmmm:
  277|   262k|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|   262k|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 9, False: 262k]
  |  Branch (278:26): [True: 9, False: 0]
  |  Branch (278:42): [True: 9, False: 0]
  ------------------
  279|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm6EEEbmmm:
  277|   262k|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|   262k|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 0, False: 262k]
  |  Branch (278:26): [True: 0, False: 0]
  |  Branch (278:42): [True: 0, False: 0]
  ------------------
  279|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm8EEEbmmm:
  277|   262k|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|   262k|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 0, False: 262k]
  |  Branch (278:26): [True: 0, False: 0]
  |  Branch (278:42): [True: 0, False: 0]
  ------------------
  279|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm9EEEbmmm:
  277|   262k|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|   262k|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 0, False: 262k]
  |  Branch (278:26): [True: 0, False: 0]
  |  Branch (278:42): [True: 0, False: 0]
  ------------------
  279|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm16EEEbmmm:
  277|   262k|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|   262k|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 262k, False: 291]
  |  Branch (278:26): [True: 262k, False: 0]
  |  Branch (278:42): [True: 262k, False: 0]
  ------------------
  279|   262k|}
mp_karat.cpp:_ZN5Botan12_GLOBAL__N_119sized_for_comba_sqrILm24EEEbmmm:
  277|    291|inline bool sized_for_comba_sqr(size_t x_sw, size_t x_size, size_t z_size) {
  278|    291|   return (x_sw <= SZ && x_size >= SZ && z_size >= 2 * SZ);
  ------------------
  |  Branch (278:12): [True: 0, False: 291]
  |  Branch (278:26): [True: 0, False: 0]
  |  Branch (278:42): [True: 0, False: 0]
  ------------------
  279|    291|}

_ZN5Botan25bigint_monty_redc_genericEPmPKmmS2_mmS0_:
   91|    323|   word r[], const word z[], size_t z_size, const word p[], size_t p_size, word p_dash, word ws[]) {
   92|    323|   BOTAN_ARG_CHECK(z_size >= 2 * p_size && p_size > 0, "Invalid sizes for bigint_monty_redc_generic");
  ------------------
  |  |   35|    323|   do {                                                          \
  |  |   36|    323|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    646|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 323, False: 0]
  |  |  |  Branch (37:12): [True: 323, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    323|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 323]
  |  |  ------------------
  ------------------
   93|       |
   94|    323|   word3<word> accum;
   95|       |
   96|    323|   accum.add(z[0]);
   97|       |
   98|    323|   ws[0] = accum.monty_step(p[0], p_dash);
   99|       |
  100|  20.6k|   for(size_t i = 1; i != p_size; ++i) {
  ------------------
  |  Branch (100:22): [True: 20.3k, False: 323]
  ------------------
  101|  20.3k|      mul_rev_range(accum, ws, p, i);
  102|  20.3k|      accum.add(z[i]);
  103|  20.3k|      ws[i] = accum.monty_step(p[0], p_dash);
  104|  20.3k|   }
  105|       |
  106|  20.6k|   for(size_t i = 0; i != p_size - 1; ++i) {
  ------------------
  |  Branch (106:22): [True: 20.3k, False: 323]
  ------------------
  107|  20.3k|      mul_rev_range(accum, &ws[i + 1], &p[i], p_size - (i + 1));
  108|  20.3k|      accum.add(z[p_size + i]);
  109|  20.3k|      ws[i] = accum.extract();
  110|  20.3k|   }
  111|       |
  112|    323|   accum.add(z[2 * p_size - 1]);
  113|       |
  114|    323|   ws[p_size - 1] = accum.extract();
  115|       |   // w1 is the final part, which is not stored in the workspace
  116|    323|   const word w1 = accum.extract();
  117|       |
  118|       |   /*
  119|       |   * The result might need to be reduced mod p. To avoid a timing
  120|       |   * channel, always perform the subtraction. If in the computation
  121|       |   * of x - p a borrow is required then x was already < p.
  122|       |   *
  123|       |   * x starts at ws[0] and is p_size bytes long plus a possible high
  124|       |   * digit left over in w1.
  125|       |   *
  126|       |   * x - p starts at z[0] and is also p_size bytes long
  127|       |   *
  128|       |   * If borrow was set after the subtraction, then x was already less
  129|       |   * than p and the subtraction was not needed. In that case overwrite
  130|       |   * z[0:p_size] with the original x in ws[0:p_size].
  131|       |   *
  132|       |   * We only copy out p_size in the final step because we know
  133|       |   * the Montgomery result is < P
  134|       |   */
  135|       |
  136|    323|   bigint_monty_maybe_sub(p_size, r, w1, ws, p);
  137|    323|}
mp_monty.cpp:_ZN5Botan12_GLOBAL__N_113mul_rev_rangeERNS_5word3ImEEPKmS5_m:
   18|  40.6k|BOTAN_FORCE_INLINE void mul_rev_range(word3<word>& accum, const word ws[], const word p[], size_t bound) {
   19|       |   /*
   20|       |   Unrolled version of:
   21|       |
   22|       |   for(size_t i = 0; i < bound; ++i) {
   23|       |      accum.mul(ws[i], p[bound - i]);
   24|       |   }
   25|       |   */
   26|       |
   27|  40.6k|   size_t lower = 0;
   28|   185k|   while(lower < bound) {
  ------------------
  |  Branch (28:10): [True: 144k, False: 40.6k]
  ------------------
   29|   144k|      const size_t upper = bound - lower;
   30|       |
   31|   144k|      if(upper >= 16) {
  ------------------
  |  Branch (31:10): [True: 62.0k, False: 82.6k]
  ------------------
   32|  62.0k|         accum.mul(ws[lower], p[upper]);
   33|  62.0k|         accum.mul(ws[lower + 1], p[upper - 1]);
   34|  62.0k|         accum.mul(ws[lower + 2], p[upper - 2]);
   35|  62.0k|         accum.mul(ws[lower + 3], p[upper - 3]);
   36|  62.0k|         accum.mul(ws[lower + 4], p[upper - 4]);
   37|  62.0k|         accum.mul(ws[lower + 5], p[upper - 5]);
   38|  62.0k|         accum.mul(ws[lower + 6], p[upper - 6]);
   39|  62.0k|         accum.mul(ws[lower + 7], p[upper - 7]);
   40|  62.0k|         accum.mul(ws[lower + 8], p[upper - 8]);
   41|  62.0k|         accum.mul(ws[lower + 9], p[upper - 9]);
   42|  62.0k|         accum.mul(ws[lower + 10], p[upper - 10]);
   43|  62.0k|         accum.mul(ws[lower + 11], p[upper - 11]);
   44|  62.0k|         accum.mul(ws[lower + 12], p[upper - 12]);
   45|  62.0k|         accum.mul(ws[lower + 13], p[upper - 13]);
   46|  62.0k|         accum.mul(ws[lower + 14], p[upper - 14]);
   47|  62.0k|         accum.mul(ws[lower + 15], p[upper - 15]);
   48|  62.0k|         lower += 16;
   49|  82.6k|      } else if(upper >= 8) {
  ------------------
  |  Branch (49:17): [True: 20.6k, False: 62.0k]
  ------------------
   50|  20.6k|         accum.mul(ws[lower], p[upper]);
   51|  20.6k|         accum.mul(ws[lower + 1], p[upper - 1]);
   52|  20.6k|         accum.mul(ws[lower + 2], p[upper - 2]);
   53|  20.6k|         accum.mul(ws[lower + 3], p[upper - 3]);
   54|  20.6k|         accum.mul(ws[lower + 4], p[upper - 4]);
   55|  20.6k|         accum.mul(ws[lower + 5], p[upper - 5]);
   56|  20.6k|         accum.mul(ws[lower + 6], p[upper - 6]);
   57|  20.6k|         accum.mul(ws[lower + 7], p[upper - 7]);
   58|  20.6k|         lower += 8;
   59|  62.0k|      } else if(upper >= 4) {
  ------------------
  |  Branch (59:17): [True: 20.6k, False: 41.3k]
  ------------------
   60|  20.6k|         accum.mul(ws[lower], p[upper]);
   61|  20.6k|         accum.mul(ws[lower + 1], p[upper - 1]);
   62|  20.6k|         accum.mul(ws[lower + 2], p[upper - 2]);
   63|  20.6k|         accum.mul(ws[lower + 3], p[upper - 3]);
   64|  20.6k|         lower += 4;
   65|  41.3k|      } else if(upper >= 2) {
  ------------------
  |  Branch (65:17): [True: 20.6k, False: 20.6k]
  ------------------
   66|  20.6k|         accum.mul(ws[lower], p[upper]);
   67|  20.6k|         accum.mul(ws[lower + 1], p[upper - 1]);
   68|  20.6k|         lower += 2;
   69|  20.6k|      } else {
   70|  20.6k|         accum.mul(ws[lower], p[upper]);
   71|  20.6k|         lower += 1;
   72|  20.6k|      }
   73|   144k|   }
   74|  40.6k|}

_ZN5Botan19bigint_monty_redc_4EPmPKmS2_mS0_:
   12|  80.5k|void bigint_monty_redc_4(word r[4], const word z[8], const word p[4], word p_dash, word ws[4]) {
   13|  80.5k|   word3<word> accum;
   14|  80.5k|   accum.add(z[0]);
   15|  80.5k|   ws[0] = accum.monty_step(p[0], p_dash);
   16|  80.5k|   accum.mul(ws[0], p[1]);
   17|  80.5k|   accum.add(z[1]);
   18|  80.5k|   ws[1] = accum.monty_step(p[0], p_dash);
   19|  80.5k|   accum.mul(ws[0], p[2]);
   20|  80.5k|   accum.mul(ws[1], p[1]);
   21|  80.5k|   accum.add(z[2]);
   22|  80.5k|   ws[2] = accum.monty_step(p[0], p_dash);
   23|  80.5k|   accum.mul(ws[0], p[3]);
   24|  80.5k|   accum.mul(ws[1], p[2]);
   25|  80.5k|   accum.mul(ws[2], p[1]);
   26|  80.5k|   accum.add(z[3]);
   27|  80.5k|   ws[3] = accum.monty_step(p[0], p_dash);
   28|  80.5k|   accum.mul(ws[1], p[3]);
   29|  80.5k|   accum.mul(ws[2], p[2]);
   30|  80.5k|   accum.mul(ws[3], p[1]);
   31|  80.5k|   accum.add(z[4]);
   32|  80.5k|   ws[0] = accum.extract();
   33|  80.5k|   accum.mul(ws[2], p[3]);
   34|  80.5k|   accum.mul(ws[3], p[2]);
   35|  80.5k|   accum.add(z[5]);
   36|  80.5k|   ws[1] = accum.extract();
   37|  80.5k|   accum.mul(ws[3], p[3]);
   38|  80.5k|   accum.add(z[6]);
   39|  80.5k|   ws[2] = accum.extract();
   40|  80.5k|   accum.add(z[7]);
   41|  80.5k|   ws[3] = accum.extract();
   42|  80.5k|   const word w1 = accum.extract();
   43|  80.5k|   bigint_monty_maybe_sub<4>(r, w1, ws, p);
   44|  80.5k|}
_ZN5Botan20bigint_monty_redc_16EPmPKmS2_mS0_:
  386|   382k|void bigint_monty_redc_16(word r[16], const word z[32], const word p[16], word p_dash, word ws[16]) {
  387|   382k|   word3<word> accum;
  388|   382k|   accum.add(z[0]);
  389|   382k|   ws[0] = accum.monty_step(p[0], p_dash);
  390|   382k|   accum.mul(ws[0], p[1]);
  391|   382k|   accum.add(z[1]);
  392|   382k|   ws[1] = accum.monty_step(p[0], p_dash);
  393|   382k|   accum.mul(ws[0], p[2]);
  394|   382k|   accum.mul(ws[1], p[1]);
  395|   382k|   accum.add(z[2]);
  396|   382k|   ws[2] = accum.monty_step(p[0], p_dash);
  397|   382k|   accum.mul(ws[0], p[3]);
  398|   382k|   accum.mul(ws[1], p[2]);
  399|   382k|   accum.mul(ws[2], p[1]);
  400|   382k|   accum.add(z[3]);
  401|   382k|   ws[3] = accum.monty_step(p[0], p_dash);
  402|   382k|   accum.mul(ws[0], p[4]);
  403|   382k|   accum.mul(ws[1], p[3]);
  404|   382k|   accum.mul(ws[2], p[2]);
  405|   382k|   accum.mul(ws[3], p[1]);
  406|   382k|   accum.add(z[4]);
  407|   382k|   ws[4] = accum.monty_step(p[0], p_dash);
  408|   382k|   accum.mul(ws[0], p[5]);
  409|   382k|   accum.mul(ws[1], p[4]);
  410|   382k|   accum.mul(ws[2], p[3]);
  411|   382k|   accum.mul(ws[3], p[2]);
  412|   382k|   accum.mul(ws[4], p[1]);
  413|   382k|   accum.add(z[5]);
  414|   382k|   ws[5] = accum.monty_step(p[0], p_dash);
  415|   382k|   accum.mul(ws[0], p[6]);
  416|   382k|   accum.mul(ws[1], p[5]);
  417|   382k|   accum.mul(ws[2], p[4]);
  418|   382k|   accum.mul(ws[3], p[3]);
  419|   382k|   accum.mul(ws[4], p[2]);
  420|   382k|   accum.mul(ws[5], p[1]);
  421|   382k|   accum.add(z[6]);
  422|   382k|   ws[6] = accum.monty_step(p[0], p_dash);
  423|   382k|   accum.mul(ws[0], p[7]);
  424|   382k|   accum.mul(ws[1], p[6]);
  425|   382k|   accum.mul(ws[2], p[5]);
  426|   382k|   accum.mul(ws[3], p[4]);
  427|   382k|   accum.mul(ws[4], p[3]);
  428|   382k|   accum.mul(ws[5], p[2]);
  429|   382k|   accum.mul(ws[6], p[1]);
  430|   382k|   accum.add(z[7]);
  431|   382k|   ws[7] = accum.monty_step(p[0], p_dash);
  432|   382k|   accum.mul(ws[0], p[8]);
  433|   382k|   accum.mul(ws[1], p[7]);
  434|   382k|   accum.mul(ws[2], p[6]);
  435|   382k|   accum.mul(ws[3], p[5]);
  436|   382k|   accum.mul(ws[4], p[4]);
  437|   382k|   accum.mul(ws[5], p[3]);
  438|   382k|   accum.mul(ws[6], p[2]);
  439|   382k|   accum.mul(ws[7], p[1]);
  440|   382k|   accum.add(z[8]);
  441|   382k|   ws[8] = accum.monty_step(p[0], p_dash);
  442|   382k|   accum.mul(ws[0], p[9]);
  443|   382k|   accum.mul(ws[1], p[8]);
  444|   382k|   accum.mul(ws[2], p[7]);
  445|   382k|   accum.mul(ws[3], p[6]);
  446|   382k|   accum.mul(ws[4], p[5]);
  447|   382k|   accum.mul(ws[5], p[4]);
  448|   382k|   accum.mul(ws[6], p[3]);
  449|   382k|   accum.mul(ws[7], p[2]);
  450|   382k|   accum.mul(ws[8], p[1]);
  451|   382k|   accum.add(z[9]);
  452|   382k|   ws[9] = accum.monty_step(p[0], p_dash);
  453|   382k|   accum.mul(ws[0], p[10]);
  454|   382k|   accum.mul(ws[1], p[9]);
  455|   382k|   accum.mul(ws[2], p[8]);
  456|   382k|   accum.mul(ws[3], p[7]);
  457|   382k|   accum.mul(ws[4], p[6]);
  458|   382k|   accum.mul(ws[5], p[5]);
  459|   382k|   accum.mul(ws[6], p[4]);
  460|   382k|   accum.mul(ws[7], p[3]);
  461|   382k|   accum.mul(ws[8], p[2]);
  462|   382k|   accum.mul(ws[9], p[1]);
  463|   382k|   accum.add(z[10]);
  464|   382k|   ws[10] = accum.monty_step(p[0], p_dash);
  465|   382k|   accum.mul(ws[0], p[11]);
  466|   382k|   accum.mul(ws[1], p[10]);
  467|   382k|   accum.mul(ws[2], p[9]);
  468|   382k|   accum.mul(ws[3], p[8]);
  469|   382k|   accum.mul(ws[4], p[7]);
  470|   382k|   accum.mul(ws[5], p[6]);
  471|   382k|   accum.mul(ws[6], p[5]);
  472|   382k|   accum.mul(ws[7], p[4]);
  473|   382k|   accum.mul(ws[8], p[3]);
  474|   382k|   accum.mul(ws[9], p[2]);
  475|   382k|   accum.mul(ws[10], p[1]);
  476|   382k|   accum.add(z[11]);
  477|   382k|   ws[11] = accum.monty_step(p[0], p_dash);
  478|   382k|   accum.mul(ws[0], p[12]);
  479|   382k|   accum.mul(ws[1], p[11]);
  480|   382k|   accum.mul(ws[2], p[10]);
  481|   382k|   accum.mul(ws[3], p[9]);
  482|   382k|   accum.mul(ws[4], p[8]);
  483|   382k|   accum.mul(ws[5], p[7]);
  484|   382k|   accum.mul(ws[6], p[6]);
  485|   382k|   accum.mul(ws[7], p[5]);
  486|   382k|   accum.mul(ws[8], p[4]);
  487|   382k|   accum.mul(ws[9], p[3]);
  488|   382k|   accum.mul(ws[10], p[2]);
  489|   382k|   accum.mul(ws[11], p[1]);
  490|   382k|   accum.add(z[12]);
  491|   382k|   ws[12] = accum.monty_step(p[0], p_dash);
  492|   382k|   accum.mul(ws[0], p[13]);
  493|   382k|   accum.mul(ws[1], p[12]);
  494|   382k|   accum.mul(ws[2], p[11]);
  495|   382k|   accum.mul(ws[3], p[10]);
  496|   382k|   accum.mul(ws[4], p[9]);
  497|   382k|   accum.mul(ws[5], p[8]);
  498|   382k|   accum.mul(ws[6], p[7]);
  499|   382k|   accum.mul(ws[7], p[6]);
  500|   382k|   accum.mul(ws[8], p[5]);
  501|   382k|   accum.mul(ws[9], p[4]);
  502|   382k|   accum.mul(ws[10], p[3]);
  503|   382k|   accum.mul(ws[11], p[2]);
  504|   382k|   accum.mul(ws[12], p[1]);
  505|   382k|   accum.add(z[13]);
  506|   382k|   ws[13] = accum.monty_step(p[0], p_dash);
  507|   382k|   accum.mul(ws[0], p[14]);
  508|   382k|   accum.mul(ws[1], p[13]);
  509|   382k|   accum.mul(ws[2], p[12]);
  510|   382k|   accum.mul(ws[3], p[11]);
  511|   382k|   accum.mul(ws[4], p[10]);
  512|   382k|   accum.mul(ws[5], p[9]);
  513|   382k|   accum.mul(ws[6], p[8]);
  514|   382k|   accum.mul(ws[7], p[7]);
  515|   382k|   accum.mul(ws[8], p[6]);
  516|   382k|   accum.mul(ws[9], p[5]);
  517|   382k|   accum.mul(ws[10], p[4]);
  518|   382k|   accum.mul(ws[11], p[3]);
  519|   382k|   accum.mul(ws[12], p[2]);
  520|   382k|   accum.mul(ws[13], p[1]);
  521|   382k|   accum.add(z[14]);
  522|   382k|   ws[14] = accum.monty_step(p[0], p_dash);
  523|   382k|   accum.mul(ws[0], p[15]);
  524|   382k|   accum.mul(ws[1], p[14]);
  525|   382k|   accum.mul(ws[2], p[13]);
  526|   382k|   accum.mul(ws[3], p[12]);
  527|   382k|   accum.mul(ws[4], p[11]);
  528|   382k|   accum.mul(ws[5], p[10]);
  529|   382k|   accum.mul(ws[6], p[9]);
  530|   382k|   accum.mul(ws[7], p[8]);
  531|   382k|   accum.mul(ws[8], p[7]);
  532|   382k|   accum.mul(ws[9], p[6]);
  533|   382k|   accum.mul(ws[10], p[5]);
  534|   382k|   accum.mul(ws[11], p[4]);
  535|   382k|   accum.mul(ws[12], p[3]);
  536|   382k|   accum.mul(ws[13], p[2]);
  537|   382k|   accum.mul(ws[14], p[1]);
  538|   382k|   accum.add(z[15]);
  539|   382k|   ws[15] = accum.monty_step(p[0], p_dash);
  540|   382k|   accum.mul(ws[1], p[15]);
  541|   382k|   accum.mul(ws[2], p[14]);
  542|   382k|   accum.mul(ws[3], p[13]);
  543|   382k|   accum.mul(ws[4], p[12]);
  544|   382k|   accum.mul(ws[5], p[11]);
  545|   382k|   accum.mul(ws[6], p[10]);
  546|   382k|   accum.mul(ws[7], p[9]);
  547|   382k|   accum.mul(ws[8], p[8]);
  548|   382k|   accum.mul(ws[9], p[7]);
  549|   382k|   accum.mul(ws[10], p[6]);
  550|   382k|   accum.mul(ws[11], p[5]);
  551|   382k|   accum.mul(ws[12], p[4]);
  552|   382k|   accum.mul(ws[13], p[3]);
  553|   382k|   accum.mul(ws[14], p[2]);
  554|   382k|   accum.mul(ws[15], p[1]);
  555|   382k|   accum.add(z[16]);
  556|   382k|   ws[0] = accum.extract();
  557|   382k|   accum.mul(ws[2], p[15]);
  558|   382k|   accum.mul(ws[3], p[14]);
  559|   382k|   accum.mul(ws[4], p[13]);
  560|   382k|   accum.mul(ws[5], p[12]);
  561|   382k|   accum.mul(ws[6], p[11]);
  562|   382k|   accum.mul(ws[7], p[10]);
  563|   382k|   accum.mul(ws[8], p[9]);
  564|   382k|   accum.mul(ws[9], p[8]);
  565|   382k|   accum.mul(ws[10], p[7]);
  566|   382k|   accum.mul(ws[11], p[6]);
  567|   382k|   accum.mul(ws[12], p[5]);
  568|   382k|   accum.mul(ws[13], p[4]);
  569|   382k|   accum.mul(ws[14], p[3]);
  570|   382k|   accum.mul(ws[15], p[2]);
  571|   382k|   accum.add(z[17]);
  572|   382k|   ws[1] = accum.extract();
  573|   382k|   accum.mul(ws[3], p[15]);
  574|   382k|   accum.mul(ws[4], p[14]);
  575|   382k|   accum.mul(ws[5], p[13]);
  576|   382k|   accum.mul(ws[6], p[12]);
  577|   382k|   accum.mul(ws[7], p[11]);
  578|   382k|   accum.mul(ws[8], p[10]);
  579|   382k|   accum.mul(ws[9], p[9]);
  580|   382k|   accum.mul(ws[10], p[8]);
  581|   382k|   accum.mul(ws[11], p[7]);
  582|   382k|   accum.mul(ws[12], p[6]);
  583|   382k|   accum.mul(ws[13], p[5]);
  584|   382k|   accum.mul(ws[14], p[4]);
  585|   382k|   accum.mul(ws[15], p[3]);
  586|   382k|   accum.add(z[18]);
  587|   382k|   ws[2] = accum.extract();
  588|   382k|   accum.mul(ws[4], p[15]);
  589|   382k|   accum.mul(ws[5], p[14]);
  590|   382k|   accum.mul(ws[6], p[13]);
  591|   382k|   accum.mul(ws[7], p[12]);
  592|   382k|   accum.mul(ws[8], p[11]);
  593|   382k|   accum.mul(ws[9], p[10]);
  594|   382k|   accum.mul(ws[10], p[9]);
  595|   382k|   accum.mul(ws[11], p[8]);
  596|   382k|   accum.mul(ws[12], p[7]);
  597|   382k|   accum.mul(ws[13], p[6]);
  598|   382k|   accum.mul(ws[14], p[5]);
  599|   382k|   accum.mul(ws[15], p[4]);
  600|   382k|   accum.add(z[19]);
  601|   382k|   ws[3] = accum.extract();
  602|   382k|   accum.mul(ws[5], p[15]);
  603|   382k|   accum.mul(ws[6], p[14]);
  604|   382k|   accum.mul(ws[7], p[13]);
  605|   382k|   accum.mul(ws[8], p[12]);
  606|   382k|   accum.mul(ws[9], p[11]);
  607|   382k|   accum.mul(ws[10], p[10]);
  608|   382k|   accum.mul(ws[11], p[9]);
  609|   382k|   accum.mul(ws[12], p[8]);
  610|   382k|   accum.mul(ws[13], p[7]);
  611|   382k|   accum.mul(ws[14], p[6]);
  612|   382k|   accum.mul(ws[15], p[5]);
  613|   382k|   accum.add(z[20]);
  614|   382k|   ws[4] = accum.extract();
  615|   382k|   accum.mul(ws[6], p[15]);
  616|   382k|   accum.mul(ws[7], p[14]);
  617|   382k|   accum.mul(ws[8], p[13]);
  618|   382k|   accum.mul(ws[9], p[12]);
  619|   382k|   accum.mul(ws[10], p[11]);
  620|   382k|   accum.mul(ws[11], p[10]);
  621|   382k|   accum.mul(ws[12], p[9]);
  622|   382k|   accum.mul(ws[13], p[8]);
  623|   382k|   accum.mul(ws[14], p[7]);
  624|   382k|   accum.mul(ws[15], p[6]);
  625|   382k|   accum.add(z[21]);
  626|   382k|   ws[5] = accum.extract();
  627|   382k|   accum.mul(ws[7], p[15]);
  628|   382k|   accum.mul(ws[8], p[14]);
  629|   382k|   accum.mul(ws[9], p[13]);
  630|   382k|   accum.mul(ws[10], p[12]);
  631|   382k|   accum.mul(ws[11], p[11]);
  632|   382k|   accum.mul(ws[12], p[10]);
  633|   382k|   accum.mul(ws[13], p[9]);
  634|   382k|   accum.mul(ws[14], p[8]);
  635|   382k|   accum.mul(ws[15], p[7]);
  636|   382k|   accum.add(z[22]);
  637|   382k|   ws[6] = accum.extract();
  638|   382k|   accum.mul(ws[8], p[15]);
  639|   382k|   accum.mul(ws[9], p[14]);
  640|   382k|   accum.mul(ws[10], p[13]);
  641|   382k|   accum.mul(ws[11], p[12]);
  642|   382k|   accum.mul(ws[12], p[11]);
  643|   382k|   accum.mul(ws[13], p[10]);
  644|   382k|   accum.mul(ws[14], p[9]);
  645|   382k|   accum.mul(ws[15], p[8]);
  646|   382k|   accum.add(z[23]);
  647|   382k|   ws[7] = accum.extract();
  648|   382k|   accum.mul(ws[9], p[15]);
  649|   382k|   accum.mul(ws[10], p[14]);
  650|   382k|   accum.mul(ws[11], p[13]);
  651|   382k|   accum.mul(ws[12], p[12]);
  652|   382k|   accum.mul(ws[13], p[11]);
  653|   382k|   accum.mul(ws[14], p[10]);
  654|   382k|   accum.mul(ws[15], p[9]);
  655|   382k|   accum.add(z[24]);
  656|   382k|   ws[8] = accum.extract();
  657|   382k|   accum.mul(ws[10], p[15]);
  658|   382k|   accum.mul(ws[11], p[14]);
  659|   382k|   accum.mul(ws[12], p[13]);
  660|   382k|   accum.mul(ws[13], p[12]);
  661|   382k|   accum.mul(ws[14], p[11]);
  662|   382k|   accum.mul(ws[15], p[10]);
  663|   382k|   accum.add(z[25]);
  664|   382k|   ws[9] = accum.extract();
  665|   382k|   accum.mul(ws[11], p[15]);
  666|   382k|   accum.mul(ws[12], p[14]);
  667|   382k|   accum.mul(ws[13], p[13]);
  668|   382k|   accum.mul(ws[14], p[12]);
  669|   382k|   accum.mul(ws[15], p[11]);
  670|   382k|   accum.add(z[26]);
  671|   382k|   ws[10] = accum.extract();
  672|   382k|   accum.mul(ws[12], p[15]);
  673|   382k|   accum.mul(ws[13], p[14]);
  674|   382k|   accum.mul(ws[14], p[13]);
  675|   382k|   accum.mul(ws[15], p[12]);
  676|   382k|   accum.add(z[27]);
  677|   382k|   ws[11] = accum.extract();
  678|   382k|   accum.mul(ws[13], p[15]);
  679|   382k|   accum.mul(ws[14], p[14]);
  680|   382k|   accum.mul(ws[15], p[13]);
  681|   382k|   accum.add(z[28]);
  682|   382k|   ws[12] = accum.extract();
  683|   382k|   accum.mul(ws[14], p[15]);
  684|   382k|   accum.mul(ws[15], p[14]);
  685|   382k|   accum.add(z[29]);
  686|   382k|   ws[13] = accum.extract();
  687|   382k|   accum.mul(ws[15], p[15]);
  688|   382k|   accum.add(z[30]);
  689|   382k|   ws[14] = accum.extract();
  690|   382k|   accum.add(z[31]);
  691|   382k|   ws[15] = accum.extract();
  692|   382k|   const word w1 = accum.extract();
  693|   382k|   bigint_monty_maybe_sub<16>(r, w1, ws, p);
  694|   382k|}

_ZN5Botan17Barrett_ReductionC2ERKNS_6BigIntES1_m:
   17|  2.57k|      m_modulus(m), m_mu(std::move(mu)), m_mod_words(mw), m_modulus_bits(m.bits()) {
   18|       |   // Give some extra space for Karatsuba
   19|  2.57k|   m_modulus.grow_to(m_mod_words + 8);
   20|  2.57k|   m_mu.grow_to(m_mod_words + 8);
   21|  2.57k|}
_ZN5Botan17Barrett_Reduction18for_public_modulusERKNS_6BigIntE:
   33|  2.57k|Barrett_Reduction Barrett_Reduction::for_public_modulus(const BigInt& mod) {
   34|  2.57k|   BOTAN_ARG_CHECK(mod.signum() > 0, "Modulus must be positive");
  ------------------
  |  |   35|  2.57k|   do {                                                          \
  |  |   36|  2.57k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.57k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 2.57k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  2.57k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 2.57k]
  |  |  ------------------
  ------------------
   35|       |
   36|  2.57k|   const size_t mod_words = mod.sig_words();
   37|       |
   38|       |   // Compute mu = floor(2^{2k} / m)
   39|  2.57k|   const size_t mu_bits = 2 * WordInfo<word>::bits * mod_words;
   40|  2.57k|   return Barrett_Reduction(mod, vartime_divide_pow2k(mu_bits, mod), mod_words);
   41|  2.57k|}
_ZNK5Botan17Barrett_Reduction8multiplyERKNS_6BigIntES3_:
  159|  3.58k|BigInt Barrett_Reduction::multiply(const BigInt& x, const BigInt& y) const {
  160|  3.58k|   BOTAN_ARG_CHECK(acceptable_barrett_input(x, m_modulus).as_bool(), "Invalid x param for Barrett multiply");
  ------------------
  |  |   35|  3.58k|   do {                                                          \
  |  |   36|  3.58k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  3.58k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 3.58k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  3.58k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 3.58k]
  |  |  ------------------
  ------------------
  161|  3.58k|   BOTAN_ARG_CHECK(acceptable_barrett_input(y, m_modulus).as_bool(), "Invalid y param for Barrett multiply");
  ------------------
  |  |   35|  3.58k|   do {                                                          \
  |  |   36|  3.58k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  3.58k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 3.58k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  3.58k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 3.58k]
  |  |  ------------------
  ------------------
  162|       |
  163|  3.58k|   secure_vector<word> ws(2 * (m_mod_words + 2));
  164|  3.58k|   secure_vector<word> xy(2 * m_mod_words);
  165|       |
  166|  3.58k|   bigint_mul(xy.data(),
  167|  3.58k|              xy.size(),
  168|  3.58k|              x._data(),
  169|  3.58k|              x.size(),
  170|  3.58k|              std::min(x.size(), m_mod_words),
  171|  3.58k|              y._data(),
  172|  3.58k|              y.size(),
  173|  3.58k|              std::min(y.size(), m_mod_words),
  174|  3.58k|              ws.data(),
  175|  3.58k|              ws.size());
  176|       |
  177|  3.58k|   return barrett_reduce(m_mod_words, m_modulus, m_mu, xy, ws);
  178|  3.58k|}
_ZNK5Botan17Barrett_Reduction6squareERKNS_6BigIntE:
  180|  1.48k|BigInt Barrett_Reduction::square(const BigInt& x) const {
  181|  1.48k|   BOTAN_ARG_CHECK(acceptable_barrett_input(x, m_modulus).as_bool(), "Invalid x param for Barrett square");
  ------------------
  |  |   35|  1.48k|   do {                                                          \
  |  |   36|  1.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.48k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.48k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.48k]
  |  |  ------------------
  ------------------
  182|       |
  183|  1.48k|   secure_vector<word> ws(2 * (m_mod_words + 2));
  184|  1.48k|   secure_vector<word> x2(2 * m_mod_words);
  185|       |
  186|  1.48k|   bigint_sqr(x2.data(), x2.size(), x._data(), x.size(), std::min(x.size(), m_mod_words), ws.data(), ws.size());
  187|       |
  188|  1.48k|   return barrett_reduce(m_mod_words, m_modulus, m_mu, x2, ws);
  189|  1.48k|}
_ZNK5Botan17Barrett_Reduction6reduceERKNS_6BigIntE:
  191|  1.48k|BigInt Barrett_Reduction::reduce(const BigInt& x) const {
  192|  1.48k|   BOTAN_ARG_CHECK(x.signum() >= 0, "Argument must be non-negative");
  ------------------
  |  |   35|  1.48k|   do {                                                          \
  |  |   36|  1.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.48k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.48k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.48k]
  |  |  ------------------
  ------------------
  193|       |
  194|  1.48k|   const size_t x_sw = x.sig_words();
  195|  1.48k|   BOTAN_ARG_CHECK(x_sw <= 2 * m_mod_words, "Argument is too large for Barrett reduction");
  ------------------
  |  |   35|  1.48k|   do {                                                          \
  |  |   36|  1.48k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.48k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.48k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.48k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.48k]
  |  |  ------------------
  ------------------
  196|       |
  197|  1.48k|   x.grow_to(2 * m_mod_words);
  198|       |
  199|  1.48k|   secure_vector<word> ws;
  200|  1.48k|   return barrett_reduce(m_mod_words, m_modulus, m_mu, x._as_span(), ws);
  201|  1.48k|}
barrett.cpp:_ZN5Botan12_GLOBAL__N_124acceptable_barrett_inputERKNS_6BigIntES3_:
  151|  8.64k|CT::Choice acceptable_barrett_input(const BigInt& x, const BigInt& modulus) {
  152|  8.64k|   auto x_is_positive = CT::Choice::from_int(static_cast<uint32_t>(x.signum() >= 0));
  153|  8.64k|   auto x_lt_mod = bigint_ct_is_lt(x._data(), x.size(), modulus._data(), modulus.sig_words()).as_choice();
  154|  8.64k|   return x_is_positive && x_lt_mod;
  155|  8.64k|}
barrett.cpp:_ZN5Botan12_GLOBAL__N_114barrett_reduceEmRKNS_6BigIntES3_NSt3__14spanIKmLm18446744073709551615EEERNS4_6vectorImNS_16secure_allocatorImEEEE:
   54|  6.54k|   size_t mod_words, const BigInt& modulus, const BigInt& mu, std::span<const word> x_words, secure_vector<word>& ws) {
   55|  6.54k|   BOTAN_ASSERT_NOMSG(modulus.sig_words() == mod_words);
  ------------------
  |  |   77|  6.54k|   do {                                                                     \
  |  |   78|  6.54k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.54k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.54k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.54k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.54k]
  |  |  ------------------
  ------------------
   56|       |
   57|       |   // Caller must expand input to be at least this size
   58|  6.54k|   BOTAN_ASSERT_NOMSG(x_words.size() >= 2 * mod_words);
  ------------------
  |  |   77|  6.54k|   do {                                                                     \
  |  |   78|  6.54k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.54k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.54k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.54k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.54k]
  |  |  ------------------
  ------------------
   59|       |
   60|       |   // Normally mod_words + 1 but can be + 2 if the modulus is a power of 2
   61|  6.54k|   const size_t mu_words = mu.sig_words();
   62|  6.54k|   BOTAN_ASSERT_NOMSG(mu_words <= mod_words + 2);
  ------------------
  |  |   77|  6.54k|   do {                                                                     \
  |  |   78|  6.54k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.54k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.54k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.54k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.54k]
  |  |  ------------------
  ------------------
   63|       |
   64|  6.54k|   if(ws.size() < 2 * (mod_words + 2)) {
  ------------------
  |  Branch (64:7): [True: 1.48k, False: 5.06k]
  ------------------
   65|  1.48k|      ws.resize(2 * (mod_words + 2));
   66|  1.48k|   }
   67|       |
   68|  6.54k|   CT::poison(x_words);
   69|       |
   70|       |   /*
   71|       |   * Following the notation of Handbook of Applied Cryptography
   72|       |   * Algorithm 14.42 "Barrett modular reduction", page 604
   73|       |   * <https://cacr.uwaterloo.ca/hac/about/chap14.pdf>
   74|       |   *
   75|       |   * Using `mu` for μ in the code
   76|       |   */
   77|       |
   78|       |   // Compute q1 = floor(x / 2^(k - 1)) which is equivalent to ignoring the low (k-1) words
   79|       |
   80|       |   // 2 * mod_words + 1 is sufficient, extra is to enable Karatsuba
   81|  6.54k|   secure_vector<word> r(2 * mu_words + 2);
   82|       |
   83|  6.54k|   copy_mem(r.data(), x_words.data() + (mod_words - 1), mod_words + 1);
   84|       |
   85|       |   // Now compute q2 = q1 * μ
   86|       |
   87|       |   // We allocate more size than required since this allows Karatsuba more often;
   88|       |   // just `mu_words + (mod_words + 1)` is sufficient
   89|  6.54k|   const size_t q2_size = 2 * mu_words + 2;
   90|       |
   91|  6.54k|   secure_vector<word> q2(q2_size);
   92|       |
   93|  6.54k|   bigint_mul(
   94|  6.54k|      q2.data(), q2.size(), r.data(), r.size(), mod_words + 1, mu._data(), mu.size(), mu_words, ws.data(), ws.size());
   95|       |
   96|       |   // Compute r2 = (floor(q2 / b^(k+1)) * m) mod 2^(k+1)
   97|       |   // The division/floor is again effected by just ignoring the low k + 1 words
   98|  6.54k|   bigint_mul(r.data(),
   99|  6.54k|              r.size(),
  100|  6.54k|              &q2[mod_words + 1],  // ignoring the low mod_words + 1 words of the first product
  101|  6.54k|              q2.size() - (mod_words + 1),
  102|  6.54k|              mod_words + 1,
  103|  6.54k|              modulus._data(),
  104|  6.54k|              modulus.size(),
  105|  6.54k|              mod_words,
  106|  6.54k|              ws.data(),
  107|  6.54k|              ws.size());
  108|       |
  109|       |   // Clear the high words of the product, equivalent to computing mod 2^(k+1)
  110|       |   // TODO add masked mul to avoid computing high bits at all
  111|  6.54k|   clear_mem(std::span{r}.subspan(mod_words + 1));
  112|       |
  113|       |   // Compute r = r1 - r2
  114|       |
  115|       |   // The return value of bigint_sub_abs isn't quite right for what we need here so first compare
  116|  6.54k|   const int32_t relative_size = bigint_cmp(r.data(), mod_words + 1, x_words.data(), mod_words + 1);
  117|       |
  118|  6.54k|   bigint_sub_abs(r.data(), r.data(), x_words.data(), mod_words + 1, ws.data());
  119|       |
  120|       |   /*
  121|       |   If r is negative then we have to set r to r + 2^(k+1)
  122|       |
  123|       |   However for r negative computing this sum is equivalent to computing 2^(k+1) - abs(r)
  124|       |   */
  125|  6.54k|   clear_mem(ws.data(), mod_words + 2);
  126|  6.54k|   ws[mod_words + 1] = 1;
  127|  6.54k|   bigint_sub2(ws.data(), mod_words + 2, r.data(), mod_words + 2);
  128|       |
  129|       |   // If relative_size > 0 then assign r to 2^(k+1) - r
  130|  6.54k|   CT::Mask<word>::is_equal(static_cast<word>(relative_size), 1).select_n(r.data(), ws.data(), r.data(), mod_words + 2);
  131|       |
  132|       |   /*
  133|       |   * Per HAC Note 14.44 (ii) "step 4 is repeated at most twice since 0 ≤ r < 3m"
  134|       |   */
  135|  6.54k|   const size_t bound = 2;
  136|       |
  137|  6.54k|   BOTAN_ASSERT_NOMSG(r.size() >= mod_words + 1);
  ------------------
  |  |   77|  6.54k|   do {                                                                     \
  |  |   78|  6.54k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.54k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.54k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.54k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.54k]
  |  |  ------------------
  ------------------
  138|  19.6k|   for(size_t i = 0; i != bound; ++i) {
  ------------------
  |  Branch (138:22): [True: 13.0k, False: 6.54k]
  ------------------
  139|  13.0k|      const word borrow = bigint_sub3(ws.data(), r.data(), mod_words + 1, modulus._data(), mod_words);
  140|  13.0k|      CT::Mask<word>::is_zero(borrow).select_n(r.data(), ws.data(), r.data(), mod_words + 1);
  141|  13.0k|   }
  142|       |
  143|  6.54k|   CT::unpoison(q2);
  144|  6.54k|   CT::unpoison(r);
  145|  6.54k|   CT::unpoison(ws);
  146|  6.54k|   CT::unpoison(x_words);
  147|       |
  148|  6.54k|   return BigInt::_from_words(r);
  149|  6.54k|}

_ZN5Botan24inverse_mod_public_primeERKNS_6BigIntES2_:
  294|  1.02k|BigInt inverse_mod_public_prime(const BigInt& x, const BigInt& p) {
  295|  1.02k|   BOTAN_ARG_CHECK(p.signum() > 0, "Modulus must be positive");
  ------------------
  |  |   35|  1.02k|   do {                                                          \
  |  |   36|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.02k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  296|  1.02k|   BOTAN_ARG_CHECK(x.signum() > 0, "Input must be positive");
  ------------------
  |  |   35|  1.02k|   do {                                                          \
  |  |   36|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.02k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  297|  1.02k|   BOTAN_ARG_CHECK(x < p, "Input must be less than modulus");
  ------------------
  |  |   35|  1.02k|   do {                                                          \
  |  |   36|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.02k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  298|  1.02k|   BOTAN_ARG_CHECK(p.is_odd() && p > 1, "Primes are odd integers greater than 1");
  ------------------
  |  |   35|  1.02k|   do {                                                          \
  |  |   36|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.05k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 1.02k, False: 0]
  |  |  |  Branch (37:12): [True: 1.02k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  299|       |
  300|       |   // TODO possibly use FLT, or the algorithm presented for this case in
  301|       |   // Handbook of Elliptic and Hyperelliptic Curve Cryptography
  302|       |
  303|  1.02k|   return inverse_mod_odd_modulus(x, p);
  304|  1.02k|}
mod_inv.cpp:_ZN5Botan12_GLOBAL__N_123inverse_mod_odd_modulusERKNS_6BigIntES3_:
   21|  1.02k|BigInt inverse_mod_odd_modulus(const BigInt& n, const BigInt& mod) {
   22|       |   // Caller should assure these preconditions:
   23|  1.02k|   BOTAN_ASSERT_NOMSG(n.signum() >= 0);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   24|  1.02k|   BOTAN_ASSERT_NOMSG(mod.signum() > 0);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   25|  1.02k|   BOTAN_ASSERT_NOMSG(n < mod);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   26|  1.02k|   BOTAN_ASSERT_NOMSG(mod >= 3 && mod.is_odd());
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  2.05k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 1.02k, False: 0]
  |  |  |  Branch (79:12): [True: 1.02k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   27|       |
   28|       |   /*
   29|       |   This uses a modular inversion algorithm designed by Niels Möller
   30|       |   and implemented in Nettle. The same algorithm was later also
   31|       |   adapted to GMP in mpn_sec_invert.
   32|       |
   33|       |   It can be easily implemented in a way that does not depend on
   34|       |   secret branches or memory lookups, providing resistance against
   35|       |   some forms of side channel attack.
   36|       |
   37|       |   There is also a description of the algorithm in Appendix 5 of "Fast
   38|       |   Software Polynomial Multiplication on ARM Processors using the NEON Engine"
   39|       |   by Danilo Câmara, Conrado P. L. Gouvêa, Julio López, and Ricardo
   40|       |   Dahab in LNCS 8182
   41|       |      https://inria.hal.science/hal-01506572/document
   42|       |
   43|       |   Thanks to Niels for creating the algorithm, explaining some things
   44|       |   about it, and the reference to the paper.
   45|       |   */
   46|       |
   47|  1.02k|   const size_t mod_words = mod.sig_words();
   48|  1.02k|   BOTAN_ASSERT(mod_words > 0, "Not empty");
  ------------------
  |  |   64|  1.02k|   do {                                                                                 \
  |  |   65|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.02k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   49|       |
   50|  1.02k|   secure_vector<word> tmp_mem(5 * mod_words);
   51|       |
   52|  1.02k|   word* v_w = &tmp_mem[0];  // NOLINT(readability-container-data-pointer)
   53|  1.02k|   word* u_w = &tmp_mem[1 * mod_words];
   54|  1.02k|   word* b_w = &tmp_mem[2 * mod_words];
   55|  1.02k|   word* a_w = &tmp_mem[3 * mod_words];
   56|  1.02k|   word* mp1o2 = &tmp_mem[4 * mod_words];
   57|       |
   58|  1.02k|   copy_mem(a_w, n._data(), std::min(n.size(), mod_words));
   59|  1.02k|   copy_mem(b_w, mod._data(), std::min(mod.size(), mod_words));
   60|  1.02k|   u_w[0] = 1;
   61|       |   // v_w = 0
   62|       |
   63|       |   // compute (mod + 1) / 2 which [because mod is odd] is equal to
   64|       |   // (mod / 2) + 1
   65|  1.02k|   copy_mem(mp1o2, mod._data(), std::min(mod.size(), mod_words));
   66|  1.02k|   bigint_shr1(mp1o2, mod_words, 1);
   67|  1.02k|   const word carry = bigint_add2(mp1o2, mod_words, u_w, 1);
   68|  1.02k|   BOTAN_ASSERT_NOMSG(carry == 0);
  ------------------
  |  |   77|  1.02k|   do {                                                                     \
  |  |   78|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.02k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
   69|       |
   70|  1.02k|   CT::poison(tmp_mem.data(), tmp_mem.size());
   71|       |
   72|       |   // Only n.bits() + mod.bits() iterations are required, but avoid leaking the size of n
   73|  1.02k|   const size_t execs = 2 * mod.bits();
   74|       |
   75|   329k|   for(size_t i = 0; i != execs; ++i) {
  ------------------
  |  Branch (75:22): [True: 328k, False: 1.02k]
  ------------------
   76|   328k|      const word odd_a = a_w[0] & 1;
   77|       |
   78|       |      //if(odd_a) a -= b
   79|   328k|      const word underflow = bigint_cnd_sub(odd_a, a_w, b_w, mod_words);
   80|       |
   81|       |      //if(underflow) { b -= a; a = abs(a); swap(u, v); }
   82|   328k|      bigint_cnd_add(underflow, b_w, a_w, mod_words);
   83|   328k|      bigint_cnd_abs(underflow, a_w, mod_words);
   84|   328k|      bigint_cnd_swap(underflow, u_w, v_w, mod_words);
   85|       |
   86|       |      // a >>= 1
   87|   328k|      bigint_shr1(a_w, mod_words, 1);
   88|       |
   89|       |      //if(odd_a) u -= v;
   90|   328k|      const word borrow = bigint_cnd_sub(odd_a, u_w, v_w, mod_words);
   91|       |
   92|       |      // if(borrow) u += p
   93|   328k|      bigint_cnd_add(borrow, u_w, mod._data(), mod_words);
   94|       |
   95|   328k|      const word odd_u = u_w[0] & 1;
   96|       |
   97|       |      // u >>= 1
   98|   328k|      bigint_shr1(u_w, mod_words, 1);
   99|       |
  100|       |      //if(odd_u) u += mp1o2;
  101|   328k|      bigint_cnd_add(odd_u, u_w, mp1o2, mod_words);
  102|   328k|   }
  103|       |
  104|  1.02k|   const auto a_is_0 = CT::all_zeros(a_w, mod_words);
  105|       |
  106|  1.02k|   auto b_is_1 = CT::Mask<word>::is_equal(b_w[0], 1);
  107|  3.08k|   for(size_t i = 1; i != mod_words; ++i) {
  ------------------
  |  Branch (107:22): [True: 2.05k, False: 1.02k]
  ------------------
  108|  2.05k|      b_is_1 &= CT::Mask<word>::is_zero(b_w[i]);
  109|  2.05k|   }
  110|       |
  111|  1.02k|   BOTAN_ASSERT(a_is_0.as_bool(), "A is zero");
  ------------------
  |  |   64|  1.02k|   do {                                                                                 \
  |  |   65|  1.02k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.02k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 1.02k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  1.02k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 1.02k]
  |  |  ------------------
  ------------------
  112|       |
  113|       |   // if b != 1 then gcd(n,mod) > 1 and inverse does not exist
  114|       |   // in which case zero out the result to indicate this
  115|  1.02k|   (~b_is_1).if_set_zero_out(v_w, mod_words);
  116|       |
  117|       |   /*
  118|       |   * We've placed the result in the lowest words of the temp buffer.
  119|       |   * So just clear out the other values and then give that buffer to a
  120|       |   * BigInt.
  121|       |   */
  122|  1.02k|   clear_mem(&tmp_mem[mod_words], 4 * mod_words);
  123|       |
  124|  1.02k|   CT::unpoison(tmp_mem.data(), tmp_mem.size());
  125|       |
  126|  1.02k|   BigInt r;
  127|  1.02k|   r.swap_reg(tmp_mem);
  128|  1.02k|   return r;
  129|  1.02k|}

_ZN5Botan17Montgomery_Params4DataC2ERKNS_6BigIntERKNS_17Barrett_ReductionE:
   40|  1.47k|Montgomery_Params::Data::Data(const BigInt& p, const Barrett_Reduction& mod_p) {
   41|  1.47k|   if(p.is_even() || p < 3) {
  ------------------
  |  Branch (41:7): [True: 0, False: 1.47k]
  |  Branch (41:22): [True: 0, False: 1.47k]
  ------------------
   42|      0|      throw Invalid_Argument("Montgomery_Params invalid modulus");
   43|      0|   }
   44|       |
   45|  1.47k|   m_p = p;
   46|  1.47k|   m_p_words = m_p.sig_words();
   47|  1.47k|   m_p_dash = monty_inverse(m_p.word_at(0));
   48|       |
   49|  1.47k|   const BigInt r = BigInt::power_of_2(m_p_words * WordInfo<word>::bits);
   50|       |
   51|  1.47k|   m_r1 = mod_p.reduce(r);
   52|  1.47k|   m_r2 = mod_p.square(m_r1);
   53|  1.47k|   m_r3 = mod_p.multiply(m_r1, m_r2);
   54|       |
   55|       |   // Barrett should be at least zero prefixing up to modulus size
   56|  1.47k|   BOTAN_ASSERT_NOMSG(m_r1.size() >= m_p_words);
  ------------------
  |  |   77|  1.47k|   do {                                                                     \
  |  |   78|  1.47k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.47k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.47k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.47k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.47k]
  |  |  ------------------
  ------------------
   57|  1.47k|   BOTAN_ASSERT_NOMSG(m_r2.size() >= m_p_words);
  ------------------
  |  |   77|  1.47k|   do {                                                                     \
  |  |   78|  1.47k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.47k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.47k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.47k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.47k]
  |  |  ------------------
  ------------------
   58|  1.47k|   BOTAN_ASSERT_NOMSG(m_r3.size() >= m_p_words);
  ------------------
  |  |   77|  1.47k|   do {                                                                     \
  |  |   78|  1.47k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  1.47k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 1.47k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  1.47k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 1.47k]
  |  |  ------------------
  ------------------
   59|  1.47k|}
_ZN5Botan17Montgomery_ParamsC2ERKNS_6BigIntERKNS_17Barrett_ReductionE:
   62|  1.47k|      m_data(std::make_shared<Data>(p, mod_p)) {}
_ZNK5Botan17Montgomery_ParamseqERKS0_:
   67|  96.4k|bool Montgomery_Params::operator==(const Montgomery_Params& other) const {
   68|  96.4k|   if(this->m_data == other.m_data) {
  ------------------
  |  Branch (68:7): [True: 96.4k, False: 0]
  ------------------
   69|  96.4k|      return true;
   70|  96.4k|   }
   71|       |
   72|      0|   return (this->m_data->p() == other.m_data->p());
   73|  96.4k|}
_ZNK5Botan17Montgomery_Params3mulERKNS_6BigIntES3_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
   90|      6|BigInt Montgomery_Params::mul(const BigInt& x, const BigInt& y, secure_vector<word>& ws) const {
   91|      6|   const size_t p_size = this->p_words();
   92|      6|   BigInt z = BigInt::with_capacity(2 * p_size);
   93|      6|   this->mul(z, x, y, ws);
   94|      6|   return z;
   95|      6|}
_ZNK5Botan17Montgomery_Params3mulERNS_6BigIntERKS1_S4_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
   97|      6|void Montgomery_Params::mul(BigInt& z, const BigInt& x, const BigInt& y, secure_vector<word>& ws) const {
   98|      6|   BOTAN_ARG_CHECK(&z != &x && &z != &y, "Montgomery_Params::mul output must not alias inputs");
  ------------------
  |  |   35|      6|   do {                                                          \
  |  |   36|      6|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|     12|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 6, False: 0]
  |  |  |  Branch (37:12): [True: 6, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|      6|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6]
  |  |  ------------------
  ------------------
   99|       |
  100|      6|   const size_t p_size = this->p_words();
  101|       |
  102|      6|   if(ws.size() < 2 * p_size) {
  ------------------
  |  Branch (102:7): [True: 3, False: 3]
  ------------------
  103|      3|      ws.resize(2 * p_size);
  104|      3|   }
  105|       |
  106|      6|   BOTAN_DEBUG_ASSERT(x.sig_words() <= p_size);
  ------------------
  |  |  130|      6|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|      6|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 6]
  |  |  ------------------
  ------------------
  107|      6|   BOTAN_DEBUG_ASSERT(y.sig_words() <= p_size);
  ------------------
  |  |  130|      6|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|      6|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 6]
  |  |  ------------------
  ------------------
  108|       |
  109|      6|   if(z.size() < 2 * p_size) {
  ------------------
  |  Branch (109:7): [True: 0, False: 6]
  ------------------
  110|      0|      z.grow_to(2 * p_size);
  111|      0|   }
  112|       |
  113|      6|   bigint_mul(z.mutable_data(),
  114|      6|              z.size(),
  115|      6|              x._data(),
  116|      6|              x.size(),
  117|      6|              std::min(p_size, x.size()),
  118|      6|              y._data(),
  119|      6|              y.size(),
  120|      6|              std::min(p_size, y.size()),
  121|      6|              ws.data(),
  122|      6|              ws.size());
  123|       |
  124|      6|   bigint_monty_redc_inplace(z.mutable_data(), this->p()._data(), p_size, this->p_dash(), ws.data(), ws.size());
  125|      6|}
_ZNK5Botan17Montgomery_Params6mul_byERNS_6BigIntERKS1_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
  157|  12.5k|void Montgomery_Params::mul_by(BigInt& x, const BigInt& y, secure_vector<word>& ws) const {
  158|  12.5k|   const size_t p_size = this->p_words();
  159|       |
  160|  12.5k|   if(ws.size() < 4 * p_size) {
  ------------------
  |  Branch (160:7): [True: 6.25k, False: 6.25k]
  ------------------
  161|  6.25k|      ws.resize(4 * p_size);
  162|  6.25k|   }
  163|       |
  164|  12.5k|   word* z_data = ws.data();
  165|  12.5k|   word* ws_data = &ws[2 * p_size];
  166|       |
  167|  12.5k|   BOTAN_DEBUG_ASSERT(x.sig_words() <= p_size);
  ------------------
  |  |  130|  12.5k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  12.5k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 12.5k]
  |  |  ------------------
  ------------------
  168|       |
  169|  12.5k|   bigint_mul(z_data,
  170|  12.5k|              2 * p_size,
  171|  12.5k|              x._data(),
  172|  12.5k|              x.size(),
  173|  12.5k|              std::min(p_size, x.size()),
  174|  12.5k|              y._data(),
  175|  12.5k|              y.size(),
  176|  12.5k|              std::min(p_size, y.size()),
  177|  12.5k|              ws_data,
  178|  12.5k|              2 * p_size);
  179|       |
  180|  12.5k|   bigint_monty_redc_inplace(z_data, this->p()._data(), p_size, this->p_dash(), ws_data, 2 * p_size);
  181|       |
  182|  12.5k|   if(x.size() < 2 * p_size) {
  ------------------
  |  Branch (182:7): [True: 0, False: 12.5k]
  ------------------
  183|      0|      x.grow_to(2 * p_size);
  184|      0|   }
  185|  12.5k|   copy_mem(x.mutable_data(), z_data, 2 * p_size);
  186|  12.5k|}
_ZN5Botan14Montgomery_IntC2ERKNS_17Montgomery_ParamsENSt3__16vectorImNS_16secure_allocatorImEEEE:
  227|  19.4k|      m_params(params), m_v(std::move(words)) {
  228|  19.4k|   BOTAN_ASSERT_NOMSG(m_v.size() == m_params.p_words());
  ------------------
  |  |   77|  19.4k|   do {                                                                     \
  |  |   78|  19.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  19.4k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 19.4k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  19.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 19.4k]
  |  |  ------------------
  ------------------
  229|  19.4k|}
_ZN5Botan14Montgomery_Int3oneERKNS_17Montgomery_ParamsE:
  231|  2.52k|Montgomery_Int Montgomery_Int::one(const Montgomery_Params& params) {
  232|  2.52k|   return Montgomery_Int(params, params.R1(), false);
  233|  2.52k|}
_ZN5Botan14Montgomery_IntC2ERKNS_17Montgomery_ParamsERKNS_6BigIntEb:
  242|  6.07k|      m_params(params), m_v(m_params.p_words()) {
  243|  6.07k|   BOTAN_ARG_CHECK(v.signum() >= 0 && v < m_params.p(), "Input out of range");
  ------------------
  |  |   35|  6.07k|   do {                                                          \
  |  |   36|  6.07k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  12.1k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 6.07k, False: 0]
  |  |  |  Branch (37:12): [True: 6.07k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.07k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.07k]
  |  |  ------------------
  ------------------
  244|       |
  245|  6.07k|   const size_t p_size = m_params.p_words();
  246|       |
  247|  6.07k|   auto v_span = v._as_span();
  248|       |
  249|  6.07k|   if(v_span.size() > p_size) {
  ------------------
  |  Branch (249:7): [True: 2.52k, False: 3.55k]
  ------------------
  250|       |      // Safe to truncate the span since we already checked v < p
  251|  2.52k|      v_span = v_span.first(p_size);
  252|  2.52k|   }
  253|       |
  254|  6.07k|   BOTAN_ASSERT_NOMSG(m_v.size() >= v_span.size());
  ------------------
  |  |   77|  6.07k|   do {                                                                     \
  |  |   78|  6.07k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.07k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.07k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.07k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.07k]
  |  |  ------------------
  ------------------
  255|       |
  256|  6.07k|   copy_mem(std::span{m_v}.first(v_span.size()), v_span);
  257|       |
  258|  6.07k|   if(redc_needed) {
  ------------------
  |  Branch (258:7): [True: 3.55k, False: 2.52k]
  ------------------
  259|  3.55k|      secure_vector<word> ws;
  260|  3.55k|      this->mul_by(m_params.R2()._as_span().first(p_size), ws);
  261|  3.55k|   }
  262|  6.07k|}
_ZN5Botan14Montgomery_IntC2ERKNS_17Montgomery_ParamsENSt3__14spanIKmLm18446744073709551615EEE:
  265|     82|      m_params(params), m_v(words.begin(), words.end()) {
  266|     82|   BOTAN_ARG_CHECK(m_v.size() == m_params.p_words(), "Invalid input span");
  ------------------
  |  |   35|     82|   do {                                                          \
  |  |   36|     82|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|     82|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 82]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|     82|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 82]
  |  |  ------------------
  ------------------
  267|     82|}
_ZNK5Botan14Montgomery_Int5valueEv:
  273|  1.43k|BigInt Montgomery_Int::value() const {
  274|  1.43k|   secure_vector<word> ws(m_params.p_words());
  275|       |
  276|  1.43k|   secure_vector<word> z = m_v;
  277|  1.43k|   z.resize(2 * m_params.p_words());  // zero extend
  278|       |
  279|  1.43k|   bigint_monty_redc_inplace(
  280|  1.43k|      z.data(), m_params.p()._data(), m_params.p_words(), m_params.p_dash(), ws.data(), ws.size());
  281|       |
  282|  1.43k|   return BigInt::_from_words(z);
  283|  1.43k|}
_ZNK5Botan14Montgomery_Int3mulERKS0_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
  320|  19.4k|Montgomery_Int Montgomery_Int::mul(const Montgomery_Int& other, secure_vector<word>& ws) const {
  321|  19.4k|   BOTAN_STATE_CHECK(other.m_params == m_params);
  ------------------
  |  |   51|  19.4k|   do {                                                         \
  |  |   52|  19.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  19.4k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 19.4k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  19.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 19.4k]
  |  |  ------------------
  ------------------
  322|       |
  323|  19.4k|   const size_t p_size = m_params.p_words();
  324|  19.4k|   BOTAN_ASSERT_NOMSG(m_v.size() == p_size && other.m_v.size() == p_size);
  ------------------
  |  |   77|  19.4k|   do {                                                                     \
  |  |   78|  19.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  38.9k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 19.4k, False: 0]
  |  |  |  Branch (79:12): [True: 19.4k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  19.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 19.4k]
  |  |  ------------------
  ------------------
  325|       |
  326|  19.4k|   if(ws.size() < 2 * p_size) {
  ------------------
  |  Branch (326:7): [True: 0, False: 19.4k]
  ------------------
  327|      0|      ws.resize(2 * p_size);
  328|      0|   }
  329|       |
  330|  19.4k|   secure_vector<word> z(2 * p_size);
  331|       |
  332|  19.4k|   bigint_mul(z.data(), z.size(), m_v.data(), p_size, p_size, other.m_v.data(), p_size, p_size, ws.data(), ws.size());
  333|       |
  334|  19.4k|   bigint_monty_redc_inplace(z.data(), m_params.p()._data(), p_size, m_params.p_dash(), ws.data(), ws.size());
  335|  19.4k|   z.resize(p_size);  // truncate off high zero words
  336|       |
  337|  19.4k|   return Montgomery_Int(m_params, std::move(z));
  338|  19.4k|}
_ZN5Botan14Montgomery_Int6mul_byERKS0_RNSt3__16vectorImNS_16secure_allocatorImEEEE:
  340|  76.9k|Montgomery_Int& Montgomery_Int::mul_by(const Montgomery_Int& other, secure_vector<word>& ws) {
  341|  76.9k|   BOTAN_STATE_CHECK(other.m_params == m_params);
  ------------------
  |  |   51|  76.9k|   do {                                                         \
  |  |   52|  76.9k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  76.9k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 76.9k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  76.9k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 76.9k]
  |  |  ------------------
  ------------------
  342|  76.9k|   return this->mul_by(std::span{other.m_v}, ws);
  343|  76.9k|}
_ZN5Botan14Montgomery_Int6mul_byENSt3__14spanIKmLm18446744073709551615EEERNS1_6vectorImNS_16secure_allocatorImEEEE:
  345|   101k|Montgomery_Int& Montgomery_Int::mul_by(std::span<const word> other, secure_vector<word>& ws) {
  346|   101k|   const size_t p_size = m_params.p_words();
  347|   101k|   BOTAN_ASSERT_NOMSG(m_v.size() == p_size && other.size() == p_size);
  ------------------
  |  |   77|   101k|   do {                                                                     \
  |  |   78|   101k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   202k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 101k, False: 0]
  |  |  |  Branch (79:12): [True: 101k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   101k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 101k]
  |  |  ------------------
  ------------------
  348|       |
  349|   101k|   if(ws.size() < 2 * p_size) {
  ------------------
  |  Branch (349:7): [True: 3.55k, False: 97.8k]
  ------------------
  350|  3.55k|      ws.resize(2 * p_size);
  351|  3.55k|   }
  352|       |
  353|   101k|   auto do_mul_by = [&](std::span<word> z) {
  354|   101k|      bigint_mul(z.data(), z.size(), m_v.data(), p_size, p_size, other.data(), p_size, p_size, ws.data(), ws.size());
  355|       |
  356|   101k|      bigint_monty_redc_inplace(z.data(), m_params.p()._data(), p_size, m_params.p_dash(), ws.data(), ws.size());
  357|       |
  358|   101k|      copy_mem(m_v, z.first(p_size));
  359|   101k|   };
  360|       |
  361|   101k|   if(p_size <= MontgomeryUseStackLimit) {
  ------------------
  |  Branch (361:7): [True: 101k, False: 34]
  ------------------
  362|   101k|      std::array<word, 2 * MontgomeryUseStackLimit> z{};
  363|   101k|      do_mul_by(z);
  364|   101k|   } else {
  365|     34|      secure_vector<word> z(2 * p_size);
  366|     34|      do_mul_by(z);
  367|     34|   }
  368|       |
  369|   101k|   return (*this);
  370|   101k|}
_ZN5Botan14Montgomery_Int19square_this_n_timesERNSt3__16vectorImNS_16secure_allocatorImEEEEm:
  372|   117k|Montgomery_Int& Montgomery_Int::square_this_n_times(secure_vector<word>& ws, size_t n) {
  373|   117k|   const size_t p_size = m_params.p_words();
  374|   117k|   BOTAN_ASSERT_NOMSG(m_v.size() == p_size);
  ------------------
  |  |   77|   117k|   do {                                                                     \
  |  |   78|   117k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   117k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 117k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   117k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 117k]
  |  |  ------------------
  ------------------
  375|       |
  376|   117k|   if(ws.size() < 2 * p_size) {
  ------------------
  |  Branch (376:7): [True: 0, False: 117k]
  ------------------
  377|      0|      ws.resize(2 * p_size);
  378|      0|   }
  379|       |
  380|   117k|   auto do_sqr_n = [&](std::span<word> z) {
  381|   117k|      for(size_t i = 0; i != n; ++i) {
  382|   117k|         bigint_sqr(z.data(), 2 * p_size, m_v.data(), p_size, p_size, ws.data(), ws.size());
  383|       |
  384|   117k|         bigint_monty_redc_inplace(z.data(), m_params.p()._data(), p_size, m_params.p_dash(), ws.data(), ws.size());
  385|       |
  386|   117k|         copy_mem(m_v, std::span{z}.first(p_size));
  387|   117k|      }
  388|   117k|   };
  389|       |
  390|   117k|   if(p_size <= MontgomeryUseStackLimit) {
  ------------------
  |  Branch (390:7): [True: 117k, False: 272]
  ------------------
  391|   117k|      std::array<word, 2 * MontgomeryUseStackLimit> z{};
  392|   117k|      do_sqr_n(z);
  393|   117k|   } else {
  394|    272|      secure_vector<word> z(2 * p_size);
  395|    272|      do_sqr_n(z);
  396|    272|   }
  397|       |
  398|   117k|   return (*this);
  399|   117k|}
_ZNK5Botan14Montgomery_Int6squareERNSt3__16vectorImNS_16secure_allocatorImEEEE:
  401|  10.2k|Montgomery_Int Montgomery_Int::square(secure_vector<word>& ws) const {
  402|  10.2k|   auto z = (*this);
  403|  10.2k|   z.square_this_n_times(ws, 1);
  404|  10.2k|   return z;
  405|  10.2k|}
monty.cpp:_ZZN5Botan14Montgomery_Int6mul_byENSt3__14spanIKmLm18446744073709551615EEERNS1_6vectorImNS_16secure_allocatorImEEEEENK3$_0clENS2_ImLm18446744073709551615EEE:
  353|   101k|   auto do_mul_by = [&](std::span<word> z) {
  354|   101k|      bigint_mul(z.data(), z.size(), m_v.data(), p_size, p_size, other.data(), p_size, p_size, ws.data(), ws.size());
  355|       |
  356|   101k|      bigint_monty_redc_inplace(z.data(), m_params.p()._data(), p_size, m_params.p_dash(), ws.data(), ws.size());
  357|       |
  358|   101k|      copy_mem(m_v, z.first(p_size));
  359|   101k|   };
monty.cpp:_ZZN5Botan14Montgomery_Int19square_this_n_timesERNSt3__16vectorImNS_16secure_allocatorImEEEEmENK3$_0clENS1_4spanImLm18446744073709551615EEE:
  380|   117k|   auto do_sqr_n = [&](std::span<word> z) {
  381|   378k|      for(size_t i = 0; i != n; ++i) {
  ------------------
  |  Branch (381:25): [True: 260k, False: 117k]
  ------------------
  382|   260k|         bigint_sqr(z.data(), 2 * p_size, m_v.data(), p_size, p_size, ws.data(), ws.size());
  383|       |
  384|   260k|         bigint_monty_redc_inplace(z.data(), m_params.p()._data(), p_size, m_params.p_dash(), ws.data(), ws.size());
  385|       |
  386|   260k|         copy_mem(m_v, std::span{z}.first(p_size));
  387|   260k|      }
  388|   117k|   };

_ZN5Botan31Montgomery_Exponentiation_StateC2ERKNS_14Montgomery_IntEmb:
   36|  1.49k|      m_params(g._params()), m_window_bits(window_bits == 0 ? 4 : window_bits) {
  ------------------
  |  Branch (36:44): [True: 0, False: 1.49k]
  ------------------
   37|  1.49k|   if(m_window_bits < 1 || m_window_bits > 12) {  // really even 8 is too large ...
  ------------------
  |  Branch (37:7): [True: 0, False: 1.49k]
  |  Branch (37:28): [True: 0, False: 1.49k]
  ------------------
   38|      0|      throw Invalid_Argument("Invalid window bits for Montgomery exponentiation");
   39|      0|   }
   40|       |
   41|  1.49k|   const size_t window_size = (static_cast<size_t>(1) << m_window_bits);
   42|       |
   43|  1.49k|   m_g.reserve(window_size);
   44|       |
   45|  1.49k|   m_g.push_back(Montgomery_Int::one(m_params));
   46|       |
   47|  1.49k|   m_g.push_back(g);
   48|       |
   49|  1.49k|   secure_vector<word> ws(2 * m_params.p_words());
   50|       |
   51|  17.8k|   for(size_t i = 2; i != window_size; ++i) {
  ------------------
  |  Branch (51:22): [True: 16.3k, False: 1.49k]
  ------------------
   52|  16.3k|      if(i % 2 == 0) {
  ------------------
  |  Branch (52:10): [True: 8.18k, False: 8.18k]
  ------------------
   53|  8.18k|         m_g.push_back(m_g[i / 2].square(ws));
   54|  8.18k|      } else {
   55|  8.18k|         m_g.push_back(m_g[1].mul(m_g[i - 1], ws));
   56|  8.18k|      }
   57|  16.3k|   }
   58|       |
   59|  1.49k|   if(const_time) {
  ------------------
  |  Branch (59:7): [True: 1.16k, False: 329]
  ------------------
   60|  1.16k|      CT::poison_range(m_g);
   61|  1.16k|   }
   62|  1.49k|}
_ZNK5Botan31Montgomery_Exponentiation_State14exponentiationERKNS_6BigIntEm:
   91|     82|Montgomery_Int Montgomery_Exponentiation_State::exponentiation(const BigInt& scalar, size_t max_k_bits) const {
   92|     82|   BOTAN_ARG_CHECK(scalar.signum() >= 0, "Invalid scalar for Montgomery exponentiation");
  ------------------
  |  |   35|     82|   do {                                                          \
  |  |   36|     82|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|     82|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 82]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|     82|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 82]
  |  |  ------------------
  ------------------
   93|     82|   BOTAN_DEBUG_ASSERT(scalar.bits() <= max_k_bits);
  ------------------
  |  |  130|     82|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|     82|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 82]
  |  |  ------------------
  ------------------
   94|       |   // TODO add a const-time implementation of above assert and use it in release builds
   95|       |
   96|     82|   const size_t exp_nibbles = (max_k_bits + m_window_bits - 1) / m_window_bits;
   97|       |
   98|     82|   if(exp_nibbles == 0) {
  ------------------
  |  Branch (98:7): [True: 0, False: 82]
  ------------------
   99|      0|      return Montgomery_Int::one(m_params);
  100|      0|   }
  101|       |
  102|     82|   secure_vector<word> e_bits(m_params.p_words());
  103|     82|   secure_vector<word> ws(2 * m_params.p_words());
  104|       |
  105|     82|   const_time_lookup(e_bits, m_g, scalar.get_substring(m_window_bits * (exp_nibbles - 1), m_window_bits));
  106|     82|   Montgomery_Int x(m_params, std::span{e_bits});
  107|       |
  108|  20.9k|   for(size_t i = exp_nibbles - 1; i > 0; --i) {
  ------------------
  |  Branch (108:36): [True: 20.9k, False: 82]
  ------------------
  109|  20.9k|      x.square_this_n_times(ws, m_window_bits);
  110|  20.9k|      const_time_lookup(e_bits, m_g, scalar.get_substring(m_window_bits * (i - 1), m_window_bits));
  111|  20.9k|      x.mul_by(e_bits, ws);
  112|  20.9k|   }
  113|       |
  114|     82|   CT::unpoison(x);
  115|     82|   return x;
  116|     82|}
_ZNK5Botan31Montgomery_Exponentiation_State22exponentiation_vartimeERKNS_6BigIntE:
  118|    329|Montgomery_Int Montgomery_Exponentiation_State::exponentiation_vartime(const BigInt& scalar) const {
  119|    329|   const size_t exp_nibbles = (scalar.bits() + m_window_bits - 1) / m_window_bits;
  120|       |
  121|    329|   secure_vector<word> ws(2 * m_params.p_words());
  122|       |
  123|    329|   if(exp_nibbles == 0) {
  ------------------
  |  Branch (123:7): [True: 0, False: 329]
  ------------------
  124|      0|      return Montgomery_Int::one(m_params);
  125|      0|   }
  126|       |
  127|    329|   Montgomery_Int x = m_g[scalar.get_substring(m_window_bits * (exp_nibbles - 1), m_window_bits)];
  128|       |
  129|  5.59k|   for(size_t i = exp_nibbles - 1; i > 0; --i) {
  ------------------
  |  Branch (129:36): [True: 5.26k, False: 329]
  ------------------
  130|  5.26k|      x.square_this_n_times(ws, m_window_bits);
  131|       |
  132|  5.26k|      const uint32_t nibble = scalar.get_substring(m_window_bits * (i - 1), m_window_bits);
  133|  5.26k|      if(nibble > 0) {
  ------------------
  |  Branch (133:10): [True: 329, False: 4.93k]
  ------------------
  134|    329|         x.mul_by(m_g[nibble], ws);
  135|    329|      }
  136|  5.26k|   }
  137|       |
  138|    329|   CT::unpoison(x);
  139|    329|   return x;
  140|    329|}
_ZN5Botan16monty_precomputeERKNS_14Montgomery_IntEmb:
  144|  1.49k|                                                                        bool const_time) {
  145|  1.49k|   return std::make_shared<const Montgomery_Exponentiation_State>(g, window_bits, const_time);
  146|  1.49k|}
_ZN5Botan16monty_precomputeERKNS_17Montgomery_ParamsERKNS_6BigIntEmb:
  151|  1.49k|                                                                        bool const_time) {
  152|  1.49k|   BOTAN_ARG_CHECK(g.signum() >= 0 && g < params.p(), "Montgomery exponentiation base integer out of range");
  ------------------
  |  |   35|  1.49k|   do {                                                          \
  |  |   36|  1.49k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.99k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 1.49k, False: 0]
  |  |  |  Branch (37:12): [True: 1.49k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.49k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.49k]
  |  |  ------------------
  ------------------
  153|  1.49k|   const Montgomery_Int monty_g(params, g);
  154|  1.49k|   return monty_precompute(monty_g, window_bits, const_time);
  155|  1.49k|}
_ZN5Botan13monty_executeERKNS_31Montgomery_Exponentiation_StateERKNS_6BigIntEm:
  159|     82|                             size_t max_k_bits) {
  160|     82|   return precomputed_state.exponentiation(k, max_k_bits);
  161|     82|}
_ZN5Botan21monty_execute_vartimeERKNS_31Montgomery_Exponentiation_StateERKNS_6BigIntE:
  163|    329|Montgomery_Int monty_execute_vartime(const Montgomery_Exponentiation_State& precomputed_state, const BigInt& k) {
  164|    329|   return precomputed_state.exponentiation_vartime(k);
  165|    329|}
_ZN5Botan15monty_multi_expERKNS_17Montgomery_ParamsERKNS_6BigIntES5_S5_S5_:
  168|  1.02k|   const Montgomery_Params& params_p, const BigInt& x_bn, const BigInt& z1, const BigInt& y_bn, const BigInt& z2) {
  169|  1.02k|   if(z1.signum() < 0 || z2.signum() < 0) {
  ------------------
  |  Branch (169:7): [True: 0, False: 1.02k]
  |  Branch (169:26): [True: 0, False: 1.02k]
  ------------------
  170|      0|      throw Invalid_Argument("multi_exponentiate exponents must be positive");
  171|      0|   }
  172|       |
  173|  1.02k|   const size_t z_bits = round_up(std::max(z1.bits(), z2.bits()), 2);
  174|       |
  175|  1.02k|   secure_vector<word> ws(2 * params_p.p_words());
  176|       |
  177|  1.02k|   const Montgomery_Int one = Montgomery_Int::one(params_p);
  178|       |
  179|  1.02k|   const Montgomery_Int x1(params_p, x_bn);
  180|  1.02k|   const Montgomery_Int x2 = x1.square(ws);
  181|  1.02k|   const Montgomery_Int x3 = x2.mul(x1, ws);
  182|       |
  183|  1.02k|   const Montgomery_Int y1(params_p, y_bn);
  184|  1.02k|   const Montgomery_Int y2 = y1.square(ws);
  185|  1.02k|   const Montgomery_Int y3 = y2.mul(y1, ws);
  186|       |
  187|  1.02k|   const Montgomery_Int y1x1 = y1.mul(x1, ws);
  188|  1.02k|   const Montgomery_Int y1x2 = y1.mul(x2, ws);
  189|  1.02k|   const Montgomery_Int y1x3 = y1.mul(x3, ws);
  190|       |
  191|  1.02k|   const Montgomery_Int y2x1 = y2.mul(x1, ws);
  192|  1.02k|   const Montgomery_Int y2x2 = y2.mul(x2, ws);
  193|  1.02k|   const Montgomery_Int y2x3 = y2.mul(x3, ws);
  194|       |
  195|  1.02k|   const Montgomery_Int y3x1 = y3.mul(x1, ws);
  196|  1.02k|   const Montgomery_Int y3x2 = y3.mul(x2, ws);
  197|  1.02k|   const Montgomery_Int y3x3 = y3.mul(x3, ws);
  198|       |
  199|       |   // NOLINTNEXTLINE(*-const-correctness) bug in clang-tidy
  200|  1.02k|   const Montgomery_Int* M[16] = {&one,
  201|  1.02k|                                  &x1,  // 0001
  202|  1.02k|                                  &x2,  // 0010
  203|  1.02k|                                  &x3,  // 0011
  204|  1.02k|                                  &y1,  // 0100
  205|  1.02k|                                  &y1x1,
  206|  1.02k|                                  &y1x2,
  207|  1.02k|                                  &y1x3,
  208|  1.02k|                                  &y2,  // 1000
  209|  1.02k|                                  &y2x1,
  210|  1.02k|                                  &y2x2,
  211|  1.02k|                                  &y2x3,
  212|  1.02k|                                  &y3,  // 1100
  213|  1.02k|                                  &y3x1,
  214|  1.02k|                                  &y3x2,
  215|  1.02k|                                  &y3x3};
  216|       |
  217|  1.02k|   Montgomery_Int H = one;
  218|       |
  219|  82.9k|   for(size_t i = 0; i != z_bits; i += 2) {
  ------------------
  |  Branch (219:22): [True: 81.9k, False: 1.02k]
  ------------------
  220|  81.9k|      if(i > 0) {
  ------------------
  |  Branch (220:10): [True: 80.8k, False: 1.02k]
  ------------------
  221|  80.8k|         H.square_this_n_times(ws, 2);
  222|  80.8k|      }
  223|       |
  224|  81.9k|      const uint32_t z1_b = z1.get_substring(z_bits - i - 2, 2);
  225|  81.9k|      const uint32_t z2_b = z2.get_substring(z_bits - i - 2, 2);
  226|       |
  227|  81.9k|      const uint32_t z12 = (4 * z2_b) + z1_b;
  228|       |
  229|  81.9k|      if(z12 > 0) {
  ------------------
  |  Branch (229:10): [True: 76.6k, False: 5.27k]
  ------------------
  230|  76.6k|         H.mul_by(*M[z12], ws);
  231|  76.6k|      }
  232|  81.9k|   }
  233|       |
  234|  1.02k|   return H;
  235|  1.02k|}
monty_exp.cpp:_ZN5Botan12_GLOBAL__N_117const_time_lookupERNSt3__16vectorImNS_16secure_allocatorImEEEERKNS2_INS_14Montgomery_IntENS1_9allocatorIS7_EEEEm:
   66|  20.9k|void const_time_lookup(secure_vector<word>& output, const std::vector<Montgomery_Int>& g, size_t nibble) {
   67|  20.9k|   BOTAN_ASSERT_NOMSG(g.size() % 2 == 0);  // actually a power of 2
  ------------------
  |  |   77|  20.9k|   do {                                                                     \
  |  |   78|  20.9k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  20.9k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 20.9k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  20.9k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 20.9k]
  |  |  ------------------
  ------------------
   68|       |
   69|  20.9k|   const size_t words = output.size();
   70|       |
   71|  20.9k|   clear_mem(output.data(), output.size());
   72|       |
   73|   188k|   for(size_t i = 0; i != g.size(); i += 2) {
  ------------------
  |  Branch (73:22): [True: 167k, False: 20.9k]
  ------------------
   74|   167k|      const secure_vector<word>& vec_0 = g[i].repr();
   75|   167k|      const secure_vector<word>& vec_1 = g[i + 1].repr();
   76|       |
   77|   167k|      BOTAN_ASSERT_NOMSG(vec_0.size() >= words && vec_1.size() >= words);
  ------------------
  |  |   77|   167k|   do {                                                                     \
  |  |   78|   167k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   335k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:12): [True: 167k, False: 0]
  |  |  |  Branch (79:12): [True: 167k, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   167k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 167k]
  |  |  ------------------
  ------------------
   78|       |
   79|   167k|      const auto mask_0 = CT::Mask<word>::is_equal(nibble, i);
   80|   167k|      const auto mask_1 = CT::Mask<word>::is_equal(nibble, i + 1);
   81|       |
   82|  2.85M|      for(size_t w = 0; w != words; ++w) {
  ------------------
  |  Branch (82:25): [True: 2.68M, False: 167k]
  ------------------
   83|  2.68M|         output[w] |= mask_0.if_set_return(vec_0[w]);
   84|  2.68M|         output[w] |= mask_1.if_set_return(vec_1[w]);
   85|  2.68M|      }
   86|   167k|   }
   87|  20.9k|}

_ZN5Botan6PCurve15PrimeOrderCurve6Scalar8_zeroizeEv:
   16|   154k|void PrimeOrderCurve::Scalar::_zeroize() {
   17|   154k|   secure_zeroize_buffer(m_value.data(), m_value.size() * sizeof(word));
   18|   154k|}
_ZN5Botan6PCurve15PrimeOrderCurve15for_named_curveENSt3__117basic_string_viewIcNS2_11char_traitsIcEEEE:
   32|      3|std::shared_ptr<const PrimeOrderCurve> PrimeOrderCurve::for_named_curve(std::string_view name) {
   33|      3|#if defined(BOTAN_HAS_PCURVES_SECP256R1)
   34|      3|   if(name == "secp256r1") {
  ------------------
  |  Branch (34:7): [True: 1, False: 2]
  ------------------
   35|      1|      return PCurveInstance::secp256r1();
   36|      1|   }
   37|      2|#endif
   38|       |
   39|      2|#if defined(BOTAN_HAS_PCURVES_SECP384R1)
   40|      2|   if(name == "secp384r1") {
  ------------------
  |  Branch (40:7): [True: 0, False: 2]
  ------------------
   41|      0|      return PCurveInstance::secp384r1();
   42|      0|   }
   43|      2|#endif
   44|       |
   45|      2|#if defined(BOTAN_HAS_PCURVES_SECP521R1)
   46|      2|   if(name == "secp521r1") {
  ------------------
  |  Branch (46:7): [True: 0, False: 2]
  ------------------
   47|      0|      return PCurveInstance::secp521r1();
   48|      0|   }
   49|      2|#endif
   50|       |
   51|       |#if defined(BOTAN_HAS_PCURVES_BRAINPOOL256R1)
   52|       |   if(name == "brainpool256r1") {
   53|       |      return PCurveInstance::brainpool256r1();
   54|       |   }
   55|       |#endif
   56|       |
   57|       |#if defined(BOTAN_HAS_PCURVES_BRAINPOOL384R1)
   58|       |   if(name == "brainpool384r1") {
   59|       |      return PCurveInstance::brainpool384r1();
   60|       |   }
   61|       |#endif
   62|       |
   63|       |#if defined(BOTAN_HAS_PCURVES_BRAINPOOL512R1)
   64|       |   if(name == "brainpool512r1") {
   65|       |      return PCurveInstance::brainpool512r1();
   66|       |   }
   67|       |#endif
   68|       |
   69|       |#if defined(BOTAN_HAS_PCURVES_FRP256V1)
   70|       |   if(name == "frp256v1") {
   71|       |      return PCurveInstance::frp256v1();
   72|       |   }
   73|       |#endif
   74|       |
   75|      2|#if defined(BOTAN_HAS_PCURVES_SECP192R1)
   76|      2|   if(name == "secp192r1") {
  ------------------
  |  Branch (76:7): [True: 0, False: 2]
  ------------------
   77|      0|      return PCurveInstance::secp192r1();
   78|      0|   }
   79|      2|#endif
   80|       |
   81|       |#if defined(BOTAN_HAS_PCURVES_SECP224R1)
   82|       |   if(name == "secp224r1") {
   83|       |      return PCurveInstance::secp224r1();
   84|       |   }
   85|       |#endif
   86|       |
   87|      2|#if defined(BOTAN_HAS_PCURVES_SECP256K1)
   88|      2|   if(name == "secp256k1") {
  ------------------
  |  Branch (88:7): [True: 1, False: 1]
  ------------------
   89|      1|      return PCurveInstance::secp256k1();
   90|      1|   }
   91|      1|#endif
   92|       |
   93|      1|#if defined(BOTAN_HAS_PCURVES_SM2P256V1)
   94|      1|   if(name == "sm2p256v1") {
  ------------------
  |  Branch (94:7): [True: 1, False: 0]
  ------------------
   95|      1|      return PCurveInstance::sm2p256v1();
   96|      1|   }
   97|      0|#endif
   98|       |
   99|       |#if defined(BOTAN_HAS_PCURVES_NUMSP512D1)
  100|       |   if(name == "numsp512d1") {
  101|       |      return PCurveInstance::numsp512d1();
  102|       |   }
  103|       |#endif
  104|       |
  105|      0|   BOTAN_UNUSED(name);
  ------------------
  |  |  144|      0|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  106|      0|   return {};
  107|      1|}

_ZN5Botan6PCurve14PCurveInstance9secp256k1Ev:
  233|      1|std::shared_ptr<const PrimeOrderCurve> PCurveInstance::secp256k1() {
  234|      1|   return PrimeOrderCurveImpl<secp256k1::Curve>::instance();
  235|      1|}
pcurves_secp256k1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE3oneEv:
   28|   133k|      constexpr static std::array<W, N> one() { return std::array<W, N>{1}; }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE4redcERKNSt3__15arrayImLm8EEE:
   30|  4.96M|      constexpr static std::array<W, N> redc(const std::array<W, 2 * N>& z) {
   31|  4.96M|         return redc_crandall<W, N, C>(std::span{z});
   32|  4.96M|      }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE8from_repERKNSt3__15arrayImLm4EEE:
   38|  8.82k|      constexpr static std::array<W, N> from_rep(const std::array<W, N>& z) { return z; }
pcurves_secp256k1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19secp256k112Secp256k1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE6to_repERKNSt3__15arrayImLm4EEE:
   34|  6.35k|      constexpr static std::array<W, N> to_rep(const std::array<W, N>& x) { return x; }

_ZN5Botan6PCurve14PCurveInstance9secp256r1Ev:
  268|      1|std::shared_ptr<const PrimeOrderCurve> PCurveInstance::secp256r1() {
  269|      1|   return PrimeOrderCurveImpl<secp256r1::Curve>::instance();
  270|      1|}
pcurves_secp256r1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS1_9secp256r16ParamsES2_E11FieldParamsEE3oneEv:
   77|   518k|      constexpr static std::array<W, N> one() { return std::array<W, N>{1}; }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS1_9secp256r16ParamsES2_E11FieldParamsEE4redcERKNSt3__15arrayImLm8EEE:
   27|  20.9M|      constexpr static std::array<W, N> redc(const std::array<W, 2 * N>& z) {
   28|  20.9M|         const int64_t X00 = get_uint32(z.data(), 0);
   29|  20.9M|         const int64_t X01 = get_uint32(z.data(), 1);
   30|  20.9M|         const int64_t X02 = get_uint32(z.data(), 2);
   31|  20.9M|         const int64_t X03 = get_uint32(z.data(), 3);
   32|  20.9M|         const int64_t X04 = get_uint32(z.data(), 4);
   33|  20.9M|         const int64_t X05 = get_uint32(z.data(), 5);
   34|  20.9M|         const int64_t X06 = get_uint32(z.data(), 6);
   35|  20.9M|         const int64_t X07 = get_uint32(z.data(), 7);
   36|  20.9M|         const int64_t X08 = get_uint32(z.data(), 8);
   37|  20.9M|         const int64_t X09 = get_uint32(z.data(), 9);
   38|  20.9M|         const int64_t X10 = get_uint32(z.data(), 10);
   39|  20.9M|         const int64_t X11 = get_uint32(z.data(), 11);
   40|  20.9M|         const int64_t X12 = get_uint32(z.data(), 12);
   41|  20.9M|         const int64_t X13 = get_uint32(z.data(), 13);
   42|  20.9M|         const int64_t X14 = get_uint32(z.data(), 14);
   43|  20.9M|         const int64_t X15 = get_uint32(z.data(), 15);
   44|       |
   45|       |         // See SP 800-186 section G.1.2
   46|  20.9M|         const int64_t S0 = P256_4[0] + X00 + X08 + X09 - (X11 + X12 + X13 + X14);
   47|  20.9M|         const int64_t S1 = P256_4[1] + X01 + X09 + X10 - (X12 + X13 + X14 + X15);
   48|  20.9M|         const int64_t S2 = P256_4[2] + X02 + X10 + X11 - (X13 + X14 + X15);
   49|  20.9M|         const int64_t S3 = P256_4[3] + X03 + 2 * (X11 + X12) + X13 - (X15 + X08 + X09);
   50|  20.9M|         const int64_t S4 = P256_4[4] + X04 + 2 * (X12 + X13) + X14 - (X09 + X10);
   51|  20.9M|         const int64_t S5 = P256_4[5] + X05 + 2 * (X13 + X14) + X15 - (X10 + X11);
   52|  20.9M|         const int64_t S6 = P256_4[6] + X06 + X13 + X14 * 3 + X15 * 2 - (X08 + X09);
   53|  20.9M|         const int64_t S7 = P256_4[7] + X07 + X15 * 3 + X08 - (X10 + X11 + X12 + X13);
   54|  20.9M|         const int64_t S8 = P256_4[8];
   55|       |
   56|  20.9M|         std::array<W, N> r = {};
   57|       |
   58|  20.9M|         SolinasAccum sum(r);
   59|       |
   60|  20.9M|         sum.accum(S0);
   61|  20.9M|         sum.accum(S1);
   62|  20.9M|         sum.accum(S2);
   63|  20.9M|         sum.accum(S3);
   64|  20.9M|         sum.accum(S4);
   65|  20.9M|         sum.accum(S5);
   66|  20.9M|         sum.accum(S6);
   67|  20.9M|         sum.accum(S7);
   68|  20.9M|         const auto S = sum.final_carry(S8);
   69|       |
   70|  20.9M|         BOTAN_DEBUG_ASSERT(S <= 8);
  ------------------
  |  |  130|  20.9M|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  20.9M|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 20.9M]
  |  |  ------------------
  ------------------
   71|       |
   72|  20.9M|         solinas_correct_redc<N>(r, P, p256_mul_mod_256(S));
   73|       |
   74|  20.9M|         return r;
   75|  20.9M|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS1_9secp256r16ParamsES2_E11FieldParamsEE16p256_mul_mod_256Em:
   89|  20.9M|      constexpr static std::array<W, N> p256_mul_mod_256(W i) {
   90|  20.9M|         static_assert(WordInfo<W>::bits == 32 || WordInfo<W>::bits == 64);
   91|       |
   92|       |         // For small i, multiples of P-256 have a simple structure so it's faster to
   93|       |         // compute the value directly vs a (constant time) table lookup
   94|       |
   95|  20.9M|         auto r = P;
   96|       |         if constexpr(WordInfo<W>::bits == 32) {
   97|       |            r[7] -= i;
   98|       |            r[6] += i;
   99|       |            r[3] += i;
  100|       |            r[0] -= i;
  101|  20.9M|         } else {
  102|  20.9M|            const uint64_t i32 = static_cast<uint64_t>(i) << 32;
  103|  20.9M|            r[3] -= i32;
  104|  20.9M|            r[3] += i;
  105|  20.9M|            r[1] += i32;
  106|  20.9M|            r[0] -= i;
  107|  20.9M|         }
  108|  20.9M|         return r;
  109|  20.9M|      }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS1_9secp256r16ParamsES2_E11FieldParamsEE8from_repERKNSt3__15arrayImLm4EEE:
   83|  34.6k|      constexpr static std::array<W, N> from_rep(const std::array<W, N>& z) { return z; }
pcurves_secp256r1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_112Secp256r1RepINS_13EllipticCurveINS1_9secp256r16ParamsES2_E11FieldParamsEE6to_repERKNSt3__15arrayImLm4EEE:
   79|  24.7k|      constexpr static std::array<W, N> to_rep(const std::array<W, N>& x) { return x; }

_ZN5Botan6PCurve14PCurveInstance9sm2p256v1Ev:
  199|      1|std::shared_ptr<const PrimeOrderCurve> PCurveInstance::sm2p256v1() {
  200|      1|   return PrimeOrderCurveImpl<sm2p256v1::Curve>::instance();
  201|      1|}
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE3oneEv:
   71|      1|      constexpr static std::array<W, N> one() { return std::array<W, N>{1}; }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE4redcERKNSt3__15arrayImLm8EEE:
   25|  29.4k|      constexpr static std::array<W, N> redc(const std::array<W, 2 * N>& z) {
   26|  29.4k|         const int64_t X00 = get_uint32(z.data(), 0);
   27|  29.4k|         const int64_t X01 = get_uint32(z.data(), 1);
   28|  29.4k|         const int64_t X02 = get_uint32(z.data(), 2);
   29|  29.4k|         const int64_t X03 = get_uint32(z.data(), 3);
   30|  29.4k|         const int64_t X04 = get_uint32(z.data(), 4);
   31|  29.4k|         const int64_t X05 = get_uint32(z.data(), 5);
   32|  29.4k|         const int64_t X06 = get_uint32(z.data(), 6);
   33|  29.4k|         const int64_t X07 = get_uint32(z.data(), 7);
   34|  29.4k|         const int64_t X08 = get_uint32(z.data(), 8);
   35|  29.4k|         const int64_t X09 = get_uint32(z.data(), 9);
   36|  29.4k|         const int64_t X10 = get_uint32(z.data(), 10);
   37|  29.4k|         const int64_t X11 = get_uint32(z.data(), 11);
   38|  29.4k|         const int64_t X12 = get_uint32(z.data(), 12);
   39|  29.4k|         const int64_t X13 = get_uint32(z.data(), 13);
   40|  29.4k|         const int64_t X14 = get_uint32(z.data(), 14);
   41|  29.4k|         const int64_t X15 = get_uint32(z.data(), 15);
   42|       |
   43|  29.4k|         const int64_t S0 = X00 + X08 + X09 + X10 + X11 + X12 + 2 * (X13 + X14 + X15);
   44|  29.4k|         const int64_t S1 = X01 + X09 + X10 + X11 + X12 + X13 + 2 * (X14 + X15);
   45|  29.4k|         const int64_t S2 = X02 - (X08 + X09 + X13 + X14);
   46|  29.4k|         const int64_t S3 = X03 + X08 + X11 + X12 + 2 * X13 + X14 + X15;
   47|  29.4k|         const int64_t S4 = X04 + X09 + X12 + X13 + 2 * X14 + X15;
   48|  29.4k|         const int64_t S5 = X05 + X10 + X13 + X14 + 2 * X15;
   49|  29.4k|         const int64_t S6 = X06 + X11 + X14 + X15;
   50|  29.4k|         const int64_t S7 = X07 + X08 + X09 + X10 + X11 + 2 * (X12 + X13 + X14 + X15) + X15;
   51|       |
   52|  29.4k|         std::array<W, N> r = {};
   53|       |
   54|  29.4k|         SolinasAccum sum(r);
   55|       |
   56|  29.4k|         sum.accum(S0);
   57|  29.4k|         sum.accum(S1);
   58|  29.4k|         sum.accum(S2);
   59|  29.4k|         sum.accum(S3);
   60|  29.4k|         sum.accum(S4);
   61|  29.4k|         sum.accum(S5);
   62|  29.4k|         sum.accum(S6);
   63|  29.4k|         sum.accum(S7);
   64|  29.4k|         const auto S = sum.final_carry(0);
   65|       |
   66|  29.4k|         solinas_correct_redc<N>(r, P, sm2_mul_mod_256(S));
   67|       |
   68|  29.4k|         return r;
   69|  29.4k|      }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE15sm2_mul_mod_256Em:
   83|  29.4k|      constexpr static std::array<W, N> sm2_mul_mod_256(W i) {
   84|  29.4k|         static_assert(WordInfo<W>::bits == 32 || WordInfo<W>::bits == 64);
   85|       |
   86|       |         // For small i, multiples of P have a simple structure so it's faster to
   87|       |         // compute the value directly vs a (constant time) table lookup
   88|       |
   89|  29.4k|         auto r = P;
   90|       |         if constexpr(WordInfo<W>::bits == 32) {
   91|       |            r[7] -= i;
   92|       |            r[3] -= i;
   93|       |            r[2] += i;
   94|       |            r[0] -= i;
   95|  29.4k|         } else {
   96|  29.4k|            const uint64_t i32 = static_cast<uint64_t>(i) << 32;
   97|  29.4k|            r[3] -= i32;
   98|  29.4k|            r[1] -= i32;
   99|  29.4k|            r[1] += i;
  100|  29.4k|            r[0] -= i;
  101|  29.4k|         }
  102|  29.4k|         return r;
  103|  29.4k|      }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE8from_repERKNSt3__15arrayImLm4EEE:
   77|      1|      constexpr static std::array<W, N> from_rep(const std::array<W, N>& z) { return z; }
pcurves_sm2p256v1.cpp:_ZN5Botan6PCurve12_GLOBAL__N_19sm2p256v112Sm2p256v1RepINS_13EllipticCurveINS2_6ParamsES3_E11FieldParamsEE6to_repERKNSt3__15arrayImLm4EEE:
   73|      5|      constexpr static std::array<W, N> to_rep(const std::array<W, N>& x) { return x; }

_ZN5Botan9AEAD_Mode6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEENS_10Cipher_DirES5_:
   63|  31.7k|std::unique_ptr<AEAD_Mode> AEAD_Mode::create(std::string_view algo, Cipher_Dir dir, std::string_view provider) {
   64|  31.7k|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|  31.7k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
   65|       |#if defined(BOTAN_HAS_AEAD_CHACHA20_POLY1305)
   66|       |   if(algo == "ChaCha20Poly1305") {
   67|       |      if(dir == Cipher_Dir::Encryption) {
   68|       |         return std::make_unique<ChaCha20Poly1305_Encryption>();
   69|       |      } else {
   70|       |         return std::make_unique<ChaCha20Poly1305_Decryption>();
   71|       |      }
   72|       |   }
   73|       |#endif
   74|       |
   75|       |#if defined(BOTAN_HAS_ASCON_AEAD128)
   76|       |   if(algo == "Ascon-AEAD128") {
   77|       |      if(dir == Cipher_Dir::Encryption) {
   78|       |         return std::make_unique<Ascon_AEAD128_Encryption>();
   79|       |      } else {
   80|       |         return std::make_unique<Ascon_AEAD128_Decryption>();
   81|       |      }
   82|       |   }
   83|       |#endif
   84|       |
   85|  31.7k|   if(algo.find('/') != std::string::npos) {
  ------------------
  |  Branch (85:7): [True: 15.8k, False: 15.8k]
  ------------------
   86|  15.8k|      const std::vector<std::string> algo_parts = split_on(algo, '/');
   87|  15.8k|      if(algo_parts.size() < 2) {
  ------------------
  |  Branch (87:10): [True: 0, False: 15.8k]
  ------------------
   88|      0|         return std::unique_ptr<AEAD_Mode>();
   89|      0|      }
   90|  15.8k|      const std::string_view cipher_name = algo_parts[0];
   91|  15.8k|      const std::vector<std::string> mode_info = parse_algorithm_name(algo_parts[1]);
   92|       |
   93|  15.8k|      if(mode_info.empty()) {
  ------------------
  |  Branch (93:10): [True: 0, False: 15.8k]
  ------------------
   94|      0|         return std::unique_ptr<AEAD_Mode>();
   95|      0|      }
   96|       |
   97|  15.8k|      std::ostringstream mode_name;
   98|       |
   99|  15.8k|      mode_name << mode_info[0] << '(' << cipher_name;
  100|  15.8k|      for(size_t i = 1; i < mode_info.size(); ++i) {
  ------------------
  |  Branch (100:25): [True: 0, False: 15.8k]
  ------------------
  101|      0|         mode_name << ',' << mode_info[i];
  102|      0|      }
  103|  15.8k|      for(size_t i = 2; i < algo_parts.size(); ++i) {
  ------------------
  |  Branch (103:25): [True: 0, False: 15.8k]
  ------------------
  104|      0|         mode_name << ',' << algo_parts[i];
  105|      0|      }
  106|  15.8k|      mode_name << ')';
  107|       |
  108|  15.8k|      return AEAD_Mode::create(mode_name.str(), dir);
  109|  15.8k|   }
  110|       |
  111|  15.8k|#if defined(BOTAN_HAS_BLOCK_CIPHER)
  112|       |
  113|  15.8k|   const SCAN_Name req(algo);
  114|       |
  115|  15.8k|   if(req.arg_count() == 0) {
  ------------------
  |  Branch (115:7): [True: 0, False: 15.8k]
  ------------------
  116|      0|      return std::unique_ptr<AEAD_Mode>();
  117|      0|   }
  118|       |
  119|  15.8k|   auto bc = BlockCipher::create(req.arg(0), provider);
  120|       |
  121|  15.8k|   if(!bc) {
  ------------------
  |  Branch (121:7): [True: 0, False: 15.8k]
  ------------------
  122|      0|      return std::unique_ptr<AEAD_Mode>();
  123|      0|   }
  124|       |
  125|       |   #if defined(BOTAN_HAS_AEAD_CCM)
  126|       |   if(req.algo_name() == "CCM") {
  127|       |      const size_t tag_len = req.arg_as_integer(1, 16);
  128|       |      const size_t L_len = req.arg_as_integer(2, 3);
  129|       |      if(dir == Cipher_Dir::Encryption) {
  130|       |         return std::make_unique<CCM_Encryption>(std::move(bc), tag_len, L_len);
  131|       |      } else {
  132|       |         return std::make_unique<CCM_Decryption>(std::move(bc), tag_len, L_len);
  133|       |      }
  134|       |   }
  135|       |   #endif
  136|       |
  137|  15.8k|   #if defined(BOTAN_HAS_AEAD_GCM)
  138|  15.8k|   if(req.algo_name() == "GCM") {
  ------------------
  |  Branch (138:7): [True: 3.39k, False: 12.4k]
  ------------------
  139|  3.39k|      const size_t tag_len = req.arg_as_integer(1, 16);
  140|  3.39k|      if(dir == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (140:10): [True: 1.84k, False: 1.55k]
  ------------------
  141|  1.84k|         return std::make_unique<GCM_Encryption>(std::move(bc), tag_len);
  142|  1.84k|      } else {
  143|  1.55k|         return std::make_unique<GCM_Decryption>(std::move(bc), tag_len);
  144|  1.55k|      }
  145|  3.39k|   }
  146|  12.4k|   #endif
  147|       |
  148|       |   #if defined(BOTAN_HAS_AEAD_GCM_SIV)
  149|       |   if(req.algo_name() == "GCM-SIV") {
  150|       |      // Unlike GCM the tag length is fixed, so reject eg "AES-128/GCM-SIV(12)"
  151|       |      if(req.arg_count() != 1) {
  152|       |         return std::unique_ptr<AEAD_Mode>();
  153|       |      }
  154|       |      if(dir == Cipher_Dir::Encryption) {
  155|       |         return std::make_unique<GCM_SIV_Encryption>(std::move(bc));
  156|       |      } else {
  157|       |         return std::make_unique<GCM_SIV_Decryption>(std::move(bc));
  158|       |      }
  159|       |   }
  160|       |   #endif
  161|       |
  162|  12.4k|   #if defined(BOTAN_HAS_AEAD_OCB)
  163|  12.4k|   if(req.algo_name() == "OCB") {
  ------------------
  |  Branch (163:7): [True: 7.60k, False: 4.86k]
  ------------------
  164|  7.60k|      const size_t tag_len = req.arg_as_integer(1, 16);
  165|  7.60k|      if(dir == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (165:10): [True: 3.82k, False: 3.78k]
  ------------------
  166|  3.82k|         return std::make_unique<OCB_Encryption>(std::move(bc), tag_len);
  167|  3.82k|      } else {
  168|  3.78k|         return std::make_unique<OCB_Decryption>(std::move(bc), tag_len);
  169|  3.78k|      }
  170|  7.60k|   }
  171|  4.86k|   #endif
  172|       |
  173|  4.86k|   #if defined(BOTAN_HAS_AEAD_EAX)
  174|  4.86k|   if(req.algo_name() == "EAX") {
  ------------------
  |  Branch (174:7): [True: 4.86k, False: 0]
  ------------------
  175|  4.86k|      const size_t tag_len = req.arg_as_integer(1, bc->block_size());
  176|  4.86k|      if(dir == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (176:10): [True: 2.21k, False: 2.64k]
  ------------------
  177|  2.21k|         return std::make_unique<EAX_Encryption>(std::move(bc), tag_len);
  178|  2.64k|      } else {
  179|  2.64k|         return std::make_unique<EAX_Decryption>(std::move(bc), tag_len);
  180|  2.64k|      }
  181|  4.86k|   }
  182|      0|   #endif
  183|       |
  184|       |   #if defined(BOTAN_HAS_AEAD_SIV)
  185|       |   if(req.algo_name() == "SIV") {
  186|       |      if(dir == Cipher_Dir::Encryption) {
  187|       |         return std::make_unique<SIV_Encryption>(std::move(bc));
  188|       |      } else {
  189|       |         return std::make_unique<SIV_Decryption>(std::move(bc));
  190|       |      }
  191|       |   }
  192|       |   #endif
  193|       |
  194|      0|#endif
  195|       |
  196|      0|   return std::unique_ptr<AEAD_Mode>();
  197|  4.86k|}

_ZN5Botan8EAX_ModeC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
   42|  4.86k|      m_tag_size(tag_size),
   43|  4.86k|      m_cipher(std::move(cipher)),
   44|  4.86k|      m_ctr(std::make_unique<CTR_BE>(m_cipher->new_object())),
   45|  4.86k|      m_cmac(std::make_unique<CMAC>(m_cipher->new_object())) {
   46|  4.86k|   if(m_tag_size < 8 || m_tag_size > m_cmac->output_length()) {
  ------------------
  |  Branch (46:7): [True: 0, False: 4.86k]
  |  Branch (46:25): [True: 0, False: 4.86k]
  ------------------
   47|      0|      throw Invalid_Argument(fmt("Tag size {} is not allowed for {}", tag_size, name()));
   48|      0|   }
   49|  4.86k|}
_ZN5Botan8EAX_Mode5resetEv:
   59|   243k|void EAX_Mode::reset() {
   60|   243k|   m_nonce_mac.clear();
   61|       |
   62|       |   // Clear out any data added to the CMAC calculation
   63|   243k|   try {
   64|   243k|      m_cmac->final();
   65|   243k|   } catch(Key_Not_Set&) {}
   66|   243k|}
_ZNK5Botan8EAX_Mode18update_granularityEv:
   72|  4.86k|size_t EAX_Mode::update_granularity() const {
   73|  4.86k|   return 1;
   74|  4.86k|}
_ZNK5Botan8EAX_Mode17ideal_granularityEv:
   76|  9.72k|size_t EAX_Mode::ideal_granularity() const {
   77|  9.72k|   return m_cipher->parallel_bytes();
   78|  9.72k|}
_ZNK5Botan8EAX_Mode8key_specEv:
   80|  4.86k|Key_Length_Specification EAX_Mode::key_spec() const {
   81|  4.86k|   return m_ctr->key_spec();
   82|  4.86k|}
_ZN5Botan8EAX_Mode12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
   91|  4.86k|void EAX_Mode::key_schedule(std::span<const uint8_t> key) {
   92|       |   /*
   93|       |   * These could share the key schedule, which is one nice part of EAX,
   94|       |   * but it's much easier to ignore that here...
   95|       |   */
   96|  4.86k|   m_ctr->set_key(key);
   97|  4.86k|   m_cmac->set_key(key);
   98|       |
   99|       |   // m_ad_mac was precomputed under the previous CMAC key (if any).
  100|       |   // Re-keying invalidates it; AD must be re-set after set_key.
  101|  4.86k|   m_ad_mac.clear();
  102|       |
  103|       |   // Also drop any per-message state.
  104|  4.86k|   reset();
  105|  4.86k|}
_ZN5Botan8EAX_Mode21set_associated_data_nEmNSt3__14spanIKhLm18446744073709551615EEE:
  110|   239k|void EAX_Mode::set_associated_data_n(size_t idx, std::span<const uint8_t> ad) {
  111|   239k|   BOTAN_ARG_CHECK(idx == 0, "EAX: cannot handle non-zero index in set_associated_data_n");
  ------------------
  |  |   35|   239k|   do {                                                          \
  |  |   36|   239k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   239k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 239k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   239k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 239k]
  |  |  ------------------
  ------------------
  112|   239k|   if(!m_nonce_mac.empty()) {
  ------------------
  |  Branch (112:7): [True: 0, False: 239k]
  ------------------
  113|      0|      throw Invalid_State("Cannot set AD for EAX while processing a message");
  114|      0|   }
  115|   239k|   m_ad_mac = eax_prf(1, block_size(), *m_cmac, ad.data(), ad.size());
  116|   239k|}
_ZN5Botan8EAX_Mode9start_msgEPKhm:
  118|   239k|void EAX_Mode::start_msg(const uint8_t nonce[], size_t nonce_len) {
  119|   239k|   BOTAN_STATE_CHECK(m_nonce_mac.empty());
  ------------------
  |  |   51|   239k|   do {                                                         \
  |  |   52|   239k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   239k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 239k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   239k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 239k]
  |  |  ------------------
  ------------------
  120|       |
  121|   239k|   if(!valid_nonce_length(nonce_len)) {
  ------------------
  |  Branch (121:7): [True: 0, False: 239k]
  ------------------
  122|      0|      throw Invalid_IV_Length(name(), nonce_len);
  123|      0|   }
  124|       |
  125|   239k|   m_nonce_mac = eax_prf(0, block_size(), *m_cmac, nonce, nonce_len);
  126|       |
  127|   239k|   m_ctr->set_iv(m_nonce_mac.data(), m_nonce_mac.size());
  128|       |
  129|  3.83M|   for(size_t i = 0; i != block_size() - 1; ++i) {
  ------------------
  |  Branch (129:22): [True: 3.59M, False: 239k]
  ------------------
  130|  3.59M|      m_cmac->update(0);
  131|  3.59M|   }
  132|   239k|   m_cmac->update(2);
  133|   239k|}
_ZN5Botan14EAX_Encryption11process_msgEPhm:
  139|   360k|size_t EAX_Encryption::process_msg(uint8_t buf[], size_t sz) {
  140|   360k|   BOTAN_STATE_CHECK(!m_nonce_mac.empty());
  ------------------
  |  |   51|   360k|   do {                                                         \
  |  |   52|   360k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   360k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 360k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   360k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 360k]
  |  |  ------------------
  ------------------
  141|   360k|   m_ctr->cipher(buf, buf, sz);
  142|   360k|   m_cmac->update(buf, sz);
  143|   360k|   return sz;
  144|   360k|}
_ZN5Botan14EAX_Encryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  146|   163k|void EAX_Encryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  147|   163k|   BOTAN_STATE_CHECK(!m_nonce_mac.empty());
  ------------------
  |  |   51|   163k|   do {                                                         \
  |  |   52|   163k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   163k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 163k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   163k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 163k]
  |  |  ------------------
  ------------------
  148|   163k|   BOTAN_ARG_CHECK(buffer.size() >= offset, "Offset is out of range");
  ------------------
  |  |   35|   163k|   do {                                                          \
  |  |   36|   163k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   163k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 163k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   163k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 163k]
  |  |  ------------------
  ------------------
  149|   163k|   update(buffer, offset);
  150|       |
  151|   163k|   secure_vector<uint8_t> data_mac = m_cmac->final();
  152|   163k|   xor_buf(data_mac, m_nonce_mac, data_mac.size());
  153|       |
  154|   163k|   if(m_ad_mac.empty()) {
  ------------------
  |  Branch (154:7): [True: 0, False: 163k]
  ------------------
  155|      0|      m_ad_mac = eax_prf(1, block_size(), *m_cmac, nullptr, 0);
  156|      0|   }
  157|       |
  158|   163k|   xor_buf(data_mac, m_ad_mac, data_mac.size());
  159|       |
  160|   163k|   buffer += std::make_pair(data_mac.data(), tag_size());
  161|       |
  162|   163k|   m_nonce_mac.clear();
  163|   163k|}
_ZN5Botan14EAX_Decryption11process_msgEPhm:
  170|   489k|size_t EAX_Decryption::process_msg(uint8_t buf[], size_t sz) {
  171|   489k|   BOTAN_STATE_CHECK(!m_nonce_mac.empty());
  ------------------
  |  |   51|   489k|   do {                                                         \
  |  |   52|   489k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   489k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 489k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   489k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 489k]
  |  |  ------------------
  ------------------
  172|   489k|   m_cmac->update(buf, sz);
  173|   489k|   m_ctr->cipher(buf, buf, sz);
  174|   489k|   return sz;
  175|   489k|}
_ZN5Botan14EAX_Decryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  177|  75.8k|void EAX_Decryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  178|  75.8k|   BOTAN_STATE_CHECK(!m_nonce_mac.empty());
  ------------------
  |  |   51|  75.8k|   do {                                                         \
  |  |   52|  75.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  75.8k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 75.8k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  75.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 75.8k]
  |  |  ------------------
  ------------------
  179|  75.8k|   BOTAN_ARG_CHECK(buffer.size() >= offset, "Offset is out of range");
  ------------------
  |  |   35|  75.8k|   do {                                                          \
  |  |   36|  75.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  75.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 75.8k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  75.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 75.8k]
  |  |  ------------------
  ------------------
  180|  75.8k|   const size_t sz = buffer.size() - offset;
  181|  75.8k|   uint8_t* buf = buffer.data() + offset;
  182|       |
  183|  75.8k|   BOTAN_ARG_CHECK(sz >= tag_size(), "input did not include the tag");
  ------------------
  |  |   35|  75.8k|   do {                                                          \
  |  |   36|  75.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  75.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 75.8k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  75.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 75.8k]
  |  |  ------------------
  ------------------
  184|       |
  185|  75.8k|   const size_t remaining = sz - tag_size();
  186|       |
  187|  75.8k|   if(remaining > 0) {
  ------------------
  |  Branch (187:7): [True: 75.0k, False: 810]
  ------------------
  188|  75.0k|      m_cmac->update(buf, remaining);
  189|  75.0k|      m_ctr->cipher(buf, buf, remaining);
  190|  75.0k|   }
  191|       |
  192|  75.8k|   const uint8_t* included_tag = &buf[remaining];
  193|       |
  194|  75.8k|   secure_vector<uint8_t> mac = m_cmac->final();
  195|  75.8k|   mac ^= m_nonce_mac;
  196|       |
  197|  75.8k|   if(m_ad_mac.empty()) {
  ------------------
  |  Branch (197:7): [True: 0, False: 75.8k]
  ------------------
  198|      0|      m_ad_mac = eax_prf(1, block_size(), *m_cmac, nullptr, 0);
  199|      0|   }
  200|       |
  201|  75.8k|   mac ^= m_ad_mac;
  202|       |
  203|  75.8k|   const bool accept_mac = CT::is_equal(mac.data(), included_tag, tag_size()).as_bool();
  204|       |
  205|  75.8k|   buffer.resize(offset + remaining);
  206|       |
  207|  75.8k|   m_nonce_mac.clear();
  208|       |
  209|  75.8k|   if(!accept_mac) {
  ------------------
  |  Branch (209:7): [True: 882, False: 74.9k]
  ------------------
  210|    882|      clear_mem(std::span{buffer}.subspan(offset, remaining));
  211|    882|      throw Invalid_Authentication_Tag("EAX tag check failed");
  212|    882|   }
  213|  75.8k|}
eax.cpp:_ZN5Botan12_GLOBAL__N_17eax_prfEhmRNS_25MessageAuthenticationCodeEPKhm:
   27|   479k|   uint8_t tag, size_t block_size, MessageAuthenticationCode& mac, const uint8_t in[], size_t length) {
   28|  7.66M|   for(size_t i = 0; i != block_size - 1; ++i) {
  ------------------
  |  Branch (28:22): [True: 7.18M, False: 479k]
  ------------------
   29|  7.18M|      mac.update(0);
   30|  7.18M|   }
   31|   479k|   mac.update(tag);
   32|   479k|   mac.update(in, length);
   33|   479k|   return mac.final();
   34|   479k|}

_ZN5Botan8GCM_ModeC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
   27|  3.39k|      m_tag_size(tag_size), m_cipher_name(cipher->name()) {
   28|  3.39k|   if(cipher->block_size() != GCM_BS) {
  ------------------
  |  Branch (28:7): [True: 93, False: 3.30k]
  ------------------
   29|     93|      throw Invalid_Argument("Invalid block cipher for GCM");
   30|     93|   }
   31|       |
   32|       |   /* We allow any of the values 128, 120, 112, 104, or 96 bits as a tag size */
   33|       |   /* 64 bit tag is still supported but deprecated and will be removed in the future */
   34|  3.30k|   if(m_tag_size != 8 && (m_tag_size < 12 || m_tag_size > 16)) {
  ------------------
  |  Branch (34:7): [True: 3.30k, False: 0]
  |  Branch (34:27): [True: 0, False: 3.30k]
  |  Branch (34:46): [True: 0, False: 3.30k]
  ------------------
   35|      0|      throw Invalid_Argument(fmt("{} cannot use a tag of {} bytes", name(), m_tag_size));
   36|      0|   }
   37|       |
   38|  3.30k|   m_ctr = std::make_unique<CTR_BE>(std::move(cipher), 4);
   39|  3.30k|   m_ghash = std::make_unique<GHASH>();
   40|  3.30k|}
_ZN5Botan8GCM_ModeD2Ev:
   42|  3.30k|GCM_Mode::~GCM_Mode() = default;
_ZN5Botan8GCM_Mode5resetEv:
   50|   105k|void GCM_Mode::reset() {
   51|   105k|   m_ghash->reset_state();
   52|   105k|   m_in_msg = false;
   53|   105k|}
_ZNK5Botan8GCM_Mode18update_granularityEv:
   63|   222k|size_t GCM_Mode::update_granularity() const {
   64|   222k|   return 1;
   65|   222k|}
_ZNK5Botan8GCM_Mode17ideal_granularityEv:
   67|  6.61k|size_t GCM_Mode::ideal_granularity() const {
   68|  6.61k|   return GCM_BS * std::max<size_t>(2, BlockCipher::ParallelismMult);
   69|  6.61k|}
_ZNK5Botan8GCM_Mode18valid_nonce_lengthEm:
   71|   102k|bool GCM_Mode::valid_nonce_length(size_t len) const {
   72|       |   // GCM does not support empty nonces
   73|   102k|   return (len > 0);
   74|   102k|}
_ZNK5Botan8GCM_Mode8key_specEv:
   76|  3.30k|Key_Length_Specification GCM_Mode::key_spec() const {
   77|  3.30k|   return m_ctr->key_spec();
   78|  3.30k|}
_ZN5Botan8GCM_Mode12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
   84|  3.30k|void GCM_Mode::key_schedule(std::span<const uint8_t> key) {
   85|  3.30k|   reset();
   86|  3.30k|   m_ctr->set_key(key);
   87|       |
   88|  3.30k|   std::array<uint8_t, GCM_BS> zeros{};
   89|  3.30k|   m_ctr->set_iv(zeros);
   90|       |
   91|  3.30k|   uint8_t H[GCM_BS] = {0};
   92|  3.30k|   m_ctr->encipher(H);
   93|  3.30k|   m_ghash->set_key(H);
   94|  3.30k|}
_ZN5Botan8GCM_Mode21set_associated_data_nEmNSt3__14spanIKhLm18446744073709551615EEE:
   96|   102k|void GCM_Mode::set_associated_data_n(size_t idx, std::span<const uint8_t> ad) {
   97|   102k|   BOTAN_ARG_CHECK(idx == 0, "GCM: cannot handle non-zero index in set_associated_data_n");
  ------------------
  |  |   35|   102k|   do {                                                          \
  |  |   36|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   102k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
   98|   102k|   m_ghash->set_associated_data(ad);
   99|   102k|}
_ZN5Botan8GCM_Mode9start_msgEPKhm:
  101|   102k|void GCM_Mode::start_msg(const uint8_t nonce[], size_t nonce_len) {
  102|   102k|   BOTAN_STATE_CHECK(!m_in_msg);
  ------------------
  |  |   51|   102k|   do {                                                         \
  |  |   52|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   102k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  103|       |
  104|   102k|   if(!valid_nonce_length(nonce_len)) {
  ------------------
  |  Branch (104:7): [True: 0, False: 102k]
  ------------------
  105|      0|      throw Invalid_IV_Length(name(), nonce_len);
  106|      0|   }
  107|       |
  108|   102k|   std::array<uint8_t, GCM_BS> y0 = {};
  109|       |
  110|   102k|   if(nonce_len == 12) {
  ------------------
  |  Branch (110:7): [True: 102k, False: 0]
  ------------------
  111|   102k|      copy_mem(y0.data(), nonce, nonce_len);
  112|   102k|      y0[15] = 1;
  113|   102k|   } else {
  114|      0|      m_ghash->nonce_hash(std::span<uint8_t, GCM_BS>(y0), {nonce, nonce_len});
  115|      0|   }
  116|       |
  117|   102k|   m_ctr->set_iv(y0.data(), y0.size());
  118|       |
  119|   102k|   clear_mem(y0.data(), y0.size());
  120|   102k|   m_ctr->encipher(y0);
  121|       |
  122|   102k|   m_ghash->start(y0);
  123|   102k|   secure_scrub_memory(y0);
  124|   102k|   m_in_msg = true;
  125|   102k|}
_ZN5Botan14GCM_Encryption11process_msgEPhm:
  131|   122k|size_t GCM_Encryption::process_msg(uint8_t buf[], size_t sz) {
  132|   122k|   BOTAN_STATE_CHECK(m_in_msg);
  ------------------
  |  |   51|   122k|   do {                                                         \
  |  |   52|   122k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   122k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 122k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   122k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 122k]
  |  |  ------------------
  ------------------
  133|   122k|   BOTAN_ARG_CHECK(sz % update_granularity() == 0, "Invalid buffer size");
  ------------------
  |  |   35|   122k|   do {                                                          \
  |  |   36|   122k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   122k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 122k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   122k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 122k]
  |  |  ------------------
  ------------------
  134|   122k|   m_ctr->cipher(buf, buf, sz);
  135|   122k|   m_ghash->update({buf, sz});
  136|   122k|   return sz;
  137|   122k|}
_ZN5Botan14GCM_Encryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  139|  72.4k|void GCM_Encryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  140|  72.4k|   BOTAN_STATE_CHECK(m_in_msg);
  ------------------
  |  |   51|  72.4k|   do {                                                         \
  |  |   52|  72.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  72.4k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 72.4k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  72.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 72.4k]
  |  |  ------------------
  ------------------
  141|  72.4k|   BOTAN_ARG_CHECK(offset <= buffer.size(), "Invalid offset");
  ------------------
  |  |   35|  72.4k|   do {                                                          \
  |  |   36|  72.4k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  72.4k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 72.4k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  72.4k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 72.4k]
  |  |  ------------------
  ------------------
  142|  72.4k|   const size_t sz = buffer.size() - offset;
  143|  72.4k|   uint8_t* buf = buffer.data() + offset;
  144|       |
  145|  72.4k|   m_ctr->cipher(buf, buf, sz);
  146|  72.4k|   m_ghash->update({buf, sz});
  147|       |
  148|  72.4k|   std::array<uint8_t, 16> mac = {0};
  149|  72.4k|   m_ghash->final(std::span(mac).first(tag_size()));
  150|  72.4k|   buffer += std::make_pair(mac.data(), tag_size());
  151|  72.4k|   m_in_msg = false;
  152|  72.4k|}
_ZN5Botan14GCM_Decryption11process_msgEPhm:
  159|  96.2k|size_t GCM_Decryption::process_msg(uint8_t buf[], size_t sz) {
  160|  96.2k|   BOTAN_STATE_CHECK(m_in_msg);
  ------------------
  |  |   51|  96.2k|   do {                                                         \
  |  |   52|  96.2k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  96.2k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 96.2k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  96.2k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 96.2k]
  |  |  ------------------
  ------------------
  161|  96.2k|   BOTAN_ARG_CHECK(sz % update_granularity() == 0, "Invalid buffer size");
  ------------------
  |  |   35|  96.2k|   do {                                                          \
  |  |   36|  96.2k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  96.2k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 96.2k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  96.2k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 96.2k]
  |  |  ------------------
  ------------------
  162|  96.2k|   m_ghash->update({buf, sz});
  163|  96.2k|   m_ctr->cipher(buf, buf, sz);
  164|  96.2k|   return sz;
  165|  96.2k|}
_ZN5Botan14GCM_Decryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  167|  29.8k|void GCM_Decryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  168|  29.8k|   BOTAN_STATE_CHECK(m_in_msg);
  ------------------
  |  |   51|  29.8k|   do {                                                         \
  |  |   52|  29.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  29.8k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 29.8k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  29.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 29.8k]
  |  |  ------------------
  ------------------
  169|  29.8k|   BOTAN_ARG_CHECK(offset <= buffer.size(), "Invalid offset");
  ------------------
  |  |   35|  29.8k|   do {                                                          \
  |  |   36|  29.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  29.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 29.8k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  29.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 29.8k]
  |  |  ------------------
  ------------------
  170|  29.8k|   const size_t sz = buffer.size() - offset;
  171|  29.8k|   uint8_t* buf = buffer.data() + offset;
  172|       |
  173|  29.8k|   BOTAN_ARG_CHECK(sz >= tag_size(), "input did not include the tag");
  ------------------
  |  |   35|  29.8k|   do {                                                          \
  |  |   36|  29.8k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  29.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 29.8k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  29.8k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 29.8k]
  |  |  ------------------
  ------------------
  174|       |
  175|  29.8k|   const size_t remaining = sz - tag_size();
  176|       |
  177|       |   // handle any final input before the tag
  178|  29.8k|   if(remaining > 0) {
  ------------------
  |  Branch (178:7): [True: 29.1k, False: 731]
  ------------------
  179|  29.1k|      m_ghash->update({buf, remaining});
  180|  29.1k|      m_ctr->cipher(buf, buf, remaining);
  181|  29.1k|   }
  182|       |
  183|  29.8k|   std::array<uint8_t, 16> mac = {0};
  184|  29.8k|   m_ghash->final(std::span(mac).first(tag_size()));
  185|       |
  186|  29.8k|   const uint8_t* included_tag = &buffer[remaining + offset];
  187|       |
  188|  29.8k|   m_in_msg = false;
  189|       |
  190|  29.8k|   if(!CT::is_equal(mac.data(), included_tag, tag_size()).as_bool()) {
  ------------------
  |  Branch (190:7): [True: 13, False: 29.8k]
  ------------------
  191|     13|      clear_mem(std::span{buffer}.subspan(offset, remaining));
  192|     13|      throw Invalid_Authentication_Tag("GCM tag check failed");
  193|     13|   }
  194|       |
  195|  29.8k|   buffer.resize(offset + remaining);
  196|  29.8k|}

_ZN5Botan8OCB_ModeC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
  166|  7.60k|      m_cipher(std::move(cipher)),
  167|  7.60k|      m_checksum(m_cipher->parallel_bytes()),
  168|  7.60k|      m_ad_hash(m_cipher->block_size()),
  169|  7.60k|      m_tag_size(tag_size),
  170|  7.60k|      m_block_size(m_cipher->block_size()),
  171|  7.60k|      m_par_blocks(m_cipher->parallel_bytes() / m_block_size) {
  172|  7.60k|   const size_t BS = block_size();
  173|       |
  174|       |   /*
  175|       |   * draft-krovetz-ocb-wide-d1 specifies OCB for several other block
  176|       |   * sizes but only 128, 192, 256 and 512 bit are currently supported
  177|       |   * by this implementation.
  178|       |   */
  179|  7.60k|   BOTAN_ARG_CHECK(BS == 16 || BS == 24 || BS == 32 || BS == 64, "Invalid block size for OCB");
  ------------------
  |  |   35|  7.60k|   do {                                                          \
  |  |   36|  7.60k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  23.6k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 7.33k, False: 276]
  |  |  |  Branch (37:12): [True: 0, False: 276]
  |  |  |  Branch (37:12): [True: 0, False: 276]
  |  |  |  Branch (37:12): [True: 0, False: 276]
  |  |  ------------------
  |  |   38|    276|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|    276|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|    276|      }                                                          \
  |  |   41|  7.60k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 7.60k]
  |  |  ------------------
  ------------------
  180|       |
  181|  7.60k|   BOTAN_ARG_CHECK(m_tag_size % 4 == 0 && m_tag_size >= 8 && m_tag_size <= BS && m_tag_size <= 32,
  ------------------
  |  |   35|  7.60k|   do {                                                          \
  |  |   36|  7.60k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  44.8k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 7.33k, False: 276]
  |  |  |  Branch (37:12): [True: 7.33k, False: 0]
  |  |  |  Branch (37:12): [True: 7.33k, False: 0]
  |  |  |  Branch (37:12): [True: 7.33k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  7.60k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 7.60k]
  |  |  ------------------
  ------------------
  182|  7.60k|                   "Invalid OCB tag length");
  183|  7.60k|}
_ZN5Botan8OCB_ModeD2Ev:
  185|  7.33k|OCB_Mode::~OCB_Mode() = default;
_ZN5Botan8OCB_Mode5resetEv:
  194|   765k|void OCB_Mode::reset() {
  195|   765k|   m_block_index = 0;
  196|   765k|   zeroise(m_checksum);
  197|   765k|   m_last_nonce.clear();
  198|   765k|   m_stretch.clear();
  199|   765k|   zeroise(m_nonce_buf);
  200|   765k|   zeroise(m_offset);
  201|   765k|   if(m_L) {
  ------------------
  |  Branch (201:7): [True: 765k, False: 0]
  ------------------
  202|   765k|      m_L->reset();
  203|   765k|   }
  204|   765k|}
_ZNK5Botan8OCB_Mode18valid_nonce_lengthEm:
  206|   379k|bool OCB_Mode::valid_nonce_length(size_t length) const {
  207|   379k|   if(length == 0) {
  ------------------
  |  Branch (207:7): [True: 0, False: 379k]
  ------------------
  208|      0|      return false;
  209|      0|   }
  210|   379k|   if(block_size() == 16) {
  ------------------
  |  Branch (210:7): [True: 379k, False: 0]
  ------------------
  211|   379k|      return length < 16;
  212|   379k|   } else {
  213|      0|      return length < (block_size() - 1);
  214|      0|   }
  215|   379k|}
_ZNK5Botan8OCB_Mode18update_granularityEv:
  221|   779k|size_t OCB_Mode::update_granularity() const {
  222|   779k|   return block_size();
  223|   779k|}
_ZNK5Botan8OCB_Mode17ideal_granularityEv:
  225|  14.6k|size_t OCB_Mode::ideal_granularity() const {
  226|  14.6k|   return (m_par_blocks * block_size());
  227|  14.6k|}
_ZNK5Botan8OCB_Mode8key_specEv:
  229|  7.33k|Key_Length_Specification OCB_Mode::key_spec() const {
  230|  7.33k|   return m_cipher->key_spec();
  231|  7.33k|}
_ZNK5Botan8OCB_Mode19has_keying_materialEv:
  233|  2.28M|bool OCB_Mode::has_keying_material() const {
  234|  2.28M|   return m_cipher->has_keying_material();
  235|  2.28M|}
_ZN5Botan8OCB_Mode12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  237|  7.33k|void OCB_Mode::key_schedule(std::span<const uint8_t> key) {
  238|  7.33k|   m_cipher->set_key(key);
  239|  7.33k|   m_L = std::make_unique<L_computer>(*m_cipher);
  240|       |
  241|       |   // Drop all key-dependent per-message state: m_last_nonce/m_stretch are
  242|       |   // cached for the update_nonce() fast path and would otherwise allow a
  243|       |   // start_msg() with a same-valued nonce under the new key to silently
  244|       |   // reuse the stretch computed under the previous key.
  245|  7.33k|   reset();
  246|       |
  247|       |   // m_ad_hash was precomputed against the previous L values and cipher
  248|       |   // key. Re-keying invalidates it; AD must be re-set after set_key.
  249|  7.33k|   zeroise(m_ad_hash);
  250|  7.33k|}
_ZN5Botan8OCB_Mode21set_associated_data_nEmNSt3__14spanIKhLm18446744073709551615EEE:
  252|   379k|void OCB_Mode::set_associated_data_n(size_t idx, std::span<const uint8_t> ad) {
  253|   379k|   BOTAN_ARG_CHECK(idx == 0, "OCB: cannot handle non-zero index in set_associated_data_n");
  ------------------
  |  |   35|   379k|   do {                                                          \
  |  |   36|   379k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   379k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 379k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   379k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 379k]
  |  |  ------------------
  ------------------
  254|   379k|   assert_key_material_set();
  255|   379k|   BOTAN_STATE_CHECK(!m_L->initialized());
  ------------------
  |  |   51|   379k|   do {                                                         \
  |  |   52|   379k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   379k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 379k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   379k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 379k]
  |  |  ------------------
  ------------------
  256|   379k|   m_ad_hash = ocb_hash(*m_L, *m_cipher, ad.data(), ad.size());
  257|   379k|}
_ZN5Botan8OCB_Mode12update_nonceEPKhm:
  259|   379k|const secure_vector<uint8_t>& OCB_Mode::update_nonce(const uint8_t nonce[], size_t nonce_len) {
  260|   379k|   const size_t BS = block_size();
  261|       |
  262|   379k|   BOTAN_ASSERT(BS == 16 || BS == 24 || BS == 32 || BS == 64, "OCB block size is supported");
  ------------------
  |  |   64|   379k|   do {                                                                                 \
  |  |   65|   379k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.13M|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:12): [True: 379k, False: 0]
  |  |  |  Branch (66:12): [True: 0, False: 0]
  |  |  |  Branch (66:12): [True: 0, False: 0]
  |  |  |  Branch (66:12): [True: 0, False: 0]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|   379k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 379k]
  |  |  ------------------
  ------------------
  263|       |
  264|       |   // NOLINTNEXTLINE(readability-avoid-nested-conditional-operator)
  265|   379k|   const size_t MASKLEN = (BS == 16 ? 6 : ((BS == 24) ? 7 : 8));
  ------------------
  |  Branch (265:28): [True: 379k, False: 0]
  |  Branch (265:44): [True: 0, False: 0]
  ------------------
  266|       |
  267|   379k|   const uint8_t BOTTOM_MASK = static_cast<uint8_t>((static_cast<uint16_t>(1) << MASKLEN) - 1);
  268|       |
  269|   379k|   m_nonce_buf.resize(BS);
  270|   379k|   clear_mem(m_nonce_buf.data(), m_nonce_buf.size());
  271|       |
  272|   379k|   copy_mem(&m_nonce_buf[BS - nonce_len], nonce, nonce_len);
  273|   379k|   m_nonce_buf[0] = static_cast<uint8_t>(((tag_size() * 8) % (BS * 8)) << (BS <= 16 ? 1 : 0));
  ------------------
  |  Branch (273:76): [True: 379k, False: 0]
  ------------------
  274|       |
  275|   379k|   m_nonce_buf[BS - nonce_len - 1] ^= 1;
  276|       |
  277|   379k|   const uint8_t bottom = m_nonce_buf[BS - 1] & BOTTOM_MASK;
  278|   379k|   m_nonce_buf[BS - 1] &= ~BOTTOM_MASK;
  279|       |
  280|   379k|   const bool need_new_stretch = (m_last_nonce != m_nonce_buf);
  281|       |
  282|   379k|   if(need_new_stretch) {
  ------------------
  |  Branch (282:7): [True: 379k, False: 0]
  ------------------
  283|   379k|      m_last_nonce = m_nonce_buf;
  284|       |
  285|   379k|      m_cipher->encrypt(m_nonce_buf);
  286|       |
  287|       |      /*
  288|       |      The loop bounds (BS vs BS/2) are derived from the relation
  289|       |      between the block size and the MASKLEN. Using the terminology
  290|       |      of draft-krovetz-ocb-wide, we have to derive enough bits in
  291|       |      ShiftedKtop to read up to BLOCKLEN+bottom bits from Stretch.
  292|       |
  293|       |                 +----------+---------+-------+---------+
  294|       |                 | BLOCKLEN | RESIDUE | SHIFT | MASKLEN |
  295|       |                 +----------+---------+-------+---------+
  296|       |                 |       32 |     141 |    17 |    4    |
  297|       |                 |       64 |      27 |    25 |    5    |
  298|       |                 |       96 |    1601 |    33 |    6    |
  299|       |                 |      128 |     135 |     8 |    6    |
  300|       |                 |      192 |     135 |    40 |    7    |
  301|       |                 |      256 |    1061 |     1 |    8    |
  302|       |                 |      384 |    4109 |    80 |    8    |
  303|       |                 |      512 |     293 |   176 |    8    |
  304|       |                 |     1024 |  524355 |   352 |    9    |
  305|       |                 +----------+---------+-------+---------+
  306|       |      */
  307|   379k|      if(BS == 16) {
  ------------------
  |  Branch (307:10): [True: 379k, False: 0]
  ------------------
  308|  3.41M|         for(size_t i = 0; i != BS / 2; ++i) {
  ------------------
  |  Branch (308:28): [True: 3.03M, False: 379k]
  ------------------
  309|  3.03M|            m_nonce_buf.push_back(m_nonce_buf[i] ^ m_nonce_buf[i + 1]);
  310|  3.03M|         }
  311|   379k|      } else if(BS == 24) {
  ------------------
  |  Branch (311:17): [True: 0, False: 0]
  ------------------
  312|      0|         for(size_t i = 0; i != 16; ++i) {
  ------------------
  |  Branch (312:28): [True: 0, False: 0]
  ------------------
  313|      0|            m_nonce_buf.push_back(m_nonce_buf[i] ^ m_nonce_buf[i + 5]);
  314|      0|         }
  315|      0|      } else if(BS == 32) {
  ------------------
  |  Branch (315:17): [True: 0, False: 0]
  ------------------
  316|      0|         for(size_t i = 0; i != BS; ++i) {
  ------------------
  |  Branch (316:28): [True: 0, False: 0]
  ------------------
  317|      0|            m_nonce_buf.push_back(m_nonce_buf[i] ^ (m_nonce_buf[i] << 1) ^ (m_nonce_buf[i + 1] >> 7));
  318|      0|         }
  319|      0|      } else if(BS == 64) {
  ------------------
  |  Branch (319:17): [True: 0, False: 0]
  ------------------
  320|      0|         for(size_t i = 0; i != BS / 2; ++i) {
  ------------------
  |  Branch (320:28): [True: 0, False: 0]
  ------------------
  321|      0|            m_nonce_buf.push_back(m_nonce_buf[i] ^ m_nonce_buf[i + 22]);
  322|      0|         }
  323|      0|      }
  324|       |
  325|   379k|      m_stretch = m_nonce_buf;
  326|   379k|   }
  327|       |
  328|       |   // now set the offset from stretch and bottom
  329|   379k|   const size_t shift_bytes = bottom / 8;
  330|   379k|   const size_t shift_bits = bottom % 8;
  331|       |
  332|   379k|   BOTAN_ASSERT(m_stretch.size() >= BS + shift_bytes + 1, "Size ok");
  ------------------
  |  |   64|   379k|   do {                                                                                 \
  |  |   65|   379k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|   379k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 379k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|   379k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 379k]
  |  |  ------------------
  ------------------
  333|       |
  334|   379k|   m_offset.resize(BS);
  335|  6.45M|   for(size_t i = 0; i != BS; ++i) {
  ------------------
  |  Branch (335:22): [True: 6.07M, False: 379k]
  ------------------
  336|  6.07M|      m_offset[i] = (m_stretch[i + shift_bytes] << shift_bits);
  337|  6.07M|      m_offset[i] |= (m_stretch[i + shift_bytes + 1] >> (8 - shift_bits));
  338|  6.07M|   }
  339|       |
  340|   379k|   return m_offset;
  341|   379k|}
_ZN5Botan8OCB_Mode9start_msgEPKhm:
  343|   379k|void OCB_Mode::start_msg(const uint8_t nonce[], size_t nonce_len) {
  344|   379k|   if(!valid_nonce_length(nonce_len)) {
  ------------------
  |  Branch (344:7): [True: 0, False: 379k]
  ------------------
  345|      0|      throw Invalid_IV_Length(name(), nonce_len);
  346|      0|   }
  347|       |
  348|   379k|   assert_key_material_set();
  349|   379k|   BOTAN_STATE_CHECK(!m_L->initialized());
  ------------------
  |  |   51|   379k|   do {                                                         \
  |  |   52|   379k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   379k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 379k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   379k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 379k]
  |  |  ------------------
  ------------------
  350|       |
  351|   379k|   m_L->init(update_nonce(nonce, nonce_len));
  352|   379k|   zeroise(m_checksum);
  353|   379k|   m_block_index = 0;
  354|   379k|}
_ZN5Botan14OCB_Encryption7encryptEPhm:
  360|   610k|void OCB_Encryption::encrypt(uint8_t buffer[], size_t blocks) {
  361|   610k|   assert_key_material_set();
  362|   610k|   BOTAN_STATE_CHECK(m_L->initialized());
  ------------------
  |  |   51|   610k|   do {                                                         \
  |  |   52|   610k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   610k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 610k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   610k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 610k]
  |  |  ------------------
  ------------------
  363|       |
  364|   610k|   const size_t BS = block_size();
  365|       |
  366|  1.45M|   while(blocks > 0) {
  ------------------
  |  Branch (366:10): [True: 841k, False: 610k]
  ------------------
  367|   841k|      const size_t proc_blocks = std::min(blocks, par_blocks());
  368|   841k|      const size_t proc_bytes = proc_blocks * BS;
  369|       |
  370|   841k|      const uint8_t* offsets = m_L->compute_offsets(m_block_index, proc_blocks);
  371|       |
  372|   841k|      xor_buf(m_checksum.data(), buffer, proc_bytes);
  373|       |
  374|   841k|      xor_buf(buffer, offsets, proc_bytes);
  375|   841k|      m_cipher->encrypt_n(buffer, buffer, proc_blocks);
  376|   841k|      xor_buf(buffer, offsets, proc_bytes);
  377|       |
  378|   841k|      buffer += proc_bytes;
  379|   841k|      blocks -= proc_blocks;
  380|   841k|      m_block_index += proc_blocks;
  381|   841k|   }
  382|   610k|}
_ZN5Botan14OCB_Encryption11process_msgEPhm:
  384|   390k|size_t OCB_Encryption::process_msg(uint8_t buf[], size_t sz) {
  385|   390k|   BOTAN_ARG_CHECK(sz % update_granularity() == 0, "Invalid OCB input size");
  ------------------
  |  |   35|   390k|   do {                                                          \
  |  |   36|   390k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   390k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 390k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   390k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 390k]
  |  |  ------------------
  ------------------
  386|   390k|   encrypt(buf, sz / block_size());
  387|   390k|   return sz;
  388|   390k|}
_ZN5Botan14OCB_Encryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  390|   222k|void OCB_Encryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  391|   222k|   assert_key_material_set();
  392|   222k|   BOTAN_STATE_CHECK(m_L->initialized());
  ------------------
  |  |   51|   222k|   do {                                                         \
  |  |   52|   222k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   222k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 222k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   222k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 222k]
  |  |  ------------------
  ------------------
  393|       |
  394|   222k|   const size_t BS = block_size();
  395|       |
  396|   222k|   BOTAN_ARG_CHECK(buffer.size() >= offset, "Offset is out of range");
  ------------------
  |  |   35|   222k|   do {                                                          \
  |  |   36|   222k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   222k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 222k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   222k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 222k]
  |  |  ------------------
  ------------------
  397|   222k|   const size_t sz = buffer.size() - offset;
  398|   222k|   uint8_t* buf = buffer.data() + offset;
  399|       |
  400|   222k|   secure_vector<uint8_t> mac(BS);
  401|       |
  402|   222k|   if(sz > 0) {
  ------------------
  |  Branch (402:7): [True: 220k, False: 2.39k]
  ------------------
  403|   220k|      const size_t final_full_blocks = sz / BS;
  404|   220k|      const size_t remainder_bytes = sz - (final_full_blocks * BS);
  405|       |
  406|   220k|      encrypt(buf, final_full_blocks);
  407|   220k|      mac = m_L->offset();
  408|       |
  409|   220k|      if(remainder_bytes > 0) {
  ------------------
  |  Branch (409:10): [True: 1.77k, False: 218k]
  ------------------
  410|  1.77k|         BOTAN_ASSERT(remainder_bytes < BS, "Only a partial block left");
  ------------------
  |  |   64|  1.77k|   do {                                                                                 \
  |  |   65|  1.77k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.77k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 1.77k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  1.77k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 1.77k]
  |  |  ------------------
  ------------------
  411|  1.77k|         uint8_t* remainder = &buf[sz - remainder_bytes];
  412|       |
  413|  1.77k|         xor_buf(m_checksum.data(), remainder, remainder_bytes);
  414|  1.77k|         m_checksum[remainder_bytes] ^= 0x80;
  415|       |
  416|       |         // Offset_*
  417|  1.77k|         mac ^= m_L->star();
  418|       |
  419|  1.77k|         secure_vector<uint8_t> pad(BS);
  420|  1.77k|         m_cipher->encrypt(mac, pad);
  421|  1.77k|         xor_buf(remainder, pad.data(), remainder_bytes);
  422|  1.77k|      }
  423|   220k|   } else {
  424|  2.39k|      mac = m_L->offset();
  425|  2.39k|   }
  426|       |
  427|       |   // now compute the tag
  428|       |
  429|       |   // fold checksum
  430|  1.58M|   for(size_t i = 0; i != m_checksum.size(); i += BS) {
  ------------------
  |  Branch (430:22): [True: 1.36M, False: 222k]
  ------------------
  431|  1.36M|      xor_buf(mac.data(), m_checksum.data() + i, BS);
  432|  1.36M|   }
  433|       |
  434|   222k|   xor_buf(mac.data(), m_L->dollar().data(), BS);
  435|   222k|   m_cipher->encrypt(mac);
  436|   222k|   xor_buf(mac.data(), m_ad_hash.data(), BS);
  437|       |
  438|   222k|   buffer += std::make_pair(mac.data(), tag_size());
  439|       |
  440|   222k|   reset();
  441|   222k|}
_ZN5Botan14OCB_Decryption7decryptEPhm:
  448|   536k|void OCB_Decryption::decrypt(uint8_t buffer[], size_t blocks) {
  449|   536k|   assert_key_material_set();
  450|   536k|   BOTAN_STATE_CHECK(m_L->initialized());
  ------------------
  |  |   51|   536k|   do {                                                         \
  |  |   52|   536k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   536k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 536k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   536k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 536k]
  |  |  ------------------
  ------------------
  451|       |
  452|   536k|   const size_t BS = block_size();
  453|       |
  454|  1.26M|   while(blocks > 0) {
  ------------------
  |  Branch (454:10): [True: 731k, False: 536k]
  ------------------
  455|   731k|      const size_t proc_blocks = std::min(blocks, par_blocks());
  456|   731k|      const size_t proc_bytes = proc_blocks * BS;
  457|       |
  458|   731k|      const uint8_t* offsets = m_L->compute_offsets(m_block_index, proc_blocks);
  459|       |
  460|   731k|      xor_buf(buffer, offsets, proc_bytes);
  461|   731k|      m_cipher->decrypt_n(buffer, buffer, proc_blocks);
  462|   731k|      xor_buf(buffer, offsets, proc_bytes);
  463|       |
  464|   731k|      xor_buf(m_checksum.data(), buffer, proc_bytes);
  465|       |
  466|   731k|      buffer += proc_bytes;
  467|   731k|      blocks -= proc_blocks;
  468|   731k|      m_block_index += proc_blocks;
  469|   731k|   }
  470|   536k|}
_ZN5Botan14OCB_Decryption11process_msgEPhm:
  472|   381k|size_t OCB_Decryption::process_msg(uint8_t buf[], size_t sz) {
  473|   381k|   BOTAN_ARG_CHECK(sz % update_granularity() == 0, "Invalid OCB input size");
  ------------------
  |  |   35|   381k|   do {                                                          \
  |  |   36|   381k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   381k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 381k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   381k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 381k]
  |  |  ------------------
  ------------------
  474|   381k|   decrypt(buf, sz / block_size());
  475|   381k|   return sz;
  476|   381k|}
_ZN5Botan14OCB_Decryption10finish_msgERNSt3__16vectorIhNS_16secure_allocatorIhEEEEm:
  478|   156k|void OCB_Decryption::finish_msg(secure_vector<uint8_t>& buffer, size_t offset) {
  479|   156k|   assert_key_material_set();
  480|   156k|   BOTAN_STATE_CHECK(m_L->initialized());
  ------------------
  |  |   51|   156k|   do {                                                         \
  |  |   52|   156k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   156k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 156k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   156k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 156k]
  |  |  ------------------
  ------------------
  481|       |
  482|   156k|   const size_t BS = block_size();
  483|       |
  484|   156k|   BOTAN_ARG_CHECK(buffer.size() >= offset, "Offset is out of range");
  ------------------
  |  |   35|   156k|   do {                                                          \
  |  |   36|   156k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   156k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 156k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   156k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 156k]
  |  |  ------------------
  ------------------
  485|   156k|   const size_t sz = buffer.size() - offset;
  486|   156k|   uint8_t* buf = buffer.data() + offset;
  487|       |
  488|   156k|   BOTAN_ARG_CHECK(sz >= tag_size(), "input did not include the tag");
  ------------------
  |  |   35|   156k|   do {                                                          \
  |  |   36|   156k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   156k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 156k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   156k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 156k]
  |  |  ------------------
  ------------------
  489|       |
  490|   156k|   const size_t remaining = sz - tag_size();
  491|       |
  492|   156k|   secure_vector<uint8_t> mac(BS);
  493|       |
  494|   156k|   if(remaining > 0) {
  ------------------
  |  Branch (494:7): [True: 154k, False: 1.67k]
  ------------------
  495|   154k|      const size_t final_full_blocks = remaining / BS;
  496|   154k|      const size_t final_bytes = remaining - (final_full_blocks * BS);
  497|       |
  498|   154k|      decrypt(buf, final_full_blocks);
  499|   154k|      mac ^= m_L->offset();
  500|       |
  501|   154k|      if(final_bytes > 0) {
  ------------------
  |  Branch (501:10): [True: 1.84k, False: 152k]
  ------------------
  502|  1.84k|         BOTAN_ASSERT(final_bytes < BS, "Only a partial block left");
  ------------------
  |  |   64|  1.84k|   do {                                                                                 \
  |  |   65|  1.84k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.84k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 1.84k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  1.84k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 1.84k]
  |  |  ------------------
  ------------------
  503|       |
  504|  1.84k|         uint8_t* remainder = &buf[remaining - final_bytes];
  505|       |
  506|  1.84k|         mac ^= m_L->star();
  507|  1.84k|         secure_vector<uint8_t> pad(BS);
  508|  1.84k|         m_cipher->encrypt(mac, pad);  // P_*
  509|  1.84k|         xor_buf(remainder, pad.data(), final_bytes);
  510|       |
  511|  1.84k|         xor_buf(m_checksum.data(), remainder, final_bytes);
  512|  1.84k|         m_checksum[final_bytes] ^= 0x80;
  513|  1.84k|      }
  514|   154k|   } else {
  515|  1.67k|      mac = m_L->offset();
  516|  1.67k|   }
  517|       |
  518|       |   // compute the mac
  519|       |
  520|       |   // fold checksum
  521|  1.23M|   for(size_t i = 0; i != m_checksum.size(); i += BS) {
  ------------------
  |  Branch (521:22): [True: 1.07M, False: 156k]
  ------------------
  522|  1.07M|      xor_buf(mac.data(), m_checksum.data() + i, BS);
  523|  1.07M|   }
  524|       |
  525|   156k|   mac ^= m_L->dollar();
  526|   156k|   m_cipher->encrypt(mac);
  527|   156k|   mac ^= m_ad_hash;
  528|       |
  529|   156k|   reset();
  530|       |
  531|       |   // compare mac
  532|   156k|   const uint8_t* included_tag = &buf[remaining];
  533|       |
  534|   156k|   if(!CT::is_equal(mac.data(), included_tag, tag_size()).as_bool()) {
  ------------------
  |  Branch (534:7): [True: 143, False: 156k]
  ------------------
  535|    143|      clear_mem(std::span{buffer}.subspan(offset, remaining));
  536|    143|      throw Invalid_Authentication_Tag("OCB tag check failed");
  537|    143|   }
  538|       |
  539|       |   // remove tag from end of message
  540|   156k|   buffer.resize(remaining + offset);
  541|   156k|}
_ZN5Botan10L_computer5resetEv:
   51|   765k|      void reset() { m_offset.clear(); }
_ZNK5Botan10L_computer11initializedEv:
   53|  2.28M|      bool initialized() const { return !m_offset.empty(); }
ocb.cpp:_ZN5Botan12_GLOBAL__N_18ocb_hashERKNS_10L_computerERKNS_11BlockCipherEPKhm:
  132|   379k|secure_vector<uint8_t> ocb_hash(const L_computer& L, const BlockCipher& cipher, const uint8_t ad[], size_t ad_len) {
  133|   379k|   const size_t BS = cipher.block_size();
  134|   379k|   secure_vector<uint8_t> sum(BS);
  135|   379k|   secure_vector<uint8_t> offset(BS);
  136|       |
  137|   379k|   secure_vector<uint8_t> buf(BS);
  138|       |
  139|   379k|   const size_t ad_blocks = (ad_len / BS);
  140|   379k|   const size_t ad_remainder = (ad_len % BS);
  141|       |
  142|   381k|   for(size_t i = 0; i != ad_blocks; ++i) {
  ------------------
  |  Branch (142:22): [True: 2.12k, False: 379k]
  ------------------
  143|       |      // this loop could run in parallel
  144|  2.12k|      offset ^= L.get(var_ctz64(i + 1));
  145|  2.12k|      buf = offset;
  146|  2.12k|      xor_buf(buf.data(), &ad[BS * i], BS);
  147|  2.12k|      cipher.encrypt(buf);
  148|  2.12k|      sum ^= buf;
  149|  2.12k|   }
  150|       |
  151|   379k|   if(ad_remainder > 0) {
  ------------------
  |  Branch (151:7): [True: 379k, False: 0]
  ------------------
  152|   379k|      offset ^= L.star();
  153|   379k|      buf = offset;
  154|   379k|      xor_buf(buf.data(), &ad[BS * ad_blocks], ad_remainder);
  155|   379k|      buf[ad_remainder] ^= 0x80;
  156|   379k|      cipher.encrypt(buf);
  157|   379k|      sum ^= buf;
  158|   379k|   }
  159|       |
  160|   379k|   return sum;
  161|   379k|}
_ZNK5Botan10L_computer3getEm:
   61|  4.97M|      const secure_vector<uint8_t>& get(size_t i) const {
   62|  4.98M|         while(m_L.size() <= i) {
  ------------------
  |  Branch (62:16): [True: 1.94k, False: 4.97M]
  ------------------
   63|  1.94k|            m_L.push_back(poly_double(m_L.back()));
   64|  1.94k|         }
   65|       |
   66|  4.97M|         return m_L[i];
   67|  4.97M|      }
_ZN5Botan10L_computer11poly_doubleERKNSt3__16vectorIhNS_16secure_allocatorIhEEEE:
  114|  67.9k|      static secure_vector<uint8_t> poly_double(const secure_vector<uint8_t>& in) {
  115|  67.9k|         secure_vector<uint8_t> out(in.size());
  116|  67.9k|         poly_double_n(out.data(), in.data(), out.size());
  117|  67.9k|         return out;
  118|  67.9k|      }
_ZN5Botan10L_computer4initERKNSt3__16vectorIhNS_16secure_allocatorIhEEEE:
   49|   379k|      void init(const secure_vector<uint8_t>& offset) { m_offset = offset; }
_ZN5Botan10L_computer15compute_offsetsEmm:
   69|  1.57M|      const uint8_t* compute_offsets(uint64_t block_index, size_t blocks) {
   70|  1.57M|         BOTAN_ASSERT(blocks <= m_max_blocks, "OCB offsets");
  ------------------
  |  |   64|  1.57M|   do {                                                                                 \
  |  |   65|  1.57M|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  1.57M|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 1.57M]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  1.57M|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 1.57M]
  |  |  ------------------
  ------------------
   71|       |
   72|  1.57M|         uint8_t* offsets = m_offset_buf.data();
   73|       |
   74|  1.57M|         if(block_index % 4 == 0) {
  ------------------
  |  Branch (74:13): [True: 1.47M, False: 101k]
  ------------------
   75|  1.47M|            const secure_vector<uint8_t>& L0 = get(0);
   76|  1.47M|            const secure_vector<uint8_t>& L1 = get(1);
   77|       |
   78|  3.08M|            while(blocks >= 4) {
  ------------------
  |  Branch (78:19): [True: 1.61M, False: 1.47M]
  ------------------
   79|       |               // ntz(4*i+1) == 0
   80|       |               // ntz(4*i+2) == 1
   81|       |               // ntz(4*i+3) == 0
   82|  1.61M|               block_index += 4;
   83|  1.61M|               const size_t ntz4 = var_ctz64(block_index);
   84|       |
   85|  1.61M|               xor_buf(offsets, m_offset.data(), L0.data(), m_BS);
   86|  1.61M|               offsets += m_BS;
   87|       |
   88|  1.61M|               xor_buf(offsets, offsets - m_BS, L1.data(), m_BS);
   89|  1.61M|               offsets += m_BS;
   90|       |
   91|  1.61M|               xor_buf(m_offset.data(), L1.data(), m_BS);
   92|  1.61M|               copy_mem(offsets, m_offset.data(), m_BS);
   93|  1.61M|               offsets += m_BS;
   94|       |
   95|  1.61M|               xor_buf(m_offset.data(), get(ntz4).data(), m_BS);
   96|  1.61M|               copy_mem(offsets, m_offset.data(), m_BS);
   97|  1.61M|               offsets += m_BS;
   98|       |
   99|  1.61M|               blocks -= 4;
  100|  1.61M|            }
  101|  1.47M|         }
  102|       |
  103|  1.99M|         for(size_t i = 0; i != blocks; ++i) {  // could be done in parallel
  ------------------
  |  Branch (103:28): [True: 421k, False: 1.57M]
  ------------------
  104|   421k|            const size_t ntz = var_ctz64(block_index + i + 1);
  105|   421k|            xor_buf(m_offset.data(), get(ntz).data(), m_BS);
  106|   421k|            copy_mem(offsets, m_offset.data(), m_BS);
  107|   421k|            offsets += m_BS;
  108|   421k|         }
  109|       |
  110|  1.57M|         return m_offset_buf.data();
  111|  1.57M|      }
_ZNK5Botan10L_computer6offsetEv:
   59|   378k|      const secure_vector<uint8_t>& offset() const { return m_offset; }
_ZNK5Botan10L_computer4starEv:
   55|   390k|      const secure_vector<uint8_t>& star() const { return m_L_star; }
_ZNK5Botan10L_computer6dollarEv:
   57|   386k|      const secure_vector<uint8_t>& dollar() const { return m_L_dollar; }
_ZN5Botan10L_computerC2ERKNS_11BlockCipherE:
   25|  7.33k|            m_BS(cipher.block_size()), m_max_blocks(cipher.parallel_bytes() / m_BS) {
   26|  7.33k|         m_L_star.resize(m_BS);
   27|  7.33k|         cipher.encrypt(m_L_star);
   28|  7.33k|         m_L_dollar = poly_double(star());
   29|       |
   30|       |         // Preallocate the m_L vector to the maximum expected size to avoid
   31|       |         // re-allocations during runtime. This had caused a use-after-free in
   32|       |         // earlier versions, due to references into this buffer becoming stale
   33|       |         // in `compute_offset()`, after calling `get()` in the hot path.
   34|       |         //
   35|       |         // Note, that the list member won't be pre-allocated, so the expected
   36|       |         // memory overhead is negligible.
   37|       |         //
   38|       |         // See also https://github.com/randombit/botan/issues/3812
   39|  7.33k|         m_L.reserve(65);
   40|  7.33k|         m_L.push_back(poly_double(dollar()));
   41|       |
   42|  58.6k|         while(m_L.size() < 8) {
  ------------------
  |  Branch (42:16): [True: 51.3k, False: 7.33k]
  ------------------
   43|  51.3k|            m_L.push_back(poly_double(m_L.back()));
   44|  51.3k|         }
   45|       |
   46|  7.33k|         m_offset_buf.resize(m_BS * m_max_blocks);
   47|  7.33k|      }

_ZN5Botan11Cipher_Mode6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEENS_10Cipher_DirES5_:
   56|  15.8k|                                                 std::string_view provider) {
   57|       |#if defined(BOTAN_HAS_COMMONCRYPTO)
   58|       |   if(provider.empty() || provider == "commoncrypto") {
   59|       |      if(auto cm = make_commoncrypto_cipher_mode(algo, direction))
   60|       |         return cm;
   61|       |
   62|       |      if(!provider.empty())
   63|       |         return nullptr;
   64|       |   }
   65|       |#endif
   66|       |
   67|  15.8k|   if(provider != "base" && !provider.empty()) {
  ------------------
  |  Branch (67:7): [True: 15.8k, False: 0]
  |  Branch (67:29): [True: 0, False: 15.8k]
  ------------------
   68|      0|      return nullptr;
   69|      0|   }
   70|       |
   71|  15.8k|#if defined(BOTAN_HAS_STREAM_CIPHER)
   72|  15.8k|   if(auto sc = StreamCipher::create(algo)) {
  ------------------
  |  Branch (72:12): [True: 0, False: 15.8k]
  ------------------
   73|      0|      return std::make_unique<Stream_Cipher_Mode>(std::move(sc));
   74|      0|   }
   75|  15.8k|#endif
   76|       |
   77|  15.8k|#if defined(BOTAN_HAS_AEAD_MODES)
   78|  15.8k|   if(auto aead = AEAD_Mode::create(algo, direction)) {
  ------------------
  |  Branch (78:12): [True: 15.5k, False: 369]
  ------------------
   79|  15.5k|      return aead;
   80|  15.5k|   }
   81|    369|#endif
   82|       |
   83|    369|   if(algo.find('/') != std::string::npos) {
  ------------------
  |  Branch (83:7): [True: 0, False: 369]
  ------------------
   84|      0|      const std::vector<std::string> algo_parts = split_on(algo, '/');
   85|      0|      if(algo_parts.size() < 2) {
  ------------------
  |  Branch (85:10): [True: 0, False: 0]
  ------------------
   86|      0|         return std::unique_ptr<Cipher_Mode>();
   87|      0|      }
   88|      0|      const std::string_view cipher_name = algo_parts[0];
   89|      0|      const std::vector<std::string> mode_info = parse_algorithm_name(algo_parts[1]);
   90|       |
   91|      0|      if(mode_info.empty()) {
  ------------------
  |  Branch (91:10): [True: 0, False: 0]
  ------------------
   92|      0|         return std::unique_ptr<Cipher_Mode>();
   93|      0|      }
   94|       |
   95|      0|      std::ostringstream mode_name;
   96|       |
   97|      0|      mode_name << mode_info[0] << '(' << cipher_name;
   98|      0|      for(size_t i = 1; i < mode_info.size(); ++i) {
  ------------------
  |  Branch (98:25): [True: 0, False: 0]
  ------------------
   99|      0|         mode_name << ',' << mode_info[i];
  100|      0|      }
  101|      0|      for(size_t i = 2; i < algo_parts.size(); ++i) {
  ------------------
  |  Branch (101:25): [True: 0, False: 0]
  ------------------
  102|      0|         mode_name << ',' << algo_parts[i];
  103|      0|      }
  104|      0|      mode_name << ')';
  105|       |
  106|      0|      return Cipher_Mode::create(mode_name.str(), direction, provider);
  107|      0|   }
  108|       |
  109|    369|#if defined(BOTAN_HAS_BLOCK_CIPHER)
  110|       |
  111|    369|   const SCAN_Name spec(algo);
  112|       |
  113|    369|   if(spec.arg_count() == 0) {
  ------------------
  |  Branch (113:7): [True: 0, False: 369]
  ------------------
  114|      0|      return std::unique_ptr<Cipher_Mode>();
  115|      0|   }
  116|       |
  117|    369|   auto bc = BlockCipher::create(spec.arg(0), provider);
  118|       |
  119|    369|   if(!bc) {
  ------------------
  |  Branch (119:7): [True: 0, False: 369]
  ------------------
  120|      0|      return std::unique_ptr<Cipher_Mode>();
  121|      0|   }
  122|       |
  123|    369|   #if defined(BOTAN_HAS_MODE_CBC)
  124|    369|   if(spec.algo_name() == "CBC") {
  ------------------
  |  Branch (124:7): [True: 0, False: 369]
  ------------------
  125|      0|      const std::string padding = spec.arg(1, "PKCS7");
  126|       |
  127|      0|      if(padding == "CTS") {
  ------------------
  |  Branch (127:10): [True: 0, False: 0]
  ------------------
  128|      0|         if(direction == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (128:13): [True: 0, False: 0]
  ------------------
  129|      0|            return std::make_unique<CTS_Encryption>(std::move(bc));
  130|      0|         } else {
  131|      0|            return std::make_unique<CTS_Decryption>(std::move(bc));
  132|      0|         }
  133|      0|      } else {
  134|      0|         auto pad = BlockCipherModePaddingMethod::create(padding);
  135|       |
  136|      0|         if(pad) {
  ------------------
  |  Branch (136:13): [True: 0, False: 0]
  ------------------
  137|      0|            if(direction == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (137:16): [True: 0, False: 0]
  ------------------
  138|      0|               return std::make_unique<CBC_Encryption>(std::move(bc), std::move(pad));
  139|      0|            } else {
  140|      0|               return std::make_unique<CBC_Decryption>(std::move(bc), std::move(pad));
  141|      0|            }
  142|      0|         }
  143|      0|      }
  144|      0|   }
  145|    369|   #endif
  146|       |
  147|       |   #if defined(BOTAN_HAS_MODE_XTS)
  148|       |   if(spec.algo_name() == "XTS") {
  149|       |      if(direction == Cipher_Dir::Encryption) {
  150|       |         return std::make_unique<XTS_Encryption>(std::move(bc));
  151|       |      } else {
  152|       |         return std::make_unique<XTS_Decryption>(std::move(bc));
  153|       |      }
  154|       |   }
  155|       |   #endif
  156|       |
  157|    369|   #if defined(BOTAN_HAS_MODE_CFB)
  158|    369|   if(spec.algo_name() == "CFB") {
  ------------------
  |  Branch (158:7): [True: 0, False: 369]
  ------------------
  159|      0|      const size_t feedback_bits = spec.arg_as_integer(1, 8 * bc->block_size());
  160|      0|      if(direction == Cipher_Dir::Encryption) {
  ------------------
  |  Branch (160:10): [True: 0, False: 0]
  ------------------
  161|      0|         return std::make_unique<CFB_Encryption>(std::move(bc), feedback_bits);
  162|      0|      } else {
  163|      0|         return std::make_unique<CFB_Decryption>(std::move(bc), feedback_bits);
  164|      0|      }
  165|      0|   }
  166|    369|   #endif
  167|       |
  168|    369|#endif
  169|       |
  170|    369|   return std::unique_ptr<Cipher_Mode>();
  171|    369|}

_ZN5Botan6Argon26blamkaEPmS1_:
  169|  21.2M|void Argon2::blamka(uint64_t N[128], uint64_t T[128]) {
  170|       |#if defined(BOTAN_HAS_ARGON2_AVX512)
  171|       |   if(CPUID::has(CPUID::Feature::AVX512)) {
  172|       |      return Argon2::blamka_avx512(N, T);
  173|       |   }
  174|       |#endif
  175|       |
  176|       |#if defined(BOTAN_HAS_ARGON2_AVX2)
  177|       |   if(CPUID::has(CPUID::Feature::AVX2)) {
  178|       |      return Argon2::blamka_avx2(N, T);
  179|       |   }
  180|       |#endif
  181|       |
  182|       |#if defined(BOTAN_HAS_ARGON2_SIMD64)
  183|       |   if(CPUID::has(CPUID::Feature::SIMD_2X64)) {
  184|       |      return Argon2::blamka_simd64(N, T);
  185|       |   }
  186|       |#endif
  187|       |
  188|  21.2M|   copy_mem(T, N, 128);
  189|       |
  190|   191M|   for(size_t i = 0; i != 128; i += 16) {
  ------------------
  |  Branch (190:22): [True: 170M, False: 21.2M]
  ------------------
  191|   170M|      blamka_G(T[i + 0], T[i + 4], T[i + 8], T[i + 12]);
  192|   170M|      blamka_G(T[i + 1], T[i + 5], T[i + 9], T[i + 13]);
  193|   170M|      blamka_G(T[i + 2], T[i + 6], T[i + 10], T[i + 14]);
  194|   170M|      blamka_G(T[i + 3], T[i + 7], T[i + 11], T[i + 15]);
  195|       |
  196|   170M|      blamka_G(T[i + 0], T[i + 5], T[i + 10], T[i + 15]);
  197|   170M|      blamka_G(T[i + 1], T[i + 6], T[i + 11], T[i + 12]);
  198|   170M|      blamka_G(T[i + 2], T[i + 7], T[i + 8], T[i + 13]);
  199|   170M|      blamka_G(T[i + 3], T[i + 4], T[i + 9], T[i + 14]);
  200|   170M|   }
  201|       |
  202|   191M|   for(size_t i = 0; i != 128 / 8; i += 2) {
  ------------------
  |  Branch (202:22): [True: 170M, False: 21.2M]
  ------------------
  203|   170M|      blamka_G(T[i + 0], T[i + 32], T[i + 64], T[i + 96]);
  204|   170M|      blamka_G(T[i + 1], T[i + 33], T[i + 65], T[i + 97]);
  205|   170M|      blamka_G(T[i + 16], T[i + 48], T[i + 80], T[i + 112]);
  206|   170M|      blamka_G(T[i + 17], T[i + 49], T[i + 81], T[i + 113]);
  207|       |
  208|   170M|      blamka_G(T[i + 0], T[i + 33], T[i + 80], T[i + 113]);
  209|   170M|      blamka_G(T[i + 1], T[i + 48], T[i + 81], T[i + 96]);
  210|   170M|      blamka_G(T[i + 16], T[i + 49], T[i + 64], T[i + 97]);
  211|   170M|      blamka_G(T[i + 17], T[i + 32], T[i + 65], T[i + 112]);
  212|   170M|   }
  213|       |
  214|  2.74G|   for(size_t i = 0; i != 128; ++i) {
  ------------------
  |  Branch (214:22): [True: 2.72G, False: 21.2M]
  ------------------
  215|  2.72G|      N[i] ^= T[i];
  216|  2.72G|   }
  217|  21.2M|}
_ZNK5Botan6Argon26argon2EPhmPKcmPKhmS5_mS5_m:
  401|    211|                    size_t ad_len) const {
  402|    211|   BOTAN_ARG_CHECK(output_len >= 4 && output_len <= std::numeric_limits<uint32_t>::max(),
  ------------------
  |  |   35|    211|   do {                                                          \
  |  |   36|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    422|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 211, False: 0]
  |  |  |  Branch (37:12): [True: 211, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  403|    211|                   "Invalid Argon2 output length");
  404|    211|   BOTAN_ARG_CHECK(password_len <= std::numeric_limits<uint32_t>::max(), "Invalid Argon2 password length");
  ------------------
  |  |   35|    211|   do {                                                          \
  |  |   36|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    211|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 211]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  405|    211|   BOTAN_ARG_CHECK(salt_len <= std::numeric_limits<uint32_t>::max(), "Invalid Argon2 salt length");
  ------------------
  |  |   35|    211|   do {                                                          \
  |  |   36|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    211|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 211]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  406|    211|   BOTAN_ARG_CHECK(key_len <= std::numeric_limits<uint32_t>::max(), "Invalid Argon2 key length");
  ------------------
  |  |   35|    211|   do {                                                          \
  |  |   36|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    211|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 211]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  407|    211|   BOTAN_ARG_CHECK(ad_len <= std::numeric_limits<uint32_t>::max(), "Invalid Argon2 ad length");
  ------------------
  |  |   35|    211|   do {                                                          \
  |  |   36|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    211|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 211]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  408|       |
  409|    211|   auto blake2 = HashFunction::create_or_throw("BLAKE2b");
  410|       |
  411|    211|   uint8_t H0[64] = {0};
  412|    211|   argon2_H0(H0,
  413|    211|             *blake2,
  414|    211|             output_len,
  415|    211|             password,
  416|    211|             password_len,
  417|    211|             salt,
  418|    211|             salt_len,
  419|    211|             key,
  420|    211|             key_len,
  421|    211|             ad,
  422|    211|             ad_len,
  423|    211|             m_family,
  424|    211|             m_p,
  425|    211|             m_M,
  426|    211|             m_t);
  427|       |
  428|    211|   const size_t memory = (m_M / (SYNC_POINTS * m_p)) * (SYNC_POINTS * m_p);
  429|       |
  430|    211|   constexpr size_t M_scale = 1024 / 8;
  431|    211|   secure_vector<uint64_t> B(memory * M_scale);
  432|       |
  433|    211|   init_blocks(B, *blake2, H0, memory, m_p);
  434|    211|   process_blocks(B, m_t, memory, m_p, m_family);
  435|       |
  436|    211|   clear_mem(output, output_len);
  437|    211|   extract_key(output, output_len, B, memory, m_p);
  438|    211|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_18blamka_GERmS1_S1_S1_:
  153|  2.72G|BOTAN_FORCE_INLINE void blamka_G(uint64_t& A, uint64_t& B, uint64_t& C, uint64_t& D) {
  154|  2.72G|   A += B + (static_cast<uint64_t>(2) * static_cast<uint32_t>(A)) * static_cast<uint32_t>(B);
  155|  2.72G|   D = rotr<32>(A ^ D);
  156|       |
  157|  2.72G|   C += D + (static_cast<uint64_t>(2) * static_cast<uint32_t>(C)) * static_cast<uint32_t>(D);
  158|  2.72G|   B = rotr<24>(B ^ C);
  159|       |
  160|  2.72G|   A += B + (static_cast<uint64_t>(2) * static_cast<uint32_t>(A)) * static_cast<uint32_t>(B);
  161|  2.72G|   D = rotr<16>(A ^ D);
  162|       |
  163|  2.72G|   C += D + (static_cast<uint64_t>(2) * static_cast<uint32_t>(C)) * static_cast<uint32_t>(D);
  164|  2.72G|   B = rotr<63>(B ^ C);
  165|  2.72G|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_19argon2_H0EPhRNS_12HashFunctionEmPKcmPKhmS7_mS7_mmmmm:
   46|    211|               size_t t) {
   47|    211|   const uint8_t v = 19;  // Argon2 version code
   48|       |
   49|    211|   blake2b.update_le(static_cast<uint32_t>(p));
   50|    211|   blake2b.update_le(static_cast<uint32_t>(output_len));
   51|    211|   blake2b.update_le(static_cast<uint32_t>(M));
   52|    211|   blake2b.update_le(static_cast<uint32_t>(t));
   53|    211|   blake2b.update_le(static_cast<uint32_t>(v));
   54|    211|   blake2b.update_le(static_cast<uint32_t>(y));
   55|       |
   56|    211|   blake2b.update_le(static_cast<uint32_t>(password_len));
   57|    211|   blake2b.update(as_span_of_bytes(password, password_len));
   58|       |
   59|    211|   blake2b.update_le(static_cast<uint32_t>(salt_len));
   60|    211|   blake2b.update(salt, salt_len);
   61|       |
   62|    211|   blake2b.update_le(static_cast<uint32_t>(key_len));
   63|    211|   blake2b.update(key, key_len);
   64|       |
   65|    211|   blake2b.update_le(static_cast<uint32_t>(ad_len));
   66|    211|   blake2b.update(ad, ad_len);
   67|       |
   68|    211|   blake2b.final(H0);
   69|    211|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_111init_blocksERNSt3__16vectorImNS_16secure_allocatorImEEEERNS_12HashFunctionEPKhmm:
  125|    211|   secure_vector<uint64_t>& B, HashFunction& blake2b, const uint8_t H0[64], size_t memory, size_t threads) {
  126|    211|   BOTAN_ASSERT_NOMSG(B.size() >= threads * 256);
  ------------------
  |  |   77|    211|   do {                                                                     \
  |  |   78|    211|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    211|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 211]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    211|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 211]
  |  |  ------------------
  ------------------
  127|       |
  128|  7.07k|   for(size_t i = 0; i != threads; ++i) {
  ------------------
  |  Branch (128:22): [True: 6.86k, False: 211]
  ------------------
  129|  6.86k|      const size_t B_off = i * (memory / threads);
  130|       |
  131|  6.86k|      BOTAN_ASSERT_NOMSG(B.size() >= 128 * (B_off + 2));
  ------------------
  |  |   77|  6.86k|   do {                                                                     \
  |  |   78|  6.86k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  6.86k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 6.86k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  6.86k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 6.86k]
  |  |  ------------------
  ------------------
  132|       |
  133|  20.5k|      for(size_t j = 0; j != 2; ++j) {
  ------------------
  |  Branch (133:25): [True: 13.7k, False: 6.86k]
  ------------------
  134|  13.7k|         uint8_t T[64] = {0};
  135|       |
  136|  13.7k|         blake2b.update_le(static_cast<uint32_t>(1024));
  137|  13.7k|         blake2b.update(H0, 64);
  138|  13.7k|         blake2b.update_le(static_cast<uint32_t>(j));
  139|  13.7k|         blake2b.update_le(static_cast<uint32_t>(i));
  140|  13.7k|         blake2b.final(T);
  141|       |
  142|   425k|         for(size_t k = 0; k != 30; ++k) {
  ------------------
  |  Branch (142:28): [True: 411k, False: 13.7k]
  ------------------
  143|   411k|            load_le(&B[128 * (B_off + j) + 4 * k], T, 32 / 8);
  144|   411k|            blake2b.update(T, 64);
  145|   411k|            blake2b.final(T);
  146|   411k|         }
  147|       |
  148|  13.7k|         load_le(&B[128 * (B_off + j) + 4 * 30], T, 64 / 8);
  149|  13.7k|      }
  150|  6.86k|   }
  151|    211|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_114process_blocksERNSt3__16vectorImNS_16secure_allocatorImEEEEmmmh:
  353|    211|void process_blocks(secure_vector<uint64_t>& B, size_t t, size_t memory, size_t threads, uint8_t mode) {
  354|    211|   const size_t lanes = memory / threads;
  355|    211|   const size_t segments = lanes / SYNC_POINTS;
  356|       |
  357|       |#if defined(BOTAN_HAS_THREAD_UTILS)
  358|       |   if(threads > 1) {
  359|       |      auto& thread_pool = Thread_Pool::global_instance();
  360|       |
  361|       |      for(size_t n = 0; n != t; ++n) {
  362|       |         for(size_t slice = 0; slice != SYNC_POINTS; ++slice) {
  363|       |            std::vector<std::future<void>> fut_results;
  364|       |            fut_results.reserve(threads);
  365|       |
  366|       |            for(size_t lane = 0; lane != threads; ++lane) {
  367|       |               fut_results.push_back(thread_pool.run(
  368|       |                  process_block, std::ref(B), n, slice, lane, lanes, segments, threads, mode, memory, t));
  369|       |            }
  370|       |
  371|       |            for(auto& fut : fut_results) {
  372|       |               fut.get();
  373|       |            }
  374|       |         }
  375|       |      }
  376|       |
  377|       |      return;
  378|       |   }
  379|       |#endif
  380|       |
  381|  12.2k|   for(size_t n = 0; n != t; ++n) {
  ------------------
  |  Branch (381:22): [True: 12.0k, False: 211]
  ------------------
  382|  60.0k|      for(size_t slice = 0; slice != SYNC_POINTS; ++slice) {
  ------------------
  |  Branch (382:29): [True: 48.0k, False: 12.0k]
  ------------------
  383|  1.95M|         for(size_t lane = 0; lane != threads; ++lane) {
  ------------------
  |  Branch (383:31): [True: 1.90M, False: 48.0k]
  ------------------
  384|  1.90M|            process_block(B, n, slice, lane, lanes, segments, threads, mode, memory, t);
  385|  1.90M|         }
  386|  48.0k|      }
  387|  12.0k|   }
  388|    211|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_113process_blockERNSt3__16vectorImNS_16secure_allocatorImEEEEmmmmmmhmm:
  306|  1.90M|                   size_t time) {
  307|  1.90M|   uint64_t T[128];
  308|  1.90M|   size_t index = 0;
  309|  1.90M|   if(n == 0 && slice == 0) {
  ------------------
  |  Branch (309:7): [True: 27.4k, False: 1.88M]
  |  Branch (309:17): [True: 6.86k, False: 20.5k]
  ------------------
  310|  6.86k|      index = 2;
  311|  6.86k|   }
  312|       |
  313|  1.90M|   const bool use_2i = mode == 1 || (mode == 2 && n == 0 && slice < SYNC_POINTS / 2);
  ------------------
  |  Branch (313:24): [True: 0, False: 1.90M]
  |  Branch (313:38): [True: 1.90M, False: 0]
  |  Branch (313:51): [True: 27.4k, False: 1.88M]
  |  Branch (313:61): [True: 13.7k, False: 13.7k]
  ------------------
  314|       |
  315|  1.90M|   uint64_t addresses[128];
  316|  1.90M|   size_t address_counter = 1;
  317|       |
  318|  1.90M|   if(use_2i) {
  ------------------
  |  Branch (318:7): [True: 13.7k, False: 1.89M]
  ------------------
  319|  13.7k|      gen_2i_addresses(T, addresses, n, lane, slice, memory, time, mode, address_counter);
  320|  13.7k|   }
  321|       |
  322|  23.1M|   while(index < segments) {
  ------------------
  |  Branch (322:10): [True: 21.2M, False: 1.90M]
  ------------------
  323|  21.2M|      const size_t offset = lane * lanes + slice * segments + index;
  324|       |
  325|  21.2M|      size_t prev = offset - 1;
  326|  21.2M|      if(index == 0 && slice == 0) {
  ------------------
  |  Branch (326:10): [True: 1.90M, False: 19.3M]
  |  Branch (326:24): [True: 470k, False: 1.43M]
  ------------------
  327|   470k|         prev += lanes;
  328|   470k|      }
  329|       |
  330|  21.2M|      if(use_2i && index > 0 && index % 128 == 0) {
  ------------------
  |  Branch (330:10): [True: 740k, False: 20.4M]
  |  Branch (330:20): [True: 733k, False: 6.86k]
  |  Branch (330:33): [True: 4.48k, False: 729k]
  ------------------
  331|  4.48k|         address_counter += 1;
  332|  4.48k|         gen_2i_addresses(T, addresses, n, lane, slice, memory, time, mode, address_counter);
  333|  4.48k|      }
  334|       |
  335|  21.2M|      const uint64_t random = use_2i ? addresses[index % 128] : B.at(128 * prev);
  ------------------
  |  Branch (335:31): [True: 740k, False: 20.4M]
  ------------------
  336|  21.2M|      const size_t new_offset = index_alpha(random, lanes, segments, threads, n, slice, lane, index);
  337|       |
  338|  21.2M|      uint64_t N[128];
  339|  2.73G|      for(size_t i = 0; i != 128; ++i) {
  ------------------
  |  Branch (339:25): [True: 2.71G, False: 21.2M]
  ------------------
  340|  2.71G|         N[i] = B[128 * prev + i] ^ B[128 * new_offset + i];
  341|  2.71G|      }
  342|       |
  343|  21.2M|      Argon2::blamka(N, T);
  344|       |
  345|  2.73G|      for(size_t i = 0; i != 128; ++i) {
  ------------------
  |  Branch (345:25): [True: 2.71G, False: 21.2M]
  ------------------
  346|  2.71G|         B[128 * offset + i] ^= N[i];
  347|  2.71G|      }
  348|       |
  349|  21.2M|      index += 1;
  350|  21.2M|   }
  351|  1.90M|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_116gen_2i_addressesEPmS1_mmmmmmm:
  229|  18.2k|                      size_t cnt) {
  230|  18.2k|   clear_mem(B, 128);
  231|       |
  232|  18.2k|   B[0] = n;
  233|  18.2k|   B[1] = lane;
  234|  18.2k|   B[2] = slice;
  235|  18.2k|   B[3] = memory;
  236|  18.2k|   B[4] = time;
  237|  18.2k|   B[5] = mode;
  238|  18.2k|   B[6] = cnt;
  239|       |
  240|  54.6k|   for(size_t r = 0; r != 2; ++r) {
  ------------------
  |  Branch (240:22): [True: 36.4k, False: 18.2k]
  ------------------
  241|  36.4k|      Argon2::blamka(B, T);
  242|  36.4k|   }
  243|  18.2k|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_111index_alphaEmmmmmmmm:
  264|  21.2M|   uint64_t random, size_t lanes, size_t segments, size_t threads, size_t n, size_t slice, size_t lane, size_t index) {
  265|  21.2M|   size_t ref_lane = mod_threads(static_cast<uint32_t>(random >> 32), threads);
  266|       |
  267|  21.2M|   if(n == 0 && slice == 0) {
  ------------------
  |  Branch (267:7): [True: 1.49M, False: 19.7M]
  |  Branch (267:17): [True: 363k, False: 1.13M]
  ------------------
  268|   363k|      ref_lane = lane;
  269|   363k|   }
  270|       |
  271|  21.2M|   size_t m = 3 * segments;
  272|  21.2M|   size_t s = ((slice + 1) % 4) * segments;
  273|       |
  274|  21.2M|   if(lane == ref_lane) {
  ------------------
  |  Branch (274:7): [True: 2.37M, False: 18.8M]
  ------------------
  275|  2.37M|      m += index;
  276|  2.37M|   }
  277|       |
  278|  21.2M|   if(n == 0) {
  ------------------
  |  Branch (278:7): [True: 1.49M, False: 19.7M]
  ------------------
  279|  1.49M|      m = slice * segments;
  280|  1.49M|      s = 0;
  281|  1.49M|      if(slice == 0 || lane == ref_lane) {
  ------------------
  |  Branch (281:10): [True: 363k, False: 1.13M]
  |  Branch (281:24): [True: 286k, False: 845k]
  ------------------
  282|   649k|         m += index;
  283|   649k|      }
  284|  1.49M|   }
  285|       |
  286|  21.2M|   if(index == 0 || lane == ref_lane) {
  ------------------
  |  Branch (286:7): [True: 1.90M, False: 19.3M]
  |  Branch (286:21): [True: 2.32M, False: 16.9M]
  ------------------
  287|  4.22M|      m -= 1;
  288|  4.22M|   }
  289|       |
  290|  21.2M|   uint64_t p = static_cast<uint32_t>(random);
  291|  21.2M|   p = (p * p) >> 32;
  292|  21.2M|   p = (p * m) >> 32;
  293|       |
  294|  21.2M|   return static_cast<uint32_t>(ref_lane * lanes + mod_lanes(s + m - (p + 1), lanes));
  295|  21.2M|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_111mod_threadsEjm:
  246|  21.2M|inline size_t mod_threads(uint32_t random, size_t threads) {
  247|  21.2M|   if(is_power_of_2(threads)) {
  ------------------
  |  Branch (247:7): [True: 1.67M, False: 19.5M]
  ------------------
  248|  1.67M|      return random & static_cast<uint32_t>(threads - 1);
  249|  19.5M|   } else {
  250|  19.5M|      return random % threads;
  251|  19.5M|   }
  252|  21.2M|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_19mod_lanesEmm:
  255|  21.2M|inline size_t mod_lanes(uint64_t alpha, size_t lanes) {
  256|  21.2M|   if(is_power_of_2(lanes)) {
  ------------------
  |  Branch (256:7): [True: 6.12M, False: 15.0M]
  ------------------
  257|  6.12M|      return static_cast<size_t>(alpha & static_cast<uint64_t>(lanes - 1));
  258|  15.0M|   } else {
  259|  15.0M|      return alpha % lanes;
  260|  15.0M|   }
  261|  21.2M|}
argon2.cpp:_ZN5Botan12_GLOBAL__N_111extract_keyEPhmRKNSt3__16vectorImNS_16secure_allocatorImEEEEmm:
   71|    211|void extract_key(uint8_t output[], size_t output_len, const secure_vector<uint64_t>& B, size_t memory, size_t threads) {
   72|    211|   const size_t lanes = memory / threads;
   73|       |
   74|    211|   uint64_t sum[128] = {0};
   75|       |
   76|  7.07k|   for(size_t lane = 0; lane != threads; ++lane) {
  ------------------
  |  Branch (76:25): [True: 6.86k, False: 211]
  ------------------
   77|  6.86k|      const size_t start = 128 * (lane * lanes + lanes - 1);
   78|  6.86k|      const size_t end = 128 * (lane * lanes + lanes);
   79|       |
   80|   885k|      for(size_t j = start; j != end; ++j) {
  ------------------
  |  Branch (80:29): [True: 878k, False: 6.86k]
  ------------------
   81|   878k|         sum[j % 128] ^= B[j];
   82|   878k|      }
   83|  6.86k|   }
   84|       |
   85|    211|   if(output_len <= 64) {
  ------------------
  |  Branch (85:7): [True: 211, False: 0]
  ------------------
   86|    211|      auto blake2b = HashFunction::create_or_throw(fmt("BLAKE2b({})", output_len * 8));
   87|    211|      blake2b->update_le(static_cast<uint32_t>(output_len));
   88|  27.2k|      for(size_t i = 0; i != 128; ++i) {  // NOLINT(modernize-loop-convert)
  ------------------
  |  Branch (88:25): [True: 27.0k, False: 211]
  ------------------
   89|  27.0k|         blake2b->update_le(sum[i]);
   90|  27.0k|      }
   91|    211|      blake2b->final(output);
   92|    211|   } else {
   93|      0|      secure_vector<uint8_t> T(64);
   94|       |
   95|      0|      auto blake2b = HashFunction::create_or_throw("BLAKE2b(512)");
   96|      0|      blake2b->update_le(static_cast<uint32_t>(output_len));
   97|      0|      for(size_t i = 0; i != 128; ++i) {  // NOLINT(modernize-loop-convert)
  ------------------
  |  Branch (97:25): [True: 0, False: 0]
  ------------------
   98|      0|         blake2b->update_le(sum[i]);
   99|      0|      }
  100|      0|      blake2b->final(std::span{T});
  101|       |
  102|      0|      while(output_len > 64) {
  ------------------
  |  Branch (102:13): [True: 0, False: 0]
  ------------------
  103|      0|         copy_mem(output, T.data(), 32);
  104|      0|         output_len -= 32;
  105|      0|         output += 32;
  106|       |
  107|      0|         if(output_len > 64) {
  ------------------
  |  Branch (107:13): [True: 0, False: 0]
  ------------------
  108|      0|            blake2b->update(T);
  109|      0|            blake2b->final(std::span{T});
  110|      0|         }
  111|      0|      }
  112|       |
  113|      0|      if(output_len == 64) {
  ------------------
  |  Branch (113:10): [True: 0, False: 0]
  ------------------
  114|      0|         blake2b->update(T);
  115|      0|         blake2b->final(output);
  116|      0|      } else {
  117|      0|         auto blake2b_f = HashFunction::create_or_throw(fmt("BLAKE2b({})", output_len * 8));
  118|      0|         blake2b_f->update(T);
  119|      0|         blake2b_f->final(output);
  120|      0|      }
  121|      0|   }
  122|    211|}

_ZN5Botan6Argon2C2Ehmmm:
   37|    241|Argon2::Argon2(uint8_t family, size_t M, size_t t, size_t p) : m_family(family), m_M(M), m_t(t), m_p(p) {
   38|    241|   BOTAN_ARG_CHECK(m_family == 0 || m_family == 1 || m_family == 2, "Invalid Argon2 family parameter");
  ------------------
  |  |   35|    241|   do {                                                          \
  |  |   36|    241|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    964|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 0, False: 241]
  |  |  |  Branch (37:12): [True: 0, False: 241]
  |  |  |  Branch (37:12): [True: 241, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    241|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 241]
  |  |  ------------------
  ------------------
   39|    241|   BOTAN_ARG_CHECK(m_p >= 1 && m_p <= 128, "Invalid Argon2 threads parameter");
  ------------------
  |  |   35|    241|   do {                                                          \
  |  |   36|    241|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    482|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 241, False: 0]
  |  |  |  Branch (37:12): [True: 230, False: 11]
  |  |  ------------------
  |  |   38|     11|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|     11|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|     11|      }                                                          \
  |  |   41|    241|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 241]
  |  |  ------------------
  ------------------
   40|    241|   BOTAN_ARG_CHECK(m_M >= 8 * m_p && m_M <= MAX_ARGON_MEMORY_GB * 1024 * 1024, "Invalid Argon2 M parameter");
  ------------------
  |  |   35|    241|   do {                                                          \
  |  |   36|    241|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    471|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 230, False: 11]
  |  |  |  Branch (37:12): [True: 211, False: 19]
  |  |  ------------------
  |  |   38|     19|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|     19|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|     19|      }                                                          \
  |  |   41|    241|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 241]
  |  |  ------------------
  ------------------
   41|    241|   BOTAN_ARG_CHECK(m_t >= 1 && m_t <= std::numeric_limits<uint32_t>::max(), "Invalid Argon2 t parameter");
  ------------------
  |  |   35|    241|   do {                                                          \
  |  |   36|    241|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|    452|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 211, False: 30]
  |  |  |  Branch (37:12): [True: 211, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|    241|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 241]
  |  |  ------------------
  ------------------
   42|    241|}
_ZNK5Botan6Argon210derive_keyEPhmPKcmPKhm:
   49|    211|                        size_t salt_len) const {
   50|    211|   argon2(output, output_len, password, password_len, salt, salt_len, nullptr, 0, nullptr, 0);
   51|    211|}
_ZN5Botan13Argon2_FamilyC2Eh:
   70|    241|Argon2_Family::Argon2_Family(uint8_t family) : m_family(family) {
   71|    241|   if(m_family != 0 && m_family != 1 && m_family != 2) {
  ------------------
  |  Branch (71:7): [True: 241, False: 0]
  |  Branch (71:24): [True: 241, False: 0]
  |  Branch (71:41): [True: 0, False: 241]
  ------------------
   72|      0|      throw Invalid_Argument("Unknown Argon2 family identifier");
   73|      0|   }
   74|    241|}
_ZNK5Botan13Argon2_Family11from_paramsEmmm:
  149|    241|std::unique_ptr<PasswordHash> Argon2_Family::from_params(size_t M, size_t t, size_t p) const {
  150|    241|   return std::make_unique<Argon2>(m_family, M, t, p);
  151|    241|}

_ZNK5Botan18RFC4880_S2K_Family11from_paramsEmmm:
  119|  19.9k|                                                              size_t /*unused*/) const {
  120|  19.9k|   return std::make_unique<RFC4880_S2K>(m_hash->new_object(), iterations);
  121|  19.9k|}
_ZN5Botan11RFC4880_S2KC2ENSt3__110unique_ptrINS_12HashFunctionENS1_14default_deleteIS3_EEEEm:
  132|  19.9k|      m_hash(std::move(hash)), m_iterations(iterations) {}
_ZNK5Botan11RFC4880_S2K10derive_keyEPhmPKcmPKhm:
  143|  19.9k|                             size_t salt_len) const {
  144|  19.9k|   pgp_s2k(*m_hash, out, out_len, password, password_len, salt, salt_len, m_iterations);
  145|  19.9k|}
pgp_s2k.cpp:_ZN5Botan12_GLOBAL__N_17pgp_s2kERNS_12HashFunctionEPhmPKcmPKhmm:
   30|  19.9k|             size_t iterations) {
   31|  19.9k|   if(iterations > 1 && salt_len == 0) {
  ------------------
  |  Branch (31:7): [True: 18.1k, False: 1.83k]
  |  Branch (31:25): [True: 0, False: 18.1k]
  ------------------
   32|      0|      throw Invalid_Argument("OpenPGP S2K requires a salt in iterated mode");
   33|      0|   }
   34|       |
   35|  19.9k|   const size_t input_len = add_or_throw(salt_len, password_size, "OpenPGP S2K salt and password are too large");
   36|  19.9k|   secure_vector<uint8_t> input_buf(input_len);
   37|  19.9k|   if(salt_len > 0) {
  ------------------
  |  Branch (37:7): [True: 19.3k, False: 667]
  ------------------
   38|  19.3k|      copy_mem(input_buf.data(), salt, salt_len);
   39|  19.3k|   }
   40|  19.9k|   if(password_size > 0) {
  ------------------
  |  Branch (40:7): [True: 19.9k, False: 0]
  ------------------
   41|  19.9k|      copy_mem(std::span(input_buf).subspan(salt_len), as_span_of_bytes(password, password_size));
   42|  19.9k|   }
   43|       |
   44|  19.9k|   secure_vector<uint8_t> hash_buf(hash.output_length());
   45|       |
   46|  19.9k|   size_t pass = 0;
   47|  19.9k|   size_t generated = 0;
   48|       |
   49|  47.4k|   while(generated != output_len) {
  ------------------
  |  Branch (49:10): [True: 27.5k, False: 19.9k]
  ------------------
   50|  27.5k|      const size_t output_this_pass = std::min(hash_buf.size(), output_len - generated);
   51|       |
   52|       |      // Preload some number of zero bytes (empty first iteration)
   53|  27.5k|      std::vector<uint8_t> zero_padding(pass);
   54|  27.5k|      hash.update(zero_padding);
   55|       |
   56|       |      // The input is always fully processed even if iterations is very small
   57|  27.5k|      if(!input_buf.empty()) {
  ------------------
  |  Branch (57:10): [True: 27.5k, False: 0]
  ------------------
   58|  27.5k|         size_t left = std::max(iterations, input_buf.size());
   59|   161M|         while(left > 0) {
  ------------------
  |  Branch (59:16): [True: 161M, False: 27.5k]
  ------------------
   60|   161M|            const size_t input_to_take = std::min(left, input_buf.size());
   61|   161M|            hash.update(input_buf.data(), input_to_take);
   62|   161M|            left -= input_to_take;
   63|   161M|         }
   64|  27.5k|      }
   65|       |
   66|  27.5k|      hash.final(hash_buf.data());
   67|  27.5k|      copy_mem(output_buf + generated, hash_buf.data(), output_this_pass);
   68|  27.5k|      generated += output_this_pass;
   69|  27.5k|      ++pass;
   70|  27.5k|   }
   71|  19.9k|}

_ZN5Botan18PasswordHashFamily6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
   58|  20.5k|std::unique_ptr<PasswordHashFamily> PasswordHashFamily::create(std::string_view algo_spec, std::string_view provider) {
   59|  20.5k|   const SCAN_Name req(algo_spec);
   60|       |
   61|       |#if defined(BOTAN_HAS_PBKDF2)
   62|       |   if(req.algo_name() == "PBKDF2") {
   63|       |      if(provider.empty() || provider == "base") {
   64|       |         if(auto mac = MessageAuthenticationCode::create("HMAC(" + req.arg(0) + ")")) {
   65|       |            return std::make_unique<PBKDF2_Family>(std::move(mac));
   66|       |         }
   67|       |
   68|       |         if(auto mac = MessageAuthenticationCode::create(req.arg(0))) {
   69|       |            return std::make_unique<PBKDF2_Family>(std::move(mac));
   70|       |         }
   71|       |      }
   72|       |
   73|       |      return nullptr;
   74|       |   }
   75|       |#endif
   76|       |
   77|       |#if defined(BOTAN_HAS_SCRYPT)
   78|       |   if(req.algo_name() == "Scrypt") {
   79|       |      return std::make_unique<Scrypt_Family>();
   80|       |   }
   81|       |#endif
   82|       |
   83|  20.5k|#if defined(BOTAN_HAS_ARGON2)
   84|  20.5k|   if(req.algo_name() == "Argon2d") {
  ------------------
  |  Branch (84:7): [True: 0, False: 20.5k]
  ------------------
   85|      0|      return std::make_unique<Argon2_Family>(static_cast<uint8_t>(0));
   86|  20.5k|   } else if(req.algo_name() == "Argon2i") {
  ------------------
  |  Branch (86:14): [True: 0, False: 20.5k]
  ------------------
   87|      0|      return std::make_unique<Argon2_Family>(static_cast<uint8_t>(1));
   88|  20.5k|   } else if(req.algo_name() == "Argon2id") {
  ------------------
  |  Branch (88:14): [True: 241, False: 20.3k]
  ------------------
   89|    241|      return std::make_unique<Argon2_Family>(static_cast<uint8_t>(2));
   90|    241|   }
   91|  20.3k|#endif
   92|       |
   93|       |#if defined(BOTAN_HAS_PBKDF_BCRYPT)
   94|       |   if(req.algo_name() == "Bcrypt-PBKDF") {
   95|       |      return std::make_unique<Bcrypt_PBKDF_Family>();
   96|       |   }
   97|       |#endif
   98|       |
   99|  20.3k|#if defined(BOTAN_HAS_PGP_S2K)
  100|  20.3k|   if(req.algo_name() == "OpenPGP-S2K" && req.arg_count() == 1) {
  ------------------
  |  Branch (100:7): [True: 20.3k, False: 0]
  |  Branch (100:43): [True: 20.3k, False: 0]
  ------------------
  101|  20.3k|      if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (101:15): [True: 19.9k, False: 386]
  ------------------
  102|  19.9k|         return std::make_unique<RFC4880_S2K_Family>(std::move(hash));
  103|  19.9k|      }
  104|  20.3k|   }
  105|    386|#endif
  106|       |
  107|       |#if defined(BOTAN_HAS_PKCS12_KDF)
  108|       |   if(req.algo_name() == "PKCS12-KDF" && req.arg_count() == 2) {
  109|       |      if(auto hash = HashFunction::create(req.arg(0))) {
  110|       |         const auto id_param = req.arg_as_integer(1);
  111|       |         return std::make_unique<PKCS12_KDF_Family>(std::move(hash), id_param);
  112|       |      }
  113|       |   }
  114|       |#endif
  115|       |
  116|    386|   BOTAN_UNUSED(req);
  ------------------
  |  |  144|    386|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  117|    386|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|    386|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  118|       |
  119|    386|   return nullptr;
  120|  20.3k|}

_ZN5Botan18Keccak_Permutation5clearEv:
   37|  4.48k|void Keccak_Permutation::clear() {
   38|  4.48k|   state() = {};
   39|  4.48k|   reset_cursor();
   40|  4.48k|}
_ZN5Botan18Keccak_Permutation6absorbENSt3__14spanIKhLm18446744073709551615EEE:
   42|  4.36M|void Keccak_Permutation::absorb(std::span<const uint8_t> input) {
   43|  4.36M|   absorb_into_sponge(*this, input);
   44|  4.36M|}
_ZN5Botan18Keccak_Permutation7squeezeENSt3__14spanIhLm18446744073709551615EEE:
   46|  4.48k|void Keccak_Permutation::squeeze(std::span<uint8_t> output) {
   47|  4.48k|   squeeze_from_sponge(*this, output);
   48|  4.48k|}
_ZN5Botan18Keccak_Permutation6finishEv:
   50|  4.48k|void Keccak_Permutation::finish() {
   51|       |   // The padding for Keccak[c]-based functions spans the entire remaining
   52|       |   // byterate until the next permute() call. At most that could be an entire
   53|       |   // byterate. First are a few bits of "custom" padding defined by the using
   54|       |   // function (e.g. SHA-3 uses "01"), then the remaining space is filled with
   55|       |   // "pad10*1" (see NIST FIPS 202 Section 5.1) followed by a final permute().
   56|       |
   57|  4.48k|   auto& S = state();
   58|       |
   59|       |   // Apply the custom padding + the left-most 1-bit of "pad10*1" to the current
   60|       |   // (partial) word of the sponge state
   61|       |
   62|  4.48k|   const uint64_t start_of_padding = (m_padding.padding | uint64_t(1) << m_padding.bit_len);
   63|  4.48k|   S[cursor() / word_bytes] ^= start_of_padding << (8 * (cursor() % word_bytes));
   64|       |
   65|       |   // XOR'ing the 0-bits of "pad10*1" into the state is a NOOP
   66|       |
   67|       |   // If the custom padding + the left-most 1-bit of "pad10*1" had resulted in a
   68|       |   // byte-aligned "partial padding", the final 1-bit of of "pad10*1" could
   69|       |   // potentially override parts of the already-appended "start_of_padding".
   70|       |   // In case we ever introduce a Keccak-based function with such a need, we
   71|       |   // have to modify this padding algorithm.
   72|  4.48k|   BOTAN_DEBUG_ASSERT(m_padding.bit_len % 8 != 7);
  ------------------
  |  |  130|  4.48k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.48k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.48k]
  |  |  ------------------
  ------------------
   73|       |
   74|       |   // Append the final bit of "pad10*1" into the last word of the input range
   75|  4.48k|   S[(byte_rate() / word_bytes) - 1] ^= uint64_t(0x8000000000000000);
   76|       |
   77|       |   // Perform the final permutation and reset the state cursor
   78|  4.48k|   permute();
   79|  4.48k|   reset_cursor();
   80|       |
   81|  4.48k|   BOTAN_DEBUG_ASSERT(cursor() == 0);
  ------------------
  |  |  130|  4.48k|      do { /* NOLINT(*-avoid-do-while) */ \
  |  |  131|  4.48k|      } while(0)
  |  |  ------------------
  |  |  |  Branch (131:15): [Folded, False: 4.48k]
  |  |  ------------------
  ------------------
   82|  4.48k|}
_ZN5Botan18Keccak_Permutation7permuteEv:
   84|   600k|void Keccak_Permutation::permute() {
   85|       |#if defined(BOTAN_HAS_KECCAK_PERM_AVX512)
   86|       |   if(CPUID::has(CPUID::Feature::AVX512)) {
   87|       |      return permute_avx512();
   88|       |   }
   89|       |#endif
   90|       |
   91|       |#if defined(BOTAN_HAS_KECCAK_PERM_BMI2)
   92|       |   if(CPUID::has(CPUID::Feature::BMI)) {
   93|       |      return permute_bmi2();
   94|       |   }
   95|       |#endif
   96|       |
   97|   600k|   static const uint64_t RC[24] = {0x0000000000000001, 0x0000000000008082, 0x800000000000808A, 0x8000000080008000,
   98|   600k|                                   0x000000000000808B, 0x0000000080000001, 0x8000000080008081, 0x8000000000008009,
   99|   600k|                                   0x000000000000008A, 0x0000000000000088, 0x0000000080008009, 0x000000008000000A,
  100|   600k|                                   0x000000008000808B, 0x800000000000008B, 0x8000000000008089, 0x8000000000008003,
  101|   600k|                                   0x8000000000008002, 0x8000000000000080, 0x000000000000800A, 0x800000008000000A,
  102|   600k|                                   0x8000000080008081, 0x8000000000008080, 0x0000000080000001, 0x8000000080008008};
  103|       |
  104|   600k|   uint64_t T[25];
  105|       |
  106|  7.80M|   for(size_t i = 0; i != 24; i += 2) {
  ------------------
  |  Branch (106:22): [True: 7.20M, False: 600k]
  ------------------
  107|  7.20M|      Keccak_Permutation_round(T, state().data(), RC[i + 0]);
  108|  7.20M|      Keccak_Permutation_round(state().data(), T, RC[i + 1]);
  109|  7.20M|   }
  110|   600k|}

_ZNK5Botan12EME_PKCS1v153padENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEEmRNS_21RandomNumberGeneratorE:
   24|     41|                         RandomNumberGenerator& rng) const {
   25|     41|   key_length /= 8;
   26|       |
   27|     41|   if(input.size() > maximum_input_size(key_length * 8)) {
  ------------------
  |  Branch (27:7): [True: 0, False: 41]
  ------------------
   28|      0|      throw Invalid_Argument("PKCS1: Input is too large");
   29|      0|   }
   30|       |
   31|     41|   BufferStuffer stuffer(output);
   32|       |
   33|     41|   const size_t padding_bytes = [&]() {
   34|     41|      auto d = checked_sub(key_length, input.size() + 2);
   35|     41|      BOTAN_ASSERT_NOMSG(d.has_value());
   36|     41|      return *d;
   37|     41|   }();
   38|       |
   39|     41|   stuffer.append(0x02);
   40|  4.01k|   for(size_t i = 0; i != padding_bytes; ++i) {
  ------------------
  |  Branch (40:22): [True: 3.97k, False: 41]
  ------------------
   41|  3.97k|      stuffer.append(rng.next_nonzero_byte());
   42|  3.97k|   }
   43|     41|   stuffer.append(0x00);
   44|     41|   stuffer.append(input);
   45|       |
   46|     41|   return output.size() - stuffer.remaining_capacity();
   47|     41|}
_ZNK5Botan12EME_PKCS1v1518maximum_input_sizeEm:
   97|     41|size_t EME_PKCS1v15::maximum_input_size(size_t keybits) const {
   98|     41|   if(keybits / 8 > 10) {
  ------------------
  |  Branch (98:7): [True: 41, False: 0]
  ------------------
   99|     41|      return ((keybits / 8) - 10);
  100|     41|   } else {
  101|      0|      return 0;
  102|      0|   }
  103|     41|}
eme_pkcs.cpp:_ZZNK5Botan12EME_PKCS1v153padENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEEmRNS_21RandomNumberGeneratorEENK3$_0clEv:
   33|     41|   const size_t padding_bytes = [&]() {
   34|     41|      auto d = checked_sub(key_length, input.size() + 2);
   35|     41|      BOTAN_ASSERT_NOMSG(d.has_value());
  ------------------
  |  |   77|     41|   do {                                                                     \
  |  |   78|     41|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|     41|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 41]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|     41|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 41]
  |  |  ------------------
  ------------------
   36|     41|      return *d;
   37|     41|   }();

_ZN5Botan23EncryptionPaddingScheme6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   27|     41|std::unique_ptr<EncryptionPaddingScheme> EncryptionPaddingScheme::create(std::string_view algo_spec) {
   28|       |#if defined(BOTAN_HAS_EME_RAW)
   29|       |   if(algo_spec == "Raw") {
   30|       |      return std::make_unique<EME_Raw>();
   31|       |   }
   32|       |#endif
   33|       |
   34|     41|#if defined(BOTAN_HAS_EME_PKCS1)
   35|       |   // TODO(Botan4) Remove all but "PKCS1v15"
   36|     41|   if(algo_spec == "PKCS1v15" || algo_spec == "EME-PKCS1-v1_5") {
  ------------------
  |  Branch (36:7): [True: 41, False: 0]
  |  Branch (36:34): [True: 0, False: 0]
  ------------------
   37|     41|      return std::make_unique<EME_PKCS1v15>();
   38|     41|   }
   39|      0|#endif
   40|       |
   41|       |#if defined(BOTAN_HAS_EME_OAEP)
   42|       |   const SCAN_Name req(algo_spec);
   43|       |
   44|       |   // TODO(Botan4) Remove all but "OAEP"
   45|       |   if(req.algo_name() == "OAEP" || req.algo_name() == "EME-OAEP" || req.algo_name() == "EME1") {
   46|       |      if(req.arg_count() == 1 || ((req.arg_count() == 2 || req.arg_count() == 3) && req.arg(1) == "MGF1")) {
   47|       |         if(auto hash = HashFunction::create(req.arg(0))) {
   48|       |            return std::make_unique<OAEP>(std::move(hash), req.arg(2, ""));
   49|       |         }
   50|       |      } else if(req.arg_count() == 2 || req.arg_count() == 3) {
   51|       |         auto mgf_params = parse_algorithm_name(req.arg(1));
   52|       |
   53|       |         if(mgf_params.size() == 2 && mgf_params[0] == "MGF1") {
   54|       |            auto hash = HashFunction::create(req.arg(0));
   55|       |            auto mgf1_hash = HashFunction::create(mgf_params[1]);
   56|       |
   57|       |            if(hash && mgf1_hash) {
   58|       |               return std::make_unique<OAEP>(std::move(hash), std::move(mgf1_hash), req.arg(2, ""));
   59|       |            }
   60|       |         }
   61|       |      }
   62|       |   }
   63|       |#endif
   64|       |
   65|      0|   throw Algorithm_Not_Found(algo_spec);
   66|     41|}
_ZN5Botan23EncryptionPaddingSchemeD2Ev:
   68|     41|EncryptionPaddingScheme::~EncryptionPaddingScheme() = default;

_ZN5Botan12pkcs_hash_idENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEE:
   78|    348|std::vector<uint8_t> pkcs_hash_id(std::string_view name) {
   79|       |   // Special case for SSL/TLS RSA signatures
   80|    348|   if(name == "Parallel(MD5,SHA-1)") {
  ------------------
  |  Branch (80:7): [True: 0, False: 348]
  ------------------
   81|      0|      return std::vector<uint8_t>();
   82|      0|   }
   83|       |
   84|       |   // If you add a value to this function, also update test_hash_id.cpp
   85|       |
   86|    348|   if(name == "MD5") {
  ------------------
  |  Branch (86:7): [True: 18, False: 330]
  ------------------
   87|     18|      return std::vector<uint8_t>(MD5_PKCS_ID, MD5_PKCS_ID + sizeof(MD5_PKCS_ID));
   88|     18|   }
   89|       |
   90|    330|   if(name == "RIPEMD-160") {
  ------------------
  |  Branch (90:7): [True: 11, False: 319]
  ------------------
   91|     11|      return std::vector<uint8_t>(RIPEMD_160_PKCS_ID, RIPEMD_160_PKCS_ID + sizeof(RIPEMD_160_PKCS_ID));
   92|     11|   }
   93|       |
   94|    319|   if(name == "SHA-1") {
  ------------------
  |  Branch (94:7): [True: 222, False: 97]
  ------------------
   95|    222|      return std::vector<uint8_t>(SHA_1_PKCS_ID, SHA_1_PKCS_ID + sizeof(SHA_1_PKCS_ID));
   96|    222|   }
   97|       |
   98|     97|   if(name == "SHA-224") {
  ------------------
  |  Branch (98:7): [True: 20, False: 77]
  ------------------
   99|     20|      return std::vector<uint8_t>(SHA_224_PKCS_ID, SHA_224_PKCS_ID + sizeof(SHA_224_PKCS_ID));
  100|     20|   }
  101|       |
  102|     77|   if(name == "SHA-256") {
  ------------------
  |  Branch (102:7): [True: 24, False: 53]
  ------------------
  103|     24|      return std::vector<uint8_t>(SHA_256_PKCS_ID, SHA_256_PKCS_ID + sizeof(SHA_256_PKCS_ID));
  104|     24|   }
  105|       |
  106|     53|   if(name == "SHA-384") {
  ------------------
  |  Branch (106:7): [True: 16, False: 37]
  ------------------
  107|     16|      return std::vector<uint8_t>(SHA_384_PKCS_ID, SHA_384_PKCS_ID + sizeof(SHA_384_PKCS_ID));
  108|     16|   }
  109|       |
  110|     37|   if(name == "SHA-512") {
  ------------------
  |  Branch (110:7): [True: 18, False: 19]
  ------------------
  111|     18|      return std::vector<uint8_t>(SHA_512_PKCS_ID, SHA_512_PKCS_ID + sizeof(SHA_512_PKCS_ID));
  112|     18|   }
  113|       |
  114|     19|   if(name == "SHA-512-256") {
  ------------------
  |  Branch (114:7): [True: 0, False: 19]
  ------------------
  115|      0|      return std::vector<uint8_t>(SHA_512_256_PKCS_ID, SHA_512_256_PKCS_ID + sizeof(SHA_512_256_PKCS_ID));
  116|      0|   }
  117|       |
  118|     19|   if(name == "SHA-3(224)") {
  ------------------
  |  Branch (118:7): [True: 0, False: 19]
  ------------------
  119|      0|      return std::vector<uint8_t>(SHA3_224_PKCS_ID, SHA3_224_PKCS_ID + sizeof(SHA3_224_PKCS_ID));
  120|      0|   }
  121|       |
  122|     19|   if(name == "SHA-3(256)") {
  ------------------
  |  Branch (122:7): [True: 11, False: 8]
  ------------------
  123|     11|      return std::vector<uint8_t>(SHA3_256_PKCS_ID, SHA3_256_PKCS_ID + sizeof(SHA3_256_PKCS_ID));
  124|     11|   }
  125|       |
  126|      8|   if(name == "SHA-3(384)") {
  ------------------
  |  Branch (126:7): [True: 0, False: 8]
  ------------------
  127|      0|      return std::vector<uint8_t>(SHA3_384_PKCS_ID, SHA3_384_PKCS_ID + sizeof(SHA3_384_PKCS_ID));
  128|      0|   }
  129|       |
  130|      8|   if(name == "SHA-3(512)") {
  ------------------
  |  Branch (130:7): [True: 7, False: 1]
  ------------------
  131|      7|      return std::vector<uint8_t>(SHA3_512_PKCS_ID, SHA3_512_PKCS_ID + sizeof(SHA3_512_PKCS_ID));
  132|      7|   }
  133|       |
  134|      1|   if(name == "SM3") {
  ------------------
  |  Branch (134:7): [True: 1, False: 0]
  ------------------
  135|      1|      return std::vector<uint8_t>(SM3_PKCS_ID, SM3_PKCS_ID + sizeof(SM3_PKCS_ID));
  136|      1|   }
  137|       |
  138|      0|   throw Invalid_Argument("No PKCS #1 identifier for " + std::string(name));
  139|      1|}

_ZN5Botan15RawHashFunction8add_dataENSt3__14spanIKhLm18446744073709551615EEE:
   14|  7.33k|void RawHashFunction::add_data(std::span<const uint8_t> input) {
   15|  7.33k|   m_bits += std::make_pair(input.data(), input.size());
   16|  7.33k|}
_ZN5Botan15RawHashFunction12final_resultENSt3__14spanIhLm18446744073709551615EEE:
   18|  7.33k|void RawHashFunction::final_result(std::span<uint8_t> out) {
   19|  7.33k|   if(m_output_length > 0 && m_bits.size() != m_output_length) {
  ------------------
  |  Branch (19:7): [True: 6.25k, False: 1.08k]
  |  Branch (19:30): [True: 0, False: 6.25k]
  ------------------
   20|      0|      m_bits.clear();
   21|      0|      throw Invalid_Argument("Raw padding was configured to use a " + std::to_string(m_output_length) +
   22|      0|                             " byte hash but instead was used for a " + std::to_string(m_bits.size()) + " byte hash");
   23|      0|   }
   24|       |
   25|  7.33k|   copy_mem(out.data(), m_bits.data(), m_bits.size());
   26|  7.33k|   m_bits.clear();
   27|  7.33k|}
_ZNK5Botan15RawHashFunction13output_lengthEv:
   41|  7.33k|size_t RawHashFunction::output_length() const {
   42|  7.33k|   if(m_output_length > 0) {
  ------------------
  |  Branch (42:7): [True: 6.25k, False: 1.08k]
  ------------------
   43|  6.25k|      return m_output_length;
   44|  6.25k|   }
   45|  1.08k|   return m_bits.size();
   46|  7.33k|}

_ZN5Botan35PKCS1v15_Raw_SignaturePaddingSchemeC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  103|    348|PKCS1v15_Raw_SignaturePaddingScheme::PKCS1v15_Raw_SignaturePaddingScheme(std::string_view hash_algo) {
  104|    348|   std::unique_ptr<HashFunction> hash(HashFunction::create_or_throw(hash_algo));
  105|    348|   m_hash_id = pkcs_hash_id(hash_algo);
  106|    348|   m_hash_name = hash->name();
  107|    348|   m_hash_output_len = hash->output_length();
  108|    348|}
_ZN5Botan35PKCS1v15_Raw_SignaturePaddingScheme6updateEPKhm:
  110|    348|void PKCS1v15_Raw_SignaturePaddingScheme::update(const uint8_t input[], size_t length) {
  111|    348|   if(length > 0) {
  ------------------
  |  Branch (111:7): [True: 348, False: 0]
  ------------------
  112|       |      // A sanity check to prevent someone from accidentally feeding an entire message
  113|       |      // into PKCS1v15(Raw), which would have to be buffered in memory
  114|    348|      if(m_message.size() + length > 16384 / 8) {
  ------------------
  |  Branch (114:10): [True: 0, False: 348]
  ------------------
  115|      0|         throw Invalid_Argument("PKCS1v15(Raw) message too long");
  116|      0|      }
  117|    348|      m_message.insert(m_message.end(), input, input + length);
  118|    348|   }
  119|    348|}
_ZN5Botan35PKCS1v15_Raw_SignaturePaddingScheme8raw_dataEv:
  121|    348|std::vector<uint8_t> PKCS1v15_Raw_SignaturePaddingScheme::raw_data() {
  122|    348|   std::vector<uint8_t> ret;
  123|    348|   std::swap(ret, m_message);
  124|       |
  125|    348|   if(m_hash_output_len > 0 && ret.size() != m_hash_output_len) {
  ------------------
  |  Branch (125:7): [True: 348, False: 0]
  |  Branch (125:32): [True: 0, False: 348]
  ------------------
  126|      0|      throw Encoding_Error("PKCS1v15_Raw_SignaturePaddingScheme::encoding_of: Bad input length");
  127|      0|   }
  128|       |
  129|    348|   return ret;
  130|    348|}
_ZN5Botan35PKCS1v15_Raw_SignaturePaddingScheme6verifyENSt3__14spanIKhLm18446744073709551615EEES4_m:
  140|    329|                                                 size_t key_bits) {
  141|    329|   if(m_hash_output_len > 0 && raw.size() != m_hash_output_len) {
  ------------------
  |  Branch (141:7): [True: 329, False: 0]
  |  Branch (141:32): [True: 0, False: 329]
  ------------------
  142|      0|      return false;
  143|      0|   }
  144|       |
  145|    329|   try {
  146|    329|      const auto pkcs1 = pkcs1v15_sig_encoding(raw, key_bits, m_hash_id);
  147|    329|      return constant_time_compare(coded, pkcs1);
  148|    329|   } catch(...) {
  149|      0|      return false;
  150|      0|   }
  151|    329|}
pkcs1_sig_padding.cpp:_ZN5Botan12_GLOBAL__N_121pkcs1v15_sig_encodingENSt3__14spanIKhLm18446744073709551615EEEmS4_:
   23|    329|                                           std::span<const uint8_t> hash_id) {
   24|    329|   const size_t output_length = output_bits / 8;
   25|       |
   26|    329|   if(output_length < hash_id.size() + msg.size() + 2 + 8) {
  ------------------
  |  Branch (26:7): [True: 0, False: 329]
  ------------------
   27|      0|      throw Encoding_Error("pkcs1v15_sig_encoding: Output length is too small");
   28|      0|   }
   29|       |
   30|    329|   std::vector<uint8_t> padded(output_length);
   31|    329|   BufferStuffer stuffer(padded);
   32|       |
   33|    329|   stuffer.append(0x01);
   34|    329|   stuffer.append(0xFF, stuffer.remaining_capacity() - (1 + hash_id.size() + msg.size()));
   35|    329|   stuffer.append(0x00);
   36|    329|   stuffer.append(hash_id);
   37|    329|   stuffer.append(msg);
   38|    329|   BOTAN_ASSERT_NOMSG(stuffer.full());
  ------------------
  |  |   77|    329|   do {                                                                     \
  |  |   78|    329|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|    329|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 329]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|    329|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 329]
  |  |  ------------------
  ------------------
   39|       |
   40|    329|   return padded;
   41|    329|}

_ZN5Botan22SignaturePaddingScheme6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   35|    348|std::unique_ptr<SignaturePaddingScheme> SignaturePaddingScheme::create(std::string_view algo_spec) {
   36|    348|   const SCAN_Name req(algo_spec);
   37|       |
   38|    348|#if defined(BOTAN_HAS_EMSA_PKCS1)
   39|       |   // TODO(Botan4) Remove all but "PKCS1v15"
   40|    348|   if(req.algo_name() == "EMSA_PKCS1" || req.algo_name() == "PKCS1v15" || req.algo_name() == "EMSA-PKCS1-v1_5" ||
  ------------------
  |  Branch (40:7): [True: 0, False: 348]
  |  Branch (40:42): [True: 0, False: 348]
  |  Branch (40:75): [True: 348, False: 0]
  ------------------
   41|    348|      req.algo_name() == "EMSA3") {
  ------------------
  |  Branch (41:7): [True: 0, False: 0]
  ------------------
   42|    348|      if(req.arg_count() == 2 && req.arg(0) == "Raw") {
  ------------------
  |  Branch (42:10): [True: 348, False: 0]
  |  Branch (42:10): [True: 348, False: 0]
  |  Branch (42:34): [True: 348, False: 0]
  ------------------
   43|    348|         return std::make_unique<PKCS1v15_Raw_SignaturePaddingScheme>(req.arg(1));
   44|    348|      } else if(req.arg_count() == 1) {
  ------------------
  |  Branch (44:17): [True: 0, False: 0]
  ------------------
   45|      0|         if(req.arg(0) == "Raw") {
  ------------------
  |  Branch (45:13): [True: 0, False: 0]
  ------------------
   46|      0|            return std::make_unique<PKCS1v15_Raw_SignaturePaddingScheme>();
   47|      0|         } else {
   48|      0|            if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (48:21): [True: 0, False: 0]
  ------------------
   49|      0|               return std::make_unique<PKCS1v15_SignaturePaddingScheme>(std::move(hash));
   50|      0|            }
   51|      0|         }
   52|      0|      }
   53|    348|   }
   54|      0|#endif
   55|       |
   56|       |#if defined(BOTAN_HAS_EMSA_PSSR)
   57|       |   // TODO(Botan4) Remove all but "PSS_Raw"
   58|       |   if(req.algo_name() == "PSS_Raw" || req.algo_name() == "PSSR_Raw") {
   59|       |      if(req.arg_count_between(1, 3) && req.arg(1, "MGF1") == "MGF1") {
   60|       |         if(auto hash = HashFunction::create(req.arg(0))) {
   61|       |            if(req.arg_count() == 3) {
   62|       |               const size_t salt_size = req.arg_as_integer(2, 0);
   63|       |               return std::make_unique<PSS_Raw>(std::move(hash), salt_size);
   64|       |            } else {
   65|       |               return std::make_unique<PSS_Raw>(std::move(hash));
   66|       |            }
   67|       |         }
   68|       |      }
   69|       |   }
   70|       |
   71|       |   // TODO(Botan4) Remove all but "PSS"
   72|       |   if(req.algo_name() == "PSS" || req.algo_name() == "PSSR" || req.algo_name() == "EMSA-PSS" ||
   73|       |      req.algo_name() == "PSS-MGF1" || req.algo_name() == "EMSA4") {
   74|       |      if(req.arg_count_between(1, 3) && req.arg(1, "MGF1") == "MGF1") {
   75|       |         if(auto hash = HashFunction::create(req.arg(0))) {
   76|       |            if(req.arg_count() == 3) {
   77|       |               const size_t salt_size = req.arg_as_integer(2, 0);
   78|       |               return std::make_unique<PSSR>(std::move(hash), salt_size);
   79|       |            } else {
   80|       |               return std::make_unique<PSSR>(std::move(hash));
   81|       |            }
   82|       |         }
   83|       |      }
   84|       |   }
   85|       |#endif
   86|       |
   87|       |#if defined(BOTAN_HAS_ISO_9796)
   88|       |   if(req.algo_name() == "ISO_9796_DS2") {
   89|       |      if(req.arg_count_between(1, 3)) {
   90|       |         const std::string trailer = req.arg(1, "exp");
   91|       |         if(trailer != "imp" && trailer != "exp") {
   92|       |            return nullptr;
   93|       |         }
   94|       |         if(auto hash = HashFunction::create(req.arg(0))) {
   95|       |            const size_t salt_size = req.arg_as_integer(2, hash->output_length());
   96|       |            return std::make_unique<ISO_9796_DS2>(std::move(hash), trailer == "imp", salt_size);
   97|       |         }
   98|       |      }
   99|       |   }
  100|       |   //ISO-9796-2 DS 3 is deterministic and DS2 without a salt
  101|       |   if(req.algo_name() == "ISO_9796_DS3") {
  102|       |      if(req.arg_count_between(1, 2)) {
  103|       |         const std::string trailer = req.arg(1, "exp");
  104|       |         if(trailer != "imp" && trailer != "exp") {
  105|       |            return nullptr;
  106|       |         }
  107|       |         if(auto hash = HashFunction::create(req.arg(0))) {
  108|       |            return std::make_unique<ISO_9796_DS3>(std::move(hash), trailer == "imp");
  109|       |         }
  110|       |      }
  111|       |   }
  112|       |#endif
  113|       |
  114|       |#if defined(BOTAN_HAS_X931_SIGNATURE_PADDING)
  115|       |   // TODO(Botan4) Remove all but "X9.31"
  116|       |   if(req.algo_name() == "EMSA_X931" || req.algo_name() == "EMSA2" || req.algo_name() == "X9.31") {
  117|       |      if(req.arg_count() == 1) {
  118|       |         if(auto hash = HashFunction::create(req.arg(0))) {
  119|       |            return std::make_unique<X931_SignaturePadding>(std::move(hash));
  120|       |         }
  121|       |      }
  122|       |   }
  123|       |#endif
  124|       |
  125|      0|#if defined(BOTAN_HAS_RAW_SIGNATURE_PADDING)
  126|      0|   if(req.algo_name() == "Raw") {
  ------------------
  |  Branch (126:7): [True: 0, False: 0]
  ------------------
  127|      0|      if(req.arg_count() == 0) {
  ------------------
  |  Branch (127:10): [True: 0, False: 0]
  ------------------
  128|      0|         return std::make_unique<SignRawBytes>();
  129|      0|      } else {
  130|      0|         auto hash = HashFunction::create(req.arg(0));
  131|      0|         if(hash) {
  ------------------
  |  Branch (131:13): [True: 0, False: 0]
  ------------------
  132|      0|            return std::make_unique<SignRawBytes>(hash->output_length());
  133|      0|         }
  134|      0|      }
  135|      0|   }
  136|      0|#endif
  137|       |
  138|      0|   return nullptr;
  139|      0|}
_ZN5Botan22SignaturePaddingScheme15create_or_throwENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  141|    348|std::unique_ptr<SignaturePaddingScheme> SignaturePaddingScheme::create_or_throw(std::string_view algo_spec) {
  142|    348|   if(auto padding = SignaturePaddingScheme::create(algo_spec)) {
  ------------------
  |  Branch (142:12): [True: 348, False: 0]
  ------------------
  143|    348|      return padding;
  144|    348|   } else {
  145|      0|      throw Algorithm_Not_Found(algo_spec);
  146|      0|   }
  147|    348|}

_ZN5Botan12DL_PublicKeyC2ERKNS_8DL_GroupERKNS_6BigIntE:
   38|  1.12k|DL_PublicKey::DL_PublicKey(const DL_Group& group, const BigInt& public_key) : m_group(group), m_public_key(public_key) {
   39|       |   // The subgroup check (y^q == 1 mod p) is deferred to check_key() since it can be expensive
   40|  1.12k|   BOTAN_ARG_CHECK(m_public_key > 1 && m_public_key < m_group.get_p(), "Invalid DL public key");
  ------------------
  |  |   35|  1.12k|   do {                                                          \
  |  |   36|  1.12k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  2.25k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 1.12k, False: 0]
  |  |  |  Branch (37:12): [True: 1.12k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.12k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.12k]
  |  |  ------------------
  ------------------
   41|  1.12k|}

_ZN5Botan8DL_GroupC2ERKNS_6BigIntES3_:
  398|     41|DL_Group::DL_Group(const BigInt& p, const BigInt& g) {
  399|     41|   m_data = DL_Group_Data::create(p, g, DL_Group_Source::ExternalSource);
  400|     41|}
_ZN5Botan8DL_GroupC2ERKNS_6BigIntES3_S3_:
  405|  1.08k|DL_Group::DL_Group(const BigInt& p, const BigInt& q, const BigInt& g) {
  406|  1.08k|   if(q.is_zero()) {
  ------------------
  |  Branch (406:7): [True: 0, False: 1.08k]
  ------------------
  407|      0|      m_data = DL_Group_Data::create(p, g, DL_Group_Source::ExternalSource);
  408|  1.08k|   } else {
  409|  1.08k|      m_data = DL_Group_Data::create(p, q, g, DL_Group_Source::ExternalSource);
  410|  1.08k|   }
  411|  1.08k|}
_ZNK5Botan8DL_Group4dataEv:
  413|  19.2k|const DL_Group_Data& DL_Group::data() const {
  414|  19.2k|   if(m_data) {
  ------------------
  |  Branch (414:7): [True: 19.2k, False: 0]
  ------------------
  415|  19.2k|      return *m_data;
  416|  19.2k|   }
  417|       |
  418|      0|   throw Invalid_State("DL_Group uninitialized");
  419|  19.2k|}
_ZNK5Botan8DL_Group5get_pEv:
  523|  1.16k|const BigInt& DL_Group::get_p() const {
  524|  1.16k|   return data().p();
  525|  1.16k|}
_ZNK5Botan8DL_Group5get_gEv:
  530|  1.02k|const BigInt& DL_Group::get_g() const {
  531|  1.02k|   return data().g();
  532|  1.02k|}
_ZNK5Botan8DL_Group5get_qEv:
  537|  3.14k|const BigInt& DL_Group::get_q() const {
  538|  3.14k|   return data().q();
  539|  3.14k|}
_ZNK5Botan8DL_Group15_monty_params_pEv:
  541|     41|const Montgomery_Params& DL_Group::_monty_params_p() const {
  542|     41|   return data().monty_params_p();
  543|     41|}
_ZNK5Botan8DL_Group5has_qEv:
  545|  1.08k|bool DL_Group::has_q() const {
  546|  1.08k|   return data().q_is_set();
  547|  1.08k|}
_ZNK5Botan8DL_Group6p_bitsEv:
  549|     82|size_t DL_Group::p_bits() const {
  550|     82|   return data().p_bits();
  551|     82|}
_ZNK5Botan8DL_Group7p_bytesEv:
  553|     41|size_t DL_Group::p_bytes() const {
  554|     41|   return data().p_bytes();
  555|     41|}
_ZNK5Botan8DL_Group6q_bitsEv:
  557|  2.11k|size_t DL_Group::q_bits() const {
  558|  2.11k|   data().assert_q_is_set("q_bits");
  559|  2.11k|   return data().q_bits();
  560|  2.11k|}
_ZNK5Botan8DL_Group7q_bytesEv:
  562|  1.08k|size_t DL_Group::q_bytes() const {
  563|  1.08k|   data().assert_q_is_set("q_bytes");
  564|  1.08k|   return data().q_bytes();
  565|  1.08k|}
_ZNK5Botan8DL_Group14multiply_mod_pERKNS_6BigIntES3_:
  584|     41|BigInt DL_Group::multiply_mod_p(const BigInt& x, const BigInt& y) const {
  585|     41|   return data().reducer_mod_p().multiply(x, y);
  586|     41|}
_ZNK5Botan8DL_Group13inverse_mod_qERKNS_6BigIntE:
  592|  1.02k|BigInt DL_Group::inverse_mod_q(const BigInt& x) const {
  593|  1.02k|   data().assert_q_is_set("inverse_mod_q");
  594|       |   // precompute??
  595|  1.02k|   return inverse_mod_public_prime(x, get_q());
  596|  1.02k|}
_ZNK5Botan8DL_Group14multiply_mod_qERKNS_6BigIntES3_:
  603|  2.05k|BigInt DL_Group::multiply_mod_q(const BigInt& x, const BigInt& y) const {
  604|  2.05k|   data().assert_q_is_set("multiply_mod_q");
  605|  2.05k|   return data().reducer_mod_q().multiply(x, y);
  606|  2.05k|}
_ZNK5Botan8DL_Group18multi_exponentiateERKNS_6BigIntES3_S3_:
  618|  1.02k|BigInt DL_Group::multi_exponentiate(const BigInt& x, const BigInt& y, const BigInt& z) const {
  619|  1.02k|   return monty_multi_exp(data().monty_params_p(), get_g(), x, y, z).value();
  620|  1.02k|}
_ZNK5Botan8DL_Group9power_g_pERKNS_6BigIntEm:
  622|     41|BigInt DL_Group::power_g_p(const BigInt& x, size_t max_x_bits) const {
  623|     41|   return data().power_g_p(x, max_x_bits);
  624|     41|}
_ZN5Botan13DL_Group_Data6createERKNS_6BigIntES3_S3_NS_15DL_Group_SourceE:
   52|  1.08k|                                                   DL_Group_Source source) {
   53|  1.08k|         check_dl_group_params(p, q, g);
   54|  1.08k|         return std::make_shared<DL_Group_Data>(p, q, g, source);
   55|  1.08k|      }
dl_group.cpp:_ZN5Botan12_GLOBAL__N_121check_dl_group_paramsERKNS_6BigIntES3_S3_:
   38|  1.08k|void check_dl_group_params(const BigInt& p, const BigInt& q, const BigInt& g) {
   39|  1.08k|   check_dl_group_params(p, g);
   40|  1.08k|   if(q.signum() <= 0 || q.is_even() || q.bits() >= p.bits()) {
  ------------------
  |  Branch (40:7): [True: 0, False: 1.08k]
  |  Branch (40:26): [True: 0, False: 1.08k]
  |  Branch (40:41): [True: 0, False: 1.08k]
  ------------------
   41|      0|      throw Decoding_Error("Invalid DL group subgroup order");
   42|      0|   }
   43|  1.08k|}
dl_group.cpp:_ZN5Botan12_GLOBAL__N_121check_dl_group_paramsERKNS_6BigIntES3_:
   29|  1.12k|void check_dl_group_params(const BigInt& p, const BigInt& g) {
   30|  1.12k|   if(p.signum() <= 0 || p.is_even() || p.bits() < 3 || p.bits() > 16384) {
  ------------------
  |  Branch (30:7): [True: 0, False: 1.12k]
  |  Branch (30:26): [True: 0, False: 1.12k]
  |  Branch (30:41): [True: 0, False: 1.12k]
  |  Branch (30:57): [True: 0, False: 1.12k]
  ------------------
   31|      0|      throw Decoding_Error("Invalid DL group prime");
   32|      0|   }
   33|  1.12k|   if(g.signum() <= 0 || g < 2 || g >= p) {
  ------------------
  |  Branch (33:7): [True: 0, False: 1.12k]
  |  Branch (33:26): [True: 0, False: 1.12k]
  |  Branch (33:35): [True: 0, False: 1.12k]
  ------------------
   34|      0|      throw Decoding_Error("Invalid DL group generator");
   35|      0|   }
   36|  1.12k|}
_ZN5Botan13DL_Group_DataC2ERKNS_6BigIntES3_S3_NS_15DL_Group_SourceE:
   65|  1.08k|            m_p(p),
   66|  1.08k|            m_q(q),
   67|  1.08k|            m_g(g),
   68|  1.08k|            m_mod_p(Barrett_Reduction::for_public_modulus(p)),
   69|  1.08k|            m_mod_q(Barrett_Reduction::for_public_modulus(q)),
   70|  1.08k|            m_monty_params(m_p, m_mod_p),
   71|  1.08k|            m_monty(monty_precompute(m_monty_params, m_g, /*window bits=*/4)),
   72|  1.08k|            m_p_bits(p.bits()),
   73|  1.08k|            m_q_bits(q.bits()),
   74|       |            // For DL crypto in a prime-order subgroup, security is bounded by
   75|       |            // both the NFS cost in Z_p* and Pollard rho in the q-order subgroup.
   76|  1.08k|            m_estimated_strength(std::min(dl_work_factor(m_p_bits), m_q_bits / 2)),
   77|  1.08k|            m_exponent_bits(dl_exponent_size(m_p_bits)),
   78|  1.08k|            m_source(source) {}
_ZN5Botan13DL_Group_DataD2Ev:
   94|  1.12k|      ~DL_Group_Data() = default;
_ZN5Botan13DL_Group_Data6createERKNS_6BigIntES3_NS_15DL_Group_SourceE:
   57|     41|      static std::shared_ptr<DL_Group_Data> create(const BigInt& p, const BigInt& g, DL_Group_Source source) {
   58|     41|         check_dl_group_params(p, g);
   59|     41|         return std::make_shared<DL_Group_Data>(p, g, source);
   60|     41|      }
_ZN5Botan13DL_Group_DataC2ERKNS_6BigIntES3_NS_15DL_Group_SourceE:
   83|     41|            m_p(p),
   84|     41|            m_g(g),
   85|     41|            m_mod_p(Barrett_Reduction::for_public_modulus(p)),
   86|     41|            m_monty_params(m_p, m_mod_p),
   87|     41|            m_monty(monty_precompute(m_monty_params, m_g, /*window bits=*/4)),
   88|     41|            m_p_bits(p.bits()),
   89|     41|            m_q_bits(0),
   90|     41|            m_estimated_strength(dl_work_factor(m_p_bits)),
   91|     41|            m_exponent_bits(dl_exponent_size(m_p_bits)),
   92|     41|            m_source(source) {}
_ZNK5Botan13DL_Group_Data1pEv:
  101|  1.16k|      const BigInt& p() const { return m_p; }
_ZNK5Botan13DL_Group_Data1gEv:
  105|  1.02k|      const BigInt& g() const { return m_g; }
_ZNK5Botan13DL_Group_Data1qEv:
  103|  3.14k|      const BigInt& q() const { return m_q; }
_ZNK5Botan13DL_Group_Data14monty_params_pEv:
  114|  1.06k|      const Montgomery_Params& monty_params_p() const { return m_monty_params; }
_ZNK5Botan13DL_Group_Data8q_is_setEv:
  142|  7.36k|      bool q_is_set() const { return m_q_bits > 0; }
_ZNK5Botan13DL_Group_Data6p_bitsEv:
  116|     82|      size_t p_bits() const { return m_p_bits; }
_ZNK5Botan13DL_Group_Data7p_bytesEv:
  120|     41|      size_t p_bytes() const { return (m_p_bits + 7) / 8; }
_ZNK5Botan13DL_Group_Data15assert_q_is_setENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  144|  6.28k|      void assert_q_is_set(std::string_view function) const {
  145|  6.28k|         if(!q_is_set()) {
  ------------------
  |  Branch (145:13): [True: 0, False: 6.28k]
  ------------------
  146|      0|            throw Invalid_State(fmt("DL_Group::{}: q is not set for this group", function));
  147|      0|         }
  148|  6.28k|      }
_ZNK5Botan13DL_Group_Data6q_bitsEv:
  118|  2.11k|      size_t q_bits() const { return m_q_bits; }
_ZNK5Botan13DL_Group_Data7q_bytesEv:
  122|  1.08k|      size_t q_bytes() const { return (m_q_bits + 7) / 8; }
_ZNK5Botan13DL_Group_Data13reducer_mod_pEv:
  107|     41|      const Barrett_Reduction& reducer_mod_p() const { return m_mod_p; }
_ZNK5Botan13DL_Group_Data13reducer_mod_qEv:
  109|  2.05k|      const Barrett_Reduction& reducer_mod_q() const {
  110|  2.05k|         BOTAN_STATE_CHECK(m_mod_q);
  ------------------
  |  |   51|  2.05k|   do {                                                         \
  |  |   52|  2.05k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  2.05k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 2.05k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  2.05k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 2.05k]
  |  |  ------------------
  ------------------
  111|  2.05k|         return *m_mod_q;
  112|  2.05k|      }
_ZNK5Botan13DL_Group_Data9power_g_pERKNS_6BigIntEm:
  128|     41|      BigInt power_g_p(const BigInt& k, size_t max_k_bits) const {
  129|     41|         return monty_execute(*m_monty, k, max_k_bits).value();
  130|     41|      }

_ZNK5Botan13DSA_PublicKey40_signature_element_size_for_DER_encodingEv:
   34|  1.08k|std::optional<size_t> DSA_PublicKey::_signature_element_size_for_DER_encoding() const {
   35|  1.08k|   return m_public_key->group().q_bytes();
   36|  1.08k|}
_ZN5Botan13DSA_PublicKeyC1ERKNS_8DL_GroupERKNS_6BigIntE:
   76|  1.08k|DSA_PublicKey::DSA_PublicKey(const DL_Group& group, const BigInt& y) {
   77|  1.08k|   m_public_key = std::make_shared<DL_PublicKey>(group, y);
   78|       |
   79|  1.08k|   check_dsa_group(m_public_key->group());
   80|  1.08k|}
_ZNK5Botan13DSA_PublicKey22create_verification_opENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  276|  1.08k|                                                                            std::string_view provider) const {
  277|  1.08k|   if(provider == "base" || provider.empty()) {
  ------------------
  |  Branch (277:7): [True: 0, False: 1.08k]
  |  Branch (277:29): [True: 1.08k, False: 0]
  ------------------
  278|  1.08k|      return std::make_unique<DSA_Verification_Operation>(this->m_public_key, params);
  279|  1.08k|   }
  280|      0|   throw Provider_Not_Found(algo_name(), provider);
  281|  1.08k|}
dsa.cpp:_ZN5Botan12_GLOBAL__N_115check_dsa_groupERKNS_8DL_GroupE:
   26|  1.08k|void check_dsa_group(const DL_Group& group) {
   27|  1.08k|   BOTAN_ARG_CHECK(group.has_q(), "Q parameter must be set for DSA");
  ------------------
  |  |   35|  1.08k|   do {                                                          \
  |  |   36|  1.08k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.08k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.08k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.08k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.08k]
  |  |  ------------------
  ------------------
   28|       |   // All versions of FIPS 186 have required that Q be at least 160 bits
   29|  1.08k|   BOTAN_ARG_CHECK(group.q_bits() >= 160, "DSA Q parameter must be at least 160 bits");
  ------------------
  |  |   35|  1.08k|   do {                                                          \
  |  |   36|  1.08k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.08k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 1, False: 1.08k]
  |  |  ------------------
  |  |   38|      1|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      1|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      1|      }                                                          \
  |  |   41|  1.08k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.08k]
  |  |  ------------------
  ------------------
   30|  1.08k|}
dsa.cpp:_ZN5Botan12_GLOBAL__N_126DSA_Verification_OperationC2ERKNSt3__110shared_ptrIKNS_12DL_PublicKeyEEENS2_17basic_string_viewIcNS2_11char_traitsIcEEEE:
  224|  1.08k|            PK_Ops::Verification_with_Hash(hash_fn), m_key(key) {}
dsa.cpp:_ZN5Botan12_GLOBAL__N_126DSA_Verification_Operation6verifyENSt3__14spanIKhLm18446744073709551615EEES5_:
  235|  1.08k|bool DSA_Verification_Operation::verify(std::span<const uint8_t> input, std::span<const uint8_t> sig) {
  236|  1.08k|   const auto group = m_key->group();
  237|       |
  238|  1.08k|   const BigInt& q = group.get_q();
  239|  1.08k|   const size_t q_bytes = q.bytes();
  240|       |
  241|  1.08k|   if(sig.size() != 2 * q_bytes) {
  ------------------
  |  Branch (241:7): [True: 0, False: 1.08k]
  ------------------
  242|      0|      return false;
  243|      0|   }
  244|       |
  245|  1.08k|   const BigInt r(sig.first(q_bytes));
  246|  1.08k|   BigInt s(sig.last(q_bytes));
  247|       |
  248|  1.08k|   if(r == 0 || r >= q || s == 0 || s >= q) {
  ------------------
  |  Branch (248:7): [True: 1, False: 1.08k]
  |  Branch (248:17): [True: 24, False: 1.06k]
  |  Branch (248:27): [True: 0, False: 1.06k]
  |  Branch (248:37): [True: 34, False: 1.02k]
  ------------------
  249|     59|      return false;
  250|     59|   }
  251|       |
  252|  1.02k|   BigInt i = BigInt::from_bytes_with_max_bits(input.data(), input.size(), group.q_bits());
  253|  1.02k|   if(i >= q) {
  ------------------
  |  Branch (253:7): [True: 491, False: 536]
  ------------------
  254|    491|      i -= q;
  255|    491|   }
  256|       |
  257|  1.02k|   s = group.inverse_mod_q(s);
  258|       |
  259|       |   // Since we already checked for s == 0 above this shouldn't happen
  260|  1.02k|   if(s.is_zero()) {
  ------------------
  |  Branch (260:7): [True: 0, False: 1.02k]
  ------------------
  261|      0|      return false;
  262|      0|   }
  263|       |
  264|  1.02k|   const BigInt sr = group.multiply_mod_q(s, r);
  265|  1.02k|   const BigInt si = group.multiply_mod_q(s, i);
  266|       |
  267|  1.02k|   s = group.multi_exponentiate(si, m_key->public_key(), sr);
  268|       |
  269|       |   // s is too big for Barrett, and verification doesn't need to be const-time
  270|  1.02k|   return (s % group.get_q() == r);
  271|  1.02k|}

_ZN5Botan14EC_AffinePointC2ENSt3__110unique_ptrINS_19EC_AffinePoint_DataENS1_14default_deleteIS3_EEEE:
   16|  6.25k|EC_AffinePoint::EC_AffinePoint(std::unique_ptr<EC_AffinePoint_Data> point) : m_point(std::move(point)) {
   17|  6.25k|   BOTAN_ASSERT_NONNULL(m_point);
  ------------------
  |  |  116|  6.25k|   do {                                                                                   \
  |  |  117|  6.25k|      if((ptr) == nullptr) {                                                              \
  |  |  ------------------
  |  |  |  Branch (117:10): [True: 0, False: 6.25k]
  |  |  ------------------
  |  |  118|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                              \
  |  |  119|      0|         Botan::assertion_failure(#ptr " is not null", "", __func__, __FILE__, __LINE__); \
  |  |  120|      0|      }                                                                                   \
  |  |  121|  6.25k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (121:12): [Folded, False: 6.25k]
  |  |  ------------------
  ------------------
   18|  6.25k|}
_ZN5Botan14EC_AffinePointC2ERKS0_:
   20|  6.25k|EC_AffinePoint::EC_AffinePoint(const EC_AffinePoint& other) : m_point(other.inner().clone()) {}
_ZN5Botan14EC_AffinePointC2EOS0_:
   22|  12.5k|EC_AffinePoint::EC_AffinePoint(EC_AffinePoint&& other) noexcept : m_point(std::move(other.m_point)) {}
_ZNK5Botan14EC_AffinePoint15to_legacy_pointEv:
   46|  6.25k|EC_Point EC_AffinePoint::to_legacy_point() const {
   47|  6.25k|   return m_point->to_legacy_point();
   48|  6.25k|}
_ZN5Botan14EC_AffinePoint14from_bigint_xyERKNS_8EC_GroupERKNS_6BigIntES6_:
   93|  6.29k|std::optional<EC_AffinePoint> EC_AffinePoint::from_bigint_xy(const EC_Group& group, const BigInt& x, const BigInt& y) {
   94|  6.29k|   if(x.signum() < 0 || x >= group.get_p()) {
  ------------------
  |  Branch (94:7): [True: 0, False: 6.29k]
  |  Branch (94:25): [True: 0, False: 6.29k]
  ------------------
   95|      0|      return {};
   96|      0|   }
   97|  6.29k|   if(y.signum() < 0 || y >= group.get_p()) {
  ------------------
  |  Branch (97:7): [True: 0, False: 6.29k]
  |  Branch (97:25): [True: 0, False: 6.29k]
  ------------------
   98|      0|      return {};
   99|      0|   }
  100|       |
  101|  6.29k|   const size_t fe_bytes = group.get_p_bytes();
  102|  6.29k|   std::vector<uint8_t> sec1(1 + 2 * fe_bytes);
  103|  6.29k|   sec1[0] = 0x04;
  104|  6.29k|   x.serialize_to(std::span{sec1}.subspan(1, fe_bytes));
  105|  6.29k|   y.serialize_to(std::span{sec1}.last(fe_bytes));
  106|       |
  107|  6.29k|   return EC_AffinePoint::deserialize_uncompressed(group, sec1);
  108|  6.29k|}
_ZNK5Botan14EC_AffinePoint11is_identityEv:
  114|  6.25k|bool EC_AffinePoint::is_identity() const {
  115|  6.25k|   return inner().is_identity();
  116|  6.25k|}
_ZN5Botan14EC_AffinePointD2Ev:
  148|  25.0k|EC_AffinePoint::~EC_AffinePoint() = default;
_ZN5Botan14EC_AffinePoint24deserialize_uncompressedERKNS_8EC_GroupENSt3__14spanIKhLm18446744073709551615EEE:
  199|  6.29k|                                                                       std::span<const uint8_t> bytes) {
  200|  6.29k|   if(auto pt = group._data()->point_deserialize_uncompressed(bytes)) {
  ------------------
  |  Branch (200:12): [True: 6.25k, False: 41]
  ------------------
  201|  6.25k|      return EC_AffinePoint(std::move(pt));
  202|  6.25k|   } else {
  203|     41|      return {};
  204|     41|   }
  205|  6.29k|}
_ZNK5Botan14EC_AffinePoint6_groupEv:
  287|  6.25k|const std::shared_ptr<const EC_Group_Data>& EC_AffinePoint::_group() const {
  288|  6.25k|   return inner().group();
  289|  6.25k|}

_ZN5Botan8EC_Group13ec_group_dataEv:
  231|  6.29k|EC_Group_Data_Map& EC_Group::ec_group_data() {
  232|       |   /*
  233|       |   * This exists purely to ensure the allocator is constructed before g_ec_data,
  234|       |   * which ensures that its destructor runs after ~g_ec_data is complete.
  235|       |   */
  236|       |
  237|  6.29k|   static const Allocator_Initializer g_init_allocator;
  238|  6.29k|   static EC_Group_Data_Map g_ec_data;
  239|  6.29k|   return g_ec_data;
  240|  6.29k|}
_ZN5Botan8EC_Group18load_EC_group_infoEPKcS2_S2_S2_S2_S2_RKNS_3OIDE:
  254|      3|                                                            const OID& oid) {
  255|      3|   BOTAN_ARG_CHECK(oid.has_value(), "EC_Group::load_EC_group_info OID must be set");
  ------------------
  |  |   35|      3|   do {                                                          \
  |  |   36|      3|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|      3|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 3]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|      3|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 3]
  |  |  ------------------
  ------------------
  256|       |
  257|      3|   const BigInt p(p_str);
  258|      3|   const BigInt a(a_str);
  259|      3|   const BigInt b(b_str);
  260|      3|   const BigInt g_x(g_x_str);
  261|      3|   const BigInt g_y(g_y_str);
  262|      3|   const BigInt order(order_str);
  263|      3|   const BigInt cofactor(1);  // implicit
  264|       |
  265|      3|   return EC_Group_Data::create(p, a, b, g_x, g_y, order, cofactor, oid, EC_Group_Source::Builtin);
  266|      3|}
_ZN5Botan8EC_GroupD2Ev:
  412|  25.0k|EC_Group::~EC_Group() = default;
_ZN5Botan8EC_GroupC2ERKS0_:
  414|  12.5k|EC_Group::EC_Group(const EC_Group&) = default;
_ZN5Botan8EC_GroupC2EONSt3__110shared_ptrINS_13EC_Group_DataEEE:
  419|  6.29k|EC_Group::EC_Group(std::shared_ptr<EC_Group_Data>&& data) : m_data(std::move(data)) {}
_ZN5Botan8EC_Group20supports_named_groupENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  422|  6.29k|bool EC_Group::supports_named_group(std::string_view name) {
  423|  6.29k|   if(name.empty()) {
  ------------------
  |  Branch (423:7): [True: 0, False: 6.29k]
  ------------------
  424|      0|      return false;
  425|      0|   }
  426|       |
  427|       |   // Is it one of the groups compiled into the library?
  428|  6.29k|   if(EC_Group::known_named_groups().contains(std::string(name))) {
  ------------------
  |  Branch (428:7): [True: 6.29k, False: 0]
  ------------------
  429|  6.29k|      return true;
  430|  6.29k|   }
  431|       |
  432|       |   // Is it a custom group registered by the application?
  433|      0|   if(auto oid = OID::from_name(name)) {
  ------------------
  |  Branch (433:12): [True: 0, False: 0]
  ------------------
  434|      0|      try {
  435|      0|         if(ec_group_data().lookup(oid.value()) != nullptr) {
  ------------------
  |  Branch (435:13): [True: 0, False: 0]
  ------------------
  436|      0|            return true;
  437|      0|         }
  438|      0|      } catch(Not_Implemented&) {
  439|       |         // This would be thrown for example if the group is a known curve
  440|       |         // but the relevant module that enables it is not compiled in
  441|      0|      }
  442|      0|   }
  443|       |
  444|       |   // Not known
  445|      0|   return false;
  446|      0|}
_ZN5Botan8EC_Group9from_nameENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  478|  6.29k|EC_Group EC_Group::from_name(std::string_view name) {
  479|  6.29k|   std::shared_ptr<EC_Group_Data> data;
  480|       |
  481|  6.29k|   if(auto oid = OID::from_name(name)) {
  ------------------
  |  Branch (481:12): [True: 6.29k, False: 0]
  ------------------
  482|  6.29k|      data = ec_group_data().lookup(oid.value());
  483|  6.29k|   }
  484|       |
  485|  6.29k|   if(!data) {
  ------------------
  |  Branch (485:7): [True: 0, False: 6.29k]
  ------------------
  486|      0|      throw Invalid_Argument(fmt("Unknown EC_Group '{}'", name));
  487|      0|   }
  488|       |
  489|  6.29k|   return EC_Group(std::move(data));
  490|  6.29k|}
_ZNK5Botan8EC_Group4dataEv:
  647|  31.3k|const EC_Group_Data& EC_Group::data() const {
  648|  31.3k|   if(m_data == nullptr) {
  ------------------
  |  Branch (648:7): [True: 0, False: 31.3k]
  ------------------
  649|      0|      throw Invalid_State("EC_Group uninitialized");
  650|      0|   }
  651|  31.3k|   return *m_data;
  652|  31.3k|}
_ZNK5Botan8EC_Group11get_p_bytesEv:
  658|  6.29k|size_t EC_Group::get_p_bytes() const {
  659|  6.29k|   return data().p_bytes();
  660|  6.29k|}
_ZNK5Botan8EC_Group15get_order_bytesEv:
  666|  6.25k|size_t EC_Group::get_order_bytes() const {
  667|  6.25k|   return data().order_bytes();
  668|  6.25k|}
_ZNK5Botan8EC_Group5get_pEv:
  670|  12.5k|const BigInt& EC_Group::get_p() const {
  671|  12.5k|   return data().p();
  672|  12.5k|}
_ZNK5Botan8EC_Group13get_curve_oidEv:
  738|  6.25k|const OID& EC_Group::get_curve_oid() const {
  739|  6.25k|   return data().oid();
  740|  6.25k|}
_ZN5Botan8EC_Group9Mul2TableC2ERKNS_14EC_AffinePointE:
  911|  6.25k|EC_Group::Mul2Table::Mul2Table(const EC_AffinePoint& h) : m_tbl(h._group()->make_mul2_table(h._inner())) {}
_ZN5Botan8EC_Group9Mul2TableD2Ev:
  913|  6.25k|EC_Group::Mul2Table::~Mul2Table() = default;
_ZNK5Botan8EC_Group9Mul2Table27mul2_vartime_x_mod_order_eqERKNS_9EC_ScalarES4_S4_:
  926|  6.18k|                                                      const EC_Scalar& y) const {
  927|  6.18k|   return m_tbl->mul2_vartime_x_mod_order_eq(v._inner(), x._inner(), y._inner());
  928|  6.18k|}
_ZNK5Botan8EC_Group9Mul2Table27mul2_vartime_x_mod_order_eqERKNS_9EC_ScalarES4_S4_S4_:
  933|  6.18k|                                                      const EC_Scalar& y) const {
  934|  6.18k|   return this->mul2_vartime_x_mod_order_eq(v, c * x, c * y);
  935|  6.18k|}
_ZN5Botan17EC_Group_Data_Map6lookupERKNS_3OIDE:
   54|  6.29k|      std::shared_ptr<EC_Group_Data> lookup(const OID& oid) {
   55|  6.29k|         const lock_guard_type<mutex_type> lock(m_mutex);
   56|       |
   57|  7.59k|         for(auto i : m_registered_curves) {
  ------------------
  |  Branch (57:21): [True: 7.59k, False: 3]
  ------------------
   58|  7.59k|            if(i->oid() == oid) {
  ------------------
  |  Branch (58:16): [True: 6.28k, False: 1.30k]
  ------------------
   59|  6.28k|               return i;
   60|  6.28k|            }
   61|  7.59k|         }
   62|       |
   63|       |         // Not found, check hardcoded data
   64|      3|         std::shared_ptr<EC_Group_Data> data = EC_Group::EC_group_info(oid);
   65|       |
   66|      3|         if(data) {
  ------------------
  |  Branch (66:13): [True: 3, False: 0]
  ------------------
   67|       |            // The requested OID may be an alias for a curve whose canonical OID differs
   68|       |            // TODO(Botan4) remove this once we require exactly one canonical OID per curve
   69|      3|            if(data->oid() != oid) {
  ------------------
  |  Branch (69:16): [True: 0, False: 3]
  ------------------
   70|      0|               for(const auto& i : m_registered_curves) {
  ------------------
  |  Branch (70:34): [True: 0, False: 0]
  ------------------
   71|      0|                  if(i->oid() == data->oid()) {
  ------------------
  |  Branch (71:22): [True: 0, False: 0]
  ------------------
   72|      0|                     return i;
   73|      0|                  }
   74|      0|               }
   75|      0|            }
   76|       |
   77|      3|            m_registered_curves.push_back(data);
   78|      3|            return data;
   79|      3|         }
   80|       |
   81|       |         // Nope, unknown curve
   82|      0|         return std::shared_ptr<EC_Group_Data>();
   83|      3|      }

_ZN5Botan13EC_Group_DataD2Ev:
   28|      3|EC_Group_Data::~EC_Group_Data() = default;
_ZN5Botan13EC_Group_DataC2ERKNS_6BigIntES3_S3_S3_S3_S3_S3_RKNS_3OIDENS_15EC_Group_SourceE:
   40|      3|      m_p(p),
   41|      3|      m_a(a),
   42|      3|      m_b(b),
   43|      3|      m_g_x(g_x),
   44|      3|      m_g_y(g_y),
   45|      3|      m_order(order),
   46|      3|      m_cofactor(cofactor),
   47|       |#if defined(BOTAN_HAS_LEGACY_EC_POINT)
   48|      3|      m_mod_field(Barrett_Reduction::for_public_modulus(p)),
   49|      3|      m_mod_order(Barrett_Reduction::for_public_modulus(order)),
   50|      3|      m_monty(m_p, m_mod_field),
   51|       |#endif
   52|      3|      m_oid(oid),
   53|      3|      m_p_words(p.sig_words()),
   54|      3|      m_p_bits(p.bits()),
   55|      3|      m_order_bits(order.bits()),
   56|      3|      m_order_bytes((m_order_bits + 7) / 8),
   57|      3|      m_a_is_minus_3(a == p - 3),
   58|      3|      m_a_is_zero(a.is_zero()),
   59|      3|      m_has_cofactor(m_cofactor != 1),
   60|      3|      m_order_is_less_than_p(m_order < p),
   61|      3|      m_source(source) {
   62|       |   // Verify the generator (x, y) satisfies y^2 = x^3 + a*x + b (mod p)
   63|      3|   auto mod_p = Barrett_Reduction::for_public_modulus(p);
   64|      3|   const BigInt y2 = mod_p.square(g_y);
   65|      3|   const BigInt x3_ax_b = mod_p.reduce(mod_p.cube(g_x) + mod_p.multiply(a, g_x) + b);
   66|      3|   if(y2 != x3_ax_b) {
  ------------------
  |  Branch (66:7): [True: 0, False: 3]
  ------------------
   67|      0|      throw Invalid_Argument("EC_Group generator is not on the curve");
   68|      0|   }
   69|       |
   70|       |   // TODO(Botan4) we can assume/assert the OID is set
   71|      3|   if(!m_oid.empty()) {
  ------------------
  |  Branch (71:7): [True: 3, False: 0]
  ------------------
   72|      3|      DER_Encoder der(m_der_named_curve);
   73|      3|      der.encode(m_oid);
   74|       |
   75|      3|      if(const auto name = m_oid.registered_name()) {
  ------------------
  |  Branch (75:21): [True: 3, False: 0]
  ------------------
   76|       |         // returns nullptr if unknown or not supported
   77|      3|         m_pcurve = PCurve::PrimeOrderCurve::for_named_curve(*name);
   78|      3|      }
   79|      3|      if(m_pcurve) {
  ------------------
  |  Branch (79:10): [True: 3, False: 0]
  ------------------
   80|      3|         m_engine = EC_Group_Engine::Optimized;
   81|      3|      }
   82|      3|   }
   83|       |
   84|       |   // Try a generic pcurves instance
   85|      3|   if(!m_pcurve && !m_has_cofactor) {
  ------------------
  |  Branch (85:7): [True: 0, False: 3]
  |  Branch (85:20): [True: 0, False: 0]
  ------------------
   86|      0|      m_pcurve = PCurve::PrimeOrderCurve::from_params(p, a, b, g_x, g_y, order);
   87|      0|      if(m_pcurve) {
  ------------------
  |  Branch (87:10): [True: 0, False: 0]
  ------------------
   88|      0|         m_engine = EC_Group_Engine::Generic;
   89|      0|      }
   90|       |      // possibly still null here, if parameters unsuitable or if the
   91|       |      // pcurves_generic module wasn't included in the build
   92|      0|   }
   93|       |
   94|      3|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
   95|      3|   secure_vector<word> ws;
   96|      3|   m_a_r = m_monty.mul(a, m_monty.R2(), ws);
   97|      3|   m_b_r = m_monty.mul(b, m_monty.R2(), ws);
   98|      3|   if(!m_pcurve) {
  ------------------
  |  Branch (98:7): [True: 0, False: 3]
  ------------------
   99|      0|      m_engine = EC_Group_Engine::Legacy;
  100|      0|   }
  101|       |#else
  102|       |   if(!m_pcurve) {
  103|       |      if(m_oid.empty()) {
  104|       |         throw Not_Implemented("EC_Group this group is not supported in this build configuration");
  105|       |      } else {
  106|       |         throw Not_Implemented(
  107|       |            fmt("EC_Group the group {} is not supported in this build configuration", oid.to_string()));
  108|       |      }
  109|       |   }
  110|       |#endif
  111|      3|}
_ZN5Botan13EC_Group_Data6createERKNS_6BigIntES3_S3_S3_S3_S3_S3_RKNS_3OIDENS_15EC_Group_SourceE:
  121|      3|                                                     EC_Group_Source source) {
  122|      3|   auto group = std::make_shared<EC_Group_Data>(p, a, b, g_x, g_y, order, cofactor, oid, source);
  123|       |
  124|      3|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  125|      3|   group->m_curve = CurveGFp(group.get());
  126|      3|   group->m_base_point = EC_Point(group->m_curve, g_x, g_y);
  127|      3|   if(!group->m_pcurve) {
  ------------------
  |  Branch (127:7): [True: 0, False: 3]
  ------------------
  128|      0|      group->m_base_mult = std::make_unique<EC_Point_Base_Point_Precompute>(group->m_base_point, group->m_mod_order);
  129|      0|   }
  130|      3|#endif
  131|       |
  132|      3|   return group;
  133|      3|}
_ZNK5Botan13EC_Group_Data28scalar_from_bytes_with_truncENSt3__14spanIKhLm18446744073709551615EEE:
  243|  6.18k|std::unique_ptr<EC_Scalar_Data> EC_Group_Data::scalar_from_bytes_with_trunc(std::span<const uint8_t> bytes) const {
  244|  6.18k|   const size_t bit_length = 8 * bytes.size();
  245|       |
  246|  6.18k|   if(bit_length < order_bits()) {
  ------------------
  |  Branch (246:7): [True: 376, False: 5.80k]
  ------------------
  247|       |      // No shifting required, but might still need to reduce by modulus
  248|    376|      return this->scalar_from_bytes_mod_order(bytes);
  249|  5.80k|   } else {
  250|  5.80k|      const size_t shift = bit_length - order_bits();
  251|       |
  252|  5.80k|      const size_t new_length = bytes.size() - (shift / 8);
  253|  5.80k|      const size_t bit_shift = shift % 8;
  254|       |
  255|  5.80k|      if(bit_shift == 0) {
  ------------------
  |  Branch (255:10): [True: 5.80k, False: 0]
  ------------------
  256|       |         // Easy case just read different bytes
  257|  5.80k|         return this->scalar_from_bytes_mod_order(bytes.first(new_length));
  258|  5.80k|      } else {
  259|      0|         std::vector<uint8_t> sbytes(new_length);
  260|       |
  261|      0|         uint8_t carry = 0;
  262|      0|         for(size_t i = 0; i != new_length; ++i) {
  ------------------
  |  Branch (262:28): [True: 0, False: 0]
  ------------------
  263|      0|            const uint8_t w = bytes[i];
  264|      0|            sbytes[i] = (w >> bit_shift) | carry;
  265|      0|            carry = w << (8 - bit_shift);
  266|      0|         }
  267|       |
  268|      0|         return this->scalar_from_bytes_mod_order(sbytes);
  269|      0|      }
  270|  5.80k|   }
  271|  6.18k|}
_ZNK5Botan13EC_Group_Data27scalar_from_bytes_mod_orderENSt3__14spanIKhLm18446744073709551615EEE:
  273|  6.18k|std::unique_ptr<EC_Scalar_Data> EC_Group_Data::scalar_from_bytes_mod_order(std::span<const uint8_t> bytes) const {
  274|  6.18k|   if(bytes.size() > 2 * order_bytes()) {
  ------------------
  |  Branch (274:7): [True: 0, False: 6.18k]
  ------------------
  275|      0|      return {};
  276|      0|   }
  277|       |
  278|  6.18k|   if(m_pcurve) {
  ------------------
  |  Branch (278:7): [True: 6.18k, False: 0]
  ------------------
  279|  6.18k|      if(auto s = m_pcurve->scalar_from_wide_bytes(bytes)) {
  ------------------
  |  Branch (279:15): [True: 6.18k, False: 0]
  ------------------
  280|  6.18k|         return std::make_unique<EC_Scalar_Data_PC>(shared_from_this(), std::move(*s));
  281|  6.18k|      } else {
  282|      0|         return {};
  283|      0|      }
  284|  6.18k|   } else {
  285|      0|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  286|      0|      return std::make_unique<EC_Scalar_Data_BN>(shared_from_this(), m_mod_order.reduce(BigInt(bytes)));
  287|       |#else
  288|       |      throw Not_Implemented("Legacy EC interfaces disabled in this build configuration");
  289|       |#endif
  290|      0|   }
  291|  6.18k|}
_ZNK5Botan13EC_Group_Data18scalar_deserializeENSt3__14spanIKhLm18446744073709551615EEE:
  358|  12.5k|std::unique_ptr<EC_Scalar_Data> EC_Group_Data::scalar_deserialize(std::span<const uint8_t> bytes) const {
  359|  12.5k|   if(bytes.size() != m_order_bytes) {
  ------------------
  |  Branch (359:7): [True: 0, False: 12.5k]
  ------------------
  360|      0|      return nullptr;
  361|      0|   }
  362|       |
  363|  12.5k|   if(m_pcurve) {
  ------------------
  |  Branch (363:7): [True: 12.5k, False: 0]
  ------------------
  364|  12.5k|      if(auto s = m_pcurve->deserialize_scalar(bytes)) {
  ------------------
  |  Branch (364:15): [True: 12.4k, False: 73]
  ------------------
  365|  12.4k|         return std::make_unique<EC_Scalar_Data_PC>(shared_from_this(), *s);
  366|  12.4k|      } else {
  367|     73|         return nullptr;
  368|     73|      }
  369|  12.5k|   } else {
  370|      0|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  371|      0|      BigInt r(bytes);
  372|       |
  373|      0|      if(r.is_zero() || r >= m_order) {
  ------------------
  |  Branch (373:10): [True: 0, False: 0]
  |  Branch (373:25): [True: 0, False: 0]
  ------------------
  374|      0|         return nullptr;
  375|      0|      }
  376|       |
  377|      0|      return std::make_unique<EC_Scalar_Data_BN>(shared_from_this(), std::move(r));
  378|       |#else
  379|       |      throw Not_Implemented("Legacy EC interfaces disabled in this build configuration");
  380|       |#endif
  381|      0|   }
  382|  12.5k|}
_ZNK5Botan13EC_Group_Data30point_deserialize_uncompressedENSt3__14spanIKhLm18446744073709551615EEE:
  385|  6.29k|   std::span<const uint8_t> bytes) const {
  386|  6.29k|   if(bytes.size() != 1 + 2 * p_bytes() || bytes[0] != 0x04) {
  ------------------
  |  Branch (386:7): [True: 0, False: 6.29k]
  |  Branch (386:44): [True: 0, False: 6.29k]
  ------------------
  387|      0|      return {};
  388|      0|   }
  389|       |
  390|  6.29k|   if(m_pcurve) {
  ------------------
  |  Branch (390:7): [True: 6.29k, False: 0]
  ------------------
  391|  6.29k|      if(auto pt = m_pcurve->deserialize_point_uncompressed(bytes)) {
  ------------------
  |  Branch (391:15): [True: 6.25k, False: 41]
  ------------------
  392|  6.25k|         return std::make_unique<EC_AffinePoint_Data_PC>(shared_from_this(), std::move(*pt));
  393|  6.25k|      } else {
  394|     41|         return {};
  395|     41|      }
  396|  6.29k|   } else {
  397|      0|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  398|      0|      try {
  399|      0|         auto pt = Botan::OS2ECP(bytes, m_curve);
  400|      0|         return std::make_unique<EC_AffinePoint_Data_BN>(shared_from_this(), std::move(pt));
  401|      0|      } catch(...) {
  402|      0|         return {};
  403|      0|      }
  404|       |#else
  405|       |      throw Not_Implemented("Legacy EC interfaces disabled in this build configuration");
  406|       |#endif
  407|      0|   }
  408|  6.29k|}
_ZNK5Botan13EC_Group_Data15make_mul2_tableERKNS_19EC_AffinePoint_DataE:
  636|  6.25k|std::unique_ptr<EC_Mul2Table_Data> EC_Group_Data::make_mul2_table(const EC_AffinePoint_Data& h) const {
  637|  6.25k|   if(m_pcurve) {
  ------------------
  |  Branch (637:7): [True: 6.25k, False: 0]
  ------------------
  638|  6.25k|      return std::make_unique<EC_Mul2Table_Data_PC>(h);
  639|  6.25k|   } else {
  640|      0|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  641|      0|      const EC_AffinePoint_Data_BN g(shared_from_this(), this->base_point());
  642|      0|      return std::make_unique<EC_Mul2Table_Data_BN>(g, h);
  643|       |#else
  644|       |      throw Not_Implemented("Legacy EC interfaces disabled in this build configuration");
  645|       |#endif
  646|      0|   }
  647|  6.25k|}

_ZN5Botan17EC_Scalar_Data_PC11checked_refERKNS_14EC_Scalar_DataE:
   14|  30.9k|const EC_Scalar_Data_PC& EC_Scalar_Data_PC::checked_ref(const EC_Scalar_Data& data) {
   15|  30.9k|   const auto* p = dynamic_cast<const EC_Scalar_Data_PC*>(&data);
   16|  30.9k|   if(p == nullptr) {
  ------------------
  |  Branch (16:7): [True: 0, False: 30.9k]
  ------------------
   17|      0|      throw Invalid_State("Failed conversion to EC_Scalar_Data_PC");
   18|      0|   }
   19|  30.9k|   return *p;
   20|  30.9k|}
_ZNK5Botan17EC_Scalar_Data_PC5groupEv:
   22|  74.1k|const std::shared_ptr<const EC_Group_Data>& EC_Scalar_Data_PC::group() const {
   23|  74.1k|   return m_group;
   24|  74.1k|}
_ZNK5Botan17EC_Scalar_Data_PC5cloneEv:
   30|  12.3k|std::unique_ptr<EC_Scalar_Data> EC_Scalar_Data_PC::clone() const {
   31|  12.3k|   return std::make_unique<EC_Scalar_Data_PC>(this->group(), this->value());
   32|  12.3k|}
_ZNK5Botan17EC_Scalar_Data_PC7is_zeroEv:
   34|  12.3k|bool EC_Scalar_Data_PC::is_zero() const {
   35|  12.3k|   const auto& pcurve = this->group()->pcurve();
   36|  12.3k|   return pcurve.scalar_is_zero(m_v);
   37|  12.3k|}
_ZNK5Botan17EC_Scalar_Data_PC14invert_vartimeEv:
   66|  6.18k|std::unique_ptr<EC_Scalar_Data> EC_Scalar_Data_PC::invert_vartime() const {
   67|  6.18k|   return std::make_unique<EC_Scalar_Data_PC>(m_group, m_group->pcurve().scalar_invert_vartime(m_v));
   68|  6.18k|}
_ZNK5Botan17EC_Scalar_Data_PC3mulERKNS_14EC_Scalar_DataE:
   78|  12.3k|std::unique_ptr<EC_Scalar_Data> EC_Scalar_Data_PC::mul(const EC_Scalar_Data& other) const {
   79|  12.3k|   return std::make_unique<EC_Scalar_Data_PC>(m_group, group()->pcurve().scalar_mul(m_v, checked_ref(other).m_v));
   80|  12.3k|}
_ZN5Botan22EC_AffinePoint_Data_PCC2ENSt3__110shared_ptrIKNS_13EC_Group_DataEEENS_6PCurve15PrimeOrderCurve11AffinePointE:
   89|  12.5k|      m_group(std::move(group)), m_pt(std::move(pt)) {
   90|  12.5k|   const auto& pcurve = m_group->pcurve();
   91|       |
   92|  12.5k|   if(!pcurve.affine_point_is_identity(m_pt)) {
  ------------------
  |  Branch (92:7): [True: 12.5k, False: 0]
  ------------------
   93|  12.5k|      m_xy.resize(1 + 2 * field_element_bytes());
   94|  12.5k|      pcurve.serialize_point(m_xy, m_pt);
   95|  12.5k|   }
   96|  12.5k|}
_ZN5Botan22EC_AffinePoint_Data_PC11checked_refERKNS_19EC_AffinePoint_DataE:
   98|  6.25k|const EC_AffinePoint_Data_PC& EC_AffinePoint_Data_PC::checked_ref(const EC_AffinePoint_Data& data) {
   99|  6.25k|   const auto* p = dynamic_cast<const EC_AffinePoint_Data_PC*>(&data);
  100|  6.25k|   if(p == nullptr) {
  ------------------
  |  Branch (100:7): [True: 0, False: 6.25k]
  ------------------
  101|      0|      throw Invalid_State("Failed conversion to EC_AffinePoint_Data_PC");
  102|      0|   }
  103|  6.25k|   return *p;
  104|  6.25k|}
_ZNK5Botan22EC_AffinePoint_Data_PC5cloneEv:
  106|  6.25k|std::unique_ptr<EC_AffinePoint_Data> EC_AffinePoint_Data_PC::clone() const {
  107|  6.25k|   return std::make_unique<EC_AffinePoint_Data_PC>(m_group, m_pt);
  108|  6.25k|}
_ZNK5Botan22EC_AffinePoint_Data_PC5groupEv:
  110|  18.7k|const std::shared_ptr<const EC_Group_Data>& EC_AffinePoint_Data_PC::group() const {
  111|  18.7k|   return m_group;
  112|  18.7k|}
_ZNK5Botan22EC_AffinePoint_Data_PC19field_element_bytesEv:
  130|  18.7k|size_t EC_AffinePoint_Data_PC::field_element_bytes() const {
  131|  18.7k|   return m_group->pcurve().field_element_bytes();
  132|  18.7k|}
_ZNK5Botan22EC_AffinePoint_Data_PC11is_identityEv:
  134|  12.5k|bool EC_AffinePoint_Data_PC::is_identity() const {
  135|  12.5k|   return m_xy.empty();
  136|  12.5k|}
_ZNK5Botan22EC_AffinePoint_Data_PC15to_legacy_pointEv:
  178|  6.25k|EC_Point EC_AffinePoint_Data_PC::to_legacy_point() const {
  179|  6.25k|   if(this->is_identity()) {
  ------------------
  |  Branch (179:7): [True: 0, False: 6.25k]
  ------------------
  180|      0|      return EC_Point(m_group->curve());
  181|  6.25k|   } else {
  182|  6.25k|      const size_t fe_bytes = this->field_element_bytes();
  183|  6.25k|      return EC_Point(m_group->curve(),
  184|  6.25k|                      BigInt::from_bytes(std::span{m_xy}.subspan(1, fe_bytes)),
  185|  6.25k|                      BigInt::from_bytes(std::span{m_xy}.last(fe_bytes)));
  186|  6.25k|   }
  187|  6.25k|}
_ZN5Botan20EC_Mul2Table_Data_PCC2ERKNS_19EC_AffinePoint_DataE:
  190|  6.25k|EC_Mul2Table_Data_PC::EC_Mul2Table_Data_PC(const EC_AffinePoint_Data& q) : m_group(q.group()) {
  191|  6.25k|   BOTAN_ARG_CHECK(q.group() == m_group, "Curve mismatch");
  ------------------
  |  |   35|  6.25k|   do {                                                          \
  |  |   36|  6.25k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.25k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.25k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.25k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.25k]
  |  |  ------------------
  ------------------
  192|       |
  193|  6.25k|   const auto& pt_q = EC_AffinePoint_Data_PC::checked_ref(q);
  194|       |
  195|  6.25k|   m_tbl = m_group->pcurve().mul2_setup_g(pt_q.value());
  196|  6.25k|}
_ZNK5Botan20EC_Mul2Table_Data_PC27mul2_vartime_x_mod_order_eqERKNS_14EC_Scalar_DataES3_S3_:
  216|  6.18k|                                                       const EC_Scalar_Data& yd) const {
  217|  6.18k|   BOTAN_ARG_CHECK(xd.group() == m_group && yd.group() == m_group, "Curve mismatch");
  ------------------
  |  |   35|  6.18k|   do {                                                          \
  |  |   36|  6.18k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  12.3k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 6.18k, False: 0]
  |  |  |  Branch (37:12): [True: 6.18k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.18k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.18k]
  |  |  ------------------
  ------------------
  218|       |
  219|  6.18k|   const auto& v = EC_Scalar_Data_PC::checked_ref(vd);
  220|  6.18k|   const auto& x = EC_Scalar_Data_PC::checked_ref(xd);
  221|  6.18k|   const auto& y = EC_Scalar_Data_PC::checked_ref(yd);
  222|       |
  223|  6.18k|   return m_group->pcurve().mul2_vartime_x_mod_order_eq(*m_tbl, v.value(), x.value(), y.value());
  224|  6.18k|}

_ZN5Botan8EC_Group13EC_group_infoERKNS_3OIDE:
   16|      3|std::shared_ptr<EC_Group_Data> EC_Group::EC_group_info(const OID& oid) {
   17|       |   // secp256r1
   18|      3|   if(oid == OID{1, 2, 840, 10045, 3, 1, 7}) {
  ------------------
  |  Branch (18:7): [True: 1, False: 2]
  ------------------
   19|      1|      return load_EC_group_info(
   20|      1|         "0xFFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFF",
   21|      1|         "0xFFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFC",
   22|      1|         "0x5AC635D8AA3A93E7B3EBBD55769886BC651D06B0CC53B0F63BCE3C3E27D2604B",
   23|      1|         "0x6B17D1F2E12C4247F8BCE6E563A440F277037D812DEB33A0F4A13945D898C296",
   24|      1|         "0x4FE342E2FE1A7F9B8EE7EB4A7C0F9E162BCE33576B315ECECBB6406837BF51F5",
   25|      1|         "0xFFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551",
   26|      1|         oid);
   27|      1|   }
   28|       |
   29|       |   // secp384r1
   30|      2|   if(oid == OID{1, 3, 132, 0, 34}) {
  ------------------
  |  Branch (30:7): [True: 0, False: 2]
  ------------------
   31|      0|      return load_EC_group_info(
   32|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFF",
   33|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFC",
   34|      0|         "0xB3312FA7E23EE7E4988E056BE3F82D19181D9C6EFE8141120314088F5013875AC656398D8A2ED19D2A85C8EDD3EC2AEF",
   35|      0|         "0xAA87CA22BE8B05378EB1C71EF320AD746E1D3B628BA79B9859F741E082542A385502F25DBF55296C3A545E3872760AB7",
   36|      0|         "0x3617DE4A96262C6F5D9E98BF9292DC29F8F41DBD289A147CE9DA3113B5F0B8C00A60B1CE1D7E819D7A431D7C90EA0E5F",
   37|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC7634D81F4372DDF581A0DB248B0A77AECEC196ACCC52973",
   38|      0|         oid);
   39|      0|   }
   40|       |
   41|       |   // secp521r1
   42|      2|   if(oid == OID{1, 3, 132, 0, 35}) {
  ------------------
  |  Branch (42:7): [True: 0, False: 2]
  ------------------
   43|      0|      return load_EC_group_info(
   44|      0|         "0x1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF",
   45|      0|         "0x1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC",
   46|      0|         "0x51953EB9618E1C9A1F929A21A0B68540EEA2DA725B99B315F3B8B489918EF109E156193951EC7E937B1652C0BD3BB1BF073573DF883D2C34F1EF451FD46B503F00",
   47|      0|         "0xC6858E06B70404E9CD9E3ECB662395B4429C648139053FB521F828AF606B4D3DBAA14B5E77EFE75928FE1DC127A2FFA8DE3348B3C1856A429BF97E7E31C2E5BD66",
   48|      0|         "0x11839296A789A3BC0045C8A5FB42C7D1BD998F54449579B446817AFBD17273E662C97EE72995EF42640C550B9013FAD0761353C7086A272C24088BE94769FD16650",
   49|      0|         "0x1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFA51868783BF2F966B7FCC0148F709A5D03BB5C9B8899C47AEBB6FB71E91386409",
   50|      0|         oid);
   51|      0|   }
   52|       |
   53|       |   // brainpool160r1
   54|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 1}) {
  ------------------
  |  Branch (54:7): [True: 0, False: 2]
  ------------------
   55|      0|      return load_EC_group_info(
   56|      0|         "0xE95E4A5F737059DC60DFC7AD95B3D8139515620F",
   57|      0|         "0x340E7BE2A280EB74E2BE61BADA745D97E8F7C300",
   58|      0|         "0x1E589A8595423412134FAA2DBDEC95C8D8675E58",
   59|      0|         "0xBED5AF16EA3F6A4F62938C4631EB5AF7BDBCDBC3",
   60|      0|         "0x1667CB477A1A8EC338F94741669C976316DA6321",
   61|      0|         "0xE95E4A5F737059DC60DF5991D45029409E60FC09",
   62|      0|         oid);
   63|      0|   }
   64|       |
   65|       |   // brainpool192r1
   66|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 3}) {
  ------------------
  |  Branch (66:7): [True: 0, False: 2]
  ------------------
   67|      0|      return load_EC_group_info(
   68|      0|         "0xC302F41D932A36CDA7A3463093D18DB78FCE476DE1A86297",
   69|      0|         "0x6A91174076B1E0E19C39C031FE8685C1CAE040E5C69A28EF",
   70|      0|         "0x469A28EF7C28CCA3DC721D044F4496BCCA7EF4146FBF25C9",
   71|      0|         "0xC0A0647EAAB6A48753B033C56CB0F0900A2F5C4853375FD6",
   72|      0|         "0x14B690866ABD5BB88B5F4828C1490002E6773FA2FA299B8F",
   73|      0|         "0xC302F41D932A36CDA7A3462F9E9E916B5BE8F1029AC4ACC1",
   74|      0|         oid);
   75|      0|   }
   76|       |
   77|       |   // brainpool224r1
   78|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 5}) {
  ------------------
  |  Branch (78:7): [True: 0, False: 2]
  ------------------
   79|      0|      return load_EC_group_info(
   80|      0|         "0xD7C134AA264366862A18302575D1D787B09F075797DA89F57EC8C0FF",
   81|      0|         "0x68A5E62CA9CE6C1C299803A6C1530B514E182AD8B0042A59CAD29F43",
   82|      0|         "0x2580F63CCFE44138870713B1A92369E33E2135D266DBB372386C400B",
   83|      0|         "0xD9029AD2C7E5CF4340823B2A87DC68C9E4CE3174C1E6EFDEE12C07D",
   84|      0|         "0x58AA56F772C0726F24C6B89E4ECDAC24354B9E99CAA3F6D3761402CD",
   85|      0|         "0xD7C134AA264366862A18302575D0FB98D116BC4B6DDEBCA3A5A7939F",
   86|      0|         oid);
   87|      0|   }
   88|       |
   89|       |   // brainpool256r1
   90|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 7}) {
  ------------------
  |  Branch (90:7): [True: 0, False: 2]
  ------------------
   91|      0|      return load_EC_group_info(
   92|      0|         "0xA9FB57DBA1EEA9BC3E660A909D838D726E3BF623D52620282013481D1F6E5377",
   93|      0|         "0x7D5A0975FC2C3057EEF67530417AFFE7FB8055C126DC5C6CE94A4B44F330B5D9",
   94|      0|         "0x26DC5C6CE94A4B44F330B5D9BBD77CBF958416295CF7E1CE6BCCDC18FF8C07B6",
   95|      0|         "0x8BD2AEB9CB7E57CB2C4B482FFC81B7AFB9DE27E1E3BD23C23A4453BD9ACE3262",
   96|      0|         "0x547EF835C3DAC4FD97F8461A14611DC9C27745132DED8E545C1D54C72F046997",
   97|      0|         "0xA9FB57DBA1EEA9BC3E660A909D838D718C397AA3B561A6F7901E0E82974856A7",
   98|      0|         oid);
   99|      0|   }
  100|       |
  101|       |   // brainpool320r1
  102|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 9}) {
  ------------------
  |  Branch (102:7): [True: 0, False: 2]
  ------------------
  103|      0|      return load_EC_group_info(
  104|      0|         "0xD35E472036BC4FB7E13C785ED201E065F98FCFA6F6F40DEF4F92B9EC7893EC28FCD412B1F1B32E27",
  105|      0|         "0x3EE30B568FBAB0F883CCEBD46D3F3BB8A2A73513F5EB79DA66190EB085FFA9F492F375A97D860EB4",
  106|      0|         "0x520883949DFDBC42D3AD198640688A6FE13F41349554B49ACC31DCCD884539816F5EB4AC8FB1F1A6",
  107|      0|         "0x43BD7E9AFB53D8B85289BCC48EE5BFE6F20137D10A087EB6E7871E2A10A599C710AF8D0D39E20611",
  108|      0|         "0x14FDD05545EC1CC8AB4093247F77275E0743FFED117182EAA9C77877AAAC6AC7D35245D1692E8EE1",
  109|      0|         "0xD35E472036BC4FB7E13C785ED201E065F98FCFA5B68F12A32D482EC7EE8658E98691555B44C59311",
  110|      0|         oid);
  111|      0|   }
  112|       |
  113|       |   // brainpool384r1
  114|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 11}) {
  ------------------
  |  Branch (114:7): [True: 0, False: 2]
  ------------------
  115|      0|      return load_EC_group_info(
  116|      0|         "0x8CB91E82A3386D280F5D6F7E50E641DF152F7109ED5456B412B1DA197FB71123ACD3A729901D1A71874700133107EC53",
  117|      0|         "0x7BC382C63D8C150C3C72080ACE05AFA0C2BEA28E4FB22787139165EFBA91F90F8AA5814A503AD4EB04A8C7DD22CE2826",
  118|      0|         "0x4A8C7DD22CE28268B39B55416F0447C2FB77DE107DCD2A62E880EA53EEB62D57CB4390295DBC9943AB78696FA504C11",
  119|      0|         "0x1D1C64F068CF45FFA2A63A81B7C13F6B8847A3E77EF14FE3DB7FCAFE0CBD10E8E826E03436D646AAEF87B2E247D4AF1E",
  120|      0|         "0x8ABE1D7520F9C2A45CB1EB8E95CFD55262B70B29FEEC5864E19C054FF99129280E4646217791811142820341263C5315",
  121|      0|         "0x8CB91E82A3386D280F5D6F7E50E641DF152F7109ED5456B31F166E6CAC0425A7CF3AB6AF6B7FC3103B883202E9046565",
  122|      0|         oid);
  123|      0|   }
  124|       |
  125|       |   // brainpool512r1
  126|      2|   if(oid == OID{1, 3, 36, 3, 3, 2, 8, 1, 1, 13}) {
  ------------------
  |  Branch (126:7): [True: 0, False: 2]
  ------------------
  127|      0|      return load_EC_group_info(
  128|      0|         "0xAADD9DB8DBE9C48B3FD4E6AE33C9FC07CB308DB3B3C9D20ED6639CCA703308717D4D9B009BC66842AECDA12AE6A380E62881FF2F2D82C68528AA6056583A48F3",
  129|      0|         "0x7830A3318B603B89E2327145AC234CC594CBDD8D3DF91610A83441CAEA9863BC2DED5D5AA8253AA10A2EF1C98B9AC8B57F1117A72BF2C7B9E7C1AC4D77FC94CA",
  130|      0|         "0x3DF91610A83441CAEA9863BC2DED5D5AA8253AA10A2EF1C98B9AC8B57F1117A72BF2C7B9E7C1AC4D77FC94CADC083E67984050B75EBAE5DD2809BD638016F723",
  131|      0|         "0x81AEE4BDD82ED9645A21322E9C4C6A9385ED9F70B5D916C1B43B62EEF4D0098EFF3B1F78E2D0D48D50D1687B93B97D5F7C6D5047406A5E688B352209BCB9F822",
  132|      0|         "0x7DDE385D566332ECC0EABFA9CF7822FDF209F70024A57B1AA000C55B881F8111B2DCDE494A5F485E5BCA4BD88A2763AED1CA2B2FA8F0540678CD1E0F3AD80892",
  133|      0|         "0xAADD9DB8DBE9C48B3FD4E6AE33C9FC07CB308DB3B3C9D20ED6639CCA70330870553E5C414CA92619418661197FAC10471DB1D381085DDADDB58796829CA90069",
  134|      0|         oid);
  135|      0|   }
  136|       |
  137|       |   // frp256v1
  138|      2|   if(oid == OID{1, 2, 250, 1, 223, 101, 256, 1}) {
  ------------------
  |  Branch (138:7): [True: 0, False: 2]
  ------------------
  139|      0|      return load_EC_group_info(
  140|      0|         "0xF1FD178C0B3AD58F10126DE8CE42435B3961ADBCABC8CA6DE8FCF353D86E9C03",
  141|      0|         "0xF1FD178C0B3AD58F10126DE8CE42435B3961ADBCABC8CA6DE8FCF353D86E9C00",
  142|      0|         "0xEE353FCA5428A9300D4ABA754A44C00FDFEC0C9AE4B1A1803075ED967B7BB73F",
  143|      0|         "0xB6B3D4C356C139EB31183D4749D423958C27D2DCAF98B70164C97A2DD98F5CFF",
  144|      0|         "0x6142E0F7C8B204911F9271F0F3ECEF8C2701C307E8E4C9E183115A1554062CFB",
  145|      0|         "0xF1FD178C0B3AD58F10126DE8CE42435B53DC67E140D2BF941FFDD459C6D655E1",
  146|      0|         oid);
  147|      0|   }
  148|       |
  149|       |   // gost_256A
  150|      2|   if(oid == OID{1, 2, 643, 7, 1, 2, 1, 1, 1} || oid == OID{1, 2, 643, 2, 2, 35, 1} || oid == OID{1, 2, 643, 2, 2, 36, 0}) {
  ------------------
  |  Branch (150:7): [True: 0, False: 2]
  |  Branch (150:7): [True: 0, False: 2]
  |  Branch (150:50): [True: 0, False: 2]
  |  Branch (150:88): [True: 0, False: 2]
  ------------------
  151|      0|      return load_EC_group_info(
  152|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFD97",
  153|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFD94",
  154|      0|         "0xA6",
  155|      0|         "0x1",
  156|      0|         "0x8D91E471E0989CDA27DF505A453F2B7635294F2DDF23E3B122ACC99C9E9F1E14",
  157|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF6C611070995AD10045841B09B761B893",
  158|      0|         OID{1, 2, 643, 7, 1, 2, 1, 1, 1});
  159|      0|   }
  160|       |
  161|       |   // gost_512A
  162|      2|   if(oid == OID{1, 2, 643, 7, 1, 2, 1, 2, 1}) {
  ------------------
  |  Branch (162:7): [True: 0, False: 2]
  ------------------
  163|      0|      return load_EC_group_info(
  164|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFDC7",
  165|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFDC4",
  166|      0|         "0xE8C2505DEDFC86DDC1BD0B2B6667F1DA34B82574761CB0E879BD081CFD0B6265EE3CB090F30D27614CB4574010DA90DD862EF9D4EBEE4761503190785A71C760",
  167|      0|         "0x3",
  168|      0|         "0x7503CFE87A836AE3A61B8816E25450E6CE5E1C93ACF1ABC1778064FDCBEFA921DF1626BE4FD036E93D75E6A50E3A41E98028FE5FC235F5B889A589CB5215F2A4",
  169|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF27E69532F48D89116FF22B8D4E0560609B4B38ABFAD2B85DCACDB1411F10B275",
  170|      0|         oid);
  171|      0|   }
  172|       |
  173|       |   // secp160k1
  174|      2|   if(oid == OID{1, 3, 132, 0, 9}) {
  ------------------
  |  Branch (174:7): [True: 0, False: 2]
  ------------------
  175|      0|      return load_EC_group_info(
  176|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73",
  177|      0|         "0x0",
  178|      0|         "0x7",
  179|      0|         "0x3B4C382CE37AA192A4019E763036F4F5DD4D7EBB",
  180|      0|         "0x938CF935318FDCED6BC28286531733C3F03C4FEE",
  181|      0|         "0x100000000000000000001B8FA16DFAB9ACA16B6B3",
  182|      0|         oid);
  183|      0|   }
  184|       |
  185|       |   // secp160r1
  186|      2|   if(oid == OID{1, 3, 132, 0, 8}) {
  ------------------
  |  Branch (186:7): [True: 0, False: 2]
  ------------------
  187|      0|      return load_EC_group_info(
  188|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF",
  189|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC",
  190|      0|         "0x1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45",
  191|      0|         "0x4A96B5688EF573284664698968C38BB913CBFC82",
  192|      0|         "0x23A628553168947D59DCC912042351377AC5FB32",
  193|      0|         "0x100000000000000000001F4C8F927AED3CA752257",
  194|      0|         oid);
  195|      0|   }
  196|       |
  197|       |   // secp160r2
  198|      2|   if(oid == OID{1, 3, 132, 0, 30}) {
  ------------------
  |  Branch (198:7): [True: 0, False: 2]
  ------------------
  199|      0|      return load_EC_group_info(
  200|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73",
  201|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC70",
  202|      0|         "0xB4E134D3FB59EB8BAB57274904664D5AF50388BA",
  203|      0|         "0x52DCB034293A117E1F4FF11B30F7199D3144CE6D",
  204|      0|         "0xFEAFFEF2E331F296E071FA0DF9982CFEA7D43F2E",
  205|      0|         "0x100000000000000000000351EE786A818F3A1A16B",
  206|      0|         oid);
  207|      0|   }
  208|       |
  209|       |   // secp192k1
  210|      2|   if(oid == OID{1, 3, 132, 0, 31}) {
  ------------------
  |  Branch (210:7): [True: 0, False: 2]
  ------------------
  211|      0|      return load_EC_group_info(
  212|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37",
  213|      0|         "0x0",
  214|      0|         "0x3",
  215|      0|         "0xDB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D",
  216|      0|         "0x9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D",
  217|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D",
  218|      0|         oid);
  219|      0|   }
  220|       |
  221|       |   // secp192r1
  222|      2|   if(oid == OID{1, 2, 840, 10045, 3, 1, 1}) {
  ------------------
  |  Branch (222:7): [True: 0, False: 2]
  ------------------
  223|      0|      return load_EC_group_info(
  224|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF",
  225|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC",
  226|      0|         "0x64210519E59C80E70FA7E9AB72243049FEB8DEECC146B9B1",
  227|      0|         "0x188DA80EB03090F67CBF20EB43A18800F4FF0AFD82FF1012",
  228|      0|         "0x7192B95FFC8DA78631011ED6B24CDD573F977A11E794811",
  229|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFF99DEF836146BC9B1B4D22831",
  230|      0|         oid);
  231|      0|   }
  232|       |
  233|       |   // secp224k1
  234|      2|   if(oid == OID{1, 3, 132, 0, 32}) {
  ------------------
  |  Branch (234:7): [True: 0, False: 2]
  ------------------
  235|      0|      return load_EC_group_info(
  236|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFE56D",
  237|      0|         "0x0",
  238|      0|         "0x5",
  239|      0|         "0xA1455B334DF099DF30FC28A169A467E9E47075A90F7E650EB6B7A45C",
  240|      0|         "0x7E089FED7FBA344282CAFBD6F7E319F7C0B0BD59E2CA4BDB556D61A5",
  241|      0|         "0x10000000000000000000000000001DCE8D2EC6184CAF0A971769FB1F7",
  242|      0|         oid);
  243|      0|   }
  244|       |
  245|       |   // secp224r1
  246|      2|   if(oid == OID{1, 3, 132, 0, 33}) {
  ------------------
  |  Branch (246:7): [True: 0, False: 2]
  ------------------
  247|      0|      return load_EC_group_info(
  248|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF000000000000000000000001",
  249|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFE",
  250|      0|         "0xB4050A850C04B3ABF54132565044B0B7D7BFD8BA270B39432355FFB4",
  251|      0|         "0xB70E0CBD6BB4BF7F321390B94A03C1D356C21122343280D6115C1D21",
  252|      0|         "0xBD376388B5F723FB4C22DFE6CD4375A05A07476444D5819985007E34",
  253|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFF16A2E0B8F03E13DD29455C5C2A3D",
  254|      0|         oid);
  255|      0|   }
  256|       |
  257|       |   // secp256k1
  258|      2|   if(oid == OID{1, 3, 132, 0, 10}) {
  ------------------
  |  Branch (258:7): [True: 1, False: 1]
  ------------------
  259|      1|      return load_EC_group_info(
  260|      1|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F",
  261|      1|         "0x0",
  262|      1|         "0x7",
  263|      1|         "0x79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798",
  264|      1|         "0x483ADA7726A3C4655DA4FBFC0E1108A8FD17B448A68554199C47D08FFB10D4B8",
  265|      1|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141",
  266|      1|         oid);
  267|      1|   }
  268|       |
  269|       |   // sm2p256v1
  270|      1|   if(oid == OID{1, 2, 156, 10197, 1, 301}) {
  ------------------
  |  Branch (270:7): [True: 1, False: 0]
  ------------------
  271|      1|      return load_EC_group_info(
  272|      1|         "0xFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFF",
  273|      1|         "0xFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFC",
  274|      1|         "0x28E9FA9E9D9F5E344D5A9E4BCF6509A7F39789F515AB8F92DDBCBD414D940E93",
  275|      1|         "0x32C4AE2C1F1981195F9904466A39C9948FE30BBFF2660BE1715A4589334C74C7",
  276|      1|         "0xBC3736A2F4F6779C59BDCEE36B692153D0A9877CC62A474002DF32E52139F0A0",
  277|      1|         "0xFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFF7203DF6B21C6052B53BBF40939D54123",
  278|      1|         oid);
  279|      1|   }
  280|       |
  281|       |   // x962_p192v2
  282|      0|   if(oid == OID{1, 2, 840, 10045, 3, 1, 2}) {
  ------------------
  |  Branch (282:7): [True: 0, False: 0]
  ------------------
  283|      0|      return load_EC_group_info(
  284|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF",
  285|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC",
  286|      0|         "0xCC22D6DFB95C6B25E49C0D6364A4E5980C393AA21668D953",
  287|      0|         "0xEEA2BAE7E1497842F2DE7769CFE9C989C072AD696F48034A",
  288|      0|         "0x6574D11D69B6EC7A672BB82A083DF2F2B0847DE970B2DE15",
  289|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFE5FB1A724DC80418648D8DD31",
  290|      0|         oid);
  291|      0|   }
  292|       |
  293|       |   // x962_p192v3
  294|      0|   if(oid == OID{1, 2, 840, 10045, 3, 1, 3}) {
  ------------------
  |  Branch (294:7): [True: 0, False: 0]
  ------------------
  295|      0|      return load_EC_group_info(
  296|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF",
  297|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC",
  298|      0|         "0x22123DC2395A05CAA7423DAECCC94760A7D462256BD56916",
  299|      0|         "0x7D29778100C65A1DA1783716588DCE2B8B4AEE8E228F1896",
  300|      0|         "0x38A90F22637337334B49DCB66A6DC8F9978ACA7648A943B0",
  301|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFF7A62D031C83F4294F640EC13",
  302|      0|         oid);
  303|      0|   }
  304|       |
  305|       |   // x962_p239v1
  306|      0|   if(oid == OID{1, 2, 840, 10045, 3, 1, 4}) {
  ------------------
  |  Branch (306:7): [True: 0, False: 0]
  ------------------
  307|      0|      return load_EC_group_info(
  308|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFF",
  309|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFC",
  310|      0|         "0x6B016C3BDCF18941D0D654921475CA71A9DB2FB27D1D37796185C2942C0A",
  311|      0|         "0xFFA963CDCA8816CCC33B8642BEDF905C3D358573D3F27FBBD3B3CB9AAAF",
  312|      0|         "0x7DEBE8E4E90A5DAE6E4054CA530BA04654B36818CE226B39FCCB7B02F1AE",
  313|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFF9E5E9A9F5D9071FBD1522688909D0B",
  314|      0|         oid);
  315|      0|   }
  316|       |
  317|       |   // x962_p239v2
  318|      0|   if(oid == OID{1, 2, 840, 10045, 3, 1, 5}) {
  ------------------
  |  Branch (318:7): [True: 0, False: 0]
  ------------------
  319|      0|      return load_EC_group_info(
  320|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFF",
  321|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFC",
  322|      0|         "0x617FAB6832576CBBFED50D99F0249C3FEE58B94BA0038C7AE84C8C832F2C",
  323|      0|         "0x38AF09D98727705120C921BB5E9E26296A3CDCF2F35757A0EAFD87B830E7",
  324|      0|         "0x5B0125E4DBEA0EC7206DA0FC01D9B081329FB555DE6EF460237DFF8BE4BA",
  325|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF800000CFA7E8594377D414C03821BC582063",
  326|      0|         oid);
  327|      0|   }
  328|       |
  329|       |   // x962_p239v3
  330|      0|   if(oid == OID{1, 2, 840, 10045, 3, 1, 6}) {
  ------------------
  |  Branch (330:7): [True: 0, False: 0]
  ------------------
  331|      0|      return load_EC_group_info(
  332|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFF",
  333|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFFFFFFFF8000000000007FFFFFFFFFFC",
  334|      0|         "0x255705FA2A306654B1F4CB03D6A750A30C250102D4988717D9BA15AB6D3E",
  335|      0|         "0x6768AE8E18BB92CFCF005C949AA2C6D94853D0E660BBF854B1C9505FE95A",
  336|      0|         "0x1607E6898F390C06BC1D552BAD226F3B6FCFE48B6E818499AF18E3ED6CF3",
  337|      0|         "0x7FFFFFFFFFFFFFFFFFFFFFFF7FFFFF975DEB41B3A6057C3C432146526551",
  338|      0|         oid);
  339|      0|   }
  340|       |
  341|       |   // numsp512d1
  342|      0|   if(oid == OID{1, 3, 6, 1, 4, 1, 25258, 4, 3}) {
  ------------------
  |  Branch (342:7): [True: 0, False: 0]
  ------------------
  343|      0|      return load_EC_group_info(
  344|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFDC7",
  345|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFDC4",
  346|      0|         "0x1D99B",
  347|      0|         "0x2",
  348|      0|         "0x1C282EB23327F9711952C250EA61AD53FCC13031CF6DD336E0B9328433AFBDD8CC5A1C1F0C716FDC724DDE537C2B0ADB00BB3D08DC83755B205CC30D7F83CF28",
  349|      0|         "0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5B3CA4FB94E7831B4FC258ED97D0BDC63B568B36607CD243CE153F390433555D",
  350|      0|         oid);
  351|      0|   }
  352|       |
  353|      0|   return std::shared_ptr<EC_Group_Data>();
  354|      0|}
_ZN5Botan8EC_Group18known_named_groupsEv:
  477|  6.29k|const std::set<std::string>& EC_Group::known_named_groups() {
  478|  6.29k|   static const std::set<std::string> named_groups = {
  479|  6.29k|#if defined(BOTAN_HAS_PCURVES_BRAINPOOL256R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  480|  6.29k|      "brainpool256r1",
  481|  6.29k|#endif
  482|       |
  483|  6.29k|#if defined(BOTAN_HAS_PCURVES_BRAINPOOL384R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  484|  6.29k|      "brainpool384r1",
  485|  6.29k|#endif
  486|       |
  487|  6.29k|#if defined(BOTAN_HAS_PCURVES_BRAINPOOL512R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  488|  6.29k|      "brainpool512r1",
  489|  6.29k|#endif
  490|       |
  491|  6.29k|#if defined(BOTAN_HAS_PCURVES_FRP256V1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  492|  6.29k|      "frp256v1",
  493|  6.29k|#endif
  494|       |
  495|  6.29k|#if defined(BOTAN_HAS_PCURVES_NUMSP512D1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  496|  6.29k|      "numsp512d1",
  497|  6.29k|#endif
  498|       |
  499|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP192R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  500|  6.29k|      "secp192r1",
  501|  6.29k|#endif
  502|       |
  503|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP224R1) || defined(BOTAN_HAS_LEGACY_EC_POINT)
  504|       |      // Not supported by pcurves_generic
  505|  6.29k|      "secp224r1",
  506|  6.29k|#endif
  507|       |
  508|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP256K1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  509|  6.29k|      "secp256k1",
  510|  6.29k|#endif
  511|       |
  512|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP256R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  513|  6.29k|      "secp256r1",
  514|  6.29k|#endif
  515|       |
  516|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP384R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  517|  6.29k|      "secp384r1",
  518|  6.29k|#endif
  519|       |
  520|  6.29k|#if defined(BOTAN_HAS_PCURVES_SECP521R1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  521|  6.29k|      "secp521r1",
  522|  6.29k|#endif
  523|       |
  524|  6.29k|#if defined(BOTAN_HAS_PCURVES_SM2P256V1) || defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  525|  6.29k|      "sm2p256v1",
  526|  6.29k|#endif
  527|       |
  528|  6.29k|#if defined(BOTAN_HAS_LEGACY_EC_POINT) || defined(BOTAN_HAS_PCURVES_GENERIC)
  529|  6.29k|      "brainpool192r1",
  530|  6.29k|      "brainpool224r1",
  531|  6.29k|      "brainpool320r1",
  532|  6.29k|      "gost_256A",
  533|  6.29k|      "gost_512A",
  534|  6.29k|      "secp192k1",
  535|  6.29k|      "x962_p192v2",
  536|  6.29k|      "x962_p192v3",
  537|  6.29k|      "x962_p239v1",
  538|  6.29k|      "x962_p239v2",
  539|  6.29k|      "x962_p239v3",
  540|  6.29k|#endif
  541|       |
  542|  6.29k|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
  543|  6.29k|      "brainpool160r1",
  544|  6.29k|      "secp160k1",
  545|  6.29k|      "secp160r1",
  546|  6.29k|      "secp160r2",
  547|  6.29k|      "secp224k1",
  548|  6.29k|#endif
  549|  6.29k|   };
  550|       |
  551|  6.29k|   return named_groups;
  552|  6.29k|}

_ZN5Botan9EC_ScalarC2ENSt3__110unique_ptrINS_14EC_Scalar_DataENS1_14default_deleteIS3_EEEE:
   19|  37.1k|EC_Scalar::EC_Scalar(std::unique_ptr<EC_Scalar_Data> scalar) : m_scalar(std::move(scalar)) {
   20|  37.1k|   BOTAN_ASSERT_NONNULL(m_scalar);
  ------------------
  |  |  116|  37.1k|   do {                                                                                   \
  |  |  117|  37.1k|      if((ptr) == nullptr) {                                                              \
  |  |  ------------------
  |  |  |  Branch (117:10): [True: 0, False: 37.1k]
  |  |  ------------------
  |  |  118|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                              \
  |  |  119|      0|         Botan::assertion_failure(#ptr " is not null", "", __func__, __FILE__, __LINE__); \
  |  |  120|      0|      }                                                                                   \
  |  |  121|  37.1k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (121:12): [Folded, False: 37.1k]
  |  |  ------------------
  ------------------
   21|  37.1k|}
_ZN5Botan9EC_ScalarC2ERKS0_:
   23|  12.3k|EC_Scalar::EC_Scalar(const EC_Scalar& other) : m_scalar(other.inner().clone()) {}
_ZN5Botan9EC_ScalarC2EOS0_:
   25|  24.7k|EC_Scalar::EC_Scalar(EC_Scalar&& other) noexcept : m_scalar(std::move(other.m_scalar)) {}
_ZN5Botan9EC_ScalarD2Ev:
   46|  74.2k|EC_Scalar::~EC_Scalar() = default;
_ZN5Botan9EC_Scalar21from_bytes_with_truncERKNS_8EC_GroupENSt3__14spanIKhLm18446744073709551615EEE:
   52|  6.18k|EC_Scalar EC_Scalar::from_bytes_with_trunc(const EC_Group& group, std::span<const uint8_t> bytes) {
   53|  6.18k|   return EC_Scalar(group._data()->scalar_from_bytes_with_trunc(bytes));
   54|  6.18k|}
_ZN5Botan9EC_Scalar16deserialize_pairERKNS_8EC_GroupENSt3__14spanIKhLm18446744073709551615EEE:
  105|  6.25k|                                                                           std::span<const uint8_t> bytes) {
  106|  6.25k|   if(bytes.size() % 2 != 0) {
  ------------------
  |  Branch (106:7): [True: 0, False: 6.25k]
  ------------------
  107|      0|      return {};
  108|      0|   }
  109|       |
  110|  6.25k|   const size_t half = bytes.size() / 2;
  111|       |
  112|  6.25k|   auto r = EC_Scalar::deserialize(group, bytes.first(half));
  113|  6.25k|   auto s = EC_Scalar::deserialize(group, bytes.last(half));
  114|       |
  115|  6.25k|   if(r && s) {
  ------------------
  |  Branch (115:7): [True: 6.22k, False: 30]
  |  Branch (115:12): [True: 6.18k, False: 41]
  ------------------
  116|  6.18k|      return std::make_pair(r.value(), s.value());
  117|  6.18k|   } else {
  118|     71|      return {};
  119|     71|   }
  120|  6.25k|}
_ZN5Botan9EC_Scalar11deserializeERKNS_8EC_GroupENSt3__14spanIKhLm18446744073709551615EEE:
  122|  12.5k|std::optional<EC_Scalar> EC_Scalar::deserialize(const EC_Group& group, std::span<const uint8_t> bytes) {
  123|  12.5k|   if(auto v = group._data()->scalar_deserialize(bytes)) {
  ------------------
  |  Branch (123:12): [True: 12.4k, False: 73]
  ------------------
  124|  12.4k|      return EC_Scalar(std::move(v));
  125|  12.4k|   } else {
  126|     73|      return {};
  127|     73|   }
  128|  12.5k|}
_ZNK5Botan9EC_Scalar7is_zeroEv:
  137|  12.3k|bool EC_Scalar::is_zero() const {
  138|  12.3k|   return inner().is_zero();
  139|  12.3k|}
_ZNK5Botan9EC_Scalar14invert_vartimeEv:
  145|  6.18k|EC_Scalar EC_Scalar::invert_vartime() const {
  146|  6.18k|   return EC_Scalar(inner().invert_vartime());
  147|  6.18k|}
_ZNK5Botan9EC_Scalar3mulERKS0_:
  167|  12.3k|EC_Scalar EC_Scalar::mul(const EC_Scalar& x) const {
  168|  12.3k|   BOTAN_ARG_CHECK(inner().group() == x.inner().group(), "Curve mismatch");
  ------------------
  |  |   35|  12.3k|   do {                                                          \
  |  |   36|  12.3k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  12.3k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 12.3k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  12.3k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 12.3k]
  |  |  ------------------
  ------------------
  169|  12.3k|   return EC_Scalar(inner().mul(x.inner()));
  170|  12.3k|}

_ZN5Botan8CurveGFpC2EPKNS_13EC_Group_DataE:
   28|      3|CurveGFp::CurveGFp(const EC_Group_Data* group) : m_group(group) {
   29|      3|   BOTAN_ASSERT_NONNULL(m_group);
  ------------------
  |  |  116|      3|   do {                                                                                   \
  |  |  117|      3|      if((ptr) == nullptr) {                                                              \
  |  |  ------------------
  |  |  |  Branch (117:10): [True: 0, False: 3]
  |  |  ------------------
  |  |  118|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                              \
  |  |  119|      0|         Botan::assertion_failure(#ptr " is not null", "", __func__, __FILE__, __LINE__); \
  |  |  120|      0|      }                                                                                   \
  |  |  121|      3|   } while(0)
  |  |  ------------------
  |  |  |  Branch (121:12): [Folded, False: 3]
  |  |  ------------------
  ------------------
   30|      3|}
_ZNK5Botan8CurveGFp5groupEv:
   32|  12.5k|const EC_Group_Data& CurveGFp::group() const {
   33|  12.5k|   BOTAN_ASSERT_NONNULL(m_group);
  ------------------
  |  |  116|  12.5k|   do {                                                                                   \
  |  |  117|  12.5k|      if((ptr) == nullptr) {                                                              \
  |  |  ------------------
  |  |  |  Branch (117:10): [True: 0, False: 12.5k]
  |  |  ------------------
  |  |  118|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                              \
  |  |  119|      0|         Botan::assertion_failure(#ptr " is not null", "", __func__, __FILE__, __LINE__); \
  |  |  120|      0|      }                                                                                   \
  |  |  121|  12.5k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (121:12): [Folded, False: 12.5k]
  |  |  ------------------
  ------------------
   34|  12.5k|   return *m_group;
   35|  12.5k|}
_ZN5Botan8EC_PointC2ERKNS_8CurveGFpENS_6BigIntES4_:
  115|  6.25k|      m_curve(curve), m_x(std::move(x)), m_y(std::move(y)), m_z(m_curve.group().monty().R1()) {
  116|  6.25k|   const auto& group = m_curve.group();
  117|       |
  118|  6.25k|   if(m_x < 0 || m_x >= group.p()) {
  ------------------
  |  Branch (118:7): [True: 0, False: 6.25k]
  |  Branch (118:18): [True: 0, False: 6.25k]
  ------------------
  119|      0|      throw Invalid_Argument("Invalid EC_Point affine x");
  120|      0|   }
  121|  6.25k|   if(m_y < 0 || m_y >= group.p()) {
  ------------------
  |  Branch (121:7): [True: 0, False: 6.25k]
  |  Branch (121:18): [True: 0, False: 6.25k]
  ------------------
  122|      0|      throw Invalid_Argument("Invalid EC_Point affine y");
  123|      0|   }
  124|       |
  125|  6.25k|   secure_vector<word> monty_ws(monty_ws_size(group));
  126|       |
  127|  6.25k|   to_rep(group, m_x, monty_ws);
  128|  6.25k|   to_rep(group, m_y, monty_ws);
  129|  6.25k|}
_ZN5Botan8EC_Point4swapERS0_:
  792|  6.25k|void EC_Point::swap(EC_Point& other) noexcept {
  793|  6.25k|   m_curve.swap(other.m_curve);
  794|  6.25k|   m_x.swap(other.m_x);
  795|  6.25k|   m_y.swap(other.m_y);
  796|  6.25k|   m_z.swap(other.m_z);
  797|  6.25k|}
ec_point.cpp:_ZN5Botan12_GLOBAL__N_113monty_ws_sizeERKNS_13EC_Group_DataE:
  102|  6.25k|size_t monty_ws_size(const EC_Group_Data& group) {
  103|  6.25k|   return 2 * group.p_words();
  104|  6.25k|}
ec_point.cpp:_ZN5Botan12_GLOBAL__N_16to_repERKNS_13EC_Group_DataERNS_6BigIntERNSt3__16vectorImNS_16secure_allocatorImEEEE:
   55|  12.5k|void to_rep(const EC_Group_Data& group, BigInt& x, secure_vector<word>& ws) {
   56|  12.5k|   group.monty().mul_by(x, group.monty().R2(), ws);
   57|  12.5k|}

_ZN5Botan17EC_PublicKey_DataC2ENS_8EC_GroupENS_14EC_AffinePointE:
   41|  6.25k|      m_group(std::move(group)), m_point(std::move(pt)) {
   42|  6.25k|#if defined(BOTAN_HAS_LEGACY_EC_POINT)
   43|  6.25k|   m_legacy_point = m_point.to_legacy_point();
   44|  6.25k|#endif
   45|       |
   46|       |   // Checking that the point lies on the curve is done in the deserialization
   47|       |   // of EC_AffinePoint.
   48|  6.25k|   BOTAN_ARG_CHECK(!m_point.is_identity(), "ECC public key cannot be point at infinity");
  ------------------
  |  |   35|  6.25k|   do {                                                          \
  |  |   36|  6.25k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.25k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 6.25k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  6.25k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 6.25k]
  |  |  ------------------
  ------------------
   49|  6.25k|}

_ZN5Botan12EC_PublicKeyC2ERKNS_8EC_GroupERKNS_14EC_AffinePointE:
   66|  6.25k|EC_PublicKey::EC_PublicKey(const EC_Group& group, const EC_AffinePoint& pub_point) {
   67|  6.25k|   m_public_key = std::make_shared<const EC_PublicKey_Data>(group, pub_point);
   68|  6.25k|   m_domain_encoding = default_encoding_for(domain());  // NOLINT(*-prefer-member-initializer)
   69|  6.25k|}
_ZNK5Botan12EC_PublicKey6domainEv:
   76|  18.7k|const EC_Group& EC_PublicKey::domain() const {
   77|  18.7k|   BOTAN_STATE_CHECK(m_public_key != nullptr);
  ------------------
  |  |   51|  18.7k|   do {                                                         \
  |  |   52|  18.7k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  18.7k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 18.7k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  18.7k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 18.7k]
  |  |  ------------------
  ------------------
   78|  18.7k|   return m_public_key->group();
   79|  18.7k|}
_ZNK5Botan12EC_PublicKey16_public_ec_pointEv:
   88|  6.25k|const EC_AffinePoint& EC_PublicKey::_public_ec_point() const {
   89|  6.25k|   BOTAN_STATE_CHECK(m_public_key != nullptr);
  ------------------
  |  |   51|  6.25k|   do {                                                         \
  |  |   52|  6.25k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|  6.25k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 6.25k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|  6.25k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 6.25k]
  |  |  ------------------
  ------------------
   90|  6.25k|   return m_public_key->public_key();
   91|  6.25k|}
ecc_key.cpp:_ZN5Botan12_GLOBAL__N_120default_encoding_forERKNS_8EC_GroupE:
   38|  6.25k|EC_Group_Encoding default_encoding_for(const EC_Group& group) {
   39|  6.25k|   if(group.get_curve_oid().empty()) {
  ------------------
  |  Branch (39:7): [True: 0, False: 6.25k]
  ------------------
   40|      0|      return EC_Group_Encoding::Explicit;
   41|  6.25k|   } else {
   42|  6.25k|      return EC_Group_Encoding::NamedCurve;
   43|  6.25k|   }
   44|  6.25k|}

_ZNK5Botan15ECDSA_PublicKey40_signature_element_size_for_DER_encodingEv:
   80|  6.25k|std::optional<size_t> ECDSA_PublicKey::_signature_element_size_for_DER_encoding() const {
   81|  6.25k|   return domain().get_order_bytes();
   82|  6.25k|}
_ZNK5Botan15ECDSA_PublicKey22create_verification_opENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  264|  6.25k|                                                                              std::string_view provider) const {
  265|  6.25k|   if(provider == "base" || provider.empty()) {
  ------------------
  |  Branch (265:7): [True: 0, False: 6.25k]
  |  Branch (265:29): [True: 6.25k, False: 0]
  ------------------
  266|  6.25k|      return std::make_unique<ECDSA_Verification_Operation>(*this, params);
  267|  6.25k|   }
  268|       |
  269|      0|   throw Provider_Not_Found(algo_name(), provider);
  270|  6.25k|}
ecdsa.cpp:_ZN5Botan12_GLOBAL__N_128ECDSA_Verification_OperationC2ERKNS_15ECDSA_PublicKeyENSt3__117basic_string_viewIcNS5_11char_traitsIcEEEE:
  218|  6.25k|            PK_Ops::Verification_with_Hash(padding), m_group(ecdsa.domain()), m_gy_mul(ecdsa._public_ec_point()) {}
ecdsa.cpp:_ZN5Botan12_GLOBAL__N_128ECDSA_Verification_Operation6verifyENSt3__14spanIKhLm18446744073709551615EEES5_:
  244|  6.25k|bool ECDSA_Verification_Operation::verify(std::span<const uint8_t> msg, std::span<const uint8_t> sig) {
  245|  6.25k|   if(auto rs = EC_Scalar::deserialize_pair(m_group, sig)) {
  ------------------
  |  Branch (245:12): [True: 6.18k, False: 71]
  ------------------
  246|  6.18k|      const auto& [r, s] = rs.value();
  247|       |
  248|  6.18k|      if(r.is_nonzero() && s.is_nonzero()) {
  ------------------
  |  Branch (248:10): [True: 6.18k, False: 0]
  |  Branch (248:28): [True: 6.18k, False: 0]
  ------------------
  249|  6.18k|         const auto m = EC_Scalar::from_bytes_with_trunc(m_group, msg);
  250|       |
  251|  6.18k|         const auto w = s.invert_vartime();
  252|       |
  253|       |         // Check if r == x_coord(g*w*m + y*w*r) % n
  254|  6.18k|         return m_gy_mul.mul2_vartime_x_mod_order_eq(r, w, m, r);
  255|  6.18k|      }
  256|  6.18k|   }
  257|       |
  258|     71|   return false;
  259|  6.25k|}

_ZN5Botan14ed25519_verifyEPKhmS1_S1_S1_m:
   76|  3.08k|                    size_t domain_sep_len) {
   77|  3.08k|   if((sig[63] & 0xE0) != 0x00) {
  ------------------
  |  Branch (77:7): [True: 40, False: 3.04k]
  ------------------
   78|     40|      return false;
   79|     40|   }
   80|       |
   81|  3.04k|   const uint8_t identity_element[32] = {1};
   82|  3.04k|   if(CT::is_equal(pk, identity_element, 32).as_bool()) {
  ------------------
  |  Branch (82:7): [True: 0, False: 3.04k]
  ------------------
   83|      0|      return false;
   84|      0|   }
   85|       |
   86|  3.04k|   const uint64_t CURVE25519_ORDER[4] = {
   87|  3.04k|      0x1000000000000000,
   88|  3.04k|      0x0000000000000000,
   89|  3.04k|      0x14def9dea2f79cd6,
   90|  3.04k|      0x5812631a5cf5d3ed,
   91|  3.04k|   };
   92|       |
   93|  3.04k|   const uint64_t s[4] = {load_le<uint64_t>(sig + 32, 3),
   94|  3.04k|                          load_le<uint64_t>(sig + 32, 2),
   95|  3.04k|                          load_le<uint64_t>(sig + 32, 1),
   96|  3.04k|                          load_le<uint64_t>(sig + 32, 0)};
   97|       |
   98|       |   // RFC 8032 adds the requirement that we verify that s < order in
   99|       |   // the signature; this did not exist in the original Ed25519 spec.
  100|  3.04k|   for(size_t i = 0; i != 4; ++i) {
  ------------------
  |  Branch (100:22): [True: 3.04k, False: 0]
  ------------------
  101|  3.04k|      if(s[i] > CURVE25519_ORDER[i]) {
  ------------------
  |  Branch (101:10): [True: 8, False: 3.04k]
  ------------------
  102|      8|         return false;
  103|      8|      }
  104|  3.04k|      if(s[i] < CURVE25519_ORDER[i]) {
  ------------------
  |  Branch (104:10): [True: 3.03k, False: 4]
  ------------------
  105|  3.03k|         break;
  106|  3.03k|      }
  107|      4|      if(i == 3) {  // here s == order
  ------------------
  |  Branch (107:10): [True: 0, False: 4]
  ------------------
  108|      0|         return false;
  109|      0|      }
  110|      4|   }
  111|       |
  112|  3.03k|   uint8_t h[64];
  113|  3.03k|   auto sha512 = HashFunction::create_or_throw("SHA-512");
  114|       |
  115|  3.03k|   sha512->update(domain_sep, domain_sep_len);
  116|  3.03k|   sha512->update(sig, 32);
  117|  3.03k|   sha512->update(pk, 32);
  118|  3.03k|   sha512->update(m, mlen);
  119|  3.03k|   sha512->final(h);
  120|  3.03k|   sc_reduce(h);
  121|       |
  122|  3.03k|   return signature_check(std::span<const uint8_t, 32>{pk, 32}, h, sig, sig + 32);
  123|  3.04k|}

_ZNK5Botan20Ed25519_FieldElement6invertEv:
   18|  3.02k|Ed25519_FieldElement Ed25519_FieldElement::invert() const {
   19|  3.02k|   auto t0 = this->sqr();
   20|  3.02k|   auto t1 = t0.sqr_iter(2);
   21|  3.02k|   t1 = *this * t1;
   22|  3.02k|   t0 = t0 * t1;
   23|  3.02k|   auto t2 = t0.sqr();
   24|  3.02k|   t1 = t1 * t2;
   25|  3.02k|   t2 = t1.sqr_iter(5);
   26|  3.02k|   t1 = t2 * t1;
   27|  3.02k|   t2 = t1.sqr_iter(10);
   28|  3.02k|   t2 = t2 * t1;
   29|  3.02k|   auto t3 = t2.sqr_iter(20);
   30|  3.02k|   t2 = t3 * t2;
   31|  3.02k|   t2 = t2.sqr_iter(10);
   32|  3.02k|   t1 = t2 * t1;
   33|  3.02k|   t2 = t1.sqr_iter(50);
   34|  3.02k|   t2 = t2 * t1;
   35|  3.02k|   t3 = t2.sqr_iter(100);
   36|  3.02k|   t2 = t3 * t2;
   37|  3.02k|   t2 = t2.sqr_iter(50);
   38|  3.02k|   t1 = t2 * t1;
   39|  3.02k|   t1 = t1.sqr_iter(5);
   40|       |
   41|  3.02k|   t0 = t1 * t0;
   42|  3.02k|   return t0;
   43|  3.02k|}
_ZNK5Botan20Ed25519_FieldElement9pow_22523Ev:
   45|  3.03k|Ed25519_FieldElement Ed25519_FieldElement::pow_22523() const {
   46|  3.03k|   auto t0 = this->sqr();
   47|  3.03k|   auto t1 = t0.sqr_iter(2);
   48|  3.03k|   t1 = (*this) * t1;
   49|  3.03k|   t0 = t0 * t1;
   50|  3.03k|   t0 = t0.sqr();
   51|  3.03k|   t0 = t1 * t0;
   52|  3.03k|   t1 = t0.sqr_iter(5);
   53|  3.03k|   t0 = t1 * t0;
   54|  3.03k|   t1 = t0.sqr_iter(10);
   55|  3.03k|   t1 = t1 * t0;
   56|  3.03k|   auto t2 = t1.sqr_iter(20);
   57|  3.03k|   t1 = t2 * t1;
   58|  3.03k|   t1 = t1.sqr_iter(10);
   59|  3.03k|   t0 = t1 * t0;
   60|  3.03k|   t1 = t0.sqr_iter(50);
   61|  3.03k|   t1 = t1 * t0;
   62|  3.03k|   t2 = t1.sqr_iter(100);
   63|  3.03k|   t1 = t2 * t1;
   64|  3.03k|   t1 = t1.sqr_iter(50);
   65|  3.03k|   t0 = t1 * t0;
   66|  3.03k|   t0 = t0.sqr_iter(2);
   67|       |
   68|  3.03k|   t0 = t0 * (*this);
   69|  3.03k|   return t0;
   70|  3.03k|}
_ZN5Botan20Ed25519_FieldElement3mulERKS0_S2_:
  105|  4.41M|Ed25519_FieldElement Ed25519_FieldElement::mul(const Ed25519_FieldElement& f, const Ed25519_FieldElement& g) {
  106|  4.41M|   const int32_t f0 = f.m_fe[0];
  107|  4.41M|   const int32_t f1 = f.m_fe[1];
  108|  4.41M|   const int32_t f2 = f.m_fe[2];
  109|  4.41M|   const int32_t f3 = f.m_fe[3];
  110|  4.41M|   const int32_t f4 = f.m_fe[4];
  111|  4.41M|   const int32_t f5 = f.m_fe[5];
  112|  4.41M|   const int32_t f6 = f.m_fe[6];
  113|  4.41M|   const int32_t f7 = f.m_fe[7];
  114|  4.41M|   const int32_t f8 = f.m_fe[8];
  115|  4.41M|   const int32_t f9 = f.m_fe[9];
  116|       |
  117|  4.41M|   const int32_t g0 = g.m_fe[0];
  118|  4.41M|   const int32_t g1 = g.m_fe[1];
  119|  4.41M|   const int32_t g2 = g.m_fe[2];
  120|  4.41M|   const int32_t g3 = g.m_fe[3];
  121|  4.41M|   const int32_t g4 = g.m_fe[4];
  122|  4.41M|   const int32_t g5 = g.m_fe[5];
  123|  4.41M|   const int32_t g6 = g.m_fe[6];
  124|  4.41M|   const int32_t g7 = g.m_fe[7];
  125|  4.41M|   const int32_t g8 = g.m_fe[8];
  126|  4.41M|   const int32_t g9 = g.m_fe[9];
  127|       |
  128|  4.41M|   const int32_t g1_19 = 19 * g1; /* 1.959375*2^29 */
  129|  4.41M|   const int32_t g2_19 = 19 * g2; /* 1.959375*2^30; still ok */
  130|  4.41M|   const int32_t g3_19 = 19 * g3;
  131|  4.41M|   const int32_t g4_19 = 19 * g4;
  132|  4.41M|   const int32_t g5_19 = 19 * g5;
  133|  4.41M|   const int32_t g6_19 = 19 * g6;
  134|  4.41M|   const int32_t g7_19 = 19 * g7;
  135|  4.41M|   const int32_t g8_19 = 19 * g8;
  136|  4.41M|   const int32_t g9_19 = 19 * g9;
  137|  4.41M|   const int32_t f1_2 = 2 * f1;
  138|  4.41M|   const int32_t f3_2 = 2 * f3;
  139|  4.41M|   const int32_t f5_2 = 2 * f5;
  140|  4.41M|   const int32_t f7_2 = 2 * f7;
  141|  4.41M|   const int32_t f9_2 = 2 * f9;
  142|       |
  143|  4.41M|   const int64_t f0g0 = f0 * static_cast<int64_t>(g0);
  144|  4.41M|   const int64_t f0g1 = f0 * static_cast<int64_t>(g1);
  145|  4.41M|   const int64_t f0g2 = f0 * static_cast<int64_t>(g2);
  146|  4.41M|   const int64_t f0g3 = f0 * static_cast<int64_t>(g3);
  147|  4.41M|   const int64_t f0g4 = f0 * static_cast<int64_t>(g4);
  148|  4.41M|   const int64_t f0g5 = f0 * static_cast<int64_t>(g5);
  149|  4.41M|   const int64_t f0g6 = f0 * static_cast<int64_t>(g6);
  150|  4.41M|   const int64_t f0g7 = f0 * static_cast<int64_t>(g7);
  151|  4.41M|   const int64_t f0g8 = f0 * static_cast<int64_t>(g8);
  152|  4.41M|   const int64_t f0g9 = f0 * static_cast<int64_t>(g9);
  153|  4.41M|   const int64_t f1g0 = f1 * static_cast<int64_t>(g0);
  154|  4.41M|   const int64_t f1g1_2 = f1_2 * static_cast<int64_t>(g1);
  155|  4.41M|   const int64_t f1g2 = f1 * static_cast<int64_t>(g2);
  156|  4.41M|   const int64_t f1g3_2 = f1_2 * static_cast<int64_t>(g3);
  157|  4.41M|   const int64_t f1g4 = f1 * static_cast<int64_t>(g4);
  158|  4.41M|   const int64_t f1g5_2 = f1_2 * static_cast<int64_t>(g5);
  159|  4.41M|   const int64_t f1g6 = f1 * static_cast<int64_t>(g6);
  160|  4.41M|   const int64_t f1g7_2 = f1_2 * static_cast<int64_t>(g7);
  161|  4.41M|   const int64_t f1g8 = f1 * static_cast<int64_t>(g8);
  162|  4.41M|   const int64_t f1g9_38 = f1_2 * static_cast<int64_t>(g9_19);
  163|  4.41M|   const int64_t f2g0 = f2 * static_cast<int64_t>(g0);
  164|  4.41M|   const int64_t f2g1 = f2 * static_cast<int64_t>(g1);
  165|  4.41M|   const int64_t f2g2 = f2 * static_cast<int64_t>(g2);
  166|  4.41M|   const int64_t f2g3 = f2 * static_cast<int64_t>(g3);
  167|  4.41M|   const int64_t f2g4 = f2 * static_cast<int64_t>(g4);
  168|  4.41M|   const int64_t f2g5 = f2 * static_cast<int64_t>(g5);
  169|  4.41M|   const int64_t f2g6 = f2 * static_cast<int64_t>(g6);
  170|  4.41M|   const int64_t f2g7 = f2 * static_cast<int64_t>(g7);
  171|  4.41M|   const int64_t f2g8_19 = f2 * static_cast<int64_t>(g8_19);
  172|  4.41M|   const int64_t f2g9_19 = f2 * static_cast<int64_t>(g9_19);
  173|  4.41M|   const int64_t f3g0 = f3 * static_cast<int64_t>(g0);
  174|  4.41M|   const int64_t f3g1_2 = f3_2 * static_cast<int64_t>(g1);
  175|  4.41M|   const int64_t f3g2 = f3 * static_cast<int64_t>(g2);
  176|  4.41M|   const int64_t f3g3_2 = f3_2 * static_cast<int64_t>(g3);
  177|  4.41M|   const int64_t f3g4 = f3 * static_cast<int64_t>(g4);
  178|  4.41M|   const int64_t f3g5_2 = f3_2 * static_cast<int64_t>(g5);
  179|  4.41M|   const int64_t f3g6 = f3 * static_cast<int64_t>(g6);
  180|  4.41M|   const int64_t f3g7_38 = f3_2 * static_cast<int64_t>(g7_19);
  181|  4.41M|   const int64_t f3g8_19 = f3 * static_cast<int64_t>(g8_19);
  182|  4.41M|   const int64_t f3g9_38 = f3_2 * static_cast<int64_t>(g9_19);
  183|  4.41M|   const int64_t f4g0 = f4 * static_cast<int64_t>(g0);
  184|  4.41M|   const int64_t f4g1 = f4 * static_cast<int64_t>(g1);
  185|  4.41M|   const int64_t f4g2 = f4 * static_cast<int64_t>(g2);
  186|  4.41M|   const int64_t f4g3 = f4 * static_cast<int64_t>(g3);
  187|  4.41M|   const int64_t f4g4 = f4 * static_cast<int64_t>(g4);
  188|  4.41M|   const int64_t f4g5 = f4 * static_cast<int64_t>(g5);
  189|  4.41M|   const int64_t f4g6_19 = f4 * static_cast<int64_t>(g6_19);
  190|  4.41M|   const int64_t f4g7_19 = f4 * static_cast<int64_t>(g7_19);
  191|  4.41M|   const int64_t f4g8_19 = f4 * static_cast<int64_t>(g8_19);
  192|  4.41M|   const int64_t f4g9_19 = f4 * static_cast<int64_t>(g9_19);
  193|  4.41M|   const int64_t f5g0 = f5 * static_cast<int64_t>(g0);
  194|  4.41M|   const int64_t f5g1_2 = f5_2 * static_cast<int64_t>(g1);
  195|  4.41M|   const int64_t f5g2 = f5 * static_cast<int64_t>(g2);
  196|  4.41M|   const int64_t f5g3_2 = f5_2 * static_cast<int64_t>(g3);
  197|  4.41M|   const int64_t f5g4 = f5 * static_cast<int64_t>(g4);
  198|  4.41M|   const int64_t f5g5_38 = f5_2 * static_cast<int64_t>(g5_19);
  199|  4.41M|   const int64_t f5g6_19 = f5 * static_cast<int64_t>(g6_19);
  200|  4.41M|   const int64_t f5g7_38 = f5_2 * static_cast<int64_t>(g7_19);
  201|  4.41M|   const int64_t f5g8_19 = f5 * static_cast<int64_t>(g8_19);
  202|  4.41M|   const int64_t f5g9_38 = f5_2 * static_cast<int64_t>(g9_19);
  203|  4.41M|   const int64_t f6g0 = f6 * static_cast<int64_t>(g0);
  204|  4.41M|   const int64_t f6g1 = f6 * static_cast<int64_t>(g1);
  205|  4.41M|   const int64_t f6g2 = f6 * static_cast<int64_t>(g2);
  206|  4.41M|   const int64_t f6g3 = f6 * static_cast<int64_t>(g3);
  207|  4.41M|   const int64_t f6g4_19 = f6 * static_cast<int64_t>(g4_19);
  208|  4.41M|   const int64_t f6g5_19 = f6 * static_cast<int64_t>(g5_19);
  209|  4.41M|   const int64_t f6g6_19 = f6 * static_cast<int64_t>(g6_19);
  210|  4.41M|   const int64_t f6g7_19 = f6 * static_cast<int64_t>(g7_19);
  211|  4.41M|   const int64_t f6g8_19 = f6 * static_cast<int64_t>(g8_19);
  212|  4.41M|   const int64_t f6g9_19 = f6 * static_cast<int64_t>(g9_19);
  213|  4.41M|   const int64_t f7g0 = f7 * static_cast<int64_t>(g0);
  214|  4.41M|   const int64_t f7g1_2 = f7_2 * static_cast<int64_t>(g1);
  215|  4.41M|   const int64_t f7g2 = f7 * static_cast<int64_t>(g2);
  216|  4.41M|   const int64_t f7g3_38 = f7_2 * static_cast<int64_t>(g3_19);
  217|  4.41M|   const int64_t f7g4_19 = f7 * static_cast<int64_t>(g4_19);
  218|  4.41M|   const int64_t f7g5_38 = f7_2 * static_cast<int64_t>(g5_19);
  219|  4.41M|   const int64_t f7g6_19 = f7 * static_cast<int64_t>(g6_19);
  220|  4.41M|   const int64_t f7g7_38 = f7_2 * static_cast<int64_t>(g7_19);
  221|  4.41M|   const int64_t f7g8_19 = f7 * static_cast<int64_t>(g8_19);
  222|  4.41M|   const int64_t f7g9_38 = f7_2 * static_cast<int64_t>(g9_19);
  223|  4.41M|   const int64_t f8g0 = f8 * static_cast<int64_t>(g0);
  224|  4.41M|   const int64_t f8g1 = f8 * static_cast<int64_t>(g1);
  225|  4.41M|   const int64_t f8g2_19 = f8 * static_cast<int64_t>(g2_19);
  226|  4.41M|   const int64_t f8g3_19 = f8 * static_cast<int64_t>(g3_19);
  227|  4.41M|   const int64_t f8g4_19 = f8 * static_cast<int64_t>(g4_19);
  228|  4.41M|   const int64_t f8g5_19 = f8 * static_cast<int64_t>(g5_19);
  229|  4.41M|   const int64_t f8g6_19 = f8 * static_cast<int64_t>(g6_19);
  230|  4.41M|   const int64_t f8g7_19 = f8 * static_cast<int64_t>(g7_19);
  231|  4.41M|   const int64_t f8g8_19 = f8 * static_cast<int64_t>(g8_19);
  232|  4.41M|   const int64_t f8g9_19 = f8 * static_cast<int64_t>(g9_19);
  233|  4.41M|   const int64_t f9g0 = f9 * static_cast<int64_t>(g0);
  234|  4.41M|   const int64_t f9g1_38 = f9_2 * static_cast<int64_t>(g1_19);
  235|  4.41M|   const int64_t f9g2_19 = f9 * static_cast<int64_t>(g2_19);
  236|  4.41M|   const int64_t f9g3_38 = f9_2 * static_cast<int64_t>(g3_19);
  237|  4.41M|   const int64_t f9g4_19 = f9 * static_cast<int64_t>(g4_19);
  238|  4.41M|   const int64_t f9g5_38 = f9_2 * static_cast<int64_t>(g5_19);
  239|  4.41M|   const int64_t f9g6_19 = f9 * static_cast<int64_t>(g6_19);
  240|  4.41M|   const int64_t f9g7_38 = f9_2 * static_cast<int64_t>(g7_19);
  241|  4.41M|   const int64_t f9g8_19 = f9 * static_cast<int64_t>(g8_19);
  242|  4.41M|   const int64_t f9g9_38 = f9_2 * static_cast<int64_t>(g9_19);
  243|       |
  244|  4.41M|   int64_t h0 = f0g0 + f1g9_38 + f2g8_19 + f3g7_38 + f4g6_19 + f5g5_38 + f6g4_19 + f7g3_38 + f8g2_19 + f9g1_38;
  245|  4.41M|   int64_t h1 = f0g1 + f1g0 + f2g9_19 + f3g8_19 + f4g7_19 + f5g6_19 + f6g5_19 + f7g4_19 + f8g3_19 + f9g2_19;
  246|  4.41M|   int64_t h2 = f0g2 + f1g1_2 + f2g0 + f3g9_38 + f4g8_19 + f5g7_38 + f6g6_19 + f7g5_38 + f8g4_19 + f9g3_38;
  247|  4.41M|   int64_t h3 = f0g3 + f1g2 + f2g1 + f3g0 + f4g9_19 + f5g8_19 + f6g7_19 + f7g6_19 + f8g5_19 + f9g4_19;
  248|  4.41M|   int64_t h4 = f0g4 + f1g3_2 + f2g2 + f3g1_2 + f4g0 + f5g9_38 + f6g8_19 + f7g7_38 + f8g6_19 + f9g5_38;
  249|  4.41M|   int64_t h5 = f0g5 + f1g4 + f2g3 + f3g2 + f4g1 + f5g0 + f6g9_19 + f7g8_19 + f8g7_19 + f9g6_19;
  250|  4.41M|   int64_t h6 = f0g6 + f1g5_2 + f2g4 + f3g3_2 + f4g2 + f5g1_2 + f6g0 + f7g9_38 + f8g8_19 + f9g7_38;
  251|  4.41M|   int64_t h7 = f0g7 + f1g6 + f2g5 + f3g4 + f4g3 + f5g2 + f6g1 + f7g0 + f8g9_19 + f9g8_19;
  252|  4.41M|   int64_t h8 = f0g8 + f1g7_2 + f2g6 + f3g5_2 + f4g4 + f5g3_2 + f6g2 + f7g1_2 + f8g0 + f9g9_38;
  253|  4.41M|   int64_t h9 = f0g9 + f1g8 + f2g7 + f3g6 + f4g5 + f5g4 + f6g3 + f7g2 + f8g1 + f9g0;
  254|       |
  255|       |   /*
  256|       |   |h0| <= (1.65*1.65*2^52*(1+19+19+19+19)+1.65*1.65*2^50*(38+38+38+38+38))
  257|       |   i.e. |h0| <= 1.4*2^60; narrower ranges for h2, h4, h6, h8
  258|       |   |h1| <= (1.65*1.65*2^51*(1+1+19+19+19+19+19+19+19+19))
  259|       |   i.e. |h1| <= 1.7*2^59; narrower ranges for h3, h5, h7, h9
  260|       |   */
  261|  4.41M|   carry<26>(h0, h1);
  262|  4.41M|   carry<26>(h4, h5);
  263|       |
  264|       |   /* |h0| <= 2^25 */
  265|       |   /* |h4| <= 2^25 */
  266|       |   /* |h1| <= 1.71*2^59 */
  267|       |   /* |h5| <= 1.71*2^59 */
  268|       |
  269|  4.41M|   carry<25>(h1, h2);
  270|  4.41M|   carry<25>(h5, h6);
  271|       |
  272|       |   /* |h1| <= 2^24; from now on fits into int32 */
  273|       |   /* |h5| <= 2^24; from now on fits into int32 */
  274|       |   /* |h2| <= 1.41*2^60 */
  275|       |   /* |h6| <= 1.41*2^60 */
  276|       |
  277|  4.41M|   carry<26>(h2, h3);
  278|  4.41M|   carry<26>(h6, h7);
  279|       |   /* |h2| <= 2^25; from now on fits into int32 unchanged */
  280|       |   /* |h6| <= 2^25; from now on fits into int32 unchanged */
  281|       |   /* |h3| <= 1.71*2^59 */
  282|       |   /* |h7| <= 1.71*2^59 */
  283|       |
  284|  4.41M|   carry<25>(h3, h4);
  285|  4.41M|   carry<25>(h7, h8);
  286|       |   /* |h3| <= 2^24; from now on fits into int32 unchanged */
  287|       |   /* |h7| <= 2^24; from now on fits into int32 unchanged */
  288|       |   /* |h4| <= 1.72*2^34 */
  289|       |   /* |h8| <= 1.41*2^60 */
  290|       |
  291|  4.41M|   carry<26>(h4, h5);
  292|  4.41M|   carry<26>(h8, h9);
  293|       |   /* |h4| <= 2^25; from now on fits into int32 unchanged */
  294|       |   /* |h8| <= 2^25; from now on fits into int32 unchanged */
  295|       |   /* |h5| <= 1.01*2^24 */
  296|       |   /* |h9| <= 1.71*2^59 */
  297|       |
  298|  4.41M|   carry<25, 19>(h9, h0);
  299|       |
  300|       |   /* |h9| <= 2^24; from now on fits into int32 unchanged */
  301|       |   /* |h0| <= 1.1*2^39 */
  302|       |
  303|  4.41M|   carry<26>(h0, h1);
  304|       |   /* |h0| <= 2^25; from now on fits into int32 unchanged */
  305|       |   /* |h1| <= 1.01*2^24 */
  306|       |
  307|  4.41M|   return Ed25519_FieldElement(h0, h1, h2, h3, h4, h5, h6, h7, h8, h9);
  308|  4.41M|}
_ZNK5Botan20Ed25519_FieldElement8sqr_iterEm:
  326|  2.35M|Ed25519_FieldElement Ed25519_FieldElement::sqr_iter(size_t iter) const {
  327|  2.35M|   int32_t f0 = m_fe[0];
  328|  2.35M|   int32_t f1 = m_fe[1];
  329|  2.35M|   int32_t f2 = m_fe[2];
  330|  2.35M|   int32_t f3 = m_fe[3];
  331|  2.35M|   int32_t f4 = m_fe[4];
  332|  2.35M|   int32_t f5 = m_fe[5];
  333|  2.35M|   int32_t f6 = m_fe[6];
  334|  2.35M|   int32_t f7 = m_fe[7];
  335|  2.35M|   int32_t f8 = m_fe[8];
  336|  2.35M|   int32_t f9 = m_fe[9];
  337|       |
  338|  6.17M|   for(size_t i = 0; i != iter; ++i) {
  ------------------
  |  Branch (338:22): [True: 3.82M, False: 2.35M]
  ------------------
  339|  3.82M|      const int32_t f0_2 = 2 * f0;
  340|  3.82M|      const int32_t f1_2 = 2 * f1;
  341|  3.82M|      const int32_t f2_2 = 2 * f2;
  342|  3.82M|      const int32_t f3_2 = 2 * f3;
  343|  3.82M|      const int32_t f4_2 = 2 * f4;
  344|  3.82M|      const int32_t f5_2 = 2 * f5;
  345|  3.82M|      const int32_t f6_2 = 2 * f6;
  346|  3.82M|      const int32_t f7_2 = 2 * f7;
  347|  3.82M|      const int32_t f5_38 = 38 * f5; /* 1.959375*2^30 */
  348|  3.82M|      const int32_t f6_19 = 19 * f6; /* 1.959375*2^30 */
  349|  3.82M|      const int32_t f7_38 = 38 * f7; /* 1.959375*2^30 */
  350|  3.82M|      const int32_t f8_19 = 19 * f8; /* 1.959375*2^30 */
  351|  3.82M|      const int32_t f9_38 = 38 * f9; /* 1.959375*2^30 */
  352|       |
  353|  3.82M|      const int64_t f0f0 = f0 * static_cast<int64_t>(f0);
  354|  3.82M|      const int64_t f0f1_2 = f0_2 * static_cast<int64_t>(f1);
  355|  3.82M|      const int64_t f0f2_2 = f0_2 * static_cast<int64_t>(f2);
  356|  3.82M|      const int64_t f0f3_2 = f0_2 * static_cast<int64_t>(f3);
  357|  3.82M|      const int64_t f0f4_2 = f0_2 * static_cast<int64_t>(f4);
  358|  3.82M|      const int64_t f0f5_2 = f0_2 * static_cast<int64_t>(f5);
  359|  3.82M|      const int64_t f0f6_2 = f0_2 * static_cast<int64_t>(f6);
  360|  3.82M|      const int64_t f0f7_2 = f0_2 * static_cast<int64_t>(f7);
  361|  3.82M|      const int64_t f0f8_2 = f0_2 * static_cast<int64_t>(f8);
  362|  3.82M|      const int64_t f0f9_2 = f0_2 * static_cast<int64_t>(f9);
  363|  3.82M|      const int64_t f1f1_2 = f1_2 * static_cast<int64_t>(f1);
  364|  3.82M|      const int64_t f1f2_2 = f1_2 * static_cast<int64_t>(f2);
  365|  3.82M|      const int64_t f1f3_4 = f1_2 * static_cast<int64_t>(f3_2);
  366|  3.82M|      const int64_t f1f4_2 = f1_2 * static_cast<int64_t>(f4);
  367|  3.82M|      const int64_t f1f5_4 = f1_2 * static_cast<int64_t>(f5_2);
  368|  3.82M|      const int64_t f1f6_2 = f1_2 * static_cast<int64_t>(f6);
  369|  3.82M|      const int64_t f1f7_4 = f1_2 * static_cast<int64_t>(f7_2);
  370|  3.82M|      const int64_t f1f8_2 = f1_2 * static_cast<int64_t>(f8);
  371|  3.82M|      const int64_t f1f9_76 = f1_2 * static_cast<int64_t>(f9_38);
  372|  3.82M|      const int64_t f2f2 = f2 * static_cast<int64_t>(f2);
  373|  3.82M|      const int64_t f2f3_2 = f2_2 * static_cast<int64_t>(f3);
  374|  3.82M|      const int64_t f2f4_2 = f2_2 * static_cast<int64_t>(f4);
  375|  3.82M|      const int64_t f2f5_2 = f2_2 * static_cast<int64_t>(f5);
  376|  3.82M|      const int64_t f2f6_2 = f2_2 * static_cast<int64_t>(f6);
  377|  3.82M|      const int64_t f2f7_2 = f2_2 * static_cast<int64_t>(f7);
  378|  3.82M|      const int64_t f2f8_38 = f2_2 * static_cast<int64_t>(f8_19);
  379|  3.82M|      const int64_t f2f9_38 = f2 * static_cast<int64_t>(f9_38);
  380|  3.82M|      const int64_t f3f3_2 = f3_2 * static_cast<int64_t>(f3);
  381|  3.82M|      const int64_t f3f4_2 = f3_2 * static_cast<int64_t>(f4);
  382|  3.82M|      const int64_t f3f5_4 = f3_2 * static_cast<int64_t>(f5_2);
  383|  3.82M|      const int64_t f3f6_2 = f3_2 * static_cast<int64_t>(f6);
  384|  3.82M|      const int64_t f3f7_76 = f3_2 * static_cast<int64_t>(f7_38);
  385|  3.82M|      const int64_t f3f8_38 = f3_2 * static_cast<int64_t>(f8_19);
  386|  3.82M|      const int64_t f3f9_76 = f3_2 * static_cast<int64_t>(f9_38);
  387|  3.82M|      const int64_t f4f4 = f4 * static_cast<int64_t>(f4);
  388|  3.82M|      const int64_t f4f5_2 = f4_2 * static_cast<int64_t>(f5);
  389|  3.82M|      const int64_t f4f6_38 = f4_2 * static_cast<int64_t>(f6_19);
  390|  3.82M|      const int64_t f4f7_38 = f4 * static_cast<int64_t>(f7_38);
  391|  3.82M|      const int64_t f4f8_38 = f4_2 * static_cast<int64_t>(f8_19);
  392|  3.82M|      const int64_t f4f9_38 = f4 * static_cast<int64_t>(f9_38);
  393|  3.82M|      const int64_t f5f5_38 = f5 * static_cast<int64_t>(f5_38);
  394|  3.82M|      const int64_t f5f6_38 = f5_2 * static_cast<int64_t>(f6_19);
  395|  3.82M|      const int64_t f5f7_76 = f5_2 * static_cast<int64_t>(f7_38);
  396|  3.82M|      const int64_t f5f8_38 = f5_2 * static_cast<int64_t>(f8_19);
  397|  3.82M|      const int64_t f5f9_76 = f5_2 * static_cast<int64_t>(f9_38);
  398|  3.82M|      const int64_t f6f6_19 = f6 * static_cast<int64_t>(f6_19);
  399|  3.82M|      const int64_t f6f7_38 = f6 * static_cast<int64_t>(f7_38);
  400|  3.82M|      const int64_t f6f8_38 = f6_2 * static_cast<int64_t>(f8_19);
  401|  3.82M|      const int64_t f6f9_38 = f6 * static_cast<int64_t>(f9_38);
  402|  3.82M|      const int64_t f7f7_38 = f7 * static_cast<int64_t>(f7_38);
  403|  3.82M|      const int64_t f7f8_38 = f7_2 * static_cast<int64_t>(f8_19);
  404|  3.82M|      const int64_t f7f9_76 = f7_2 * static_cast<int64_t>(f9_38);
  405|  3.82M|      const int64_t f8f8_19 = f8 * static_cast<int64_t>(f8_19);
  406|  3.82M|      const int64_t f8f9_38 = f8 * static_cast<int64_t>(f9_38);
  407|  3.82M|      const int64_t f9f9_38 = f9 * static_cast<int64_t>(f9_38);
  408|       |
  409|  3.82M|      int64_t h0 = f0f0 + f1f9_76 + f2f8_38 + f3f7_76 + f4f6_38 + f5f5_38;
  410|  3.82M|      int64_t h1 = f0f1_2 + f2f9_38 + f3f8_38 + f4f7_38 + f5f6_38;
  411|  3.82M|      int64_t h2 = f0f2_2 + f1f1_2 + f3f9_76 + f4f8_38 + f5f7_76 + f6f6_19;
  412|  3.82M|      int64_t h3 = f0f3_2 + f1f2_2 + f4f9_38 + f5f8_38 + f6f7_38;
  413|  3.82M|      int64_t h4 = f0f4_2 + f1f3_4 + f2f2 + f5f9_76 + f6f8_38 + f7f7_38;
  414|  3.82M|      int64_t h5 = f0f5_2 + f1f4_2 + f2f3_2 + f6f9_38 + f7f8_38;
  415|  3.82M|      int64_t h6 = f0f6_2 + f1f5_4 + f2f4_2 + f3f3_2 + f7f9_76 + f8f8_19;
  416|  3.82M|      int64_t h7 = f0f7_2 + f1f6_2 + f2f5_2 + f3f4_2 + f8f9_38;
  417|  3.82M|      int64_t h8 = f0f8_2 + f1f7_4 + f2f6_2 + f3f5_4 + f4f4 + f9f9_38;
  418|  3.82M|      int64_t h9 = f0f9_2 + f1f8_2 + f2f7_2 + f3f6_2 + f4f5_2;
  419|       |
  420|  3.82M|      carry<26>(h0, h1);
  421|  3.82M|      carry<26>(h4, h5);
  422|  3.82M|      carry<25>(h1, h2);
  423|  3.82M|      carry<25>(h5, h6);
  424|  3.82M|      carry<26>(h2, h3);
  425|  3.82M|      carry<26>(h6, h7);
  426|       |
  427|  3.82M|      carry<25>(h3, h4);
  428|  3.82M|      carry<25>(h7, h8);
  429|       |
  430|  3.82M|      carry<26>(h4, h5);
  431|  3.82M|      carry<26>(h8, h9);
  432|  3.82M|      carry<25, 19>(h9, h0);
  433|  3.82M|      carry<26>(h0, h1);
  434|       |
  435|  3.82M|      f0 = static_cast<int32_t>(h0);
  436|  3.82M|      f1 = static_cast<int32_t>(h1);
  437|  3.82M|      f2 = static_cast<int32_t>(h2);
  438|  3.82M|      f3 = static_cast<int32_t>(h3);
  439|  3.82M|      f4 = static_cast<int32_t>(h4);
  440|  3.82M|      f5 = static_cast<int32_t>(h5);
  441|  3.82M|      f6 = static_cast<int32_t>(h6);
  442|  3.82M|      f7 = static_cast<int32_t>(h7);
  443|  3.82M|      f8 = static_cast<int32_t>(h8);
  444|  3.82M|      f9 = static_cast<int32_t>(h9);
  445|  3.82M|   }
  446|       |
  447|  2.35M|   return Ed25519_FieldElement(f0, f1, f2, f3, f4, f5, f6, f7, f8, f9);
  448|  2.35M|}
_ZNK5Botan20Ed25519_FieldElement4sqr2Ev:
  466|   759k|Ed25519_FieldElement Ed25519_FieldElement::sqr2() const {
  467|   759k|   const int32_t f0 = m_fe[0];
  468|   759k|   const int32_t f1 = m_fe[1];
  469|   759k|   const int32_t f2 = m_fe[2];
  470|   759k|   const int32_t f3 = m_fe[3];
  471|   759k|   const int32_t f4 = m_fe[4];
  472|   759k|   const int32_t f5 = m_fe[5];
  473|   759k|   const int32_t f6 = m_fe[6];
  474|   759k|   const int32_t f7 = m_fe[7];
  475|   759k|   const int32_t f8 = m_fe[8];
  476|   759k|   const int32_t f9 = m_fe[9];
  477|       |
  478|   759k|   const int32_t f0_2 = 2 * f0;
  479|   759k|   const int32_t f1_2 = 2 * f1;
  480|   759k|   const int32_t f2_2 = 2 * f2;
  481|   759k|   const int32_t f3_2 = 2 * f3;
  482|   759k|   const int32_t f4_2 = 2 * f4;
  483|   759k|   const int32_t f5_2 = 2 * f5;
  484|   759k|   const int32_t f6_2 = 2 * f6;
  485|   759k|   const int32_t f7_2 = 2 * f7;
  486|   759k|   const int32_t f5_38 = 38 * f5; /* 1.959375*2^30 */
  487|   759k|   const int32_t f6_19 = 19 * f6; /* 1.959375*2^30 */
  488|   759k|   const int32_t f7_38 = 38 * f7; /* 1.959375*2^30 */
  489|   759k|   const int32_t f8_19 = 19 * f8; /* 1.959375*2^30 */
  490|   759k|   const int32_t f9_38 = 38 * f9; /* 1.959375*2^30 */
  491|   759k|   const int64_t f0f0 = f0 * static_cast<int64_t>(f0);
  492|   759k|   const int64_t f0f1_2 = f0_2 * static_cast<int64_t>(f1);
  493|   759k|   const int64_t f0f2_2 = f0_2 * static_cast<int64_t>(f2);
  494|   759k|   const int64_t f0f3_2 = f0_2 * static_cast<int64_t>(f3);
  495|   759k|   const int64_t f0f4_2 = f0_2 * static_cast<int64_t>(f4);
  496|   759k|   const int64_t f0f5_2 = f0_2 * static_cast<int64_t>(f5);
  497|   759k|   const int64_t f0f6_2 = f0_2 * static_cast<int64_t>(f6);
  498|   759k|   const int64_t f0f7_2 = f0_2 * static_cast<int64_t>(f7);
  499|   759k|   const int64_t f0f8_2 = f0_2 * static_cast<int64_t>(f8);
  500|   759k|   const int64_t f0f9_2 = f0_2 * static_cast<int64_t>(f9);
  501|   759k|   const int64_t f1f1_2 = f1_2 * static_cast<int64_t>(f1);
  502|   759k|   const int64_t f1f2_2 = f1_2 * static_cast<int64_t>(f2);
  503|   759k|   const int64_t f1f3_4 = f1_2 * static_cast<int64_t>(f3_2);
  504|   759k|   const int64_t f1f4_2 = f1_2 * static_cast<int64_t>(f4);
  505|   759k|   const int64_t f1f5_4 = f1_2 * static_cast<int64_t>(f5_2);
  506|   759k|   const int64_t f1f6_2 = f1_2 * static_cast<int64_t>(f6);
  507|   759k|   const int64_t f1f7_4 = f1_2 * static_cast<int64_t>(f7_2);
  508|   759k|   const int64_t f1f8_2 = f1_2 * static_cast<int64_t>(f8);
  509|   759k|   const int64_t f1f9_76 = f1_2 * static_cast<int64_t>(f9_38);
  510|   759k|   const int64_t f2f2 = f2 * static_cast<int64_t>(f2);
  511|   759k|   const int64_t f2f3_2 = f2_2 * static_cast<int64_t>(f3);
  512|   759k|   const int64_t f2f4_2 = f2_2 * static_cast<int64_t>(f4);
  513|   759k|   const int64_t f2f5_2 = f2_2 * static_cast<int64_t>(f5);
  514|   759k|   const int64_t f2f6_2 = f2_2 * static_cast<int64_t>(f6);
  515|   759k|   const int64_t f2f7_2 = f2_2 * static_cast<int64_t>(f7);
  516|   759k|   const int64_t f2f8_38 = f2_2 * static_cast<int64_t>(f8_19);
  517|   759k|   const int64_t f2f9_38 = f2 * static_cast<int64_t>(f9_38);
  518|   759k|   const int64_t f3f3_2 = f3_2 * static_cast<int64_t>(f3);
  519|   759k|   const int64_t f3f4_2 = f3_2 * static_cast<int64_t>(f4);
  520|   759k|   const int64_t f3f5_4 = f3_2 * static_cast<int64_t>(f5_2);
  521|   759k|   const int64_t f3f6_2 = f3_2 * static_cast<int64_t>(f6);
  522|   759k|   const int64_t f3f7_76 = f3_2 * static_cast<int64_t>(f7_38);
  523|   759k|   const int64_t f3f8_38 = f3_2 * static_cast<int64_t>(f8_19);
  524|   759k|   const int64_t f3f9_76 = f3_2 * static_cast<int64_t>(f9_38);
  525|   759k|   const int64_t f4f4 = f4 * static_cast<int64_t>(f4);
  526|   759k|   const int64_t f4f5_2 = f4_2 * static_cast<int64_t>(f5);
  527|   759k|   const int64_t f4f6_38 = f4_2 * static_cast<int64_t>(f6_19);
  528|   759k|   const int64_t f4f7_38 = f4 * static_cast<int64_t>(f7_38);
  529|   759k|   const int64_t f4f8_38 = f4_2 * static_cast<int64_t>(f8_19);
  530|   759k|   const int64_t f4f9_38 = f4 * static_cast<int64_t>(f9_38);
  531|   759k|   const int64_t f5f5_38 = f5 * static_cast<int64_t>(f5_38);
  532|   759k|   const int64_t f5f6_38 = f5_2 * static_cast<int64_t>(f6_19);
  533|   759k|   const int64_t f5f7_76 = f5_2 * static_cast<int64_t>(f7_38);
  534|   759k|   const int64_t f5f8_38 = f5_2 * static_cast<int64_t>(f8_19);
  535|   759k|   const int64_t f5f9_76 = f5_2 * static_cast<int64_t>(f9_38);
  536|   759k|   const int64_t f6f6_19 = f6 * static_cast<int64_t>(f6_19);
  537|   759k|   const int64_t f6f7_38 = f6 * static_cast<int64_t>(f7_38);
  538|   759k|   const int64_t f6f8_38 = f6_2 * static_cast<int64_t>(f8_19);
  539|   759k|   const int64_t f6f9_38 = f6 * static_cast<int64_t>(f9_38);
  540|   759k|   const int64_t f7f7_38 = f7 * static_cast<int64_t>(f7_38);
  541|   759k|   const int64_t f7f8_38 = f7_2 * static_cast<int64_t>(f8_19);
  542|   759k|   const int64_t f7f9_76 = f7_2 * static_cast<int64_t>(f9_38);
  543|   759k|   const int64_t f8f8_19 = f8 * static_cast<int64_t>(f8_19);
  544|   759k|   const int64_t f8f9_38 = f8 * static_cast<int64_t>(f9_38);
  545|   759k|   const int64_t f9f9_38 = f9 * static_cast<int64_t>(f9_38);
  546|       |
  547|   759k|   int64_t h0 = f0f0 + f1f9_76 + f2f8_38 + f3f7_76 + f4f6_38 + f5f5_38;
  548|   759k|   int64_t h1 = f0f1_2 + f2f9_38 + f3f8_38 + f4f7_38 + f5f6_38;
  549|   759k|   int64_t h2 = f0f2_2 + f1f1_2 + f3f9_76 + f4f8_38 + f5f7_76 + f6f6_19;
  550|   759k|   int64_t h3 = f0f3_2 + f1f2_2 + f4f9_38 + f5f8_38 + f6f7_38;
  551|   759k|   int64_t h4 = f0f4_2 + f1f3_4 + f2f2 + f5f9_76 + f6f8_38 + f7f7_38;
  552|   759k|   int64_t h5 = f0f5_2 + f1f4_2 + f2f3_2 + f6f9_38 + f7f8_38;
  553|   759k|   int64_t h6 = f0f6_2 + f1f5_4 + f2f4_2 + f3f3_2 + f7f9_76 + f8f8_19;
  554|   759k|   int64_t h7 = f0f7_2 + f1f6_2 + f2f5_2 + f3f4_2 + f8f9_38;
  555|   759k|   int64_t h8 = f0f8_2 + f1f7_4 + f2f6_2 + f3f5_4 + f4f4 + f9f9_38;
  556|   759k|   int64_t h9 = f0f9_2 + f1f8_2 + f2f7_2 + f3f6_2 + f4f5_2;
  557|       |
  558|   759k|   h0 += h0;
  559|   759k|   h1 += h1;
  560|   759k|   h2 += h2;
  561|   759k|   h3 += h3;
  562|   759k|   h4 += h4;
  563|   759k|   h5 += h5;
  564|   759k|   h6 += h6;
  565|   759k|   h7 += h7;
  566|   759k|   h8 += h8;
  567|   759k|   h9 += h9;
  568|       |
  569|   759k|   carry<26>(h0, h1);
  570|   759k|   carry<26>(h4, h5);
  571|       |
  572|   759k|   carry<25>(h1, h2);
  573|   759k|   carry<25>(h5, h6);
  574|       |
  575|   759k|   carry<26>(h2, h3);
  576|   759k|   carry<26>(h6, h7);
  577|       |
  578|   759k|   carry<25>(h3, h4);
  579|   759k|   carry<25>(h7, h8);
  580|   759k|   carry<26>(h4, h5);
  581|   759k|   carry<26>(h8, h9);
  582|   759k|   carry<25, 19>(h9, h0);
  583|   759k|   carry<26>(h0, h1);
  584|       |
  585|   759k|   return Ed25519_FieldElement(h0, h1, h2, h3, h4, h5, h6, h7, h8, h9);
  586|   759k|}
_ZN5Botan20Ed25519_FieldElement11deserializeEPKh:
  591|  3.03k|Ed25519_FieldElement Ed25519_FieldElement::deserialize(const uint8_t s[32]) {
  592|  3.03k|   int64_t h0 = load_4(s);
  593|  3.03k|   int64_t h1 = load_3(s + 4) << 6;
  594|  3.03k|   int64_t h2 = load_3(s + 7) << 5;
  595|  3.03k|   int64_t h3 = load_3(s + 10) << 3;
  596|  3.03k|   int64_t h4 = load_3(s + 13) << 2;
  597|  3.03k|   int64_t h5 = load_4(s + 16);
  598|  3.03k|   int64_t h6 = load_3(s + 20) << 7;
  599|  3.03k|   int64_t h7 = load_3(s + 23) << 5;
  600|  3.03k|   int64_t h8 = load_3(s + 26) << 4;
  601|  3.03k|   int64_t h9 = (load_3(s + 29) & 0x7fffff) << 2;
  602|       |
  603|  3.03k|   carry<25, 19>(h9, h0);
  604|  3.03k|   carry<25>(h1, h2);
  605|  3.03k|   carry<25>(h3, h4);
  606|  3.03k|   carry<25>(h5, h6);
  607|  3.03k|   carry<25>(h7, h8);
  608|       |
  609|  3.03k|   carry<26>(h0, h1);
  610|  3.03k|   carry<26>(h2, h3);
  611|  3.03k|   carry<26>(h4, h5);
  612|  3.03k|   carry<26>(h6, h7);
  613|  3.03k|   carry<26>(h8, h9);
  614|       |
  615|  3.03k|   return Ed25519_FieldElement(h0, h1, h2, h3, h4, h5, h6, h7, h8, h9);
  616|  3.03k|}
_ZNK5Botan20Ed25519_FieldElement12serialize_toENSt3__14spanIhLm32EEE:
  643|  15.2k|void Ed25519_FieldElement::serialize_to(std::span<uint8_t, 32> s) const {
  644|  15.2k|   const int32_t X25 = (1 << 25);
  645|       |
  646|  15.2k|   int32_t h0 = m_fe[0];
  647|  15.2k|   int32_t h1 = m_fe[1];
  648|  15.2k|   int32_t h2 = m_fe[2];
  649|  15.2k|   int32_t h3 = m_fe[3];
  650|  15.2k|   int32_t h4 = m_fe[4];
  651|  15.2k|   int32_t h5 = m_fe[5];
  652|  15.2k|   int32_t h6 = m_fe[6];
  653|  15.2k|   int32_t h7 = m_fe[7];
  654|  15.2k|   int32_t h8 = m_fe[8];
  655|  15.2k|   int32_t h9 = m_fe[9];
  656|       |
  657|  15.2k|   int32_t q = (19 * h9 + ((static_cast<int32_t>(1) << 24))) >> 25;
  658|  15.2k|   q = (h0 + q) >> 26;
  659|  15.2k|   q = (h1 + q) >> 25;
  660|  15.2k|   q = (h2 + q) >> 26;
  661|  15.2k|   q = (h3 + q) >> 25;
  662|  15.2k|   q = (h4 + q) >> 26;
  663|  15.2k|   q = (h5 + q) >> 25;
  664|  15.2k|   q = (h6 + q) >> 26;
  665|  15.2k|   q = (h7 + q) >> 25;
  666|  15.2k|   q = (h8 + q) >> 26;
  667|  15.2k|   q = (h9 + q) >> 25;
  668|       |
  669|       |   /* Goal: Output h-(2^255-19)q, which is between 0 and 2^255-20. */
  670|  15.2k|   h0 += 19 * q;
  671|       |   /* Goal: Output h-2^255 q, which is between 0 and 2^255-20. */
  672|       |
  673|  15.2k|   carry0<26>(h0, h1);
  674|  15.2k|   carry0<25>(h1, h2);
  675|  15.2k|   carry0<26>(h2, h3);
  676|  15.2k|   carry0<25>(h3, h4);
  677|  15.2k|   carry0<26>(h4, h5);
  678|  15.2k|   carry0<25>(h5, h6);
  679|  15.2k|   carry0<26>(h6, h7);
  680|  15.2k|   carry0<25>(h7, h8);
  681|  15.2k|   carry0<26>(h8, h9);
  682|       |
  683|  15.2k|   const int32_t carry9 = h9 >> 25;
  684|  15.2k|   h9 -= carry9 * X25;
  685|       |   /* h10 = carry9 */
  686|       |
  687|       |   /*
  688|       |   Goal: Output h0+...+2^255 h10-2^255 q, which is between 0 and 2^255-20.
  689|       |   Have h0+...+2^230 h9 between 0 and 2^255-1;
  690|       |   evidently 2^255 h10-2^255 q = 0.
  691|       |   Goal: Output h0+...+2^230 h9.
  692|       |   */
  693|       |
  694|  15.2k|   s[0] = static_cast<uint8_t>(h0 >> 0);
  695|  15.2k|   s[1] = static_cast<uint8_t>(h0 >> 8);
  696|  15.2k|   s[2] = static_cast<uint8_t>(h0 >> 16);
  697|  15.2k|   s[3] = static_cast<uint8_t>((h0 >> 24) | (h1 << 2));
  698|  15.2k|   s[4] = static_cast<uint8_t>(h1 >> 6);
  699|  15.2k|   s[5] = static_cast<uint8_t>(h1 >> 14);
  700|  15.2k|   s[6] = static_cast<uint8_t>((h1 >> 22) | (h2 << 3));
  701|  15.2k|   s[7] = static_cast<uint8_t>(h2 >> 5);
  702|  15.2k|   s[8] = static_cast<uint8_t>(h2 >> 13);
  703|  15.2k|   s[9] = static_cast<uint8_t>((h2 >> 21) | (h3 << 5));
  704|  15.2k|   s[10] = static_cast<uint8_t>(h3 >> 3);
  705|  15.2k|   s[11] = static_cast<uint8_t>(h3 >> 11);
  706|  15.2k|   s[12] = static_cast<uint8_t>((h3 >> 19) | (h4 << 6));
  707|  15.2k|   s[13] = static_cast<uint8_t>(h4 >> 2);
  708|  15.2k|   s[14] = static_cast<uint8_t>(h4 >> 10);
  709|  15.2k|   s[15] = static_cast<uint8_t>(h4 >> 18);
  710|  15.2k|   s[16] = static_cast<uint8_t>(h5 >> 0);
  711|  15.2k|   s[17] = static_cast<uint8_t>(h5 >> 8);
  712|  15.2k|   s[18] = static_cast<uint8_t>(h5 >> 16);
  713|  15.2k|   s[19] = static_cast<uint8_t>((h5 >> 24) | (h6 << 1));
  714|  15.2k|   s[20] = static_cast<uint8_t>(h6 >> 7);
  715|  15.2k|   s[21] = static_cast<uint8_t>(h6 >> 15);
  716|  15.2k|   s[22] = static_cast<uint8_t>((h6 >> 23) | (h7 << 3));
  717|  15.2k|   s[23] = static_cast<uint8_t>(h7 >> 5);
  718|  15.2k|   s[24] = static_cast<uint8_t>(h7 >> 13);
  719|  15.2k|   s[25] = static_cast<uint8_t>((h7 >> 21) | (h8 << 4));
  720|  15.2k|   s[26] = static_cast<uint8_t>(h8 >> 4);
  721|  15.2k|   s[27] = static_cast<uint8_t>(h8 >> 12);
  722|  15.2k|   s[28] = static_cast<uint8_t>((h8 >> 20) | (h9 << 6));
  723|  15.2k|   s[29] = static_cast<uint8_t>(h9 >> 2);
  724|  15.2k|   s[30] = static_cast<uint8_t>(h9 >> 10);
  725|  15.2k|   s[31] = static_cast<uint8_t>(h9 >> 18);
  726|  15.2k|}

_ZN5Botan17Ed25519_PublicKeyC1EPKhm:
   98|  3.08k|Ed25519_PublicKey::Ed25519_PublicKey(const uint8_t pub_key[], size_t pub_len) {
   99|  3.08k|   if(pub_len != 32) {
  ------------------
  |  Branch (99:7): [True: 0, False: 3.08k]
  ------------------
  100|      0|      throw Decoding_Error("Invalid length for Ed25519 key");
  101|      0|   }
  102|  3.08k|   m_public = std::make_shared<const Ed25519_PublicKey_Data>(std::vector<uint8_t>(pub_key, pub_key + pub_len));
  103|  3.08k|}
_ZNK5Botan17Ed25519_PublicKey22create_verification_opENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  343|  3.08k|                                                                                std::string_view provider) const {
  344|  3.08k|   if(provider == "base" || provider.empty()) {
  ------------------
  |  Branch (344:7): [True: 0, False: 3.08k]
  |  Branch (344:29): [True: 3.08k, False: 0]
  ------------------
  345|  3.08k|      if(params.empty() || params == "Identity" || params == "Pure") {
  ------------------
  |  Branch (345:10): [True: 0, False: 3.08k]
  |  Branch (345:28): [True: 0, False: 3.08k]
  |  Branch (345:52): [True: 3.08k, False: 0]
  ------------------
  346|  3.08k|         return std::make_unique<Ed25519_Pure_Verify_Operation>(m_public);
  347|  3.08k|      } else if(params == "Ed25519ph") {
  ------------------
  |  Branch (347:17): [True: 0, False: 0]
  ------------------
  348|      0|         return std::make_unique<Ed25519_Hashed_Verify_Operation>(m_public, "SHA-512", true);
  349|      0|      } else {
  350|      0|         return std::make_unique<Ed25519_Hashed_Verify_Operation>(m_public, params, false);
  351|      0|      }
  352|  3.08k|   }
  353|      0|   throw Provider_Not_Found(algo_name(), provider);
  354|  3.08k|}
_ZNK5Botan22Ed25519_PublicKey_Data3keyEv:
   25|  3.08k|      const std::vector<uint8_t>& key() const { return m_key; }
_ZN5Botan22Ed25519_PublicKey_DataC2ENSt3__16vectorIhNS1_9allocatorIhEEEE:
   23|  3.08k|      explicit Ed25519_PublicKey_Data(std::vector<uint8_t> key) : m_key(std::move(key)) {}
ed25519_key.cpp:_ZN5Botan12_GLOBAL__N_129Ed25519_Pure_Verify_OperationC2ENSt3__110shared_ptrIKNS_22Ed25519_PublicKey_DataEEE:
  222|  3.08k|            m_key(std::move(key)) {}
ed25519_key.cpp:_ZN5Botan12_GLOBAL__N_129Ed25519_Pure_Verify_Operation6updateENSt3__14spanIKhLm18446744073709551615EEE:
  224|  3.08k|      void update(std::span<const uint8_t> msg) override { m_msg.insert(m_msg.end(), msg.begin(), msg.end()); }
ed25519_key.cpp:_ZN5Botan12_GLOBAL__N_129Ed25519_Pure_Verify_Operation18is_valid_signatureENSt3__14spanIKhLm18446744073709551615EEE:
  226|  3.08k|      bool is_valid_signature(std::span<const uint8_t> sig) override {
  227|  3.08k|         if(sig.size() != 64) {
  ------------------
  |  Branch (227:13): [True: 0, False: 3.08k]
  ------------------
  228|      0|            m_msg.clear();
  229|      0|            return false;
  230|      0|         }
  231|       |
  232|  3.08k|         const auto& key = m_key->key();
  233|  3.08k|         BOTAN_ASSERT_EQUAL(key.size(), 32, "Expected size");
  ------------------
  |  |   90|  3.08k|   do {                                                                                                \
  |  |   91|  3.08k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                                    \
  |  |   92|  3.08k|      if((expr1) != (expr2)) {                                                                         \
  |  |  ------------------
  |  |  |  Branch (92:10): [True: 0, False: 3.08k]
  |  |  ------------------
  |  |   93|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                                           \
  |  |   94|      0|         Botan::assertion_failure(#expr1 " == " #expr2, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   95|      0|      }                                                                                                \
  |  |   96|  3.08k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (96:12): [Folded, False: 3.08k]
  |  |  ------------------
  ------------------
  234|  3.08k|         const bool ok = ed25519_verify(m_msg.data(), m_msg.size(), sig.data(), key.data(), nullptr, 0);
  235|  3.08k|         m_msg.clear();
  236|  3.08k|         return ok;
  237|  3.08k|      }

_ZN5Botan15signature_checkENSt3__14spanIKhLm32EEEPS2_S4_S4_:
 1915|  3.03k|bool signature_check(std::span<const uint8_t, 32> pk, const uint8_t h[32], const uint8_t r[32], const uint8_t s[32]) {
 1916|  3.03k|   if(auto A = frombytes_negate_vartime(pk)) {
  ------------------
  |  Branch (1916:12): [True: 3.02k, False: 11]
  ------------------
 1917|  3.02k|      std::array<uint8_t, 32> rcheck{};
 1918|  3.02k|      ge_double_scalarmult_vartime(rcheck, h, *A, s);
 1919|  3.02k|      return CT::is_equal(rcheck.data(), r, 32).as_bool();
 1920|  3.02k|   }
 1921|     11|   return false;
 1922|  3.03k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_122Ed25519_Point_Extended8identityEv:
  109|  3.03k|      static constexpr Ed25519_Point_Extended identity() {
  110|  3.03k|         Ed25519_Point_Extended h;
  111|  3.03k|         h.X = Ed25519_FieldElement::zero();
  112|  3.03k|         h.Y = Ed25519_FieldElement::one();
  113|  3.03k|         h.Z = Ed25519_FieldElement::one();
  114|  3.03k|         h.T = Ed25519_FieldElement::zero();
  115|  3.03k|         return h;
  116|  3.03k|      }
ge.cpp:_ZN5Botan12_GLOBAL__N_122Ed25519_Point_Extended4fromERKNS0_23Ed25519_Point_CompletedE:
  129|   269k|      static Ed25519_Point_Extended from(const Ed25519_Point_Completed& p) {
  130|   269k|         Ed25519_Point_Extended r;
  131|   269k|         r.X = p.X * p.T;
  132|   269k|         r.Y = p.Y * p.Z;
  133|   269k|         r.Z = p.Z * p.T;
  134|   269k|         r.T = p.X * p.Y;
  135|   269k|         return r;
  136|   269k|      }
ge.cpp:_ZN5Botan12_GLOBAL__N_1plERKNS0_22Ed25519_Point_ExtendedERKNS0_19Ed25519_Point_NielsE:
  220|  60.7k|inline Ed25519_Point_Completed operator+(const Ed25519_Point_Extended& p, const Ed25519_Point_Niels& q) {
  221|  60.7k|   Ed25519_Point_Completed r;
  222|  60.7k|   r.X = p.Y + p.X;        // YpX1 = Y1+X1
  223|  60.7k|   r.Y = p.Y - p.X;        // YmX1 = Y1-X1
  224|  60.7k|   r.Z = r.X * q.yplusx;   // A = YpX1*ypx2
  225|  60.7k|   r.Y = r.Y * q.yminusx;  // B = YmX1*ymx2
  226|  60.7k|   r.T = q.xy2d * p.T;     // C = xy2d2*T1
  227|  60.7k|   auto t0 = p.Z + p.Z;    // D = 2*Z1
  228|  60.7k|   r.X = r.Z - r.Y;        // X3 = A-B
  229|  60.7k|   r.Y = r.Z + r.Y;        // Y3 = A+B
  230|  60.7k|   r.Z = t0 + r.T;         // Z3 = D+C
  231|  60.7k|   r.T = t0 - r.T;         // T3 = D-C
  232|  60.7k|   return r;
  233|  60.7k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_124Ed25519_Point_Projective4fromERKNS0_23Ed25519_Point_CompletedE:
   56|   756k|      static Ed25519_Point_Projective from(const Ed25519_Point_Completed& p) {
   57|   756k|         Ed25519_Point_Projective r;
   58|   756k|         r.X = p.X * p.T;
   59|   756k|         r.Y = p.Y * p.Z;
   60|   756k|         r.Z = p.Z * p.T;
   61|   756k|         return r;
   62|   756k|      }
ge.cpp:_ZNK5Botan12_GLOBAL__N_122Ed25519_Point_Extended3dblEv:
  118|  3.02k|      Ed25519_Point_Completed dbl() const {
  119|  3.02k|         Ed25519_Point_Projective q;
  120|  3.02k|         q.X = X;
  121|  3.02k|         q.Y = Y;
  122|  3.02k|         q.Z = Z;
  123|  3.02k|         return q.dbl();
  124|  3.02k|      }
ge.cpp:_ZNK5Botan12_GLOBAL__N_124Ed25519_Point_Projective3dblEv:
   83|   759k|Ed25519_Point_Completed Ed25519_Point_Projective::dbl() const {
   84|   759k|   Ed25519_Point_Completed r;
   85|   759k|   r.X = X.sqr();        // XX=X1^2
   86|   759k|   r.Z = Y.sqr();        // YY=Y1^2
   87|   759k|   r.T = Z.sqr2();       // B=2*Z1^2
   88|   759k|   r.Y = X + Y;          // A=X1+Y1
   89|   759k|   auto t0 = r.Y.sqr();  // AA=A^2
   90|   759k|   r.Y = r.Z + r.X;      // Y3=YY+XX
   91|   759k|   r.Z = r.Z - r.X;      // Z3=YY-XX
   92|   759k|   r.X = t0 - r.Y;       // X3=AA-Y3
   93|   759k|   r.T = r.T - r.Z;      // T3=B-Z3
   94|   759k|   return r;
   95|   759k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_124frombytes_negate_vartimeENSt3__14spanIKhLm32EEE:
  305|  3.03k|std::optional<Ed25519_Point_Extended> frombytes_negate_vartime(std::span<const uint8_t, 32> s) {
  306|  3.03k|   static constexpr Ed25519_FieldElement d = {
  307|  3.03k|      -10913610, 13857413, -15372611, 6949391, 114729, -8787816, -6275908, -3247719, -18696448, -12055116};
  308|  3.03k|   static constexpr Ed25519_FieldElement sqrtm1 = {
  309|  3.03k|      -32595792, -7943725, 9377950, 3500415, 12389472, -272473, -25146209, -2005654, 326686, 11406482};
  310|       |
  311|  3.03k|   auto h = Ed25519_Point_Extended::identity();
  312|  3.03k|   h.Y = Ed25519_FieldElement::deserialize(s.data());
  313|  3.03k|   h.Z = Ed25519_FieldElement::one();
  314|  3.03k|   auto u = h.Y.sqr();
  315|  3.03k|   auto v = u * d;
  316|  3.03k|   u = u - h.Z; /* u = y^2-1 */
  317|  3.03k|   v = v + h.Z; /* v = dy^2+1 */
  318|       |
  319|  3.03k|   auto v3 = v.sqr() * v;
  320|  3.03k|   h.X = v3.sqr();
  321|  3.03k|   h.X = h.X * v;
  322|  3.03k|   h.X = h.X * u; /* x = uv^7 */
  323|       |
  324|  3.03k|   h.X = h.X.pow_22523();
  325|  3.03k|   h.X = h.X * v3;
  326|  3.03k|   h.X = h.X * u; /* x = uv^3(uv^7)^((q-5)/8) */
  327|       |
  328|  3.03k|   auto vxx = h.X.sqr();
  329|  3.03k|   vxx = vxx * v;
  330|  3.03k|   auto check = vxx - u; /* vx^2-u */
  331|  3.03k|   if(!check.is_zero()) {
  ------------------
  |  Branch (331:7): [True: 103, False: 2.93k]
  ------------------
  332|    103|      check = vxx + u; /* vx^2+u */
  333|    103|      if(!check.is_zero()) {
  ------------------
  |  Branch (333:10): [True: 11, False: 92]
  ------------------
  334|     11|         return {};
  335|     11|      }
  336|     92|      h.X = h.X * sqrtm1;
  337|     92|   }
  338|       |
  339|  3.02k|   if(h.X.is_negative() == bool(s[31] >> 7)) {
  ------------------
  |  Branch (339:7): [True: 76, False: 2.94k]
  ------------------
  340|     76|      h.X = -h.X;
  341|     76|   }
  342|       |
  343|       |   // RFC 8032 Section 5.1.3: "If x = 0, and x_0 = 1, decoding fails."
  344|       |   // x = 0 is invariant under the negation above, and x_0 is the encoded sign
  345|       |   // bit s[31] >> 7. This rejects the non-canonical identity encoding
  346|       |   // {0x01, 0x00 ..., 0x00, 0x80} during decoding, which otherwise decodes to
  347|       |   // the identity and slips past the canonical-only identity check in
  348|       |   // ed25519_verify(). (Ed25519_PublicKey::check_key() rejects this encoding
  349|       |   // separately, as it flips the sign bit before decoding.)
  350|  3.02k|   if(h.X.is_zero() && bool(s[31] >> 7)) {
  ------------------
  |  Branch (350:7): [True: 0, False: 3.02k]
  |  Branch (350:24): [True: 0, False: 0]
  ------------------
  351|      0|      return {};
  352|      0|   }
  353|       |
  354|  3.02k|   h.T = h.X * h.Y;
  355|  3.02k|   return h;
  356|  3.02k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_128ge_double_scalarmult_vartimeENSt3__14spanIhLm32EEEPKhRKNS0_22Ed25519_Point_ExtendedES5_:
  368|  3.02k|                                  const uint8_t* b) {
  369|  3.02k|   static constexpr Ed25519_Point_Niels Bi[8] = {
  370|  3.02k|      {
  371|  3.02k|         {25967493, -14356035, 29566456, 3660896, -12694345, 4014787, 27544626, -11754271, -6079156, 2047605},
  372|  3.02k|         {-12545711, 934262, -2722910, 3049990, -727428, 9406986, 12720692, 5043384, 19500929, -15469378},
  373|  3.02k|         {-8738181, 4489570, 9688441, -14785194, 10184609, -12363380, 29287919, 11864899, -24514362, -4438546},
  374|  3.02k|      },
  375|  3.02k|      {
  376|  3.02k|         {15636291, -9688557, 24204773, -7912398, 616977, -16685262, 27787600, -14772189, 28944400, -1550024},
  377|  3.02k|         {16568933, 4717097, -11556148, -1102322, 15682896, -11807043, 16354577, -11775962, 7689662, 11199574},
  378|  3.02k|         {30464156, -5976125, -11779434, -15670865, 23220365, 15915852, 7512774, 10017326, -17749093, -9920357},
  379|  3.02k|      },
  380|  3.02k|      {
  381|  3.02k|         {10861363, 11473154, 27284546, 1981175, -30064349, 12577861, 32867885, 14515107, -15438304, 10819380},
  382|  3.02k|         {4708026, 6336745, 20377586, 9066809, -11272109, 6594696, -25653668, 12483688, -12668491, 5581306},
  383|  3.02k|         {19563160, 16186464, -29386857, 4097519, 10237984, -4348115, 28542350, 13850243, -23678021, -15815942},
  384|  3.02k|      },
  385|  3.02k|      {
  386|  3.02k|         {5153746, 9909285, 1723747, -2777874, 30523605, 5516873, 19480852, 5230134, -23952439, -15175766},
  387|  3.02k|         {-30269007, -3463509, 7665486, 10083793, 28475525, 1649722, 20654025, 16520125, 30598449, 7715701},
  388|  3.02k|         {28881845, 14381568, 9657904, 3680757, -20181635, 7843316, -31400660, 1370708, 29794553, -1409300},
  389|  3.02k|      },
  390|  3.02k|      {
  391|  3.02k|         {-22518993, -6692182, 14201702, -8745502, -23510406, 8844726, 18474211, -1361450, -13062696, 13821877},
  392|  3.02k|         {-6455177, -7839871, 3374702, -4740862, -27098617, -10571707, 31655028, -7212327, 18853322, -14220951},
  393|  3.02k|         {4566830, -12963868, -28974889, -12240689, -7602672, -2830569, -8514358, -10431137, 2207753, -3209784},
  394|  3.02k|      },
  395|  3.02k|      {
  396|  3.02k|         {-25154831, -4185821, 29681144, 7868801, -6854661, -9423865, -12437364, -663000, -31111463, -16132436},
  397|  3.02k|         {25576264, -2703214, 7349804, -11814844, 16472782, 9300885, 3844789, 15725684, 171356, 6466918},
  398|  3.02k|         {23103977, 13316479, 9739013, -16149481, 817875, -15038942, 8965339, -14088058, -30714912, 16193877},
  399|  3.02k|      },
  400|  3.02k|      {
  401|  3.02k|         {-33521811, 3180713, -2394130, 14003687, -16903474, -16270840, 17238398, 4729455, -18074513, 9256800},
  402|  3.02k|         {-25182317, -4174131, 32336398, 5036987, -21236817, 11360617, 22616405, 9761698, -19827198, 630305},
  403|  3.02k|         {-13720693, 2639453, -24237460, -7406481, 9494427, -5774029, -6554551, -15960994, -2449256, -14291300},
  404|  3.02k|      },
  405|  3.02k|      {
  406|  3.02k|         {-3151181, -5046075, 9282714, 6866145, -31907062, -863023, -18940575, 15033784, 25105118, -7894876},
  407|  3.02k|         {-24326370, 15950226, -31801215, -14592823, -11662737, -5090925, 1573892, -2625887, 2198790, -15804619},
  408|  3.02k|         {-3099351, 10324967, -2241613, 7453183, -5446979, -2735503, -13812022, -16236442, -32461234, -12290683},
  409|  3.02k|      },
  410|  3.02k|   };
  411|       |
  412|  3.02k|   auto aslide = slide(a);
  413|  3.02k|   auto bslide = slide(b);
  414|       |
  415|  3.02k|   Ed25519_Point_Cached Ai[8]; /* A,3A,5A,7A,9A,11A,13A,15A */
  416|  3.02k|   Ai[0] = Ed25519_Point_Cached::from(A);
  417|  3.02k|   const auto A2 = Ed25519_Point_Extended::from(A.dbl());
  418|       |
  419|  24.2k|   for(size_t i = 1; i != 8; ++i) {
  ------------------
  |  Branch (419:22): [True: 21.1k, False: 3.02k]
  ------------------
  420|  21.1k|      Ai[i] = Ed25519_Point_Cached::from(A2 + Ai[i - 1]);
  421|  21.1k|   }
  422|       |
  423|  3.02k|   auto r = Ed25519_Point_Projective::identity();
  424|       |
  425|  3.02k|   int i = [&]() -> int {
  426|  3.02k|      int w = 255;
  427|  3.02k|      while(w >= 0) {
  428|  3.02k|         if(aslide[w] != 0 || bslide[w] != 0) {
  429|  3.02k|            return w;
  430|  3.02k|         } else {
  431|  3.02k|            w--;
  432|  3.02k|         }
  433|  3.02k|      }
  434|  3.02k|      return 0;
  435|  3.02k|   }();
  436|       |
  437|   759k|   for(; i >= 0; --i) {
  ------------------
  |  Branch (437:10): [True: 756k, False: 3.02k]
  ------------------
  438|   756k|      auto t = r.dbl();
  439|       |
  440|   756k|      if(aslide[i] > 0) {
  ------------------
  |  Branch (440:10): [True: 64.2k, False: 692k]
  ------------------
  441|  64.2k|         t = Ed25519_Point_Extended::from(t) + Ai[aslide[i] >> 1];
  442|   692k|      } else if(aslide[i] < 0) {
  ------------------
  |  Branch (442:17): [True: 63.4k, False: 628k]
  ------------------
  443|  63.4k|         t = Ed25519_Point_Extended::from(t) - Ai[(-aslide[i]) >> 1];
  444|  63.4k|      }
  445|       |
  446|   756k|      if(bslide[i] > 0) {
  ------------------
  |  Branch (446:10): [True: 60.7k, False: 695k]
  ------------------
  447|  60.7k|         t = Ed25519_Point_Extended::from(t) + Bi[bslide[i] >> 1];
  448|   695k|      } else if(bslide[i] < 0) {
  ------------------
  |  Branch (448:17): [True: 56.7k, False: 639k]
  ------------------
  449|  56.7k|         t = Ed25519_Point_Extended::from(t) - Bi[(-bslide[i]) >> 1];
  450|  56.7k|      }
  451|       |
  452|   756k|      r = Ed25519_Point_Projective::from(t);
  453|   756k|   }
  454|       |
  455|  3.02k|   r.serialize_to(std::span<uint8_t, 32>{out});
  456|  3.02k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_15slideEPKh:
  272|  6.05k|std::array<int8_t, 256> slide(const uint8_t* a) {
  273|  6.05k|   std::array<int8_t, 256> r{};
  274|  1.55M|   for(size_t i = 0; i < 256; ++i) {
  ------------------
  |  Branch (274:22): [True: 1.54M, False: 6.05k]
  ------------------
  275|  1.54M|      r[i] = 1 & (a[i >> 3] >> (i & 7));
  276|  1.54M|   }
  277|       |
  278|  1.55M|   for(size_t i = 0; i < 256; ++i) {
  ------------------
  |  Branch (278:22): [True: 1.54M, False: 6.05k]
  ------------------
  279|  1.54M|      if(r[i] != 0) {
  ------------------
  |  Branch (279:10): [True: 245k, False: 1.30M]
  ------------------
  280|  1.43M|         for(size_t b = 1; b <= 6 && i + b < 256; ++b) {
  ------------------
  |  Branch (280:28): [True: 1.35M, False: 75.3k]
  |  Branch (280:38): [True: 1.35M, False: 1.03k]
  ------------------
  281|  1.35M|            if(r[i + b] != 0) {
  ------------------
  |  Branch (281:16): [True: 650k, False: 708k]
  ------------------
  282|   650k|               if(r[i] + (r[i + b] << b) <= 15) {
  ------------------
  |  Branch (282:19): [True: 361k, False: 288k]
  ------------------
  283|   361k|                  r[i] += r[i + b] << b;
  284|   361k|                  r[i + b] = 0;
  285|   361k|               } else if(r[i] - (r[i + b] << b) >= -15) {
  ------------------
  |  Branch (285:26): [True: 120k, False: 168k]
  ------------------
  286|   120k|                  r[i] -= r[i + b] << b;
  287|   380k|                  for(size_t k = i + b; k < 256; ++k) {
  ------------------
  |  Branch (287:41): [True: 380k, False: 0]
  ------------------
  288|   380k|                     if(r[k] == 0) {
  ------------------
  |  Branch (288:25): [True: 120k, False: 260k]
  ------------------
  289|   120k|                        r[k] = 1;
  290|   120k|                        break;
  291|   120k|                     }
  292|   260k|                     r[k] = 0;
  293|   260k|                  }
  294|   168k|               } else {
  295|   168k|                  break;
  296|   168k|               }
  297|   650k|            }
  298|  1.35M|         }
  299|   245k|      }
  300|  1.54M|   }
  301|       |
  302|  6.05k|   return r;
  303|  6.05k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_120Ed25519_Point_Cached4fromERKNS0_22Ed25519_Point_ExtendedE:
  179|  24.2k|      static Ed25519_Point_Cached from(const Ed25519_Point_Extended& p) {
  180|  24.2k|         static constexpr Ed25519_FieldElement d2 = {
  181|  24.2k|            -21827239, -5839606, -30745221, 13898782, 229458, 15978800, -12551817, -6495438, 29715968, 9444199};
  182|  24.2k|         Ed25519_Point_Cached r;
  183|  24.2k|         r.YplusX = p.Y + p.X;
  184|  24.2k|         r.YminusX = p.Y - p.X;
  185|  24.2k|         r.Z = p.Z;
  186|  24.2k|         r.T2d = p.T * d2;
  187|  24.2k|         return r;
  188|  24.2k|      }
ge.cpp:_ZN5Botan12_GLOBAL__N_120Ed25519_Point_Cached4fromERKNS0_23Ed25519_Point_CompletedE:
  193|  21.1k|      static Ed25519_Point_Cached from(const Ed25519_Point_Completed& p) {
  194|  21.1k|         return Ed25519_Point_Cached::from(Ed25519_Point_Extended::from(p));
  195|  21.1k|      }
ge.cpp:_ZN5Botan12_GLOBAL__N_1plERKNS0_22Ed25519_Point_ExtendedERKNS0_20Ed25519_Point_CachedE:
  201|  85.4k|inline Ed25519_Point_Completed operator+(const Ed25519_Point_Extended& p, const Ed25519_Point_Cached& q) {
  202|  85.4k|   Ed25519_Point_Completed r;
  203|  85.4k|   r.X = p.Y + p.X;        // YpX1 = Y1+X1
  204|  85.4k|   r.Y = p.Y - p.X;        // YmX1 = Y1-X1
  205|  85.4k|   r.Z = r.X * q.YplusX;   // A = YpX1*YpX2
  206|  85.4k|   r.Y = r.Y * q.YminusX;  // B = YmX1*YmX2
  207|  85.4k|   r.T = q.T2d * p.T;      // C = T2d2*T1
  208|  85.4k|   r.X = p.Z * q.Z;        // ZZ = Z1*Z2
  209|  85.4k|   auto t0 = r.X + r.X;    // D = 2*ZZ
  210|  85.4k|   r.X = r.Z - r.Y;        // X3 = A-B
  211|  85.4k|   r.Y = r.Z + r.Y;        // Y3 = A+B
  212|  85.4k|   r.Z = t0 + r.T;         // Z3 = D+C
  213|  85.4k|   r.T = t0 - r.T;         // T3 = D-C
  214|  85.4k|   return r;
  215|  85.4k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_124Ed25519_Point_Projective8identityEv:
   64|  3.02k|      static constexpr Ed25519_Point_Projective identity() {
   65|  3.02k|         Ed25519_Point_Projective h;
   66|  3.02k|         h.X = Ed25519_FieldElement::zero();
   67|  3.02k|         h.Y = Ed25519_FieldElement::one();
   68|  3.02k|         h.Z = Ed25519_FieldElement::one();
   69|  3.02k|         return h;
   70|  3.02k|      }
ge.cpp:_ZZN5Botan12_GLOBAL__N_128ge_double_scalarmult_vartimeENSt3__14spanIhLm32EEEPKhRKNS0_22Ed25519_Point_ExtendedES5_ENK3$_0clEv:
  425|  3.02k|   int i = [&]() -> int {
  426|  3.02k|      int w = 255;
  427|  20.8k|      while(w >= 0) {
  ------------------
  |  Branch (427:13): [True: 20.8k, False: 0]
  ------------------
  428|  20.8k|         if(aslide[w] != 0 || bslide[w] != 0) {
  ------------------
  |  Branch (428:13): [True: 2.78k, False: 18.0k]
  |  Branch (428:31): [True: 239, False: 17.8k]
  ------------------
  429|  3.02k|            return w;
  430|  17.8k|         } else {
  431|  17.8k|            w--;
  432|  17.8k|         }
  433|  20.8k|      }
  434|      0|      return 0;
  435|  3.02k|   }();
ge.cpp:_ZN5Botan12_GLOBAL__N_1miERKNS0_22Ed25519_Point_ExtendedERKNS0_20Ed25519_Point_CachedE:
  256|  63.4k|inline Ed25519_Point_Completed operator-(const Ed25519_Point_Extended& p, const Ed25519_Point_Cached& q) {
  257|  63.4k|   Ed25519_Point_Completed r;
  258|  63.4k|   r.X = p.Y + p.X;        // YpX1 = Y1+X1
  259|  63.4k|   r.Y = p.Y - p.X;        // YmX1 = Y1-X1
  260|  63.4k|   r.Z = r.X * q.YminusX;  // A = YpX1*YmX2
  261|  63.4k|   r.Y = r.Y * q.YplusX;   // B = YmX1*YpX2
  262|  63.4k|   r.T = q.T2d * p.T;      // C = T2d2*T1
  263|  63.4k|   r.X = p.Z * q.Z;        // ZZ = Z1*Z2
  264|  63.4k|   auto t0 = r.X + r.X;    // D = 2*ZZ
  265|  63.4k|   r.X = r.Z - r.Y;        // X3 = A-B
  266|  63.4k|   r.Y = r.Z + r.Y;        // Y3 = A+B
  267|  63.4k|   r.Z = t0 - r.T;         // Z3 = D-C
  268|  63.4k|   r.T = t0 + r.T;         // T3 = D+C
  269|  63.4k|   return r;
  270|  63.4k|}
ge.cpp:_ZN5Botan12_GLOBAL__N_1miERKNS0_22Ed25519_Point_ExtendedERKNS0_19Ed25519_Point_NielsE:
  238|  56.7k|inline Ed25519_Point_Completed operator-(const Ed25519_Point_Extended& p, const Ed25519_Point_Niels& q) {
  239|  56.7k|   Ed25519_Point_Completed r;
  240|  56.7k|   r.X = p.Y + p.X;        // YpX1 = Y1+X1
  241|  56.7k|   r.Y = p.Y - p.X;        // YmX1 = Y1-X1
  242|  56.7k|   r.Z = r.X * q.yminusx;  // A = YpX1*ymx2
  243|  56.7k|   r.Y = r.Y * q.yplusx;   // B = YmX1*ypx2
  244|  56.7k|   r.T = q.xy2d * p.T;     // C = xy2d2*T1
  245|  56.7k|   auto t0 = p.Z + p.Z;    // D = 2*Z1
  246|  56.7k|   r.X = r.Z - r.Y;        // X3 = A-B
  247|  56.7k|   r.Y = r.Z + r.Y;        // Y3 = A+B
  248|  56.7k|   r.Z = t0 - r.T;         // Z3 = D-C
  249|  56.7k|   r.T = t0 + r.T;         // T3 = D+C
  250|  56.7k|   return r;
  251|  56.7k|}
ge.cpp:_ZNK5Botan12_GLOBAL__N_124Ed25519_Point_Projective12serialize_toENSt3__14spanIhLm32EEE:
   72|  3.02k|      void serialize_to(std::span<uint8_t, 32> s) const {
   73|  3.02k|         auto recip = this->Z.invert();
   74|  3.02k|         auto x = this->X * recip;
   75|  3.02k|         auto y = this->Y * recip;
   76|  3.02k|         y.serialize_to(s);
   77|  3.02k|         s[31] ^= x.is_negative() ? 0x80 : 0x00;
  ------------------
  |  Branch (77:19): [True: 1.70k, False: 1.32k]
  ------------------
   78|  3.02k|      }

_ZN5Botan9sc_reduceEPh:
   25|  3.03k|void sc_reduce(uint8_t* s) {
   26|  3.03k|   const uint32_t MASK = 0x1fffff;
   27|       |
   28|  3.03k|   int64_t s0 = MASK & load_3(s);
   29|  3.03k|   int64_t s1 = MASK & (load_4(s + 2) >> 5);
   30|  3.03k|   int64_t s2 = MASK & (load_3(s + 5) >> 2);
   31|  3.03k|   int64_t s3 = MASK & (load_4(s + 7) >> 7);
   32|  3.03k|   int64_t s4 = MASK & (load_4(s + 10) >> 4);
   33|  3.03k|   int64_t s5 = MASK & (load_3(s + 13) >> 1);
   34|  3.03k|   int64_t s6 = MASK & (load_4(s + 15) >> 6);
   35|  3.03k|   int64_t s7 = MASK & (load_3(s + 18) >> 3);
   36|  3.03k|   int64_t s8 = MASK & load_3(s + 21);
   37|  3.03k|   int64_t s9 = MASK & (load_4(s + 23) >> 5);
   38|  3.03k|   int64_t s10 = MASK & (load_3(s + 26) >> 2);
   39|  3.03k|   int64_t s11 = MASK & (load_4(s + 28) >> 7);
   40|  3.03k|   int64_t s12 = MASK & (load_4(s + 31) >> 4);
   41|  3.03k|   int64_t s13 = MASK & (load_3(s + 34) >> 1);
   42|  3.03k|   int64_t s14 = MASK & (load_4(s + 36) >> 6);
   43|  3.03k|   int64_t s15 = MASK & (load_3(s + 39) >> 3);
   44|  3.03k|   int64_t s16 = MASK & load_3(s + 42);
   45|  3.03k|   int64_t s17 = MASK & (load_4(s + 44) >> 5);
   46|  3.03k|   int64_t s18 = MASK & (load_3(s + 47) >> 2);
   47|  3.03k|   int64_t s19 = MASK & (load_4(s + 49) >> 7);
   48|  3.03k|   int64_t s20 = MASK & (load_4(s + 52) >> 4);
   49|  3.03k|   int64_t s21 = MASK & (load_3(s + 55) >> 1);
   50|  3.03k|   int64_t s22 = MASK & (load_4(s + 57) >> 6);
   51|  3.03k|   int64_t s23 = (load_4(s + 60) >> 3);
   52|       |
   53|  3.03k|   redc_mul(s11, s12, s13, s14, s15, s16, s23);
   54|  3.03k|   redc_mul(s10, s11, s12, s13, s14, s15, s22);
   55|  3.03k|   redc_mul(s9, s10, s11, s12, s13, s14, s21);
   56|  3.03k|   redc_mul(s8, s9, s10, s11, s12, s13, s20);
   57|  3.03k|   redc_mul(s7, s8, s9, s10, s11, s12, s19);
   58|  3.03k|   redc_mul(s6, s7, s8, s9, s10, s11, s18);
   59|       |
   60|  3.03k|   carry<21>(s6, s7);
   61|  3.03k|   carry<21>(s8, s9);
   62|  3.03k|   carry<21>(s10, s11);
   63|  3.03k|   carry<21>(s12, s13);
   64|  3.03k|   carry<21>(s14, s15);
   65|  3.03k|   carry<21>(s16, s17);
   66|       |
   67|  3.03k|   carry<21>(s7, s8);
   68|  3.03k|   carry<21>(s9, s10);
   69|  3.03k|   carry<21>(s11, s12);
   70|  3.03k|   carry<21>(s13, s14);
   71|  3.03k|   carry<21>(s15, s16);
   72|       |
   73|  3.03k|   redc_mul(s5, s6, s7, s8, s9, s10, s17);
   74|  3.03k|   redc_mul(s4, s5, s6, s7, s8, s9, s16);
   75|  3.03k|   redc_mul(s3, s4, s5, s6, s7, s8, s15);
   76|  3.03k|   redc_mul(s2, s3, s4, s5, s6, s7, s14);
   77|  3.03k|   redc_mul(s1, s2, s3, s4, s5, s6, s13);
   78|  3.03k|   redc_mul(s0, s1, s2, s3, s4, s5, s12);
   79|       |
   80|  3.03k|   carry<21>(s0, s1);
   81|  3.03k|   carry<21>(s2, s3);
   82|  3.03k|   carry<21>(s4, s5);
   83|  3.03k|   carry<21>(s6, s7);
   84|  3.03k|   carry<21>(s8, s9);
   85|  3.03k|   carry<21>(s10, s11);
   86|       |
   87|  3.03k|   carry<21>(s1, s2);
   88|  3.03k|   carry<21>(s3, s4);
   89|  3.03k|   carry<21>(s5, s6);
   90|  3.03k|   carry<21>(s7, s8);
   91|  3.03k|   carry<21>(s9, s10);
   92|  3.03k|   carry<21>(s11, s12);
   93|       |
   94|  3.03k|   redc_mul(s0, s1, s2, s3, s4, s5, s12);
   95|       |
   96|  3.03k|   carry0<21>(s0, s1);
   97|  3.03k|   carry0<21>(s1, s2);
   98|  3.03k|   carry0<21>(s2, s3);
   99|  3.03k|   carry0<21>(s3, s4);
  100|  3.03k|   carry0<21>(s4, s5);
  101|  3.03k|   carry0<21>(s5, s6);
  102|  3.03k|   carry0<21>(s6, s7);
  103|  3.03k|   carry0<21>(s7, s8);
  104|  3.03k|   carry0<21>(s8, s9);
  105|  3.03k|   carry0<21>(s9, s10);
  106|  3.03k|   carry0<21>(s10, s11);
  107|  3.03k|   carry0<21>(s11, s12);
  108|       |
  109|  3.03k|   redc_mul(s0, s1, s2, s3, s4, s5, s12);
  110|       |
  111|  3.03k|   carry0<21>(s0, s1);
  112|  3.03k|   carry0<21>(s1, s2);
  113|  3.03k|   carry0<21>(s2, s3);
  114|  3.03k|   carry0<21>(s3, s4);
  115|  3.03k|   carry0<21>(s4, s5);
  116|  3.03k|   carry0<21>(s5, s6);
  117|  3.03k|   carry0<21>(s6, s7);
  118|  3.03k|   carry0<21>(s7, s8);
  119|  3.03k|   carry0<21>(s8, s9);
  120|  3.03k|   carry0<21>(s9, s10);
  121|  3.03k|   carry0<21>(s10, s11);
  122|  3.03k|   carry0<21>(s11, s12);
  123|       |
  124|  3.03k|   s[0] = static_cast<uint8_t>(s0 >> 0);
  125|  3.03k|   s[1] = static_cast<uint8_t>(s0 >> 8);
  126|  3.03k|   s[2] = static_cast<uint8_t>((s0 >> 16) | (s1 << 5));
  127|  3.03k|   s[3] = static_cast<uint8_t>(s1 >> 3);
  128|  3.03k|   s[4] = static_cast<uint8_t>(s1 >> 11);
  129|  3.03k|   s[5] = static_cast<uint8_t>((s1 >> 19) | (s2 << 2));
  130|  3.03k|   s[6] = static_cast<uint8_t>(s2 >> 6);
  131|  3.03k|   s[7] = static_cast<uint8_t>((s2 >> 14) | (s3 << 7));
  132|  3.03k|   s[8] = static_cast<uint8_t>(s3 >> 1);
  133|  3.03k|   s[9] = static_cast<uint8_t>(s3 >> 9);
  134|  3.03k|   s[10] = static_cast<uint8_t>((s3 >> 17) | (s4 << 4));
  135|  3.03k|   s[11] = static_cast<uint8_t>(s4 >> 4);
  136|  3.03k|   s[12] = static_cast<uint8_t>(s4 >> 12);
  137|  3.03k|   s[13] = static_cast<uint8_t>((s4 >> 20) | (s5 << 1));
  138|  3.03k|   s[14] = static_cast<uint8_t>(s5 >> 7);
  139|  3.03k|   s[15] = static_cast<uint8_t>((s5 >> 15) | (s6 << 6));
  140|  3.03k|   s[16] = static_cast<uint8_t>(s6 >> 2);
  141|  3.03k|   s[17] = static_cast<uint8_t>(s6 >> 10);
  142|  3.03k|   s[18] = static_cast<uint8_t>((s6 >> 18) | (s7 << 3));
  143|  3.03k|   s[19] = static_cast<uint8_t>(s7 >> 5);
  144|  3.03k|   s[20] = static_cast<uint8_t>(s7 >> 13);
  145|  3.03k|   s[21] = static_cast<uint8_t>(s8 >> 0);
  146|  3.03k|   s[22] = static_cast<uint8_t>(s8 >> 8);
  147|  3.03k|   s[23] = static_cast<uint8_t>((s8 >> 16) | (s9 << 5));
  148|  3.03k|   s[24] = static_cast<uint8_t>(s9 >> 3);
  149|  3.03k|   s[25] = static_cast<uint8_t>(s9 >> 11);
  150|  3.03k|   s[26] = static_cast<uint8_t>((s9 >> 19) | (s10 << 2));
  151|  3.03k|   s[27] = static_cast<uint8_t>(s10 >> 6);
  152|  3.03k|   s[28] = static_cast<uint8_t>((s10 >> 14) | (s11 << 7));
  153|  3.03k|   s[29] = static_cast<uint8_t>(s11 >> 1);
  154|  3.03k|   s[30] = static_cast<uint8_t>(s11 >> 9);
  155|  3.03k|   s[31] = static_cast<uint8_t>(s11 >> 17);
  156|  3.03k|}

_ZN5Botan17ElGamal_PublicKeyC1ERKNS_8DL_GroupERKNS_6BigIntE:
   19|     41|ElGamal_PublicKey::ElGamal_PublicKey(const DL_Group& group, const BigInt& y) {
   20|     41|   m_public_key = std::make_shared<DL_PublicKey>(group, y);
   21|     41|}
_ZNK5Botan17ElGamal_PublicKey20create_encryption_opERNS_21RandomNumberGeneratorENSt3__117basic_string_viewIcNS3_11char_traitsIcEEEES7_:
  220|     41|                                                                            std::string_view provider) const {
  221|     41|   if(provider == "base" || provider.empty()) {
  ------------------
  |  Branch (221:7): [True: 0, False: 41]
  |  Branch (221:29): [True: 41, False: 0]
  ------------------
  222|     41|      return std::make_unique<ElGamal_Encryption_Operation>(this->m_public_key, params);
  223|     41|   }
  224|      0|   throw Provider_Not_Found(algo_name(), provider);
  225|     41|}
elgamal.cpp:_ZN5Botan12_GLOBAL__N_128ElGamal_Encryption_OperationC2ERKNSt3__110shared_ptrIKNS_12DL_PublicKeyEEENS2_17basic_string_viewIcNS2_11char_traitsIcEEEE:
  112|     41|            PK_Ops::Encryption_with_Padding(padding), m_key(key) {
  113|     41|         const size_t powm_window = 4;
  114|     41|         m_monty_y_p = monty_precompute(m_key->group()._monty_params_p(), m_key->public_key(), powm_window);
  115|     41|      }
elgamal.cpp:_ZNK5Botan12_GLOBAL__N_128ElGamal_Encryption_Operation20max_ptext_input_bitsEv:
  119|     41|      size_t max_ptext_input_bits() const override { return m_key->group().p_bits() - 1; }
elgamal.cpp:_ZN5Botan12_GLOBAL__N_128ElGamal_Encryption_Operation11raw_encryptENSt3__14spanIKhLm18446744073709551615EEERNS_21RandomNumberGeneratorE:
  129|     41|                                                               RandomNumberGenerator& rng) {
  130|     41|   const BigInt m(ptext);
  131|       |
  132|     41|   const auto& group = m_key->group();
  133|       |
  134|     41|   if(m == 0 || m >= group.get_p()) {
  ------------------
  |  Branch (134:7): [True: 0, False: 41]
  |  Branch (134:17): [True: 0, False: 41]
  ------------------
  135|      0|      throw Invalid_Argument("ElGamal encryption: Message out of valid plaintext range");
  136|      0|   }
  137|       |
  138|       |   /*
  139|       |   Some weird PGP implementations generate keys using bad parameters
  140|       |   which result in easily breakable encryption if short exponents are
  141|       |   used during encryption. To avoid this problem, always use full size
  142|       |   exponents.
  143|       |
  144|       |   See https://eprint.iacr.org/2021/923
  145|       |   */
  146|     41|   const size_t k_bits = group.p_bits() - 1;
  147|     41|   const BigInt k(rng, k_bits, false);
  148|       |
  149|     41|   const BigInt a = group.power_g_p(k, k_bits);
  150|     41|   const BigInt b = group.multiply_mod_p(m, monty_execute(*m_monty_y_p, k, k_bits).value());
  151|       |
  152|     41|   const size_t p_bytes = group.p_bytes();
  153|     41|   std::vector<uint8_t> ctext(2 * p_bytes);
  154|     41|   BufferStuffer stuffer(ctext);
  155|     41|   a.serialize_to(stuffer.next(p_bytes));
  156|     41|   b.serialize_to(stuffer.next(p_bytes));
  157|     41|   return ctext;
  158|     41|}

_ZN5Botan6PK_Ops23Encryption_with_PaddingC2ENSt3__117basic_string_viewIcNS2_11char_traitsIcEEEE:
   31|     41|      m_padding(EncryptionPaddingScheme::create(padding)) {}
_ZN5Botan6PK_Ops23Encryption_with_PaddingD2Ev:
   33|     41|PK_Ops::Encryption_with_Padding::~Encryption_with_Padding() = default;
_ZN5Botan6PK_Ops23Encryption_with_Padding7encryptENSt3__14spanIKhLm18446744073709551615EEERNS_21RandomNumberGeneratorE:
   40|     41|                                                              RandomNumberGenerator& rng) {
   41|     41|   const size_t max_input_bits = max_ptext_input_bits();
   42|     41|   const size_t max_input_bytes = (max_input_bits + 7) / 8;
   43|     41|   BOTAN_ARG_CHECK(msg.size() <= max_input_bytes, "Plaintext too large");
  ------------------
  |  |   35|     41|   do {                                                          \
  |  |   36|     41|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|     41|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 41]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|     41|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 41]
  |  |  ------------------
  ------------------
   44|       |
   45|     41|   secure_vector<uint8_t> padded_ptext(max_input_bytes);
   46|     41|   const size_t written = m_padding->pad(padded_ptext, msg, max_input_bits, rng);
   47|     41|   return raw_encrypt(std::span{padded_ptext}.first(written), rng);
   48|     41|}
_ZN5Botan6PK_Ops22Verification_with_HashC2ENSt3__117basic_string_viewIcNS2_11char_traitsIcEEEE:
  162|  7.33k|      Verification(), m_hash(create_signature_hash(padding)) {}
_ZN5Botan6PK_Ops22Verification_with_HashD2Ev:
  164|  7.33k|PK_Ops::Verification_with_Hash::~Verification_with_Hash() = default;
_ZN5Botan6PK_Ops22Verification_with_Hash6updateENSt3__14spanIKhLm18446744073709551615EEE:
  199|  7.33k|void PK_Ops::Verification_with_Hash::update(std::span<const uint8_t> msg) {
  200|  7.33k|   m_hash->update(msg);
  201|  7.33k|}
_ZN5Botan6PK_Ops22Verification_with_Hash18is_valid_signatureENSt3__14spanIKhLm18446744073709551615EEE:
  203|  7.33k|bool PK_Ops::Verification_with_Hash::is_valid_signature(std::span<const uint8_t> sig) {
  204|  7.33k|   const std::vector<uint8_t> msg = m_hash->final_stdvec();
  205|  7.33k|   return verify(msg, sig);
  206|  7.33k|}
pk_ops.cpp:_ZN5Botan12_GLOBAL__N_121create_signature_hashENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  101|  7.33k|std::unique_ptr<HashFunction> create_signature_hash(std::string_view padding) {
  102|  7.33k|   if(auto hash = HashFunction::create(padding)) {
  ------------------
  |  Branch (102:12): [True: 0, False: 7.33k]
  ------------------
  103|      0|      return hash;
  104|      0|   }
  105|       |
  106|  7.33k|   const SCAN_Name req(padding);
  107|       |
  108|  7.33k|   if(req.algo_name() == "EMSA1" && req.arg_count() == 1) {
  ------------------
  |  Branch (108:7): [True: 0, False: 7.33k]
  |  Branch (108:37): [True: 0, False: 0]
  ------------------
  109|      0|      if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (109:15): [True: 0, False: 0]
  ------------------
  110|      0|         return hash;
  111|      0|      }
  112|      0|   }
  113|       |
  114|  7.33k|#if defined(BOTAN_HAS_RAW_HASH_FN)
  115|  7.33k|   if(req.algo_name() == "Raw") {
  ------------------
  |  Branch (115:7): [True: 7.33k, False: 0]
  ------------------
  116|  7.33k|      if(req.arg_count() == 0) {
  ------------------
  |  Branch (116:10): [True: 1.08k, False: 6.25k]
  ------------------
  117|  1.08k|         return std::make_unique<RawHashFunction>("Raw", 0);
  118|  1.08k|      }
  119|       |
  120|  6.25k|      if(req.arg_count() == 1) {
  ------------------
  |  Branch (120:10): [True: 6.25k, False: 0]
  ------------------
  121|  6.25k|         if(auto hash = HashFunction::create(req.arg(0))) {
  ------------------
  |  Branch (121:18): [True: 6.25k, False: 0]
  ------------------
  122|  6.25k|            return std::make_unique<RawHashFunction>(std::move(hash));
  123|  6.25k|         }
  124|  6.25k|      }
  125|  6.25k|   }
  126|      0|#endif
  127|       |
  128|      0|   throw Algorithm_Not_Found(padding);
  129|  7.33k|}

_ZN5Botan16PK_Encryptor_EMEC2ERKNS_10Public_KeyERNS_21RandomNumberGeneratorENSt3__117basic_string_viewIcNS6_11char_traitsIcEEEESA_:
   95|     41|                                   std::string_view provider) {
   96|     41|   m_op = key.create_encryption_op(rng, padding, provider);
   97|     41|   if(!m_op) {
  ------------------
  |  Branch (97:7): [True: 0, False: 41]
  ------------------
   98|      0|      throw Invalid_Argument(fmt("Key type {} does not support encryption", key.algo_name()));
   99|      0|   }
  100|     41|}
_ZN5Botan16PK_Encryptor_EMED2Ev:
  102|     41|PK_Encryptor_EME::~PK_Encryptor_EME() = default;
_ZNK5Botan16PK_Encryptor_EME3encEPKhmRNS_21RandomNumberGeneratorE:
  111|     41|std::vector<uint8_t> PK_Encryptor_EME::enc(const uint8_t ptext[], size_t len, RandomNumberGenerator& rng) const {
  112|     41|   return m_op->encrypt(std::span{ptext, len}, rng);
  113|     41|}
_ZN5Botan11PK_VerifierC2ERKNS_10Public_KeyENSt3__117basic_string_viewIcNS4_11char_traitsIcEEEENS_16Signature_FormatES8_:
  373|  10.7k|                         std::string_view provider) {
  374|  10.7k|   m_op = key.create_verification_op(padding, provider);
  375|  10.7k|   if(!m_op) {
  ------------------
  |  Branch (375:7): [True: 0, False: 10.7k]
  ------------------
  376|      0|      throw Invalid_Argument(fmt("Key type {} does not support signature verification", key.algo_name()));
  377|      0|   }
  378|       |
  379|  10.7k|   m_sig_format = format;
  380|  10.7k|   m_sig_element_size = key._signature_element_size_for_DER_encoding();
  381|       |
  382|  10.7k|   if(m_sig_format == Signature_Format::DerSequence) {
  ------------------
  |  Branch (382:7): [True: 0, False: 10.7k]
  ------------------
  383|      0|      BOTAN_ARG_CHECK(m_sig_element_size.has_value(), "This key does not support DER signatures");
  ------------------
  |  |   35|      0|   do {                                                          \
  |  |   36|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|      0|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  384|      0|   }
  385|  10.7k|}
_ZN5Botan11PK_VerifierD2Ev:
  399|  10.7k|PK_Verifier::~PK_Verifier() = default;
_ZN5Botan11PK_Verifier6updateEPKhm:
  424|  10.7k|void PK_Verifier::update(const uint8_t in[], size_t length) {
  425|  10.7k|   m_op->update({in, length});
  426|  10.7k|}
_ZN5Botan11PK_Verifier15check_signatureEPKhm:
  455|  10.7k|bool PK_Verifier::check_signature(const uint8_t sig[], size_t length) {
  456|  10.7k|   try {
  457|  10.7k|      if(m_sig_format == Signature_Format::Standard) {
  ------------------
  |  Branch (457:10): [True: 10.7k, False: 0]
  ------------------
  458|  10.7k|         return m_op->is_valid_signature({sig, length});
  459|  10.7k|      } else if(m_sig_format == Signature_Format::DerSequence) {
  ------------------
  |  Branch (459:17): [True: 0, False: 0]
  ------------------
  460|      0|         bool decoding_success = false;
  461|      0|         std::vector<uint8_t> real_sig;
  462|       |
  463|      0|         BOTAN_ASSERT_NOMSG(m_sig_element_size.has_value());
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
  464|       |
  465|      0|         try {
  466|      0|            real_sig = decode_der_signature_pair({sig, length}, m_sig_element_size.value());
  467|      0|            decoding_success = true;
  468|      0|         } catch(...) {}
  469|       |
  470|       |         // It is critical that is_valid_signature is called even if DER decoding failed, since
  471|       |         // that is what resets the internal state (message hashes, etc)
  472|      0|         const bool accept = m_op->is_valid_signature(real_sig);
  473|       |
  474|      0|         return accept && decoding_success;
  ------------------
  |  Branch (474:17): [True: 0, False: 0]
  |  Branch (474:27): [True: 0, False: 0]
  ------------------
  475|      0|      } else {
  476|      0|         throw Internal_Error("PK_Verifier: Invalid signature format enum");
  477|      0|      }
  478|  10.7k|   } catch(Invalid_Argument&) {
  479|      0|      return false;
  480|     19|   } catch(Decoding_Error&) {
  481|     19|      return false;
  482|     19|   } catch(Encoding_Error&) {
  483|      0|      return false;
  484|      0|   }
  485|  10.7k|}

_ZNK5Botan13RSA_PublicKey11public_dataEv:
  130|    348|std::shared_ptr<const RSA_Public_Data> RSA_PublicKey::public_data() const {
  131|    348|   return m_public;
  132|    348|}
_ZN5Botan13RSA_PublicKey4initEONS_6BigIntES2_:
  156|    429|void RSA_PublicKey::init(BigInt&& n, BigInt&& e) {
  157|    429|   if(n.signum() <= 0 || n.is_even() || n.bits() < 384 || n.bits() > 16384) {
  ------------------
  |  Branch (157:7): [True: 78, False: 351]
  |  Branch (157:26): [True: 3, False: 348]
  |  Branch (157:41): [True: 0, False: 348]
  |  Branch (157:59): [True: 0, False: 348]
  ------------------
  158|     81|      throw Decoding_Error("Invalid RSA public key modulus");
  159|     81|   }
  160|    348|   if(e.is_even() || e <= 1 || e >= n || e.bits() > 256) {
  ------------------
  |  Branch (160:7): [True: 0, False: 348]
  |  Branch (160:22): [True: 0, False: 348]
  |  Branch (160:32): [True: 0, False: 348]
  |  Branch (160:42): [True: 0, False: 348]
  ------------------
  161|      0|      throw Decoding_Error("Invalid RSA public key exponent");
  162|      0|   }
  163|    348|   m_public = std::make_shared<RSA_Public_Data>(std::move(n), std::move(e));
  164|    348|}
_ZN5Botan13RSA_PublicKeyC1ERKNS_6BigIntES3_:
  187|    429|RSA_PublicKey::RSA_PublicKey(const BigInt& modulus, const BigInt& exponent) {
  188|    429|   BigInt n = modulus;
  189|    429|   BigInt e = exponent;
  190|    429|   init(std::move(n), std::move(e));
  191|    429|}
_ZNK5Botan13RSA_PublicKey22create_verification_opENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
  866|    348|                                                                            std::string_view provider) const {
  867|    348|   if(provider == "base" || provider.empty()) {
  ------------------
  |  Branch (867:7): [True: 0, False: 348]
  |  Branch (867:29): [True: 348, False: 0]
  ------------------
  868|    348|      return std::make_unique<RSA_Verify_Operation>(*this, params);
  869|    348|   }
  870|       |
  871|      0|   throw Provider_Not_Found(algo_name(), provider);
  872|    348|}
_ZNK5Botan15RSA_Public_Data5get_nEv:
   51|    348|      const BigInt& get_n() const { return m_n; }
_ZNK5Botan15RSA_Public_Data19public_modulus_bitsEv:
   55|    329|      size_t public_modulus_bits() const { return m_public_modulus_bits; }
_ZN5Botan15RSA_Public_DataC2EONS_6BigIntES2_:
   38|    348|            m_n(std::move(n)),
   39|    348|            m_e(std::move(e)),
   40|    348|            m_mod_n(Barrett_Reduction::for_public_modulus(m_n)),
   41|    348|            m_monty_n(m_n, m_mod_n),
   42|    348|            m_public_modulus_bits(m_n.bits()),
   43|    348|            m_public_modulus_bytes(m_n.bytes()) {}
rsa.cpp:_ZN5Botan12_GLOBAL__N_120RSA_Public_OperationC2ERKNS_13RSA_PublicKeyE:
  755|    348|      explicit RSA_Public_Operation(const RSA_PublicKey& rsa) : m_public(rsa.public_data()) {}
rsa.cpp:_ZNK5Botan12_GLOBAL__N_120RSA_Public_Operation20public_modulus_bytesEv:
  768|    348|      size_t public_modulus_bytes() const { return m_public->public_modulus_bytes(); }
_ZNK5Botan15RSA_Public_Data20public_modulus_bytesEv:
   57|    348|      size_t public_modulus_bytes() const { return m_public_modulus_bytes; }
rsa.cpp:_ZNK5Botan12_GLOBAL__N_120RSA_Public_Operation19public_modulus_bitsEv:
  757|    329|      size_t public_modulus_bits() const { return m_public->public_modulus_bits(); }
rsa.cpp:_ZNK5Botan12_GLOBAL__N_120RSA_Public_Operation9public_opERKNS_6BigIntE:
  760|    348|      BigInt public_op(const BigInt& m) const {
  761|    348|         if(m >= m_public->get_n()) {
  ------------------
  |  Branch (761:13): [True: 19, False: 329]
  ------------------
  762|     19|            throw Decoding_Error("RSA public op - input is too large");
  763|     19|         }
  764|       |
  765|    329|         return m_public->public_op(m);
  766|    348|      }
_ZNK5Botan15RSA_Public_Data9public_opERKNS_6BigIntE:
   45|    329|      BigInt public_op(const BigInt& m) const {
   46|    329|         const size_t powm_window = 1;
   47|    329|         auto powm_m_n = monty_precompute(m_monty_n, m, powm_window, false);
   48|    329|         return monty_execute_vartime(*powm_m_n, m_e).value();
   49|    329|      }
rsa.cpp:_ZN5Botan12_GLOBAL__N_120RSA_Verify_OperationC2ERKNS_13RSA_PublicKeyENSt3__117basic_string_viewIcNS5_11char_traitsIcEEEE:
  804|    348|            RSA_Public_Operation(rsa), m_padding(SignaturePaddingScheme::create_or_throw(padding)) {}
rsa.cpp:_ZN5Botan12_GLOBAL__N_120RSA_Verify_Operation6updateENSt3__14spanIKhLm18446744073709551615EEE:
  795|    348|      void update(std::span<const uint8_t> msg) override { m_padding->update(msg.data(), msg.size()); }
rsa.cpp:_ZN5Botan12_GLOBAL__N_120RSA_Verify_Operation18is_valid_signatureENSt3__14spanIKhLm18446744073709551615EEE:
  797|    348|      bool is_valid_signature(std::span<const uint8_t> sig) override {
  798|    348|         const auto msg = m_padding->raw_data();
  799|    348|         const auto message_repr = recover_message_repr(sig.data(), sig.size());
  800|    348|         return m_padding->verify(message_repr, msg, public_modulus_bits() - 1);
  801|    348|      }
rsa.cpp:_ZN5Botan12_GLOBAL__N_120RSA_Verify_Operation20recover_message_reprEPKhm:
  809|    348|      std::vector<uint8_t> recover_message_repr(const uint8_t input[], size_t input_len) {
  810|       |         // RFC 8017 8.1.2 and 8.2.2 state
  811|       |         //    If the length of the signature S is not k octets,
  812|       |         //    output "invalid signature" and stop.
  813|       |         //
  814|    348|         if(input_len != public_modulus_bytes()) {
  ------------------
  |  Branch (814:13): [True: 0, False: 348]
  ------------------
  815|      0|            throw Decoding_Error("RSA signature is an incorrect size for this public key");
  816|      0|         }
  817|    348|         const BigInt input_bn(input, input_len);
  818|    348|         return public_op(input_bn).serialize();
  819|    348|      }

_ZN5Botan14if_work_factorEm:
   37|  1.12k|size_t if_work_factor(size_t bits) {
   38|  1.12k|   if(bits < 512) {
  ------------------
  |  Branch (38:7): [True: 0, False: 1.12k]
  ------------------
   39|      0|      return 0;
   40|      0|   }
   41|       |
   42|       |   // RFC 3766 estimates k at .02 and o(1) to be effectively zero for sizes of interest
   43|       |
   44|  1.12k|   const double log2_k = -5.6438;  // log2(.02)
   45|  1.12k|   return nfs_workfactor(bits, log2_k);
   46|  1.12k|}
_ZN5Botan14dl_work_factorEm:
   48|  1.12k|size_t dl_work_factor(size_t bits) {
   49|       |   // Lacking better estimates...
   50|  1.12k|   return if_work_factor(bits);
   51|  1.12k|}
_ZN5Botan16dl_exponent_sizeEm:
   53|  1.12k|size_t dl_exponent_size(size_t p_bits) {
   54|  1.12k|   BOTAN_ARG_CHECK(p_bits > 1, "Invalid prime length");
  ------------------
  |  |   35|  1.12k|   do {                                                          \
  |  |   36|  1.12k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  1.12k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 1.12k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  1.12k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 1.12k]
  |  |  ------------------
  ------------------
   55|       |
   56|       |   /*
   57|       |   For relevant sizes we follow the suggestions in
   58|       |   NIST SP 800-56B Rev 2 Appendix D
   59|       |   "Maximum Security Strength Estimates for IFC Modulus Lengths"
   60|       |
   61|       |   For sizes outside the range considered in the SP we use some sensible values
   62|       |
   63|       |   Note that we return twice the value given in Table 4 since we are choosing
   64|       |   the exponent size as twice the estimated security strength.
   65|       |
   66|       |   See also NIST SP 800-56A Rev 3 Appendix D, Tables 25 and 26
   67|       |   */
   68|       |
   69|  1.12k|   if(p_bits <= 256) {
  ------------------
  |  Branch (69:7): [True: 0, False: 1.12k]
  ------------------
   70|       |      /*
   71|       |      * For stupidly small groups we might return a value larger than the group
   72|       |      * size if we fell into the conditionals below. Just use the maximum
   73|       |      * possible exponent size - for all the good it will do you with a group
   74|       |      * this weak.
   75|       |      */
   76|      0|      return p_bits - 1;
   77|  1.12k|   } else if(p_bits <= 1024) {
  ------------------
  |  Branch (77:14): [True: 1.12k, False: 0]
  ------------------
   78|       |      /*
   79|       |      Not in the SP, but general estimates are that a 1024 bit group provides at
   80|       |      most 80 bits security, so using an exponent appropriate for 96 bit security
   81|       |      is more than sufficient.
   82|       |      */
   83|  1.12k|      return 192;
   84|  1.12k|   } else if(p_bits <= 2048) {
  ------------------
  |  Branch (84:14): [True: 0, False: 0]
  ------------------
   85|      0|      return 224;  // SP 800-56B
   86|      0|   } else if(p_bits <= 3072) {
  ------------------
  |  Branch (86:14): [True: 0, False: 0]
  ------------------
   87|      0|      return 256;  // SP 800-56B
   88|      0|   } else if(p_bits <= 4096) {
  ------------------
  |  Branch (88:14): [True: 0, False: 0]
  ------------------
   89|      0|      return 304;  // SP 800-56B
   90|      0|   } else if(p_bits <= 6144) {
  ------------------
  |  Branch (90:14): [True: 0, False: 0]
  ------------------
   91|      0|      return 352;  // SP 800-56B
   92|      0|   } else if(p_bits <= 8192) {
  ------------------
  |  Branch (92:14): [True: 0, False: 0]
  ------------------
   93|      0|      return 400;  // SP 800-56B
   94|      0|   } else {
   95|       |      // For values larger than we know about, just saturate to 256 bit security
   96|       |      // which is Good Enough for FFDH
   97|       |      //
   98|       |      // NIST puts 15360 bit groups at exactly 256 bits security
   99|      0|      return 512;
  100|      0|   }
  101|  1.12k|}
workfactor.cpp:_ZN5Botan12_GLOBAL__N_114nfs_workfactorEmd:
   22|  1.12k|size_t nfs_workfactor(size_t bits, double log2_k) {
   23|       |   // approximates natural logarithm of an integer of given bitsize
   24|  1.12k|   const double log_p = static_cast<double>(bits) / std::numbers::log2e;
   25|       |
   26|  1.12k|   const double log_log_p = std::log(log_p);
   27|       |
   28|       |   // RFC 3766: k * e^((1.92 + o(1)) * cubrt(ln(n) * (ln(ln(n)))^2))
   29|  1.12k|   const double est = 1.92 * std::pow(log_p * log_log_p * log_log_p, 1.0 / 3.0);
   30|       |
   31|       |   // return log2 of the workfactor
   32|  1.12k|   return static_cast<size_t>(log2_k + std::numbers::log2e * est);
   33|  1.12k|}

_ZN5Botan14AutoSeeded_RNGD2Ev:
   46|  12.7k|AutoSeeded_RNG::~AutoSeeded_RNG() = default;
_ZN5Botan14AutoSeeded_RNGC2Em:
   68|  12.7k|AutoSeeded_RNG::AutoSeeded_RNG(size_t reseed_interval) {
   69|  12.7k|#if defined(BOTAN_HAS_SYSTEM_RNG)
   70|  12.7k|   m_rng = std::make_unique<HMAC_DRBG>(auto_rng_hmac(), system_rng(), reseed_interval);
   71|       |#elif defined(BOTAN_HAS_ENTROPY_SOURCE)
   72|       |   m_rng = std::make_unique<HMAC_DRBG>(auto_rng_hmac(), Entropy_Sources::global_sources(), reseed_interval);
   73|       |#else
   74|       |   BOTAN_UNUSED(reseed_interval);
   75|       |   throw Not_Implemented("AutoSeeded_RNG default constructor not available due to no RNG or entropy sources");
   76|       |#endif
   77|       |
   78|  12.7k|   force_reseed();
   79|  12.7k|}
_ZN5Botan14AutoSeeded_RNG12force_reseedEv:
   81|  12.7k|void AutoSeeded_RNG::force_reseed() {
   82|  12.7k|   m_rng->force_reseed();
   83|  12.7k|   m_rng->next_byte();
   84|       |
   85|  12.7k|   if(!m_rng->is_seeded()) {
  ------------------
  |  Branch (85:7): [True: 0, False: 12.7k]
  ------------------
   86|      0|      throw Internal_Error("AutoSeeded_RNG reseeding failed");
   87|      0|   }
   88|  12.7k|}
_ZN5Botan14AutoSeeded_RNG21fill_bytes_with_inputENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEE:
  106|  30.4k|void AutoSeeded_RNG::fill_bytes_with_input(std::span<uint8_t> out, std::span<const uint8_t> in) {
  107|  30.4k|   if(out.empty() && in.empty()) {
  ------------------
  |  Branch (107:7): [True: 0, False: 30.4k]
  |  Branch (107:22): [True: 0, False: 0]
  ------------------
  108|      0|      return;
  109|  30.4k|   } else if(in.empty()) {
  ------------------
  |  Branch (109:14): [True: 30.4k, False: 0]
  ------------------
  110|  30.4k|      m_rng->randomize_with_ts_input(out);
  111|  30.4k|   } else {
  112|      0|      m_rng->randomize_with_input(out, in);
  113|      0|   }
  114|  30.4k|}
auto_rng.cpp:_ZN5Botan12_GLOBAL__N_113auto_rng_hmacEv:
   26|  12.7k|std::unique_ptr<MessageAuthenticationCode> auto_rng_hmac() {
   27|  12.7k|   const std::string possible_auto_rng_hmacs[] = {
   28|  12.7k|      "HMAC(SHA-512)",
   29|  12.7k|      "HMAC(SHA-256)",
   30|  12.7k|   };
   31|       |
   32|  12.7k|   for(const auto& hmac : possible_auto_rng_hmacs) {
  ------------------
  |  Branch (32:25): [True: 12.7k, False: 0]
  ------------------
   33|  12.7k|      if(auto mac = MessageAuthenticationCode::create(hmac)) {
  ------------------
  |  Branch (33:15): [True: 12.7k, False: 0]
  ------------------
   34|  12.7k|         return mac;
   35|  12.7k|      }
   36|  12.7k|   }
   37|       |
   38|       |   // This shouldn't happen since this module has a dependency on sha2_32
   39|      0|   throw Internal_Error("AutoSeeded_RNG: No usable HMAC hash found");
   40|  12.7k|}

_ZN5Botan9HMAC_DRBGD2Ev:
   60|  12.7k|HMAC_DRBG::~HMAC_DRBG() = default;
_ZN5Botan9HMAC_DRBGC2ENSt3__110unique_ptrINS_25MessageAuthenticationCodeENS1_14default_deleteIS3_EEEERNS_21RandomNumberGeneratorEmm:
   66|  12.7k|      Stateful_RNG(underlying_rng, reseed_interval),
   67|  12.7k|      m_mac(check_not_null(std::move(prf))),
   68|  12.7k|      m_max_number_of_bytes_per_request(max_number_of_bytes_per_request),
   69|  12.7k|      m_security_level(hmac_drbg_security_level(m_mac->output_length())) {
   70|  12.7k|   check_limits(reseed_interval, max_number_of_bytes_per_request);
   71|       |
   72|  12.7k|   clear();
   73|  12.7k|}
_ZN5Botan9HMAC_DRBG11clear_stateEv:
  116|  12.7k|void HMAC_DRBG::clear_state() {
  117|  12.7k|   if(m_V.empty()) {
  ------------------
  |  Branch (117:7): [True: 12.7k, False: 0]
  ------------------
  118|  12.7k|      const size_t output_length = m_mac->output_length();
  119|  12.7k|      m_V.resize(output_length);
  120|  12.7k|      m_T.resize(output_length);
  121|  12.7k|   }
  122|       |
  123|  12.7k|   std::fill(m_V.begin(), m_V.end(), 0x01);
  124|  12.7k|   m_mac->set_key(std::vector<uint8_t>(m_V.size(), 0x00));
  125|  12.7k|}
_ZN5Botan9HMAC_DRBG15generate_outputENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEE:
  135|  43.7k|void HMAC_DRBG::generate_output(std::span<uint8_t> output, std::span<const uint8_t> input) {
  136|       |   // This is an internal function, callers should have validated this beforehand
  137|  43.7k|   BOTAN_ASSERT_NOMSG(!output.empty());
  ------------------
  |  |   77|  43.7k|   do {                                                                     \
  |  |   78|  43.7k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  43.7k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 43.7k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  43.7k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 43.7k]
  |  |  ------------------
  ------------------
  138|       |
  139|  43.7k|   if(!input.empty()) {
  ------------------
  |  Branch (139:7): [True: 30.4k, False: 13.3k]
  ------------------
  140|  30.4k|      update(input);
  141|  30.4k|   }
  142|       |
  143|   868k|   while(!output.empty()) {
  ------------------
  |  Branch (143:10): [True: 824k, False: 43.7k]
  ------------------
  144|   824k|      const size_t to_copy = std::min(output.size(), m_V.size());
  145|   824k|      m_mac->update(m_V);
  146|   824k|      m_mac->final(m_V);
  147|   824k|      copy_mem(output.data(), m_V.data(), to_copy);
  148|       |
  149|   824k|      output = output.subspan(to_copy);
  150|   824k|   }
  151|       |
  152|  43.7k|   update(input);
  153|  43.7k|}
_ZN5Botan9HMAC_DRBG6updateENSt3__14spanIKhLm18446744073709551615EEE:
  159|  87.0k|void HMAC_DRBG::update(std::span<const uint8_t> input) {
  160|  87.0k|   m_mac->update(m_V);
  161|  87.0k|   m_mac->update(0x00);
  162|  87.0k|   if(!input.empty()) {
  ------------------
  |  Branch (162:7): [True: 73.6k, False: 13.3k]
  ------------------
  163|  73.6k|      m_mac->update(input);
  164|  73.6k|   }
  165|  87.0k|   m_mac->final(m_T);
  166|  87.0k|   m_mac->set_key(m_T);
  167|       |
  168|  87.0k|   m_mac->update(m_V);
  169|  87.0k|   m_mac->final(m_V);
  170|       |
  171|  87.0k|   if(!input.empty()) {
  ------------------
  |  Branch (171:7): [True: 73.6k, False: 13.3k]
  ------------------
  172|  73.6k|      m_mac->update(m_V);
  173|  73.6k|      m_mac->update(0x01);
  174|  73.6k|      m_mac->update(input);
  175|  73.6k|      m_mac->final(m_T);
  176|  73.6k|      m_mac->set_key(m_T);
  177|       |
  178|  73.6k|      m_mac->update(m_V);
  179|  73.6k|      m_mac->final(m_V);
  180|  73.6k|   }
  181|  87.0k|}
_ZNK5Botan9HMAC_DRBG14security_levelEv:
  183|  38.2k|size_t HMAC_DRBG::security_level() const {
  184|  38.2k|   return m_security_level;
  185|  38.2k|}
hmac_drbg.cpp:_ZN5Botan12_GLOBAL__N_124hmac_drbg_security_levelEm:
   21|  12.7k|size_t hmac_drbg_security_level(size_t mac_output_length) {
   22|       |   // security strength of the hash function
   23|       |   // for pre-image resistance (see NIST SP 800-57)
   24|       |   // SHA-1: 128 bits
   25|       |   // SHA-224, SHA-512/224: 192 bits,
   26|       |   // SHA-256, SHA-512/256, SHA-384, SHA-512: >= 256 bits
   27|       |   // NIST SP 800-90A only supports up to 256 bits though
   28|       |
   29|  12.7k|   if(mac_output_length < 20) {
  ------------------
  |  Branch (29:7): [True: 0, False: 12.7k]
  ------------------
   30|      0|      throw Invalid_Argument(fmt("HMAC_DRBG MAC output length {} is too small", mac_output_length));
   31|      0|   }
   32|       |
   33|  12.7k|   if(mac_output_length < 32) {
  ------------------
  |  Branch (33:7): [True: 0, False: 12.7k]
  ------------------
   34|      0|      return (mac_output_length - 4) * 8;
   35|  12.7k|   } else {
   36|  12.7k|      return 32 * 8;
   37|  12.7k|   }
   38|  12.7k|}
hmac_drbg.cpp:_ZN5Botan12_GLOBAL__N_112check_limitsEmm:
   40|  12.7k|void check_limits(size_t reseed_interval, size_t max_number_of_bytes_per_request) {
   41|       |   // SP800-90A permits up to 2^48, but it is not usable on 32 bit
   42|       |   // platforms, so we only allow up to 2^24, which is still reasonably high
   43|  12.7k|   if(reseed_interval == 0 || reseed_interval > static_cast<size_t>(1) << 24) {
  ------------------
  |  Branch (43:7): [True: 0, False: 12.7k]
  |  Branch (43:31): [True: 0, False: 12.7k]
  ------------------
   44|      0|      throw Invalid_Argument("Invalid value for reseed_interval");
   45|      0|   }
   46|       |
   47|  12.7k|   if(max_number_of_bytes_per_request == 0 || max_number_of_bytes_per_request > 64 * 1024) {
  ------------------
  |  Branch (47:7): [True: 0, False: 12.7k]
  |  Branch (47:47): [True: 0, False: 12.7k]
  ------------------
   48|      0|      throw Invalid_Argument("Invalid value for max_number_of_bytes_per_request");
   49|      0|   }
   50|  12.7k|}
hmac_drbg.cpp:_ZN5Botan12_GLOBAL__N_114check_not_nullINS_25MessageAuthenticationCodeEEENSt3__110unique_ptrIT_NS3_14default_deleteIS5_EEEES8_:
   53|  12.7k|std::unique_ptr<T> check_not_null(std::unique_ptr<T> obj) {
   54|  12.7k|   BOTAN_ARG_CHECK(obj != nullptr, "Argument must not be null");
  ------------------
  |  |   35|  12.7k|   do {                                                          \
  |  |   36|  12.7k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  12.7k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 12.7k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  12.7k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 12.7k]
  |  |  ------------------
  ------------------
   55|  12.7k|   return obj;
   56|  12.7k|}

_ZN5Botan21RandomNumberGenerator23randomize_with_ts_inputENSt3__14spanIhLm18446744073709551615EEE:
   26|  30.4k|void RandomNumberGenerator::randomize_with_ts_input(std::span<uint8_t> output) {
   27|  30.4k|   if(this->accepts_input()) {
  ------------------
  |  Branch (27:7): [True: 30.4k, False: 0]
  ------------------
   28|  30.4k|      std::array<uint8_t, 16> additional_input = {0};
   29|       |
   30|  30.4k|#if defined(BOTAN_HAS_SYSTEM_RNG)
   31|       |      // If we have a system RNG just read 128 bits from that
   32|  30.4k|      system_rng().randomize(additional_input);
   33|  30.4k|      constexpr size_t written = additional_input.size();
   34|       |#elif defined(BOTAN_HAS_OS_UTILS)
   35|       |      // Otherwise take clock + pid
   36|       |      const uint64_t clock = OS::get_high_resolution_clock();
   37|       |      const uint32_t pid = OS::get_process_id();  // 0 if no PIDs on this system
   38|       |
   39|       |      store_le(std::span{additional_input}.first<8>(), clock);
   40|       |      store_le(std::span{additional_input}.subspan<8, 4>(), pid);
   41|       |      const size_t written = 8 + (pid != 0) ? 4 : 0;
   42|       |#else
   43|       |      // Nothing to use in this case
   44|       |      constexpr size_t written = 0;
   45|       |#endif
   46|       |
   47|  30.4k|      this->fill_bytes_with_input(output, std::span{additional_input}.first(written));
   48|  30.4k|   } else {
   49|      0|      this->fill_bytes_with_input(output, {});
   50|      0|   }
   51|  30.4k|}
_ZN5Botan21RandomNumberGenerator15reseed_from_rngERS0_m:
   65|  12.7k|void RandomNumberGenerator::reseed_from_rng(RandomNumberGenerator& rng, size_t poll_bits) {
   66|  12.7k|   if(this->accepts_input()) {
  ------------------
  |  Branch (66:7): [True: 12.7k, False: 0]
  ------------------
   67|  12.7k|      this->add_entropy(rng.random_vec(poll_bits / 8));
   68|  12.7k|   }
   69|  12.7k|}

_ZN5Botan12Stateful_RNG5clearEv:
   15|  12.7k|void Stateful_RNG::clear() {
   16|  12.7k|   const lock_guard_type<recursive_mutex_type> lock(m_mutex);
   17|  12.7k|   m_reseed_counter = 0;
   18|  12.7k|   m_last_pid = 0;
   19|  12.7k|   clear_state();
   20|  12.7k|}
_ZN5Botan12Stateful_RNG12force_reseedEv:
   22|  12.7k|void Stateful_RNG::force_reseed() {
   23|  12.7k|   const lock_guard_type<recursive_mutex_type> lock(m_mutex);
   24|  12.7k|   m_reseed_counter = 0;
   25|  12.7k|}
_ZNK5Botan12Stateful_RNG9is_seededEv:
   27|  69.2k|bool Stateful_RNG::is_seeded() const {
   28|  69.2k|   const lock_guard_type<recursive_mutex_type> lock(m_mutex);
   29|  69.2k|   return m_reseed_counter > 0;
   30|  69.2k|}
_ZN5Botan12Stateful_RNG23generate_batched_outputENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEE:
   39|  43.2k|void Stateful_RNG::generate_batched_output(std::span<uint8_t> output, std::span<const uint8_t> input) {
   40|  43.2k|   BOTAN_ASSERT_NOMSG(!output.empty());
  ------------------
  |  |   77|  43.2k|   do {                                                                     \
  |  |   78|  43.2k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  43.2k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 43.2k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  43.2k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 43.2k]
  |  |  ------------------
  ------------------
   41|       |
   42|  43.2k|   const size_t max_per_request = max_number_of_bytes_per_request();
   43|       |
   44|  43.2k|   if(max_per_request == 0) {
  ------------------
  |  Branch (44:7): [True: 0, False: 43.2k]
  ------------------
   45|       |      // no limit
   46|      0|      reseed_check();
   47|      0|      this->generate_output(output, input);
   48|  43.2k|   } else {
   49|  87.0k|      while(!output.empty()) {
  ------------------
  |  Branch (49:13): [True: 43.7k, False: 43.2k]
  ------------------
   50|  43.7k|         const size_t this_req = std::min(max_per_request, output.size());
   51|       |
   52|  43.7k|         reseed_check();
   53|  43.7k|         this->generate_output(output.subspan(0, this_req), input);
   54|       |
   55|       |         // only include the input for the first iteration
   56|  43.7k|         input = {};
   57|       |
   58|  43.7k|         output = output.subspan(this_req);
   59|  43.7k|      }
   60|  43.2k|   }
   61|  43.2k|}
_ZN5Botan12Stateful_RNG21fill_bytes_with_inputENSt3__14spanIhLm18446744073709551615EEENS2_IKhLm18446744073709551615EEE:
   63|  55.9k|void Stateful_RNG::fill_bytes_with_input(std::span<uint8_t> output, std::span<const uint8_t> input) {
   64|  55.9k|   const lock_guard_type<recursive_mutex_type> lock(m_mutex);
   65|       |
   66|  55.9k|   if(output.empty()) {
  ------------------
  |  Branch (66:7): [True: 12.7k, False: 43.2k]
  ------------------
   67|       |      // Special case for exclusively adding entropy to the stateful RNG.
   68|  12.7k|      this->update(input);
   69|       |
   70|  12.7k|      if(8 * input.size() >= security_level()) {
  ------------------
  |  Branch (70:10): [True: 12.7k, False: 0]
  ------------------
   71|  12.7k|         reset_reseed_counter();
   72|  12.7k|      }
   73|  43.2k|   } else {
   74|  43.2k|      generate_batched_output(output, input);
   75|  43.2k|   }
   76|  55.9k|}
_ZN5Botan12Stateful_RNG15reseed_from_rngERNS_21RandomNumberGeneratorEm:
   90|  12.7k|void Stateful_RNG::reseed_from_rng(RandomNumberGenerator& rng, size_t poll_bits) {
   91|  12.7k|   const lock_guard_type<recursive_mutex_type> lock(m_mutex);
   92|       |
   93|  12.7k|   RandomNumberGenerator::reseed_from_rng(rng, poll_bits);
   94|       |
   95|  12.7k|   if(poll_bits >= security_level()) {
  ------------------
  |  Branch (95:7): [True: 12.7k, False: 0]
  ------------------
   96|  12.7k|      reset_reseed_counter();
   97|  12.7k|   }
   98|  12.7k|}
_ZN5Botan12Stateful_RNG20reset_reseed_counterEv:
  100|  25.4k|void Stateful_RNG::reset_reseed_counter() {
  101|       |   // Lock is held whenever this function is called
  102|  25.4k|   m_reseed_counter = 1;
  103|  25.4k|   m_last_pid = OS::get_process_id();
  104|  25.4k|}
_ZN5Botan12Stateful_RNG12reseed_checkEv:
  106|  43.7k|void Stateful_RNG::reseed_check() {
  107|       |   // Lock is held whenever this function is called
  108|       |
  109|  43.7k|   const uint32_t cur_pid = OS::get_process_id();
  110|       |
  111|  43.7k|   const bool fork_detected = (m_last_pid > 0) && (cur_pid != m_last_pid);
  ------------------
  |  Branch (111:31): [True: 31.0k, False: 12.7k]
  |  Branch (111:51): [True: 0, False: 31.0k]
  ------------------
  112|       |
  113|  43.7k|   if(is_seeded() == false || fork_detected || (m_reseed_interval > 0 && m_reseed_counter >= m_reseed_interval)) {
  ------------------
  |  Branch (113:7): [True: 12.7k, False: 31.0k]
  |  Branch (113:31): [True: 0, False: 31.0k]
  |  Branch (113:49): [True: 31.0k, False: 0]
  |  Branch (113:74): [True: 0, False: 31.0k]
  ------------------
  114|  12.7k|      m_reseed_counter = 0;
  115|  12.7k|      m_last_pid = cur_pid;
  116|       |
  117|  12.7k|      if(m_underlying_rng != nullptr) {
  ------------------
  |  Branch (117:10): [True: 12.7k, False: 0]
  ------------------
  118|  12.7k|         reseed_from_rng(*m_underlying_rng, security_level());
  119|  12.7k|      }
  120|       |
  121|  12.7k|      if(m_entropy_sources != nullptr) {
  ------------------
  |  Branch (121:10): [True: 0, False: 12.7k]
  ------------------
  122|      0|         reseed_from_sources(*m_entropy_sources, security_level());
  123|      0|      }
  124|       |
  125|  12.7k|      if(!is_seeded()) {
  ------------------
  |  Branch (125:10): [True: 0, False: 12.7k]
  ------------------
  126|      0|         if(fork_detected) {
  ------------------
  |  Branch (126:13): [True: 0, False: 0]
  ------------------
  127|      0|            throw Invalid_State("Detected use of fork but cannot reseed DRBG");
  128|      0|         } else {
  129|      0|            throw PRNG_Unseeded(name());
  130|      0|         }
  131|      0|      }
  132|  31.0k|   } else {
  133|  31.0k|      BOTAN_ASSERT(m_reseed_counter != 0, "RNG is seeded");
  ------------------
  |  |   64|  31.0k|   do {                                                                                 \
  |  |   65|  31.0k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                                     \
  |  |   66|  31.0k|      if(!(expr)) {                                                                     \
  |  |  ------------------
  |  |  |  Branch (66:10): [True: 0, False: 31.0k]
  |  |  ------------------
  |  |   67|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                            \
  |  |   68|      0|         Botan::assertion_failure(#expr, assertion_made, __func__, __FILE__, __LINE__); \
  |  |   69|      0|      }                                                                                 \
  |  |   70|  31.0k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (70:12): [Folded, False: 31.0k]
  |  |  ------------------
  ------------------
  134|  31.0k|      m_reseed_counter += 1;
  135|  31.0k|   }
  136|  43.7k|}

_ZN5Botan10system_rngEv:
  377|  43.2k|RandomNumberGenerator& system_rng() {
  378|  43.2k|   static System_RNG_Impl g_system_rng;
  379|  43.2k|   return g_system_rng;
  380|  43.2k|}
system_rng.cpp:_ZN5Botan12_GLOBAL__N_115System_RNG_Impl21fill_bytes_with_inputENSt3__14spanIhLm18446744073709551615EEENS3_IKhLm18446744073709551615EEE:
  215|  43.2k|      void fill_bytes_with_input(std::span<uint8_t> output, std::span<const uint8_t> /* ignored */) override {
  216|  43.2k|         const unsigned int flags = 0;
  217|       |
  218|  43.2k|         uint8_t* buf = output.data();
  219|  43.2k|         size_t len = output.size();
  220|  86.4k|         while(len > 0) {
  ------------------
  |  Branch (220:16): [True: 43.2k, False: 43.2k]
  ------------------
  221|       |   #if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ < 25
  222|       |            const ssize_t got = ::syscall(SYS_getrandom, buf, len, flags);
  223|       |   #else
  224|  43.2k|            const ssize_t got = ::getrandom(buf, len, flags);
  225|  43.2k|   #endif
  226|       |
  227|  43.2k|            if(got < 0) {
  ------------------
  |  Branch (227:16): [True: 0, False: 43.2k]
  ------------------
  228|      0|               if(errno == EINTR) {
  ------------------
  |  Branch (228:19): [True: 0, False: 0]
  ------------------
  229|      0|                  continue;
  230|      0|               }
  231|      0|               throw System_Error("System_RNG getrandom failed", errno);
  232|      0|            }
  233|       |
  234|  43.2k|            if(got == 0) {
  ------------------
  |  Branch (234:16): [True: 0, False: 43.2k]
  ------------------
  235|      0|               throw System_Error("System_RNG getrandom unexpectedly returned 0");
  236|      0|            }
  237|       |
  238|  43.2k|            buf += got;
  239|  43.2k|            len -= got;
  240|  43.2k|         }
  241|  43.2k|      }

_ZN5Botan6CTR_BEC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEE:
   22|  4.86k|      m_cipher(std::move(cipher)),
   23|  4.86k|      m_block_size(m_cipher->block_size()),
   24|  4.86k|      m_ctr_size(m_block_size),
   25|  4.86k|      m_ctr_blocks(m_cipher->parallel_bytes() / m_block_size),
   26|  4.86k|      m_counter(m_cipher->parallel_bytes()),
   27|  4.86k|      m_pad(m_counter.size()),
   28|  4.86k|      m_pad_pos(0) {}
_ZN5Botan6CTR_BEC2ENSt3__110unique_ptrINS_11BlockCipherENS1_14default_deleteIS3_EEEEm:
   31|  3.30k|      m_cipher(std::move(cipher)),
   32|  3.30k|      m_block_size(m_cipher->block_size()),
   33|  3.30k|      m_ctr_size(ctr_size),
   34|  3.30k|      m_ctr_blocks(m_cipher->parallel_bytes() / m_block_size),
   35|  3.30k|      m_counter(m_cipher->parallel_bytes()),
   36|  3.30k|      m_pad(m_counter.size()),
   37|  3.30k|      m_pad_pos(0) {
   38|  3.30k|   BOTAN_ARG_CHECK(m_ctr_size >= 4 && m_ctr_size <= m_block_size, "Invalid CTR-BE counter size");
  ------------------
  |  |   35|  3.30k|   do {                                                          \
  |  |   36|  3.30k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|  6.61k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 3.30k, False: 0]
  |  |  |  Branch (37:12): [True: 3.30k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|  3.30k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 3.30k]
  |  |  ------------------
  ------------------
   39|  3.30k|}
_ZNK5Botan6CTR_BE15valid_iv_lengthEm:
   61|   353k|bool CTR_BE::valid_iv_length(size_t iv_len) const {
   62|   353k|   return (iv_len <= m_block_size);
   63|   353k|}
_ZNK5Botan6CTR_BE8key_specEv:
   69|  16.3k|Key_Length_Specification CTR_BE::key_spec() const {
   70|  16.3k|   return m_cipher->key_spec();
   71|  16.3k|}
_ZNK5Botan6CTR_BE19has_keying_materialEv:
   77|  1.70M|bool CTR_BE::has_keying_material() const {
   78|  1.70M|   return m_cipher->has_keying_material();
   79|  1.70M|}
_ZN5Botan6CTR_BE12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
   81|  8.17k|void CTR_BE::key_schedule(std::span<const uint8_t> key) {
   82|  8.17k|   m_cipher->set_key(key);
   83|       |
   84|       |   // Set a default all-zeros IV
   85|  8.17k|   set_iv(nullptr, 0);
   86|  8.17k|}
_ZN5Botan6CTR_BE12cipher_bytesEPKhPhm:
   96|  1.35M|void CTR_BE::cipher_bytes(const uint8_t in[], uint8_t out[], size_t length) {
   97|  1.35M|   assert_key_material_set();
   98|       |
   99|  1.35M|   if(m_ctr_size < sizeof(uint64_t)) {
  ------------------
  |  Branch (99:7): [True: 426k, False: 924k]
  ------------------
  100|   426k|      if(length > m_bytes_remaining) {
  ------------------
  |  Branch (100:10): [True: 0, False: 426k]
  ------------------
  101|      0|         throw Invalid_State(fmt("CTR_BE with {}-byte counter has exhausted its keystream", m_ctr_size));
  102|      0|      }
  103|   426k|      m_bytes_remaining -= length;
  104|   426k|   }
  105|       |
  106|  1.35M|   const uint8_t* pad_bits = m_pad.data();
  107|  1.35M|   const size_t pad_size = m_pad.size();
  108|       |
  109|       |   /* Consume any already computed keystream in m_pad */
  110|       |
  111|  1.35M|   if(m_pad_pos > 0) {
  ------------------
  |  Branch (111:7): [True: 362k, False: 988k]
  ------------------
  112|   362k|      const size_t avail = pad_size - m_pad_pos;
  113|   362k|      const size_t take = std::min(length, avail);
  114|   362k|      xor_buf(out, in, pad_bits + m_pad_pos, take);
  115|   362k|      length -= take;
  116|   362k|      in += take;
  117|   362k|      out += take;
  118|   362k|      m_pad_pos += take;
  119|       |
  120|   362k|      if(take == avail) {
  ------------------
  |  Branch (120:10): [True: 272k, False: 90.7k]
  ------------------
  121|   272k|         add_counter(m_ctr_blocks);
  122|   272k|         m_cipher->encrypt_n(m_counter.data(), m_pad.data(), m_ctr_blocks);
  123|   272k|         m_pad_pos = 0;
  124|   272k|      }
  125|   362k|   }
  126|       |
  127|       |   /* Bulk processing */
  128|       |
  129|  1.35M|   [[maybe_unused]] const bool can_use_bs16_ctr4_fastpath = m_block_size == 16 && m_ctr_size == 4 && pad_size % 64 == 0;
  ------------------
  |  Branch (129:61): [True: 1.03M, False: 318k]
  |  Branch (129:83): [True: 426k, False: 605k]
  |  Branch (129:102): [True: 426k, False: 0]
  ------------------
  130|       |
  131|       |#if defined(BOTAN_HAS_CTR_BE_AVX2)
  132|       |   if(length >= pad_size && can_use_bs16_ctr4_fastpath && CPUID::has(CPUID::Feature::AVX2)) {
  133|       |      const size_t consumed = ctr_proc_bs16_ctr4_avx2(in, out, length);
  134|       |      in += consumed;
  135|       |      out += consumed;
  136|       |      length -= consumed;
  137|       |   }
  138|       |#endif
  139|       |
  140|       |#if defined(BOTAN_HAS_CTR_BE_SIMD32)
  141|       |   if(length >= pad_size && can_use_bs16_ctr4_fastpath && CPUID::has(CPUID::Feature::SIMD_4X32)) {
  142|       |      const size_t consumed = ctr_proc_bs16_ctr4_simd32(in, out, length);
  143|       |      in += consumed;
  144|       |      out += consumed;
  145|       |      length -= consumed;
  146|       |   }
  147|       |#endif
  148|       |
  149|  2.67M|   while(length >= pad_size) {
  ------------------
  |  Branch (149:10): [True: 1.32M, False: 1.35M]
  ------------------
  150|  1.32M|      xor_buf(out, in, pad_bits, pad_size);
  151|  1.32M|      length -= pad_size;
  152|  1.32M|      in += pad_size;
  153|  1.32M|      out += pad_size;
  154|       |
  155|  1.32M|      add_counter(m_ctr_blocks);
  156|  1.32M|      m_cipher->encrypt_n(m_counter.data(), m_pad.data(), m_ctr_blocks);
  157|  1.32M|   }
  158|       |
  159|       |   /* Now if length > 0 then we have some remaining text, and m_pad is full - consume as required */
  160|  1.35M|   if(length > 0) {
  ------------------
  |  Branch (160:7): [True: 413k, False: 937k]
  ------------------
  161|   413k|      xor_buf(out, in, pad_bits, length);
  162|   413k|      m_pad_pos = length;
  163|   413k|   }
  164|  1.35M|}
_ZN5Botan6CTR_BE12set_iv_bytesEPKhm:
  202|   353k|void CTR_BE::set_iv_bytes(const uint8_t iv[], size_t iv_len) {
  203|   353k|   if(!valid_iv_length(iv_len)) {
  ------------------
  |  Branch (203:7): [True: 0, False: 353k]
  ------------------
  204|      0|      throw Invalid_IV_Length(name(), iv_len);
  205|      0|   }
  206|       |
  207|   353k|   m_iv.resize(m_block_size);
  208|   353k|   zeroise(m_iv);
  209|   353k|   copy_mem(m_iv.data(), iv, iv_len);
  210|       |
  211|   353k|   seek(0);
  212|   353k|}
_ZN5Botan6CTR_BE11add_counterEm:
  214|  1.59M|void CTR_BE::add_counter(const uint64_t counter) {
  215|  1.59M|   const size_t ctr_size = m_ctr_size;
  216|  1.59M|   const size_t ctr_blocks = m_ctr_blocks;
  217|  1.59M|   const size_t BS = m_block_size;
  218|       |
  219|  1.59M|   if(ctr_size == 4) {
  ------------------
  |  Branch (219:7): [True: 378k, False: 1.21M]
  ------------------
  220|   378k|      const size_t off = (BS - 4);
  221|   378k|      const uint32_t low32 = static_cast<uint32_t>(counter + load_be<uint32_t>(&m_counter[off], 0));
  222|       |
  223|  2.12M|      for(size_t i = 0; i != ctr_blocks; ++i) {
  ------------------
  |  Branch (223:25): [True: 1.74M, False: 378k]
  ------------------
  224|  1.74M|         store_be(uint32_t(low32 + i), &m_counter[i * BS + off]);
  225|  1.74M|      }
  226|  1.21M|   } else if(ctr_size == 8) {
  ------------------
  |  Branch (226:14): [True: 359k, False: 859k]
  ------------------
  227|   359k|      const size_t off = (BS - 8);
  228|   359k|      const uint64_t low64 = counter + load_be<uint64_t>(&m_counter[off], 0);
  229|       |
  230|  2.30M|      for(size_t i = 0; i != ctr_blocks; ++i) {
  ------------------
  |  Branch (230:25): [True: 1.94M, False: 359k]
  ------------------
  231|  1.94M|         store_be(uint64_t(low64 + i), &m_counter[i * BS + off]);
  232|  1.94M|      }
  233|   859k|   } else if(ctr_size == 16) {
  ------------------
  |  Branch (233:14): [True: 859k, False: 0]
  ------------------
  234|   859k|      const size_t off = (BS - 16);
  235|   859k|      uint64_t b0 = load_be<uint64_t>(&m_counter[off], 0);
  236|   859k|      uint64_t b1 = load_be<uint64_t>(&m_counter[off], 1);
  237|   859k|      b1 += counter;
  238|   859k|      b0 += (b1 < counter) ? 1 : 0;  // carry
  ------------------
  |  Branch (238:13): [True: 0, False: 859k]
  ------------------
  239|       |
  240|  5.11M|      for(size_t i = 0; i != ctr_blocks; ++i) {
  ------------------
  |  Branch (240:25): [True: 4.25M, False: 859k]
  ------------------
  241|  4.25M|         store_be(b0, &m_counter[i * BS + off]);
  242|  4.25M|         store_be(b1, &m_counter[i * BS + off + 8]);
  243|  4.25M|         b1 += 1;
  244|  4.25M|         if(b1 == 0) {
  ------------------
  |  Branch (244:13): [True: 0, False: 4.25M]
  ------------------
  245|      0|            b0 += 1;  // carry
  246|      0|         }
  247|  4.25M|      }
  248|   859k|   } else {
  249|      0|      for(size_t i = 0; i != ctr_blocks; ++i) {
  ------------------
  |  Branch (249:25): [True: 0, False: 0]
  ------------------
  250|      0|         uint64_t local_counter = counter;
  251|      0|         uint16_t carry = static_cast<uint8_t>(local_counter);
  252|      0|         for(size_t j = 0; (carry > 0 || local_counter > 0) && j != ctr_size; ++j) {
  ------------------
  |  Branch (252:29): [True: 0, False: 0]
  |  Branch (252:42): [True: 0, False: 0]
  |  Branch (252:64): [True: 0, False: 0]
  ------------------
  253|      0|            const size_t off = i * BS + (BS - 1 - j);
  254|      0|            const uint16_t cnt = static_cast<uint16_t>(m_counter[off]) + carry;
  255|      0|            m_counter[off] = static_cast<uint8_t>(cnt);
  256|      0|            local_counter = (local_counter >> 8);
  257|      0|            carry = (cnt >> 8) + static_cast<uint8_t>(local_counter);
  258|      0|         }
  259|      0|      }
  260|      0|   }
  261|  1.59M|}
_ZN5Botan6CTR_BE4seekEm:
  263|   353k|void CTR_BE::seek(uint64_t offset) {
  264|   353k|   assert_key_material_set();
  265|       |
  266|   353k|   if(m_ctr_size < sizeof(uint64_t)) {
  ------------------
  |  Branch (266:7): [True: 109k, False: 244k]
  ------------------
  267|   109k|      const uint64_t requested_block = offset / m_block_size;
  268|   109k|      const uint64_t max_blocks = uint64_t{1} << (8 * m_ctr_size);
  269|   109k|      if(requested_block >= max_blocks) {
  ------------------
  |  Branch (269:10): [True: 0, False: 109k]
  ------------------
  270|      0|         throw Invalid_Argument(fmt("CTR_BE::seek offset {} exceeds {}-byte counter range", offset, m_ctr_size));
  271|      0|      }
  272|       |
  273|   109k|      m_bytes_remaining = max_blocks * m_block_size - offset;
  274|   109k|   }
  275|       |
  276|   353k|   const uint64_t base_counter = m_ctr_blocks * (offset / m_counter.size());
  277|       |
  278|   353k|   zeroise(m_counter);
  279|   353k|   BOTAN_ASSERT_NOMSG(m_counter.size() >= m_iv.size());
  ------------------
  |  |   77|   353k|   do {                                                                     \
  |  |   78|   353k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   353k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 353k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   353k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 353k]
  |  |  ------------------
  ------------------
  280|   353k|   copy_mem(m_counter.data(), m_iv.data(), m_iv.size());
  281|       |
  282|   353k|   const size_t BS = m_block_size;
  283|       |
  284|       |   // Set m_counter blocks to IV, IV + 1, ... IV + n
  285|       |
  286|   353k|   if(m_ctr_size == 4 && BS >= 8) {
  ------------------
  |  Branch (286:7): [True: 109k, False: 244k]
  |  Branch (286:26): [True: 109k, False: 0]
  ------------------
  287|   109k|      const uint32_t low32 = load_be<uint32_t>(&m_counter[BS - 4], 0);
  288|       |
  289|   109k|      if(m_ctr_blocks >= 4 && is_power_of_2(m_ctr_blocks)) {
  ------------------
  |  Branch (289:10): [True: 109k, False: 0]
  |  Branch (289:31): [True: 109k, False: 0]
  ------------------
  290|   109k|         size_t written = 1;
  291|   422k|         while(written < m_ctr_blocks) {
  ------------------
  |  Branch (291:16): [True: 313k, False: 109k]
  ------------------
  292|   313k|            copy_mem(&m_counter[written * BS], &m_counter[0], BS * written);  // NOLINT(*container-data-pointer)
  293|   313k|            written *= 2;
  294|   313k|         }
  295|   109k|      } else {
  296|      0|         for(size_t i = 1; i != m_ctr_blocks; ++i) {
  ------------------
  |  Branch (296:28): [True: 0, False: 0]
  ------------------
  297|      0|            copy_mem(&m_counter[i * BS], &m_counter[0], BS - 4);  // NOLINT(*container-data-pointer)
  298|      0|         }
  299|      0|      }
  300|       |
  301|   818k|      for(size_t i = 1; i != m_ctr_blocks; ++i) {
  ------------------
  |  Branch (301:25): [True: 709k, False: 109k]
  ------------------
  302|   709k|         const uint32_t c = static_cast<uint32_t>(low32 + i);
  303|   709k|         store_be(c, &m_counter[(BS - 4) + i * BS]);
  304|   709k|      }
  305|   244k|   } else {
  306|       |      // do everything sequentially:
  307|  1.44M|      for(size_t i = 1; i != m_ctr_blocks; ++i) {
  ------------------
  |  Branch (307:25): [True: 1.20M, False: 244k]
  ------------------
  308|  1.20M|         copy_mem(&m_counter[i * BS], &m_counter[(i - 1) * BS], BS);
  309|       |
  310|  1.20M|         for(size_t j = 0; j != m_ctr_size; ++j) {
  ------------------
  |  Branch (310:28): [True: 1.20M, False: 0]
  ------------------
  311|  1.20M|            uint8_t& c = m_counter[i * BS + (BS - 1 - j)];
  312|  1.20M|            c += 1;
  313|  1.20M|            if(c > 0) {
  ------------------
  |  Branch (313:16): [True: 1.20M, False: 4.39k]
  ------------------
  314|  1.20M|               break;
  315|  1.20M|            }
  316|  1.20M|         }
  317|  1.20M|      }
  318|   244k|   }
  319|       |
  320|   353k|   if(base_counter > 0) {
  ------------------
  |  Branch (320:7): [True: 0, False: 353k]
  ------------------
  321|      0|      add_counter(base_counter);
  322|      0|   }
  323|       |
  324|   353k|   m_cipher->encrypt_n(m_counter.data(), m_pad.data(), m_ctr_blocks);
  325|   353k|   m_pad_pos = offset % m_counter.size();
  326|   353k|}

_ZN5Botan12StreamCipher6createENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEES5_:
   40|  15.8k|std::unique_ptr<StreamCipher> StreamCipher::create(std::string_view algo_spec, std::string_view provider) {
   41|       |#if defined(BOTAN_HAS_SHAKE_CIPHER)
   42|       |   if(algo_spec == "SHAKE-128" || algo_spec == "SHAKE-128-XOF") {
   43|       |      if(provider.empty() || provider == "base") {
   44|       |         return std::make_unique<SHAKE_128_Cipher>();
   45|       |      }
   46|       |   }
   47|       |
   48|       |   if(algo_spec == "SHAKE-256" || algo_spec == "SHAKE-256-XOF") {
   49|       |      if(provider.empty() || provider == "base") {
   50|       |         return std::make_unique<SHAKE_256_Cipher>();
   51|       |      }
   52|       |   }
   53|       |#endif
   54|       |
   55|       |#if defined(BOTAN_HAS_CHACHA)
   56|       |   if(algo_spec == "ChaCha20") {
   57|       |      if(provider.empty() || provider == "base") {
   58|       |         return std::make_unique<ChaCha>(20);
   59|       |      }
   60|       |   }
   61|       |#endif
   62|       |
   63|       |#if defined(BOTAN_HAS_SALSA20)
   64|       |   if(algo_spec == "Salsa20") {
   65|       |      if(provider.empty() || provider == "base") {
   66|       |         return std::make_unique<Salsa20>();
   67|       |      }
   68|       |   }
   69|       |#endif
   70|       |
   71|  15.8k|   const SCAN_Name req(algo_spec);
   72|       |
   73|  15.8k|#if defined(BOTAN_HAS_CTR_BE)
   74|  15.8k|   if((req.algo_name() == "CTR-BE" || req.algo_name() == "CTR") && req.arg_count_between(1, 2)) {
  ------------------
  |  Branch (74:8): [True: 0, False: 15.8k]
  |  Branch (74:39): [True: 0, False: 15.8k]
  |  Branch (74:68): [True: 0, False: 0]
  ------------------
   75|      0|      if(provider.empty() || provider == "base") {
  ------------------
  |  Branch (75:10): [True: 0, False: 0]
  |  Branch (75:30): [True: 0, False: 0]
  ------------------
   76|      0|         auto cipher = BlockCipher::create(req.arg(0));
   77|      0|         if(cipher) {
  ------------------
  |  Branch (77:13): [True: 0, False: 0]
  ------------------
   78|      0|            const size_t ctr_size = req.arg_as_integer(1, cipher->block_size());
   79|      0|            return std::make_unique<CTR_BE>(std::move(cipher), ctr_size);
   80|      0|         }
   81|      0|      }
   82|      0|   }
   83|  15.8k|#endif
   84|       |
   85|       |#if defined(BOTAN_HAS_CHACHA)
   86|       |   if(req.algo_name() == "ChaCha") {
   87|       |      if(provider.empty() || provider == "base") {
   88|       |         return std::make_unique<ChaCha>(req.arg_as_integer(0, 20));
   89|       |      }
   90|       |   }
   91|       |#endif
   92|       |
   93|       |#if defined(BOTAN_HAS_OFB)
   94|       |   if(req.algo_name() == "OFB" && req.arg_count() == 1) {
   95|       |      if(provider.empty() || provider == "base") {
   96|       |         if(auto cipher = BlockCipher::create(req.arg(0))) {
   97|       |            return std::make_unique<OFB>(std::move(cipher));
   98|       |         }
   99|       |      }
  100|       |   }
  101|       |#endif
  102|       |
  103|       |#if defined(BOTAN_HAS_RC4)
  104|       |
  105|       |   if(req.algo_name() == "RC4" || req.algo_name() == "ARC4" || req.algo_name() == "MARK-4") {
  106|       |      const size_t skip = (req.algo_name() == "MARK-4") ? 256 : req.arg_as_integer(0, 0);
  107|       |
  108|       |      if(provider.empty() || provider == "base") {
  109|       |         return std::make_unique<RC4>(skip);
  110|       |      }
  111|       |   }
  112|       |
  113|       |#endif
  114|       |
  115|  15.8k|   BOTAN_UNUSED(req);
  ------------------
  |  |  144|  15.8k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  116|  15.8k|   BOTAN_UNUSED(provider);
  ------------------
  |  |  144|  15.8k|#define BOTAN_UNUSED Botan::ignore_params
  ------------------
  117|       |
  118|  15.8k|   return nullptr;
  119|  15.8k|}

_ZN5Botan15allocate_memoryEmm:
   21|  3.20M|BOTAN_MALLOC_FN void* allocate_memory(size_t elems, size_t elem_size) {
   22|  3.20M|   if(elems == 0 || elem_size == 0) {
  ------------------
  |  Branch (22:7): [True: 0, False: 3.20M]
  |  Branch (22:21): [True: 0, False: 3.20M]
  ------------------
   23|      0|      return nullptr;
   24|      0|   }
   25|       |
   26|       |   // Some calloc implementations do not check for overflow (?!?)
   27|  3.20M|   if(!checked_mul(elems, elem_size).has_value()) {
  ------------------
  |  Branch (27:7): [True: 0, False: 3.20M]
  ------------------
   28|      0|      throw std::bad_alloc();
   29|      0|   }
   30|       |
   31|       |#if defined(BOTAN_HAS_LOCKING_ALLOCATOR)
   32|       |   // NOLINTNEXTLINE(*-const-correctness) bug in clang-tidy
   33|       |   if(void* p = mlock_allocator::instance().allocate(elems, elem_size)) {
   34|       |      return p;
   35|       |   }
   36|       |#endif
   37|       |
   38|       |#if defined(BOTAN_TARGET_OS_HAS_ALLOC_CONCEAL)
   39|       |   void* ptr = ::calloc_conceal(elems, elem_size);
   40|       |#else
   41|       |   // NOLINTNEXTLINE(*-const-correctness) bug in clang-tidy
   42|  3.20M|   void* ptr = std::calloc(elems, elem_size);  // NOLINT(*-no-malloc,*-owning-memory)
   43|  3.20M|#endif
   44|  3.20M|   if(ptr == nullptr) {
  ------------------
  |  Branch (44:7): [True: 0, False: 3.20M]
  ------------------
   45|      0|      [[unlikely]] throw std::bad_alloc();
   46|      0|   }
   47|  3.20M|   return ptr;
   48|  3.20M|}
_ZN5Botan17deallocate_memoryEPvmm:
   50|  3.20M|void deallocate_memory(void* p, size_t elems, size_t elem_size) {
   51|  3.20M|   if(p == nullptr) {
  ------------------
  |  Branch (51:7): [True: 0, False: 3.20M]
  ------------------
   52|      0|      [[unlikely]] return;
   53|      0|   }
   54|       |
   55|  3.20M|   secure_scrub_memory(p, elems * elem_size);
   56|       |
   57|       |#if defined(BOTAN_HAS_LOCKING_ALLOCATOR)
   58|       |   if(mlock_allocator::instance().deallocate(p, elems, elem_size)) {
   59|       |      return;
   60|       |   }
   61|       |#endif
   62|       |
   63|  3.20M|   std::free(p);  // NOLINT(*-no-malloc,*-owning-memory)
   64|  3.20M|}
_ZN5Botan20initialize_allocatorEv:
   66|      1|void initialize_allocator() {
   67|       |#if defined(BOTAN_HAS_LOCKING_ALLOCATOR)
   68|       |   mlock_allocator::instance();
   69|       |#endif
   70|      1|}

_ZN5Botan22throw_invalid_argumentEPKcS1_S1_:
   23|    307|void throw_invalid_argument(const char* message, const char* func, const char* file) {
   24|    307|   throw Invalid_Argument(fmt("{} in {}:{}", message, func, file));
   25|    307|}

_ZN5Botan9ExceptionC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   71|    500|Exception::Exception(std::string_view msg) : m_msg(msg) {}
_ZN5Botan9ExceptionC2EPKcNSt3__117basic_string_viewIcNS3_11char_traitsIcEEEE:
   75|  1.03k|Exception::Exception(const char* prefix, std::string_view msg) : m_msg(fmt("{} {}", prefix, msg)) {}
_ZN5Botan16Invalid_ArgumentC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   77|    400|Invalid_Argument::Invalid_Argument(std::string_view msg) : Exception(msg) {}
_ZN5Botan14Decoding_ErrorC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  125|    100|Decoding_Error::Decoding_Error(std::string_view name) : Exception(name) {}
_ZN5Botan26Invalid_Authentication_TagC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
  133|  1.03k|      Exception("Invalid authentication tag:", msg) {}

_ZN5Botan5GHASH14ghash_multiplyENSt3__14spanIhLm16EEENS2_IKhLm18446744073709551615EEEm:
   44|   545k|void GHASH::ghash_multiply(std::span<uint8_t, GCM_BS> x, std::span<const uint8_t> input, size_t blocks) {
   45|   545k|   BOTAN_ASSERT_NOMSG(input.size() % GCM_BS == 0);
  ------------------
  |  |   77|   545k|   do {                                                                     \
  |  |   78|   545k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   545k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 545k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   545k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 545k]
  |  |  ------------------
  ------------------
   46|       |
   47|       |#if defined(BOTAN_HAS_GHASH_AVX512_CLMUL)
   48|       |   if(CPUID::has(CPUID::Feature::AVX512_CLMUL)) {
   49|       |      BOTAN_ASSERT_NOMSG(!m_H_pow.empty());
   50|       |      return ghash_multiply_avx512_clmul(x.data(), m_H_pow.data(), input.data(), blocks);
   51|       |   }
   52|       |#endif
   53|       |
   54|       |#if defined(BOTAN_HAS_GHASH_CLMUL_CPU)
   55|       |   if(CPUID::has(CPUID::Feature::HW_CLMUL)) {
   56|       |      BOTAN_ASSERT_NOMSG(!m_H_pow.empty());
   57|       |      return ghash_multiply_cpu(x.data(), m_H_pow, input.data(), blocks);
   58|       |   }
   59|       |#endif
   60|       |
   61|       |#if defined(BOTAN_HAS_GHASH_CLMUL_VPERM)
   62|       |   if(CPUID::has(CPUID::Feature::SIMD_2X64)) {
   63|       |      return ghash_multiply_vperm(x.data(), m_HM.data(), input.data(), blocks);
   64|       |   }
   65|       |#endif
   66|       |
   67|   545k|   ghash_multiply_base(x, m_HM, input, blocks);
   68|   545k|}
_ZN5Botan5GHASH19ghash_multiply_baseENSt3__14spanIhLm16EEERKNS1_6vectorImNS_16secure_allocatorImEEEENS2_IKhLm18446744073709551615EEEm:
   73|   545k|                                size_t blocks) {
   74|   545k|   auto scope = CT::scoped_poison(x);
   75|       |
   76|   545k|   auto X = load_be<std::array<uint64_t, 2>>(x);
   77|       |
   78|   545k|   BufferSlicer in(input);
   79|  2.84M|   for(size_t b = 0; b != blocks; ++b) {
  ------------------
  |  Branch (79:22): [True: 2.30M, False: 545k]
  ------------------
   80|  2.30M|      const auto I = load_be<std::array<uint64_t, 2>>(in.take<GCM_BS>());
   81|  2.30M|      X[0] ^= I[0];
   82|  2.30M|      X[1] ^= I[1];
   83|       |
   84|  2.30M|      std::array<uint64_t, 2> Z{};
   85|       |
   86|   149M|      for(size_t i = 0; i != 64; ++i) {
  ------------------
  |  Branch (86:25): [True: 147M, False: 2.30M]
  ------------------
   87|   147M|         const auto X0MASK = CT::Mask<uint64_t>::expand_top_bit(X[0]);
   88|   147M|         const auto X1MASK = CT::Mask<uint64_t>::expand_top_bit(X[1]);
   89|       |
   90|   147M|         X[0] <<= 1;
   91|   147M|         X[1] <<= 1;
   92|       |
   93|   147M|         Z[0] = X0MASK.select(Z[0] ^ HM[4 * i], Z[0]);
   94|   147M|         Z[1] = X0MASK.select(Z[1] ^ HM[4 * i + 1], Z[1]);
   95|       |
   96|   147M|         Z[0] = X1MASK.select(Z[0] ^ HM[4 * i + 2], Z[0]);
   97|   147M|         Z[1] = X1MASK.select(Z[1] ^ HM[4 * i + 3], Z[1]);
   98|   147M|      }
   99|       |
  100|  2.30M|      X[0] = Z[0];
  101|  2.30M|      X[1] = Z[1];
  102|  2.30M|   }
  103|       |
  104|   545k|   store_be(x, X);
  105|   545k|}
_ZNK5Botan5GHASH19has_keying_materialEv:
  107|   525k|bool GHASH::has_keying_material() const {
  108|   525k|   return !m_HM.empty() || !m_H_pow.empty();
  ------------------
  |  Branch (108:11): [True: 525k, False: 0]
  |  Branch (108:28): [True: 0, False: 0]
  ------------------
  109|   525k|}
_ZN5Botan5GHASH12key_scheduleENSt3__14spanIKhLm18446744073709551615EEE:
  111|  3.30k|void GHASH::key_schedule(std::span<const uint8_t> key) {
  112|  3.30k|   m_H_ad = {0};
  113|  3.30k|   m_ad_len = 0;
  114|  3.30k|   m_text_len = 0;
  115|       |
  116|  3.30k|   BOTAN_ASSERT_NOMSG(key.size() == GCM_BS);
  ------------------
  |  |   77|  3.30k|   do {                                                                     \
  |  |   78|  3.30k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|  3.30k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 3.30k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|  3.30k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 3.30k]
  |  |  ------------------
  ------------------
  117|       |
  118|       |#if defined(BOTAN_HAS_GHASH_AVX512_CLMUL)
  119|       |   if(CPUID::has(CPUID::Feature::AVX512_CLMUL)) {
  120|       |      zap(m_HM);
  121|       |      if(m_H_pow.size() != 32) {
  122|       |         m_H_pow.resize(32);
  123|       |      }
  124|       |      ghash_precompute_avx512_clmul(key.data(), m_H_pow.data());
  125|       |      // m_HM left empty
  126|       |      return;
  127|       |   }
  128|       |#endif
  129|       |
  130|       |#if defined(BOTAN_HAS_GHASH_CLMUL_CPU)
  131|       |   if(CPUID::has(CPUID::Feature::HW_CLMUL)) {
  132|       |      zap(m_HM);
  133|       |      ghash_precompute_cpu(key.data(), m_H_pow);
  134|       |      // m_HM left empty
  135|       |      return;
  136|       |   }
  137|       |#endif
  138|       |
  139|  3.30k|   ghash_precompute_base(key.first<GCM_BS>(), m_HM);
  140|  3.30k|}
_ZN5Botan5GHASH21ghash_precompute_baseENSt3__14spanIKhLm16EEERNS1_6vectorImNS_16secure_allocatorImEEEE:
  142|  3.30k|void GHASH::ghash_precompute_base(std::span<const uint8_t, GCM_BS> key, secure_vector<uint64_t>& HM) {
  143|  3.30k|   auto H = load_be<std::array<uint64_t, 2>>(key);
  144|       |
  145|  3.30k|   const uint64_t R = 0xE100000000000000;
  146|       |
  147|  3.30k|   if(HM.size() != 256) {
  ------------------
  |  Branch (147:7): [True: 3.30k, False: 0]
  ------------------
  148|  3.30k|      HM.resize(256);
  149|  3.30k|   }
  150|       |
  151|       |   // precompute the multiples of H
  152|  9.91k|   for(size_t i = 0; i != 2; ++i) {
  ------------------
  |  Branch (152:22): [True: 6.61k, False: 3.30k]
  ------------------
  153|   429k|      for(size_t j = 0; j != 64; ++j) {
  ------------------
  |  Branch (153:25): [True: 423k, False: 6.61k]
  ------------------
  154|       |         /*
  155|       |         we interleave H^1, H^65, H^2, H^66, H3, H67, H4, H68
  156|       |         to make indexing nicer in the multiplication code
  157|       |         */
  158|   423k|         HM[4 * j + 2 * i] = H[0];
  159|   423k|         HM[4 * j + 2 * i + 1] = H[1];
  160|       |
  161|       |         // GCM's bit ops are reversed so we carry out of the bottom
  162|   423k|         const uint64_t carry = CT::Mask<uint64_t>::expand(H[1] & 1).if_set_return(R);
  163|   423k|         H[1] = (H[1] >> 1) | (H[0] << 63);
  164|   423k|         H[0] = (H[0] >> 1) ^ carry;
  165|   423k|      }
  166|  6.61k|   }
  167|  3.30k|}
_ZN5Botan5GHASH5startENSt3__14spanIKhLm18446744073709551615EEE:
  169|   102k|void GHASH::start(std::span<const uint8_t> nonce) {
  170|   102k|   BOTAN_ARG_CHECK(nonce.size() == 16, "GHASH requires a 128-bit nonce");
  ------------------
  |  |   35|   102k|   do {                                                          \
  |  |   36|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   102k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  171|   102k|   auto& n = m_nonce.emplace();
  172|   102k|   copy_mem(n, nonce);
  173|   102k|   copy_mem(m_ghash, m_H_ad);
  174|   102k|   m_buffer.clear();
  175|   102k|   m_text_len = 0;
  176|   102k|}
_ZN5Botan5GHASH19set_associated_dataENSt3__14spanIKhLm18446744073709551615EEE:
  178|   102k|void GHASH::set_associated_data(std::span<const uint8_t> input) {
  179|   102k|   BOTAN_STATE_CHECK(!m_nonce);
  ------------------
  |  |   51|   102k|   do {                                                         \
  |  |   52|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   102k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  180|       |
  181|   102k|   assert_key_material_set();
  182|   102k|   m_H_ad = {0};
  183|   102k|   ghash_update(m_H_ad, input);
  184|   102k|   ghash_zeropad(m_H_ad);
  185|   102k|   m_ad_len = input.size();
  186|   102k|}
_ZN5Botan5GHASH6updateENSt3__14spanIKhLm18446744073709551615EEE:
  202|   320k|void GHASH::update(std::span<const uint8_t> input) {
  203|   320k|   assert_key_material_set();
  204|   320k|   BOTAN_STATE_CHECK(m_nonce);
  ------------------
  |  |   51|   320k|   do {                                                         \
  |  |   52|   320k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   320k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 320k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   320k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 320k]
  |  |  ------------------
  ------------------
  205|   320k|   ghash_update(m_ghash, input);
  206|   320k|   m_text_len += input.size();
  207|       |
  208|       |   // NIST SP 800-38D limits plaintext/ciphertext to 2^39 - 256 bits
  209|   320k|   constexpr uint64_t GHASH_MAX_BYTES = (((static_cast<uint64_t>(1) << 39)) - 256) / 8;
  210|   320k|   if(m_text_len > GHASH_MAX_BYTES) {
  ------------------
  |  Branch (210:7): [True: 0, False: 320k]
  ------------------
  211|      0|      throw Invalid_State("GCM message length limit exceeded");
  212|      0|   }
  213|   320k|}
_ZN5Botan5GHASH5finalENSt3__14spanIhLm18446744073709551615EEE:
  215|   102k|void GHASH::final(std::span<uint8_t> mac) {
  216|   102k|   BOTAN_ARG_CHECK(!mac.empty() && mac.size() <= GCM_BS, "GHASH output length");
  ------------------
  |  |   35|   102k|   do {                                                          \
  |  |   36|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */              \
  |  |   37|   204k|      if(!(expr)) {                                              \
  |  |  ------------------
  |  |  |  Branch (37:12): [True: 102k, False: 0]
  |  |  |  Branch (37:12): [True: 102k, False: 0]
  |  |  ------------------
  |  |   38|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */     \
  |  |   39|      0|         Botan::throw_invalid_argument(msg, __func__, __FILE__); \
  |  |   40|      0|      }                                                          \
  |  |   41|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (41:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  217|   102k|   BOTAN_STATE_CHECK(m_nonce);
  ------------------
  |  |   51|   102k|   do {                                                         \
  |  |   52|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   102k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  218|   102k|   assert_key_material_set();
  219|       |
  220|   102k|   ghash_zeropad(m_ghash);
  221|   102k|   ghash_final_block(m_ghash, m_ad_len, m_text_len);
  222|       |
  223|   102k|   xor_buf(mac, std::span{m_ghash}.first(mac.size()), std::span{*m_nonce}.first(mac.size()));
  224|       |
  225|   102k|   secure_scrub_memory(m_ghash);
  226|   102k|   m_text_len = 0;
  227|   102k|   m_nonce.reset();
  228|   102k|}
_ZN5Botan5GHASH11reset_stateEv:
  247|   105k|void GHASH::reset_state() {
  248|   105k|   secure_scrub_memory(m_ghash);
  249|   105k|   if(m_nonce) {
  ------------------
  |  Branch (249:7): [True: 157, False: 105k]
  ------------------
  250|    157|      secure_scrub_memory(m_nonce.value());
  251|    157|      m_nonce.reset();
  252|    157|   }
  253|   105k|   m_buffer.clear();
  254|   105k|   m_text_len = 0;
  255|   105k|}
_ZN5Botan5GHASH12ghash_updateENSt3__14spanIhLm16EEENS2_IKhLm18446744073709551615EEE:
  257|   423k|void GHASH::ghash_update(std::span<uint8_t, GCM_BS> x, std::span<const uint8_t> input) {
  258|   423k|   BufferSlicer in(input);
  259|   866k|   while(!in.empty()) {
  ------------------
  |  Branch (259:10): [True: 443k, False: 423k]
  ------------------
  260|   443k|      if(const auto one_block = m_buffer.handle_unaligned_data(in)) {
  ------------------
  |  Branch (260:21): [True: 19.3k, False: 424k]
  ------------------
  261|  19.3k|         ghash_multiply(x, one_block.value(), 1);
  262|  19.3k|      }
  263|       |
  264|   443k|      if(m_buffer.in_alignment()) {
  ------------------
  |  Branch (264:10): [True: 320k, False: 123k]
  ------------------
  265|   320k|         const auto [aligned_data, full_blocks] = m_buffer.aligned_data_to_process(in);
  266|   320k|         if(full_blocks > 0) {
  ------------------
  |  Branch (266:13): [True: 320k, False: 30]
  ------------------
  267|   320k|            ghash_multiply(x, aligned_data, full_blocks);
  268|   320k|         }
  269|   320k|      }
  270|   443k|   }
  271|   423k|   BOTAN_ASSERT_NOMSG(in.empty());
  ------------------
  |  |   77|   423k|   do {                                                                     \
  |  |   78|   423k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|   423k|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 423k]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|   423k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 423k]
  |  |  ------------------
  ------------------
  272|   423k|}
_ZN5Botan5GHASH13ghash_zeropadENSt3__14spanIhLm16EEE:
  274|   204k|void GHASH::ghash_zeropad(std::span<uint8_t, GCM_BS> x) {
  275|   204k|   if(!m_buffer.in_alignment()) {
  ------------------
  |  Branch (275:7): [True: 104k, False: 100k]
  ------------------
  276|   104k|      m_buffer.fill_up_with_zeros();
  277|   104k|      ghash_multiply(x, m_buffer.consume(), 1);
  278|   104k|   }
  279|   204k|}
_ZN5Botan5GHASH17ghash_final_blockENSt3__14spanIhLm16EEEmm:
  281|   102k|void GHASH::ghash_final_block(std::span<uint8_t, GCM_BS> x, uint64_t ad_len, uint64_t text_len) {
  282|   102k|   BOTAN_STATE_CHECK(m_buffer.in_alignment());
  ------------------
  |  |   51|   102k|   do {                                                         \
  |  |   52|   102k|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */             \
  |  |   53|   102k|      if(!(expr)) {                                             \
  |  |  ------------------
  |  |  |  Branch (53:10): [True: 0, False: 102k]
  |  |  ------------------
  |  |   54|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */    \
  |  |   55|      0|         Botan::throw_invalid_state(#expr, __func__, __FILE__); \
  |  |   56|      0|      }                                                         \
  |  |   57|   102k|   } while(0)
  |  |  ------------------
  |  |  |  Branch (57:12): [Folded, False: 102k]
  |  |  ------------------
  ------------------
  283|   102k|   const auto final_block = store_be(8 * ad_len, 8 * text_len);
  284|   102k|   ghash_multiply(x, final_block, 1);
  285|   102k|}

_ZN5Botan21constant_time_compareENSt3__14spanIKhLm18446744073709551615EEES3_:
   17|    329|bool constant_time_compare(std::span<const uint8_t> x, std::span<const uint8_t> y) {
   18|    329|   const auto min_size = CT::Mask<size_t>::is_lte(x.size(), y.size()).select(x.size(), y.size());
   19|    329|   const auto equal_size = CT::Mask<size_t>::is_equal(x.size(), y.size());
   20|    329|   const auto equal_content = CT::Mask<size_t>::expand(CT::is_equal(x.data(), y.data(), min_size));
   21|    329|   return (equal_content & equal_size).as_bool();
   22|    329|}

_ZN5Botan19secure_scrub_memoryEPvm:
   25|  7.04M|void secure_scrub_memory(void* ptr, size_t n) {
   26|  7.04M|   return secure_zeroize_buffer(ptr, n);
   27|  7.04M|}
_ZN5Botan21secure_zeroize_bufferEPvm:
   29|  7.30M|void secure_zeroize_buffer(void* ptr, size_t n) {
   30|  7.30M|   if(n == 0) {
  ------------------
  |  Branch (30:7): [True: 1.39M, False: 5.90M]
  ------------------
   31|  1.39M|      return;
   32|  1.39M|   }
   33|       |
   34|       |#if defined(BOTAN_TARGET_OS_HAS_RTLSECUREZEROMEMORY)
   35|       |   ::RtlSecureZeroMemory(ptr, n);
   36|       |
   37|       |#elif defined(BOTAN_TARGET_OS_HAS_EXPLICIT_BZERO)
   38|  5.90M|   ::explicit_bzero(ptr, n);
   39|       |
   40|       |#elif defined(BOTAN_TARGET_OS_HAS_EXPLICIT_MEMSET)
   41|       |   (void)::explicit_memset(ptr, 0, n);
   42|       |
   43|       |#else
   44|       |   /*
   45|       |   * Call memset through a static volatile pointer, which the compiler should
   46|       |   * not elide. This construct should be safe in conforming compilers, but who
   47|       |   * knows. This has been checked to generate the expected code, which saves the
   48|       |   * memset address in the data segment and unconditionally loads and jumps to
   49|       |   * that address, with the following targets:
   50|       |   *
   51|       |   * x86-64: Clang 19, GCC 6, 11, 13, 14
   52|       |   * riscv64: GCC 14
   53|       |   * aarch64: GCC 14
   54|       |   * armv7: GCC 14
   55|       |   *
   56|       |   * Actually all of them generated the expected jump even without marking the
   57|       |   * function pointer as volatile. However this seems worth including as an
   58|       |   * additional precaution.
   59|       |   */
   60|       |   static void* (*const volatile memset_ptr)(void*, int, size_t) = std::memset;
   61|       |   (memset_ptr)(ptr, 0, n);
   62|       |#endif
   63|  5.90M|}

_ZN5Botan2OS14get_process_idEv:
   77|  69.2k|uint32_t OS::get_process_id() {
   78|  69.2k|#if defined(BOTAN_TARGET_OS_HAS_POSIX1)
   79|  69.2k|   return ::getpid();
   80|       |#elif defined(BOTAN_TARGET_OS_HAS_WIN32)
   81|       |   return ::GetCurrentProcessId();
   82|       |#elif defined(BOTAN_TARGET_OS_IS_LLVM) || defined(BOTAN_TARGET_OS_IS_NONE)
   83|       |   return 0;  // truly no meaningful value
   84|       |#else
   85|       |   #error "Missing get_process_id"
   86|       |#endif
   87|  69.2k|}
_ZN5Botan2OS17read_env_variableERNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS1_17basic_string_viewIcS4_EE:
  449|    481|bool OS::read_env_variable(std::string& value_out, std::string_view name_view) {
  450|    481|   value_out = "";
  451|       |
  452|    481|   if(running_in_privileged_state()) {
  ------------------
  |  Branch (452:7): [True: 0, False: 481]
  ------------------
  453|      0|      return false;
  454|      0|   }
  455|       |
  456|       |#if defined(BOTAN_TARGET_OS_HAS_WIN32) && \
  457|       |   (defined(BOTAN_BUILD_COMPILER_IS_MSVC) || defined(BOTAN_BUILD_COMPILER_IS_CLANGCL))
  458|       |   const std::string name(name_view);
  459|       |   char val[128] = {0};
  460|       |   size_t req_size = 0;
  461|       |   if(getenv_s(&req_size, val, sizeof(val), name.c_str()) == 0) {
  462|       |      // Microsoft's implementation always writes a terminating \0,
  463|       |      // and includes it in the reported length of the environment variable
  464|       |      // if a value exists.
  465|       |      if(req_size > 0 && val[req_size - 1] == '\0') {
  466|       |         value_out = std::string(val);
  467|       |      } else {
  468|       |         value_out = std::string(val, req_size);
  469|       |      }
  470|       |      return true;
  471|       |   }
  472|       |#else
  473|    481|   const std::string name(name_view);
  474|    481|   if(const char* val = std::getenv(name.c_str())) {
  ------------------
  |  Branch (474:19): [True: 0, False: 481]
  ------------------
  475|      0|      value_out = val;
  476|      0|      return true;
  477|      0|   }
  478|    481|#endif
  479|       |
  480|    481|   return false;
  481|    481|}
os_utils.cpp:_ZN5Botan12_GLOBAL__N_110get_auxvalENSt3__18optionalImEE:
  119|    481|std::optional<unsigned long> get_auxval(std::optional<unsigned long> id) {
  120|    481|   if(id) {
  ------------------
  |  Branch (120:7): [True: 481, False: 0]
  ------------------
  121|    481|#if defined(BOTAN_TARGET_OS_HAS_GETAUXVAL)
  122|    481|      return ::getauxval(*id);
  123|       |#elif defined(BOTAN_TARGET_OS_HAS_ELF_AUX_INFO)
  124|       |      unsigned long auxinfo = 0;
  125|       |      if(::elf_aux_info(static_cast<int>(*id), &auxinfo, sizeof(auxinfo)) == 0) {
  126|       |         return auxinfo;
  127|       |      }
  128|       |#endif
  129|    481|   }
  130|       |
  131|      0|   return {};
  132|    481|}
os_utils.cpp:_ZN5Botan12_GLOBAL__N_127running_in_privileged_stateEv:
  153|    481|bool running_in_privileged_state() {
  154|    481|#if defined(AT_SECURE)
  155|    481|   if(auto at_secure = get_auxval(AT_SECURE)) {
  ------------------
  |  Branch (155:12): [True: 481, False: 0]
  ------------------
  156|    481|      return at_secure != 0;
  157|    481|   }
  158|      0|#endif
  159|       |
  160|      0|#if defined(BOTAN_TARGET_OS_HAS_POSIX1)
  161|      0|   return (::getuid() != ::geteuid()) || (::getgid() != ::getegid());
  ------------------
  |  Branch (161:11): [True: 0, False: 0]
  |  Branch (161:42): [True: 0, False: 0]
  ------------------
  162|       |#else
  163|       |   return false;
  164|       |#endif
  165|    481|}

_ZN5Botan9parse_u32ENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEEb:
   64|  5.64k|std::optional<uint32_t> parse_u32(std::string_view input, bool require_canonical) {
   65|  5.64k|   return parse_decimal_integer<uint32_t>(input, require_canonical);
   66|  5.64k|}
_ZN5Botan9to_u32bitENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEE:
   76|  5.64k|uint32_t to_u32bit(std::string_view input) {
   77|  5.64k|   if(const auto parsed = parse_u32(input)) {
  ------------------
  |  Branch (77:18): [True: 5.64k, False: 0]
  ------------------
   78|  5.64k|      return *parsed;
   79|  5.64k|   } else {
   80|      0|      throw Invalid_Argument(fmt("Failed to parse input '{}' as a 32-bit integer", input));
   81|      0|   }
   82|  5.64k|}
_ZN5Botan20parse_algorithm_nameENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEE:
   87|  15.8k|std::vector<std::string> parse_algorithm_name(std::string_view scan_name) {
   88|  15.8k|   if(scan_name.find('(') == std::string::npos && scan_name.find(')') == std::string::npos) {
  ------------------
  |  Branch (88:7): [True: 15.8k, False: 0]
  |  Branch (88:51): [True: 15.8k, False: 0]
  ------------------
   89|  15.8k|      return {std::string(scan_name)};
   90|  15.8k|   }
   91|       |
   92|      0|   std::string name(scan_name);
   93|      0|   std::string substring;
   94|      0|   std::vector<std::string> elems;
   95|      0|   size_t level = 0;
   96|       |
   97|      0|   elems.push_back(name.substr(0, name.find('(')));
   98|      0|   name = name.substr(name.find('('));
   99|       |
  100|      0|   for(auto i = name.begin(); i != name.end(); ++i) {
  ------------------
  |  Branch (100:31): [True: 0, False: 0]
  ------------------
  101|      0|      const char c = *i;
  102|       |
  103|      0|      if(c == '(') {
  ------------------
  |  Branch (103:10): [True: 0, False: 0]
  ------------------
  104|      0|         ++level;
  105|      0|      }
  106|      0|      if(c == ')') {
  ------------------
  |  Branch (106:10): [True: 0, False: 0]
  ------------------
  107|      0|         if(level == 1 && i == name.end() - 1) {
  ------------------
  |  Branch (107:13): [True: 0, False: 0]
  |  Branch (107:13): [True: 0, False: 0]
  |  Branch (107:27): [True: 0, False: 0]
  ------------------
  108|      0|            if(elems.size() == 1) {
  ------------------
  |  Branch (108:16): [True: 0, False: 0]
  ------------------
  109|      0|               elems.push_back(substring.substr(1));
  110|      0|            } else {
  111|      0|               elems.push_back(substring);
  112|      0|            }
  113|      0|            return elems;
  114|      0|         }
  115|       |
  116|      0|         if(level == 0 || (level == 1 && i != name.end() - 1)) {
  ------------------
  |  Branch (116:13): [True: 0, False: 0]
  |  Branch (116:13): [True: 0, False: 0]
  |  Branch (116:28): [True: 0, False: 0]
  |  Branch (116:42): [True: 0, False: 0]
  ------------------
  117|      0|            throw Invalid_Algorithm_Name(scan_name);
  118|      0|         }
  119|      0|         --level;
  120|      0|      }
  121|       |
  122|      0|      if(c == ',' && level == 1) {
  ------------------
  |  Branch (122:10): [True: 0, False: 0]
  |  Branch (122:22): [True: 0, False: 0]
  ------------------
  123|      0|         if(elems.size() == 1) {
  ------------------
  |  Branch (123:13): [True: 0, False: 0]
  ------------------
  124|      0|            elems.push_back(substring.substr(1));
  125|      0|         } else {
  126|      0|            elems.push_back(substring);
  127|      0|         }
  128|      0|         substring.clear();
  129|      0|      } else {
  130|      0|         substring += c;
  131|      0|      }
  132|      0|   }
  133|       |
  134|      0|   if(!substring.empty()) {
  ------------------
  |  Branch (134:7): [True: 0, False: 0]
  ------------------
  135|      0|      throw Invalid_Algorithm_Name(scan_name);
  136|      0|   }
  137|       |
  138|      0|   return elems;
  139|      0|}
_ZN5Botan8split_onENSt3__117basic_string_viewIcNS0_11char_traitsIcEEEEc:
  141|  15.8k|std::vector<std::string> split_on(std::string_view str, char delim) {
  142|  15.8k|   std::vector<std::string> elems;
  143|  15.8k|   if(str.empty()) {
  ------------------
  |  Branch (143:7): [True: 0, False: 15.8k]
  ------------------
  144|      0|      return elems;
  145|      0|   }
  146|       |
  147|  15.8k|   std::string substr;
  148|   193k|   for(const char c : str) {
  ------------------
  |  Branch (148:21): [True: 193k, False: 15.8k]
  ------------------
  149|   193k|      if(c == delim) {
  ------------------
  |  Branch (149:10): [True: 15.8k, False: 177k]
  ------------------
  150|  15.8k|         if(!substr.empty()) {
  ------------------
  |  Branch (150:13): [True: 15.8k, False: 0]
  ------------------
  151|  15.8k|            elems.push_back(substr);
  152|  15.8k|         }
  153|  15.8k|         substr.clear();
  154|   177k|      } else {
  155|   177k|         substr += c;
  156|   177k|      }
  157|   193k|   }
  158|       |
  159|  15.8k|   if(substr.empty()) {
  ------------------
  |  Branch (159:7): [True: 0, False: 15.8k]
  ------------------
  160|      0|      throw Invalid_Argument(fmt("Unable to split string '{}", str));
  161|      0|   }
  162|  15.8k|   elems.push_back(substr);
  163|       |
  164|  15.8k|   return elems;
  165|  15.8k|}
parsing.cpp:_ZN5Botan12_GLOBAL__N_116digit_from_asciiEc:
   23|  16.9k|std::optional<size_t> digit_from_ascii(char c) {
   24|  16.9k|   if(c >= '0' && c <= '9') {
  ------------------
  |  Branch (24:7): [True: 16.9k, False: 0]
  |  Branch (24:19): [True: 16.9k, False: 0]
  ------------------
   25|  16.9k|      return c - '0';
   26|  16.9k|   } else {
   27|      0|      return {};
   28|      0|   }
   29|  16.9k|}
parsing.cpp:_ZN5Botan12_GLOBAL__N_121parse_decimal_integerITkNSt3__117unsigned_integralEjEENS2_8optionalIT_EENS2_17basic_string_viewIcNS2_11char_traitsIcEEEEb:
   32|  5.64k|std::optional<T> parse_decimal_integer(std::string_view input, bool require_canonical) {
   33|  5.64k|   if(input.empty() || input.size() > (std::numeric_limits<T>::digits10 + 1)) {
  ------------------
  |  Branch (33:7): [True: 0, False: 5.64k]
  |  Branch (33:24): [True: 0, False: 5.64k]
  ------------------
   34|      0|      return {};
   35|      0|   }
   36|       |
   37|       |   // The canonical encoding of zero is "0"; no other value starts with a zero
   38|  5.64k|   if(require_canonical && input.size() > 1 && input.front() == '0') {
  ------------------
  |  Branch (38:7): [True: 0, False: 5.64k]
  |  Branch (38:28): [True: 0, False: 0]
  |  Branch (38:48): [True: 0, False: 0]
  ------------------
   39|      0|      return {};
   40|      0|   }
   41|       |
   42|  5.64k|   T accum = 0;
   43|       |
   44|  16.9k|   for(const char c : input) {
  ------------------
  |  Branch (44:21): [True: 16.9k, False: 5.64k]
  ------------------
   45|  16.9k|      if(const auto digit = digit_from_ascii(c)) {
  ------------------
  |  Branch (45:21): [True: 16.9k, False: 0]
  ------------------
   46|  16.9k|         if(accum > (std::numeric_limits<T>::max() - static_cast<T>(*digit)) / 10) {
  ------------------
  |  Branch (46:13): [True: 0, False: 16.9k]
  ------------------
   47|      0|            return {};
   48|      0|         }
   49|  16.9k|         accum = accum * 10 + static_cast<T>(*digit);
   50|  16.9k|      } else {
   51|      0|         return {};
   52|      0|      }
   53|  16.9k|   }
   54|       |
   55|  5.64k|   return accum;
   56|  5.64k|}

_ZN5Botan13poly_double_nEPhPKhm:
   81|  77.6k|void poly_double_n(uint8_t out[], const uint8_t in[], size_t n) {
   82|  77.6k|   switch(n) {
   83|  1.98k|      case 8:
  ------------------
  |  Branch (83:7): [True: 1.98k, False: 75.6k]
  ------------------
   84|  1.98k|         return poly_double<1, MinWeightPolynomial::P64>(out, in);
   85|  75.6k|      case 16:
  ------------------
  |  Branch (85:7): [True: 75.6k, False: 1.98k]
  ------------------
   86|  75.6k|         return poly_double<2, MinWeightPolynomial::P128>(out, in);
   87|      0|      case 24:
  ------------------
  |  Branch (87:7): [True: 0, False: 77.6k]
  ------------------
   88|      0|         return poly_double<3, MinWeightPolynomial::P192>(out, in);
   89|      0|      case 32:
  ------------------
  |  Branch (89:7): [True: 0, False: 77.6k]
  ------------------
   90|      0|         return poly_double<4, MinWeightPolynomial::P256>(out, in);
   91|      0|      case 64:
  ------------------
  |  Branch (91:7): [True: 0, False: 77.6k]
  ------------------
   92|      0|         return poly_double<8, MinWeightPolynomial::P512>(out, in);
   93|      0|      case 128:
  ------------------
  |  Branch (93:7): [True: 0, False: 77.6k]
  ------------------
   94|      0|         return poly_double<16, MinWeightPolynomial::P1024>(out, in);
   95|      0|      default:
  ------------------
  |  Branch (95:7): [True: 0, False: 77.6k]
  ------------------
   96|      0|         throw Invalid_Argument("Unsupported size for poly_double_n");
   97|  77.6k|   }
   98|  77.6k|}
poly_dbl.cpp:_ZN5Botan12_GLOBAL__N_111poly_doubleILm1ELNS0_19MinWeightPolynomialE27EEEvPhPKh:
   44|  1.98k|void poly_double(uint8_t out[], const uint8_t in[]) {
   45|  1.98k|   uint64_t W[LIMBS];
   46|  1.98k|   load_be(W, in, LIMBS);
   47|       |
   48|  1.98k|   const uint64_t carry = return_carry<P>(W[0]);
   49|       |
   50|  1.98k|   if constexpr(LIMBS > 0) {
   51|  1.98k|      for(size_t i = 0; i != LIMBS - 1; ++i) {
  ------------------
  |  Branch (51:25): [True: 0, False: 1.98k]
  ------------------
   52|      0|         W[i] = (W[i] << 1) ^ (W[i + 1] >> 63);
   53|      0|      }
   54|  1.98k|   }
   55|       |
   56|  1.98k|   W[LIMBS - 1] = (W[LIMBS - 1] << 1) ^ carry;
   57|       |
   58|  1.98k|   copy_out_be(std::span(out, LIMBS * 8), W);
   59|  1.98k|}
poly_dbl.cpp:_ZN5Botan12_GLOBAL__N_112return_carryILNS0_19MinWeightPolynomialE27EEEmm:
   39|  1.98k|inline uint64_t return_carry(uint64_t c) {
   40|  1.98k|   return CT::Mask<uint64_t>::expand_top_bit(c).if_set_return(static_cast<uint64_t>(P));
   41|  1.98k|}
poly_dbl.cpp:_ZN5Botan12_GLOBAL__N_111poly_doubleILm2ELNS0_19MinWeightPolynomialE135EEEvPhPKh:
   44|  75.6k|void poly_double(uint8_t out[], const uint8_t in[]) {
   45|  75.6k|   uint64_t W[LIMBS];
   46|  75.6k|   load_be(W, in, LIMBS);
   47|       |
   48|  75.6k|   const uint64_t carry = return_carry<P>(W[0]);
   49|       |
   50|  75.6k|   if constexpr(LIMBS > 0) {
   51|   151k|      for(size_t i = 0; i != LIMBS - 1; ++i) {
  ------------------
  |  Branch (51:25): [True: 75.6k, False: 75.6k]
  ------------------
   52|  75.6k|         W[i] = (W[i] << 1) ^ (W[i + 1] >> 63);
   53|  75.6k|      }
   54|  75.6k|   }
   55|       |
   56|  75.6k|   W[LIMBS - 1] = (W[LIMBS - 1] << 1) ^ carry;
   57|       |
   58|  75.6k|   copy_out_be(std::span(out, LIMBS * 8), W);
   59|  75.6k|}
poly_dbl.cpp:_ZN5Botan12_GLOBAL__N_112return_carryILNS0_19MinWeightPolynomialE135EEEmm:
   39|  75.6k|inline uint64_t return_carry(uint64_t c) {
   40|  75.6k|   return CT::Mask<uint64_t>::expand_top_bit(c).if_set_return(static_cast<uint64_t>(P));
   41|  75.6k|}

_ZN5Botan18prefetch_array_rawEmPKv:
   14|  22.8M|uint64_t prefetch_array_raw(size_t bytes, const void* arrayv) noexcept {
   15|  22.8M|#if defined(__cpp_lib_hardware_interference_size)
   16|  22.8M|   constexpr size_t cache_line_size = std::hardware_destructive_interference_size;
   17|       |#else
   18|       |   // We arbitrarily use a 64 byte cache line, which is by far the most
   19|       |   // common size.
   20|       |   //
   21|       |   // Runtime detection adds too much overhead to this function.
   22|       |   constexpr size_t cache_line_size = 64;
   23|       |#endif
   24|       |
   25|  22.8M|   const uint8_t* array = static_cast<const uint8_t*>(arrayv);
   26|       |
   27|  22.8M|   volatile uint64_t combiner = 1;
   28|       |
   29|   114M|   for(size_t idx = 0; idx < bytes; idx += cache_line_size) {
  ------------------
  |  Branch (29:24): [True: 91.3M, False: 22.8M]
  ------------------
   30|  91.3M|#if BOTAN_COMPILER_HAS_BUILTIN(__builtin_prefetch)
   31|       |      // we have no way of knowing if the compiler will emit anything here
   32|  91.3M|      __builtin_prefetch(&array[idx]);
   33|  91.3M|#endif
   34|       |
   35|  91.3M|      combiner = combiner | array[idx];
   36|  91.3M|   }
   37|       |
   38|       |   /*
   39|       |   * The combiner variable is initialized with 1, and we accumulate using OR, so
   40|       |   * now combiner must be a value other than zero. This being the case we will
   41|       |   * always return zero here. Hopefully the compiler will not figure this out.
   42|       |   */
   43|  22.8M|   return ct_is_zero(combiner);
   44|  22.8M|}

_ZN5Botan9SCAN_NameC2ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   61|   100k|SCAN_Name::SCAN_Name(std::string_view algo_spec) : m_orig_algo_spec(algo_spec) {
   62|   100k|   if(algo_spec.empty()) {
  ------------------
  |  Branch (62:7): [True: 0, False: 100k]
  ------------------
   63|      0|      throw Invalid_Argument("Expected algorithm name, got empty string");
   64|      0|   }
   65|       |
   66|       |   // Fast path for a bare name with no arguments or modes (eg "SHA-256"),
   67|       |   // which is the common case. Equivalent to the general parse below, which
   68|       |   // for such input produces a single token and no args/modes.
   69|   100k|   if(algo_spec.find_first_of("(),/") == std::string_view::npos) {
  ------------------
  |  Branch (69:7): [True: 3.11k, False: 96.9k]
  ------------------
   70|  3.11k|      m_alg_name = std::string(algo_spec);
   71|  3.11k|      return;
   72|  3.11k|   }
   73|       |
   74|  96.9k|   std::vector<std::pair<size_t, std::string>> name;
   75|  96.9k|   size_t level = 0;
   76|  96.9k|   std::pair<size_t, std::string> accum = std::make_pair(level, "");
   77|       |
   78|  96.9k|   bool expect_token = true;
   79|       |
   80|  1.36M|   for(const char c : algo_spec) {
  ------------------
  |  Branch (80:21): [True: 1.36M, False: 96.9k]
  ------------------
   81|  1.36M|      if(c == '/' || c == ',' || c == '(' || c == ')') {
  ------------------
  |  Branch (81:10): [True: 15.8k, False: 1.34M]
  |  Branch (81:22): [True: 348, False: 1.34M]
  |  Branch (81:34): [True: 85.8k, False: 1.25M]
  |  Branch (81:46): [True: 85.8k, False: 1.17M]
  ------------------
   82|   187k|         if(c == '(') {
  ------------------
  |  Branch (82:13): [True: 85.8k, False: 102k]
  ------------------
   83|  85.8k|            ++level;
   84|   102k|         } else if(c == ')') {
  ------------------
  |  Branch (84:20): [True: 85.8k, False: 16.2k]
  ------------------
   85|  85.8k|            if(level == 0) {
  ------------------
  |  Branch (85:16): [True: 0, False: 85.8k]
  ------------------
   86|      0|               throw Invalid_Algorithm_Name(m_orig_algo_spec);
   87|      0|            }
   88|  85.8k|            --level;
   89|  85.8k|         }
   90|       |
   91|   187k|         if(c == '/' && level > 0) {
  ------------------
  |  Branch (91:13): [True: 15.8k, False: 172k]
  |  Branch (91:25): [True: 0, False: 15.8k]
  ------------------
   92|      0|            accum.second.push_back(c);
   93|      0|            expect_token = false;
   94|   187k|         } else {
   95|   187k|            if(expect_token) {
  ------------------
  |  Branch (95:16): [True: 0, False: 187k]
  ------------------
   96|      0|               throw Invalid_Algorithm_Name(m_orig_algo_spec);
   97|      0|            }
   98|   187k|            if(!accum.second.empty()) {
  ------------------
  |  Branch (98:16): [True: 183k, False: 4.80k]
  ------------------
   99|   183k|               name.push_back(accum);
  100|   183k|            }
  101|   187k|            accum = std::make_pair(level, "");
  102|   187k|            expect_token = (c != ')');
  103|   187k|         }
  104|  1.17M|      } else {
  105|  1.17M|         accum.second.push_back(c);
  106|  1.17M|         expect_token = false;
  107|  1.17M|      }
  108|  1.36M|   }
  109|       |
  110|  96.9k|   if(!accum.second.empty()) {
  ------------------
  |  Branch (110:7): [True: 15.8k, False: 81.0k]
  ------------------
  111|  15.8k|      name.push_back(accum);
  112|  15.8k|   }
  113|       |
  114|  96.9k|   if(level != 0) {
  ------------------
  |  Branch (114:7): [True: 0, False: 96.9k]
  ------------------
  115|      0|      throw Invalid_Algorithm_Name(m_orig_algo_spec);
  116|      0|   }
  117|       |
  118|  96.9k|   if(expect_token) {
  ------------------
  |  Branch (118:7): [True: 0, False: 96.9k]
  ------------------
  119|       |      // A trailing separator with no following token, eg "Foo/" or "Foo,"
  120|      0|      throw Invalid_Algorithm_Name(m_orig_algo_spec);
  121|      0|   }
  122|       |
  123|  96.9k|   if(name.empty()) {
  ------------------
  |  Branch (123:7): [True: 0, False: 96.9k]
  ------------------
  124|      0|      throw Invalid_Algorithm_Name(m_orig_algo_spec);
  125|      0|   }
  126|       |
  127|  96.9k|   m_alg_name = name[0].second;
  128|       |
  129|  96.9k|   bool in_modes = false;
  130|       |
  131|   199k|   for(size_t i = 1; i != name.size(); ++i) {
  ------------------
  |  Branch (131:22): [True: 102k, False: 96.9k]
  ------------------
  132|   102k|      if(name[i].first == 0) {
  ------------------
  |  Branch (132:10): [True: 15.8k, False: 86.2k]
  ------------------
  133|  15.8k|         m_mode_info.push_back(make_arg(name, i));
  134|  15.8k|         in_modes = true;
  135|  86.2k|      } else if(name[i].first == 1 && !in_modes) {
  ------------------
  |  Branch (135:17): [True: 81.4k, False: 4.80k]
  |  Branch (135:39): [True: 81.4k, False: 0]
  ------------------
  136|  81.4k|         m_args.push_back(make_arg(name, i));
  137|  81.4k|      }
  138|   102k|   }
  139|  96.9k|}
_ZNK5Botan9SCAN_Name3argEm:
  141|  69.5k|std::string SCAN_Name::arg(size_t i) const {
  142|  69.5k|   if(i >= arg_count()) {
  ------------------
  |  Branch (142:7): [True: 0, False: 69.5k]
  ------------------
  143|      0|      throw Invalid_Argument("SCAN_Name::arg " + std::to_string(i) + " out of range for '" + to_string() + "'");
  144|      0|   }
  145|  69.5k|   return m_args[i];
  146|  69.5k|}
_ZNK5Botan9SCAN_Name14arg_as_integerEmm:
  155|  21.7k|size_t SCAN_Name::arg_as_integer(size_t i, size_t def_value) const {
  156|  21.7k|   if(i >= arg_count()) {
  ------------------
  |  Branch (156:7): [True: 16.0k, False: 5.64k]
  ------------------
  157|  16.0k|      return def_value;
  158|  16.0k|   }
  159|  5.64k|   return to_u32bit(m_args[i]);
  160|  21.7k|}
scan_name.cpp:_ZN5Botan12_GLOBAL__N_18make_argERKNSt3__16vectorINS1_4pairImNS1_12basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEENS7_ISA_EEEEm:
   18|  97.2k|std::string make_arg(const std::vector<std::pair<size_t, std::string>>& name, size_t start) {
   19|  97.2k|   std::string output = name[start].second;
   20|  97.2k|   size_t level = name[start].first;
   21|       |
   22|  97.2k|   size_t paren_depth = 0;
   23|       |
   24|   102k|   for(size_t i = start + 1; i != name.size(); ++i) {
  ------------------
  |  Branch (24:30): [True: 5.15k, False: 96.9k]
  ------------------
   25|  5.15k|      if(name[i].first <= name[start].first) {
  ------------------
  |  Branch (25:10): [True: 348, False: 4.80k]
  ------------------
   26|    348|         break;
   27|    348|      }
   28|       |
   29|  4.80k|      if(name[i].first > level) {
  ------------------
  |  Branch (29:10): [True: 4.80k, False: 0]
  ------------------
   30|  9.61k|         for(size_t j = level; j < name[i].first; j++) {
  ------------------
  |  Branch (30:32): [True: 4.80k, False: 4.80k]
  ------------------
   31|  4.80k|            output += "(";
   32|  4.80k|            ++paren_depth;
   33|  4.80k|         }
   34|  4.80k|         output += name[i].second;
   35|  4.80k|      } else if(name[i].first < level) {
  ------------------
  |  Branch (35:17): [True: 0, False: 0]
  ------------------
   36|      0|         for(size_t j = name[i].first; j < level; j++) {
  ------------------
  |  Branch (36:40): [True: 0, False: 0]
  ------------------
   37|      0|            output += ")";
   38|      0|            BOTAN_ASSERT_NOMSG(paren_depth != 0);
  ------------------
  |  |   77|      0|   do {                                                                     \
  |  |   78|      0|      /* NOLINTNEXTLINE(*-simplify-boolean-expr) */                         \
  |  |   79|      0|      if(!(expr)) {                                                         \
  |  |  ------------------
  |  |  |  Branch (79:10): [True: 0, False: 0]
  |  |  ------------------
  |  |   80|      0|         /* NOLINTNEXTLINE(bugprone-lambda-function-name) */                \
  |  |   81|      0|         Botan::assertion_failure(#expr, "", __func__, __FILE__, __LINE__); \
  |  |   82|      0|      }                                                                     \
  |  |   83|      0|   } while(0)
  |  |  ------------------
  |  |  |  Branch (83:12): [Folded, False: 0]
  |  |  ------------------
  ------------------
   39|      0|            --paren_depth;
   40|      0|         }
   41|      0|         output += "," + name[i].second;
   42|      0|      } else {
   43|      0|         if(output[output.size() - 1] != '(') {
  ------------------
  |  Branch (43:13): [True: 0, False: 0]
  ------------------
   44|      0|            output += ",";
   45|      0|         }
   46|      0|         output += name[i].second;
   47|      0|      }
   48|       |
   49|  4.80k|      level = name[i].first;
   50|  4.80k|   }
   51|       |
   52|   102k|   for(size_t i = 0; i != paren_depth; ++i) {
  ------------------
  |  Branch (52:22): [True: 4.80k, False: 97.2k]
  ------------------
   53|  4.80k|      output += ")";
   54|  4.80k|   }
   55|       |
   56|  97.2k|   return output;
   57|  97.2k|}

_ZN3rnp13is_blank_lineEPKcm:
   71|  20.3k|{
   72|  23.8k|    for (size_t i = 0; i < len && line[i]; i++) {
  ------------------
  |  Branch (72:24): [True: 23.8k, False: 0]
  |  Branch (72:35): [True: 23.8k, False: 0]
  ------------------
   73|  23.8k|        if (line[i] != ' ' && line[i] != '\t' && line[i] != '\r') {
  ------------------
  |  Branch (73:13): [True: 21.3k, False: 2.47k]
  |  Branch (73:31): [True: 20.6k, False: 680]
  |  Branch (73:50): [True: 20.3k, False: 280]
  ------------------
   74|  20.3k|            return false;
   75|  20.3k|        }
   76|  23.8k|    }
   77|      0|    return true;
   78|  20.3k|}
_ZN3rnp11str_case_eqEPKcS1_:
   82|   376k|{
   83|  1.29M|    while (*s1 && *s2) {
  ------------------
  |  Branch (83:12): [True: 1.21M, False: 84.3k]
  |  Branch (83:19): [True: 1.21M, False: 0]
  ------------------
   84|  1.21M|        if (std::tolower(*s1) != std::tolower(*s2)) {
  ------------------
  |  Branch (84:13): [True: 291k, False: 921k]
  ------------------
   85|   291k|            return false;
   86|   291k|        }
   87|   921k|        s1++;
   88|   921k|        s2++;
   89|   921k|    }
   90|  84.3k|    return !*s1 && !*s2;
  ------------------
  |  Branch (90:12): [True: 84.3k, False: 0]
  |  Branch (90:20): [True: 84.3k, False: 0]
  ------------------
   91|   376k|}
_ZN3rnp6is_hexERKNSt3__112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE:
  113|   134k|{
  114|  7.60M|    for (size_t i = hex_prefix_len(s); i < s.length(); i++) {
  ------------------
  |  Branch (114:40): [True: 7.47M, False: 134k]
  ------------------
  115|  7.47M|        auto &ch = s[i];
  116|  7.47M|        if ((ch >= '0') && (ch <= '9')) {
  ------------------
  |  Branch (116:13): [True: 7.47M, False: 0]
  |  Branch (116:28): [True: 4.43M, False: 3.03M]
  ------------------
  117|  4.43M|            continue;
  118|  4.43M|        }
  119|  3.03M|        if ((ch >= 'a') && (ch <= 'f')) {
  ------------------
  |  Branch (119:13): [True: 2.92M, False: 109k]
  |  Branch (119:28): [True: 2.92M, False: 0]
  ------------------
  120|  2.92M|            continue;
  121|  2.92M|        }
  122|   109k|        if ((ch >= 'A') && (ch <= 'F')) {
  ------------------
  |  Branch (122:13): [True: 109k, False: 0]
  |  Branch (122:28): [True: 109k, False: 0]
  ------------------
  123|   109k|            continue;
  124|   109k|        }
  125|      0|        if ((ch == ' ') || (ch == '\t')) {
  ------------------
  |  Branch (125:13): [True: 0, False: 0]
  |  Branch (125:28): [True: 0, False: 0]
  ------------------
  126|      0|            continue;
  127|      0|        }
  128|      0|        return false;
  129|      0|    }
  130|   134k|    return true;
  131|   134k|}
str-utils.cpp:_ZN3rnpL14hex_prefix_lenERKNSt3__112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE:
  104|   134k|{
  105|   134k|    if ((str.length() >= 2) && (str[0] == '0') && ((str[1] == 'x') || (str[1] == 'X'))) {
  ------------------
  |  Branch (105:9): [True: 134k, False: 0]
  |  Branch (105:32): [True: 127k, False: 6.70k]
  |  Branch (105:52): [True: 127k, False: 486]
  |  Branch (105:71): [True: 0, False: 486]
  ------------------
  106|   127k|        return 2;
  107|   127k|    }
  108|  7.18k|    return 0;
  109|   134k|}

LLVMFuzzerTestOneInput:
  182|  12.7k|{
  183|  12.7k|    if (size < 16) {
  ------------------
  |  Branch (183:9): [True: 6, False: 12.7k]
  ------------------
  184|      6|        return 0;
  185|      6|    }
  186|       |
  187|  12.7k|    uint8_t mode = data[0] % 4;
  188|  12.7k|    uint8_t pwdlen = data[13] % (MAX_PASSWORD_LEN + 1);
  ------------------
  |  |   58|  12.7k|#define MAX_PASSWORD_LEN 32
  ------------------
  189|  12.7k|    if (size < 14 + (size_t) pwdlen + 1) {
  ------------------
  |  Branch (189:9): [True: 3, False: 12.7k]
  ------------------
  190|      3|        return 0;
  191|      3|    }
  192|  12.7k|    memcpy(encrt_password, data + 14, pwdlen);
  193|  12.7k|    encrt_password[pwdlen] = '\0';
  194|  12.7k|    encrt_password_len = pwdlen;
  195|  12.7k|    const uint8_t *msg = data + 14 + pwdlen;
  196|  12.7k|    size_t         msglen = size - 14 - pwdlen;
  197|       |
  198|  12.7k|    rnp_ffi_t ffi = NULL;
  199|  12.7k|    if (rnp_ffi_create(&ffi, "GPG", "GPG")) {
  ------------------
  |  Branch (199:9): [True: 0, False: 12.7k]
  ------------------
  200|      0|        return 0;
  201|      0|    }
  202|  12.7k|    (void) rnp_ffi_set_pass_provider(ffi, encrt_password_provider, NULL);
  203|       |
  204|       |    /* import keyring material, permissively */
  205|  12.7k|    rnp_input_t in = NULL;
  206|  12.7k|    char *      results = NULL;
  207|  12.7k|    if (!rnp_input_from_memory(&in, msg, msglen, false)) {
  ------------------
  |  Branch (207:9): [True: 12.7k, False: 0]
  ------------------
  208|  12.7k|        (void) rnp_import_keys(ffi,
  209|  12.7k|                               in,
  210|  12.7k|                               RNP_LOAD_SAVE_PUBLIC_KEYS | RNP_LOAD_SAVE_SECRET_KEYS |
  ------------------
  |  |   80|  12.7k|#define RNP_LOAD_SAVE_PUBLIC_KEYS (1U << 0)
  ------------------
                                             RNP_LOAD_SAVE_PUBLIC_KEYS | RNP_LOAD_SAVE_SECRET_KEYS |
  ------------------
  |  |   81|  12.7k|#define RNP_LOAD_SAVE_SECRET_KEYS (1U << 1)
  ------------------
  211|  12.7k|                                 RNP_LOAD_SAVE_PERMISSIVE,
  ------------------
  |  |   82|  12.7k|#define RNP_LOAD_SAVE_PERMISSIVE (1U << 8)
  ------------------
  212|  12.7k|                               &results);
  213|  12.7k|        rnp_buffer_destroy(results);
  214|  12.7k|        rnp_input_destroy(in);
  215|  12.7k|    }
  216|       |
  217|       |    /* build the protected message */
  218|  12.7k|    rnp_input_t  src = NULL;
  219|  12.7k|    rnp_output_t out = NULL;
  220|  12.7k|    if (rnp_input_from_memory(&src, msg, msglen, false)) {
  ------------------
  |  Branch (220:9): [True: 0, False: 12.7k]
  ------------------
  221|      0|        rnp_ffi_destroy(ffi);
  222|      0|        return 0;
  223|      0|    }
  224|  12.7k|    if (rnp_output_to_memory(&out, ROUNDTRIP_MAX_ALLOC)) {
  ------------------
  |  |   59|  12.7k|#define ROUNDTRIP_MAX_ALLOC (16 * 1024 * 1024)
  ------------------
  |  Branch (224:9): [True: 0, False: 12.7k]
  ------------------
  225|      0|        rnp_input_destroy(src);
  226|      0|        rnp_ffi_destroy(ffi);
  227|      0|        return 0;
  228|      0|    }
  229|       |
  230|  12.7k|    if (mode == 3) {
  ------------------
  |  Branch (230:9): [True: 718, False: 12.0k]
  ------------------
  231|       |        /* sign-only */
  232|    718|        rnp_op_sign_t op = NULL;
  233|    718|        if (!rnp_op_sign_create(&op, ffi, src, out)) {
  ------------------
  |  Branch (233:13): [True: 718, False: 0]
  ------------------
  234|    718|            (void) rnp_op_sign_set_hash(op, hashes[data[7] % 8]);
  235|    718|            (void) rnp_op_sign_set_armor(op, data[6] & 1);
  236|    718|            rnp_key_handle_t skey = encrt_pick_key(ffi, data[12], true);
  237|    718|            if (skey) {
  ------------------
  |  Branch (237:17): [True: 78, False: 640]
  ------------------
  238|     78|                (void) rnp_op_sign_add_signature(op, skey, NULL);
  239|     78|                rnp_key_handle_destroy(skey);
  240|     78|            }
  241|    718|            (void) rnp_op_sign_execute(op);
  242|    718|            rnp_op_sign_destroy(op);
  243|    718|        }
  244|  12.0k|    } else {
  245|  12.0k|        rnp_op_encrypt_t op = NULL;
  246|  12.0k|        if (!rnp_op_encrypt_create(&op, ffi, src, out)) {
  ------------------
  |  Branch (246:13): [True: 12.0k, False: 0]
  ------------------
  247|  12.0k|            (void) rnp_op_encrypt_set_cipher(op, ciphers[data[1] % 12]);
  248|  12.0k|            (void) rnp_op_encrypt_set_aead(op, aeads[data[2] % 4]);
  249|  12.0k|            (void) rnp_op_encrypt_set_aead_bits(op, data[3] % 17);
  250|  12.0k|            (void) rnp_op_encrypt_set_compression(op, comps[data[4] % 4], data[5] % 10);
  251|  12.0k|            (void) rnp_op_encrypt_set_armor(op, data[6] & 1);
  252|  12.0k|            (void) rnp_op_encrypt_set_flags(op, (data[6] & 2) ? RNP_ENCRYPT_NOWRAP : 0);
  ------------------
  |  |  142|  7.26k|#define RNP_ENCRYPT_NOWRAP (1U << 0)
  ------------------
  |  Branch (252:49): [True: 7.26k, False: 4.76k]
  ------------------
  253|  12.0k|            (void) rnp_op_encrypt_set_hash(op, hashes[data[7] % 8]);
  254|  12.0k|            (void) rnp_op_encrypt_set_file_name(op, "fuzz");
  255|  12.0k|            (void) rnp_op_encrypt_set_file_mtime(op, 0);
  256|  12.0k|#ifdef RNP_EXPERIMENTAL_CRYPTO_REFRESH
  257|  12.0k|            if (data[6] & 4) {
  ------------------
  |  Branch (257:17): [True: 3.59k, False: 8.43k]
  ------------------
  258|  3.59k|                (void) rnp_op_encrypt_enable_pkesk_v6(op);
  259|  3.59k|            }
  260|  12.0k|            if (data[6] & 8) {
  ------------------
  |  Branch (260:17): [True: 6.18k, False: 5.84k]
  ------------------
  261|  6.18k|                (void) rnp_op_encrypt_enable_skesk_v6(op);
  262|  6.18k|            }
  263|  12.0k|#endif
  264|  12.0k|#ifdef RNP_EXPERIMENTAL_PQC
  265|  12.0k|            if (data[6] & 16) {
  ------------------
  |  Branch (265:17): [True: 5.07k, False: 6.95k]
  ------------------
  266|  5.07k|                (void) rnp_op_encrypt_prefer_pqc_enc_subkey(op);
  267|  5.07k|            }
  268|  12.0k|#endif
  269|  12.0k|            if ((mode == 0) || (data[6] & 64)) {
  ------------------
  |  Branch (269:17): [True: 5.33k, False: 6.69k]
  |  Branch (269:32): [True: 4.08k, False: 2.60k]
  ------------------
  270|  9.42k|                (void) rnp_op_encrypt_add_password(op,
  271|  9.42k|                                                   encrt_password,
  272|  9.42k|                                                   hashes[data[8] % 8],
  273|  9.42k|                                                   (size_t)(data[9] % 4 + 1) * 1024,
  274|  9.42k|                                                   ciphers[data[10] % 12]);
  275|  9.42k|            }
  276|  12.0k|            if ((mode == 1) || (mode == 2) || (data[6] & 32)) {
  ------------------
  |  Branch (276:17): [True: 5.13k, False: 6.89k]
  |  Branch (276:32): [True: 1.55k, False: 5.33k]
  |  Branch (276:47): [True: 2.08k, False: 3.25k]
  ------------------
  277|  8.77k|                rnp_key_handle_t rkey = encrt_pick_key(ffi, data[11], false);
  278|  8.77k|                if (rkey) {
  ------------------
  |  Branch (278:21): [True: 3.44k, False: 5.33k]
  ------------------
  279|  3.44k|                    (void) rnp_op_encrypt_add_recipient(op, rkey);
  280|  3.44k|                    rnp_key_handle_destroy(rkey);
  281|  3.44k|                }
  282|  8.77k|            }
  283|  12.0k|            if (mode == 2) {
  ------------------
  |  Branch (283:17): [True: 1.55k, False: 10.4k]
  ------------------
  284|  1.55k|                rnp_key_handle_t skey = encrt_pick_key(ffi, data[12], true);
  285|  1.55k|                if (skey) {
  ------------------
  |  Branch (285:21): [True: 293, False: 1.26k]
  ------------------
  286|    293|                    (void) rnp_op_encrypt_add_signature(op, skey, NULL);
  287|    293|                    rnp_key_handle_destroy(skey);
  288|    293|                }
  289|  1.55k|            }
  290|  12.0k|            (void) rnp_op_encrypt_execute(op);
  291|  12.0k|            rnp_op_encrypt_destroy(op);
  292|  12.0k|        }
  293|  12.0k|    }
  294|  12.7k|    rnp_input_destroy(src);
  295|       |
  296|       |    /* parse rnp's own output back */
  297|  12.7k|    uint8_t *obuf = NULL;
  298|  12.7k|    size_t   olen = 0;
  299|  12.7k|    if (!rnp_output_memory_get_buf(out, &obuf, &olen, false) && olen) {
  ------------------
  |  Branch (299:9): [True: 12.7k, False: 0]
  |  Branch (299:65): [True: 10.2k, False: 2.54k]
  ------------------
  300|  10.2k|        encrt_verify_roundtrip(ffi, obuf, olen);
  301|  10.2k|    }
  302|  12.7k|    rnp_output_destroy(out);
  303|  12.7k|    rnp_ffi_destroy(ffi);
  304|  12.7k|    return 0;
  305|  12.7k|}
encrypt_roundtrip.c:encrt_password_provider:
   88|  8.81k|{
   89|  8.81k|    (void) ffi;
   90|  8.81k|    (void) app_ctx;
   91|  8.81k|    (void) key;
   92|  8.81k|    (void) key_info;
   93|  8.81k|    if (!buf || !buf_len) {
  ------------------
  |  Branch (93:9): [True: 0, False: 8.81k]
  |  Branch (93:17): [True: 0, False: 8.81k]
  ------------------
   94|      0|        return false;
   95|      0|    }
   96|  8.81k|    size_t len = encrt_password_len;
   97|  8.81k|    if (len > buf_len - 1) {
  ------------------
  |  Branch (97:9): [True: 0, False: 8.81k]
  ------------------
   98|      0|        len = buf_len - 1;
   99|      0|    }
  100|  8.81k|    memcpy(buf, encrt_password, len);
  101|  8.81k|    buf[len] = '\0';
  102|       |    return true;
  103|  8.81k|}
encrypt_roundtrip.c:encrt_pick_key:
  109|  11.0k|{
  110|  11.0k|    rnp_identifier_iterator_t it = NULL;
  111|  11.0k|    rnp_key_handle_t          found = NULL;
  112|  11.0k|    const char *              id = NULL;
  113|  11.0k|    size_t                    count = 0;
  114|  11.0k|    size_t                    skip = 0;
  115|  11.0k|    size_t                    idx = 0;
  116|  11.0k|    bool                      have_secret = false;
  117|       |
  118|  11.0k|    if (rnp_identifier_iterator_create(ffi, &it, "fingerprint") != RNP_SUCCESS) {
  ------------------
  |  Branch (118:9): [True: 0, False: 11.0k]
  ------------------
  119|      0|        return NULL;
  120|      0|    }
  121|  30.1k|    while (rnp_identifier_iterator_next(it, &id) == RNP_SUCCESS && id) {
  ------------------
  |  Branch (121:12): [True: 30.1k, False: 0]
  |  Branch (121:68): [True: 19.1k, False: 11.0k]
  ------------------
  122|  19.1k|        count++;
  123|  19.1k|    }
  124|  11.0k|    rnp_identifier_iterator_destroy(it);
  125|  11.0k|    if (!count) {
  ------------------
  |  Branch (125:9): [True: 6.24k, False: 4.80k]
  ------------------
  126|  6.24k|        return NULL;
  127|  6.24k|    }
  128|  4.80k|    skip = selector % count;
  129|  4.80k|    if (rnp_identifier_iterator_create(ffi, &it, "fingerprint") != RNP_SUCCESS) {
  ------------------
  |  Branch (129:9): [True: 0, False: 4.80k]
  ------------------
  130|      0|        return NULL;
  131|      0|    }
  132|  4.80k|    idx = 0;
  133|  14.5k|    while (rnp_identifier_iterator_next(it, &id) == RNP_SUCCESS && id) {
  ------------------
  |  Branch (133:12): [True: 14.5k, False: 0]
  |  Branch (133:68): [True: 13.5k, False: 991]
  ------------------
  134|  13.5k|        if (idx++ < skip) {
  ------------------
  |  Branch (134:13): [True: 6.32k, False: 7.18k]
  ------------------
  135|  6.32k|            continue;
  136|  6.32k|        }
  137|  7.18k|        if (!rnp_locate_key(ffi, "fingerprint", id, &found) && found && secret) {
  ------------------
  |  Branch (137:13): [True: 7.18k, False: 0]
  |  Branch (137:64): [True: 7.18k, False: 0]
  |  Branch (137:73): [True: 3.74k, False: 3.44k]
  ------------------
  138|  3.74k|            if (!rnp_key_have_secret(found, &have_secret) && have_secret) {
  ------------------
  |  Branch (138:17): [True: 3.74k, False: 0]
  |  Branch (138:62): [True: 371, False: 3.37k]
  ------------------
  139|    371|                break;
  140|    371|            }
  141|  3.37k|            rnp_key_handle_destroy(found);
  142|  3.37k|            found = NULL;
  143|       |            /* keep walking: a later key may hold the secret part */
  144|  3.37k|            continue;
  145|  3.74k|        }
  146|  3.44k|        break;
  147|  7.18k|    }
  148|  4.80k|    rnp_identifier_iterator_destroy(it);
  149|  4.80k|    return found;
  150|  4.80k|}
encrypt_roundtrip.c:encrt_verify_roundtrip:
  154|  10.2k|{
  155|  10.2k|    rnp_input_t     vin = NULL;
  156|  10.2k|    rnp_output_t    vout = NULL;
  157|  10.2k|    rnp_op_verify_t vop = NULL;
  158|       |
  159|  10.2k|    if (rnp_input_from_memory(&vin, data, size, false)) {
  ------------------
  |  Branch (159:9): [True: 0, False: 10.2k]
  ------------------
  160|      0|        return;
  161|      0|    }
  162|  10.2k|    if (rnp_output_to_memory(&vout, ROUNDTRIP_MAX_ALLOC)) {
  ------------------
  |  |   59|  10.2k|#define ROUNDTRIP_MAX_ALLOC (16 * 1024 * 1024)
  ------------------
  |  Branch (162:9): [True: 0, False: 10.2k]
  ------------------
  163|      0|        rnp_input_destroy(vin);
  164|      0|        return;
  165|      0|    }
  166|  10.2k|    if (!rnp_op_verify_create(&vop, ffi, vin, vout)) {
  ------------------
  |  Branch (166:9): [True: 10.2k, False: 0]
  ------------------
  167|  10.2k|        (void) rnp_op_verify_execute(vop);
  168|  10.2k|        rnp_op_verify_destroy(vop);
  169|  10.2k|    }
  170|  10.2k|    rnp_output_destroy(vout);
  171|  10.2k|    rnp_input_destroy(vin);
  172|  10.2k|}

_ZN3rnp12backend_initEPPv:
  192|  12.7k|{
  193|  12.7k|    return true;
  194|  12.7k|}
_ZN3rnp14backend_finishEPv:
  198|  12.7k|{
  199|       |    // Do nothing
  200|  12.7k|}

_ZN3rnp2bnC2ERKN3pgp3mpiE:
   93|  5.32k|    bn(const pgp::mpi &val) : bn(val.data(), val.size()){};
_ZN3rnp2bnC2EPKhm:
   83|  17.9k|    {
   84|  17.9k|        botan_mp_init(&bn_);
   85|  17.9k|        if (bn_ && botan_mp_from_bin(bn_, val, len)) {
  ------------------
  |  Branch (85:13): [True: 17.9k, False: 0]
  |  Branch (85:20): [True: 0, False: 17.9k]
  ------------------
   86|       |            /* LCOV_EXCL_START */
   87|      0|            botan_mp_destroy(bn_);
   88|      0|            bn_ = NULL;
   89|       |            /* LCOV_EXCL_END */
   90|      0|        }
   91|  17.9k|    }
_ZNK3rnp2bncvbEv:
  103|  17.9k|    {
  104|  17.9k|        return bn_;
  105|  17.9k|    }
_ZN3rnp5botan6PubkeyC2Ev:
  149|  10.9k|    Pubkey() : key_(NULL){};
_ZN3rnp5botan6Pubkey3getEv:
  160|  21.7k|    {
  161|  21.7k|        return key_;
  162|  21.7k|    };
_ZN3rnp2bn3getEv:
  109|  17.9k|    {
  110|  17.9k|        return bn_;
  111|  17.9k|    }
_ZN3rnp2bnD2Ev:
   98|  17.9k|    {
   99|  17.9k|        botan_mp_destroy(bn_);
  100|  17.9k|    }
_ZN3rnp5botan6PubkeyD2Ev:
  154|  10.9k|    {
  155|  10.9k|        botan_pubkey_destroy(key_);
  156|  10.9k|    }
_ZN3rnp5botan2op6VerifyC2Ev:
  236|  10.7k|    Verify() : op_(NULL){};
_ZN3rnp5botan2op6Verify3getEv:
  247|  32.3k|    {
  248|  32.3k|        return op_;
  249|  32.3k|    };
_ZN3rnp5botan2op6VerifyD2Ev:
  241|  10.7k|    {
  242|  10.7k|        botan_pk_op_verify_destroy(op_);
  243|  10.7k|    }
_ZN3rnp5botan2op7EncryptC2Ev:
  196|     41|    Encrypt() : op_(NULL){};
_ZN3rnp5botan2op7EncryptD2Ev:
  201|     41|    {
  202|     41|        botan_pk_op_encrypt_destroy(op_);
  203|     41|    }
_ZN3rnp5botan2op7Encrypt3getEv:
  207|     82|    {
  208|     82|        return op_;
  209|     82|    };

_ZNK27pgp_dilithium_private_key_t5paramEv:
   53|      3|    {
   54|      3|        return dilithium_param_;
   55|      3|    }
_ZNK27pgp_dilithium_private_key_t11get_encodedEv:
   60|      3|    {
   61|      3|        return key_encoded_.unlock();
   62|      3|    };
_ZNK26pgp_dilithium_public_key_t11get_encodedEv:
   95|     14|    {
   96|     14|        return key_encoded_;
   97|     14|    };
_ZN26pgp_dilithium_public_key_tC2Ev:
   77|  1.11k|    pgp_dilithium_public_key_t() = default;

_ZN26pgp_dilithium_public_key_tC2EPKhm21dilithium_parameter_e:
   35|     18|    : key_encoded_(key_encoded, key_encoded + key_encoded_len), dilithium_param_(param),
   36|     18|      is_initialized_(true)
   37|     18|{
   38|     18|}
_ZN27pgp_dilithium_private_key_tC2EPKhm21dilithium_parameter_e:
   49|      3|    : key_encoded_(key_encoded, key_encoded + key_encoded_len), dilithium_param_(param),
   50|      3|      is_initialized_(true)
   51|      3|{
   52|      3|}
_ZN27pgp_dilithium_private_key_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE21dilithium_parameter_e:
   56|      3|    : key_encoded_(key_encoded), dilithium_param_(param), is_initialized_(true)
   57|      3|{
   58|      3|}
_Z22dilithium_privkey_sizev:
   62|      6|{
   63|       |    /* seed format */
   64|      6|    return 32;
   65|      6|}
_Z21dilithium_pubkey_size21dilithium_parameter_e:
   69|    431|{
   70|    431|    switch (parameter) {
   71|    386|    case dilithium_L3:
  ------------------
  |  Branch (71:5): [True: 386, False: 45]
  ------------------
   72|    386|        return 1952;
   73|     45|    case dilithium_L5:
  ------------------
  |  Branch (73:5): [True: 45, False: 386]
  ------------------
   74|     45|        return 2592;
   75|      0|    default:
  ------------------
  |  Branch (75:5): [True: 0, False: 431]
  ------------------
   76|      0|        RNP_LOG("invalid parameter given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   77|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   78|    431|    }
   79|    431|}
_Z24dilithium_signature_size21dilithium_parameter_e:
   83|    158|{
   84|    158|    switch (parameter) {
   85|    109|    case dilithium_L3:
  ------------------
  |  Branch (85:5): [True: 109, False: 49]
  ------------------
   86|    109|        return 3309;
   87|     49|    case dilithium_L5:
  ------------------
  |  Branch (87:5): [True: 49, False: 109]
  ------------------
   88|     49|        return 4627;
   89|      0|    default:
  ------------------
  |  Branch (89:5): [True: 0, False: 158]
  ------------------
   90|      0|        RNP_LOG("invalid parameter given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   91|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   92|    158|    }
   93|    158|}

_ZN35pgp_dilithium_exdsa_composite_key_tD2Ev:
   32|  2.38k|{
   33|  2.38k|}
_ZNK35pgp_dilithium_exdsa_composite_key_t20initialized_or_throwEv:
   37|     14|{
   38|     14|    if (!is_initialized()) {
  ------------------
  |  Branch (38:9): [True: 0, False: 14]
  ------------------
   39|      0|        RNP_LOG("Trying to use uninitialized mldsa-ecdsa/eddsa key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   40|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_STATE);
   41|      0|    }
   42|     14|}
_ZN35pgp_dilithium_exdsa_composite_key_t24exdsa_curve_privkey_sizeE11pgp_curve_t:
   73|      9|{
   74|      9|    switch (curve) {
   75|      3|    case PGP_CURVE_ED25519:
  ------------------
  |  Branch (75:5): [True: 3, False: 6]
  ------------------
   76|      3|        return 32;
   77|      3|    case PGP_CURVE_ED448:
  ------------------
  |  Branch (77:5): [True: 3, False: 6]
  ------------------
   78|      3|        return 57;
   79|      0|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (79:5): [True: 0, False: 9]
  ------------------
   80|      0|        return 48;
   81|      3|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (81:5): [True: 3, False: 6]
  ------------------
   82|      3|        return 66;
   83|      0|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (83:5): [True: 0, False: 9]
  ------------------
   84|      0|        return 48;
   85|      0|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (85:5): [True: 0, False: 9]
  ------------------
   86|      0|        return 64;
   87|      0|    default:
  ------------------
  |  Branch (87:5): [True: 0, False: 9]
  ------------------
   88|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   89|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   90|      9|    }
   91|      9|}
_ZN35pgp_dilithium_exdsa_composite_key_t23exdsa_curve_pubkey_sizeE11pgp_curve_t:
   95|    449|{
   96|    449|    switch (curve) {
   97|     55|    case PGP_CURVE_ED25519:
  ------------------
  |  Branch (97:5): [True: 55, False: 394]
  ------------------
   98|     55|        return 32;
   99|     21|    case PGP_CURVE_ED448:
  ------------------
  |  Branch (99:5): [True: 21, False: 428]
  ------------------
  100|     21|        return 57;
  101|     22|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (101:5): [True: 22, False: 427]
  ------------------
  102|     22|        return 97;
  103|     19|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (103:5): [True: 19, False: 430]
  ------------------
  104|     19|        return 133;
  105|    319|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (105:5): [True: 319, False: 130]
  ------------------
  106|    319|        return 97;
  107|     13|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (107:5): [True: 13, False: 436]
  ------------------
  108|     13|        return 129;
  109|      0|    default:
  ------------------
  |  Branch (109:5): [True: 0, False: 449]
  ------------------
  110|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  111|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  112|    449|    }
  113|    449|}
_ZN35pgp_dilithium_exdsa_composite_key_t26exdsa_curve_signature_sizeE11pgp_curve_t:
  117|    158|{
  118|    158|    switch (curve) {
  119|     76|    case PGP_CURVE_ED25519:
  ------------------
  |  Branch (119:5): [True: 76, False: 82]
  ------------------
  120|     76|        return 64;
  121|     11|    case PGP_CURVE_ED448:
  ------------------
  |  Branch (121:5): [True: 11, False: 147]
  ------------------
  122|     11|        return 114;
  123|     12|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (123:5): [True: 12, False: 146]
  ------------------
  124|     12|        return 96;
  125|     17|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (125:5): [True: 17, False: 141]
  ------------------
  126|     17|        return 132;
  127|     21|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (127:5): [True: 21, False: 137]
  ------------------
  128|     21|        return 96;
  129|     21|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (129:5): [True: 21, False: 137]
  ------------------
  130|     21|        return 128;
  131|      0|    default:
  ------------------
  |  Branch (131:5): [True: 0, False: 158]
  ------------------
  132|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  133|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  134|    158|    }
  135|    158|}
_ZN35pgp_dilithium_exdsa_composite_key_t22pk_alg_to_dilithium_idE16pgp_pubkey_alg_t:
  139|    610|{
  140|    610|    switch (pk_alg) {
  141|    132|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (141:5): [True: 132, False: 478]
  ------------------
  142|    132|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    132|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  143|    166|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (143:5): [True: 34, False: 576]
  ------------------
  144|    166|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    166|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  145|    506|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (145:5): [True: 340, False: 270]
  ------------------
  146|    506|        return dilithium_L3;
  147|     34|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (147:5): [True: 34, False: 576]
  ------------------
  148|     34|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     34|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  149|     71|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (149:5): [True: 37, False: 573]
  ------------------
  150|     71|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     71|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  151|    104|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (151:5): [True: 33, False: 577]
  ------------------
  152|    104|        return dilithium_L5;
  153|      0|    default:
  ------------------
  |  Branch (153:5): [True: 0, False: 610]
  ------------------
  154|      0|        RNP_LOG("invalid PK alg given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  155|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  156|    610|    }
  157|    610|}
_ZN35pgp_dilithium_exdsa_composite_key_t18pk_alg_to_curve_idE16pgp_pubkey_alg_t:
  161|    637|{
  162|    637|    switch (pk_alg) {
  163|    140|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (163:5): [True: 140, False: 497]
  ------------------
  164|    140|        return PGP_CURVE_ED25519;
  165|     39|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (165:5): [True: 39, False: 598]
  ------------------
  166|     39|        return PGP_CURVE_NIST_P_384;
  167|    340|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (167:5): [True: 340, False: 297]
  ------------------
  168|    340|        return PGP_CURVE_BP384;
  169|     36|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (169:5): [True: 36, False: 601]
  ------------------
  170|     36|        return PGP_CURVE_BP512;
  171|     43|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (171:5): [True: 43, False: 594]
  ------------------
  172|     43|        return PGP_CURVE_NIST_P_521;
  173|     39|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (173:5): [True: 39, False: 598]
  ------------------
  174|     39|        return PGP_CURVE_ED448;
  175|      0|    default:
  ------------------
  |  Branch (175:5): [True: 0, False: 637]
  ------------------
  176|      0|        RNP_LOG("invalid PK alg given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  177|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  178|    637|    }
  179|    637|}
_ZN42pgp_dilithium_exdsa_composite_public_key_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE16pgp_pubkey_alg_t:
  190|     18|    : pk_alg_(pk_alg)
  191|     18|{
  192|     18|    parse_component_keys(key_encoded);
  193|     18|}
_ZN43pgp_dilithium_exdsa_composite_private_key_tC2EPKhm16pgp_pubkey_alg_t:
  213|      3|    : pk_alg_(pk_alg)
  214|      3|{
  215|      3|    parse_component_keys(std::vector<uint8_t>(key_encoded, key_encoded + key_encoded_len));
  216|      3|}
_ZN43pgp_dilithium_exdsa_composite_private_key_taSERKS_:
  230|     89|{
  231|     89|    pgp_dilithium_exdsa_composite_key_t::operator=(other);
  232|     89|    pk_alg_ = other.pk_alg_;
  233|     89|    if (other.is_initialized() && other.dilithium_key_) {
  ------------------
  |  Branch (233:9): [True: 3, False: 86]
  |  Branch (233:35): [True: 3, False: 0]
  ------------------
  234|      3|        dilithium_key_ =
  235|      3|          std::unique_ptr<pgp_dilithium_private_key_t>(new pgp_dilithium_private_key_t(
  236|      3|            other.dilithium_key_->get_encoded(), other.dilithium_key_->param()));
  237|      3|    }
  238|     89|    if (other.is_initialized() && other.exdsa_key_) {
  ------------------
  |  Branch (238:9): [True: 3, False: 86]
  |  Branch (238:35): [True: 3, False: 0]
  ------------------
  239|      3|        exdsa_key_ = std::unique_ptr<exdsa_private_key_t>(new exdsa_private_key_t(
  240|      3|          other.exdsa_key_->get_encoded(), other.exdsa_key_->get_curve()));
  241|      3|    }
  242|       |
  243|     89|    return *this;
  244|     89|}
_ZN43pgp_dilithium_exdsa_composite_private_key_tC2ERKS_:
  248|     86|{
  249|     86|    *this = other;
  250|     86|}
_ZN43pgp_dilithium_exdsa_composite_private_key_t12encoded_sizeE16pgp_pubkey_alg_t:
  273|      6|{
  274|      6|    pgp_curve_t curve = pk_alg_to_curve_id(pk_alg);
  275|      6|    return exdsa_curve_privkey_size(curve) + dilithium_privkey_size();
  276|      6|}
_ZN43pgp_dilithium_exdsa_composite_private_key_t20parse_component_keysENSt3__16vectorIhNS0_9allocatorIhEEEE:
  281|      3|{
  282|      3|    if (key_encoded.size() != encoded_size(pk_alg_)) {
  ------------------
  |  Branch (282:9): [True: 0, False: 3]
  ------------------
  283|      0|        RNP_LOG("ML-DSA composite key format invalid: length mismatch");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  284|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  285|      0|    }
  286|       |
  287|      3|    dilithium_parameter_e dilithium_param = pk_alg_to_dilithium_id(pk_alg_);
  288|      3|    pgp_curve_t           curve = pk_alg_to_curve_id(pk_alg_);
  289|      3|    size_t                split_at = exdsa_curve_privkey_size(pk_alg_to_curve_id(pk_alg_));
  290|       |
  291|      3|    dilithium_key_ =
  292|      3|      std::unique_ptr<pgp_dilithium_private_key_t>(new pgp_dilithium_private_key_t(
  293|      3|        key_encoded.data() + split_at, key_encoded.size() - split_at, dilithium_param));
  294|      3|    exdsa_key_ = std::unique_ptr<exdsa_private_key_t>(
  295|      3|      new exdsa_private_key_t(key_encoded.data(), split_at, curve));
  296|       |
  297|      3|    is_initialized_ = true;
  298|      3|}
_ZN43pgp_dilithium_exdsa_composite_private_key_t12secure_clearEv:
  346|     18|{
  347|       |    // private key buffer is stored in a secure_vector and will be securely erased by the
  348|       |    // destructor.
  349|     18|    dilithium_key_.reset();
  350|     18|    exdsa_key_.reset();
  351|     18|    is_initialized_ = false;
  352|     18|}
_ZN42pgp_dilithium_exdsa_composite_public_key_t12encoded_sizeE16pgp_pubkey_alg_t:
  356|    431|{
  357|    431|    dilithium_parameter_e dilithium_param = pk_alg_to_dilithium_id(pk_alg);
  358|    431|    pgp_curve_t           curve = pk_alg_to_curve_id(pk_alg);
  359|    431|    return exdsa_curve_pubkey_size(curve) + dilithium_pubkey_size(dilithium_param);
  360|    431|}
_ZN42pgp_dilithium_exdsa_composite_public_key_t20parse_component_keysENSt3__16vectorIhNS0_9allocatorIhEEEE:
  365|     18|{
  366|     18|    if (key_encoded.size() != encoded_size(pk_alg_)) {
  ------------------
  |  Branch (366:9): [True: 0, False: 18]
  ------------------
  367|      0|        RNP_LOG("ML-DSA composite key format invalid: length mismatch");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  368|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  369|      0|    }
  370|       |
  371|     18|    dilithium_parameter_e dilithium_param = pk_alg_to_dilithium_id(pk_alg_);
  372|     18|    pgp_curve_t           curve = pk_alg_to_curve_id(pk_alg_);
  373|     18|    size_t                split_at = exdsa_curve_pubkey_size(pk_alg_to_curve_id(pk_alg_));
  374|       |
  375|     18|    dilithium_key_ = pgp_dilithium_public_key_t(
  376|     18|      key_encoded.data() + split_at, key_encoded.size() - split_at, dilithium_param);
  377|     18|    exdsa_key_ = exdsa_public_key_t(key_encoded.data(), split_at, curve);
  378|       |
  379|     18|    is_initialized_ = true;
  380|     18|}
_ZNK42pgp_dilithium_exdsa_composite_public_key_t11get_encodedEv:
  384|     14|{
  385|     14|    initialized_or_throw();
  386|     14|    std::vector<uint8_t> result;
  387|     14|    std::vector<uint8_t> exdsa_key_encoded = exdsa_key_.get_encoded();
  388|     14|    std::vector<uint8_t> dilithium_key_encoded = dilithium_key_.get_encoded();
  389|       |
  390|     14|    result.insert(result.end(), std::begin(exdsa_key_encoded), std::end(exdsa_key_encoded));
  391|     14|    result.insert(
  392|     14|      result.end(), std::begin(dilithium_key_encoded), std::end(dilithium_key_encoded));
  393|     14|    return result;
  394|     14|};

_ZNK35pgp_dilithium_exdsa_composite_key_t14is_initializedEv:
   58|    192|    {
   59|    192|        return is_initialized_;
   60|    192|    }
_ZN31pgp_dilithium_exdsa_signature_t24composite_signature_sizeE16pgp_pubkey_alg_t:
   72|    158|    {
   73|    158|        return dilithium_signature_size(
   74|    158|                 pgp_dilithium_exdsa_composite_key_t::pk_alg_to_dilithium_id(pk_alg)) +
   75|    158|               pgp_dilithium_exdsa_composite_key_t::exdsa_curve_signature_size(
   76|    158|                 pgp_dilithium_exdsa_composite_key_t::pk_alg_to_curve_id(pk_alg));
   77|    158|    }
_ZN43pgp_dilithium_exdsa_composite_private_key_tC2Ev:
   96|  1.09k|    pgp_dilithium_exdsa_composite_private_key_t() = default;
_ZN42pgp_dilithium_exdsa_composite_public_key_tC2Ev:
  140|  1.09k|    pgp_dilithium_exdsa_composite_public_key_t() = default;

_ZNK3pgp3dsa3Key6verifyERKNS0_9SignatureERKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEE:
  152|  1.08k|{
  153|  1.08k|    size_t q_order = q.size();
  154|  1.08k|    size_t z_len = std::min(hash.size(), q_order);
  155|  1.08k|    size_t r_blen = sig.r.size();
  156|  1.08k|    size_t s_blen = sig.s.size();
  157|  1.08k|    if ((r_blen > q_order) || (s_blen > q_order)) {
  ------------------
  |  Branch (157:9): [True: 0, False: 1.08k]
  |  Branch (157:31): [True: 0, False: 1.08k]
  ------------------
  158|      0|        RNP_LOG("Wrong signature");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  159|      0|        return RNP_ERROR_BAD_PARAMETERS;
  160|      0|    }
  161|       |
  162|  1.08k|    rnp::bn bp(p);
  163|  1.08k|    rnp::bn bq(q);
  164|  1.08k|    rnp::bn bg(g);
  165|  1.08k|    rnp::bn by(y);
  166|       |
  167|  1.08k|    if (!bp || !bq || !bg || !by) {
  ------------------
  |  Branch (167:9): [True: 0, False: 1.08k]
  |  Branch (167:16): [True: 0, False: 1.08k]
  |  Branch (167:23): [True: 0, False: 1.08k]
  |  Branch (167:30): [True: 0, False: 1.08k]
  ------------------
  168|      0|        RNP_LOG("out of memory");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  169|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  170|      0|    }
  171|       |
  172|  1.08k|    rnp::botan::Pubkey dsa_key;
  173|  1.08k|    log_size_hint(p, q);
  174|  1.08k|    if (botan_pubkey_load_dsa(&dsa_key.get(), bp.get(), bq.get(), bg.get(), by.get())) {
  ------------------
  |  Branch (174:9): [True: 1, False: 1.08k]
  ------------------
  175|      1|        RNP_LOG("Wrong key");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  176|      1|        return RNP_ERROR_GENERIC;
  177|      1|    }
  178|       |
  179|  1.08k|    std::vector<uint8_t> sign_buf(q_order * 2, 0);
  180|  1.08k|    sig.r.copy(sign_buf.data() + q_order - r_blen);
  181|  1.08k|    sig.s.copy(sign_buf.data() + 2 * q_order - s_blen);
  182|       |
  183|  1.08k|    rnp::botan::op::Verify verify_op;
  184|  1.08k|    if (botan_pk_op_verify_create(&verify_op.get(), dsa_key.get(), "Raw", 0)) {
  ------------------
  |  Branch (184:9): [True: 0, False: 1.08k]
  ------------------
  185|      0|        RNP_LOG("Can't create verifier");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  186|      0|        return RNP_ERROR_GENERIC;
  187|      0|    }
  188|       |
  189|  1.08k|    if (botan_pk_op_verify_update(verify_op.get(), hash.data(), z_len)) {
  ------------------
  |  Branch (189:9): [True: 0, False: 1.08k]
  ------------------
  190|      0|        return RNP_ERROR_GENERIC;
  191|      0|    }
  192|       |
  193|  1.08k|    if (botan_pk_op_verify_finish(verify_op.get(), sign_buf.data(), 2 * q_order)) {
  ------------------
  |  Branch (193:9): [True: 975, False: 111]
  ------------------
  194|    975|        return RNP_ERROR_SIGNATURE_INVALID;
  195|    975|    }
  196|    111|    return RNP_SUCCESS;
  197|  1.08k|}
dsa.cpp:_ZN3pgp3dsaL13log_size_hintERKNS_3mpiES3_:
   45|  1.08k|{
   46|       |#if BOTAN_VERSION_CODE >= BOTAN_VERSION_CODE_FOR(3, 14, 0)
   47|       |    size_t pbits = p.bits();
   48|       |    size_t qbits = q.bits();
   49|       |    bool   fips = ((pbits == 1024) && (qbits == 160)) ||
   50|       |                ((pbits == 2048) && ((qbits == 224) || (qbits == 256))) ||
   51|       |                ((pbits == 3072) && (qbits == 256));
   52|       |    if (!fips) {
   53|       |        RNP_LOG("DSA key with %zu-bit p and %zu-bit q cannot be used: since Botan 3.14 DSA "
   54|       |                "keys are restricted to the FIPS 186-4 size ranges (1024/160, 2048/224, "
   55|       |                "2048/256, 3072/256), see https://github.com/randombit/botan/pull/6039",
   56|       |                pbits,
   57|       |                qbits);
   58|       |    }
   59|       |#endif
   60|  1.08k|}

_ZN3pgp3dsa3Key12clear_secretEv:
   56|  3.91k|    {
   57|  3.91k|        x.forget();
   58|  3.91k|    }
_ZN3pgp3dsa3KeyD2Ev:
   61|  3.43k|    {
   62|  3.43k|        clear_secret();
   63|  3.43k|    }

_ZNK3pgp2ec5Curve5bytesEv:
  102|  16.6k|    {
  103|       |        return BITS_TO_BYTES(bitlen);
  ------------------
  |  |   56|  16.6k|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  ------------------
  104|  16.6k|    }
_ZN3pgp2ec3Key12clear_secretEv:
  125|   153k|    {
  126|   153k|        x.forget();
  127|   153k|    }
_ZN3pgp2ec3KeyD2Ev:
  130|   144k|    {
  131|   144k|        clear_secret();
  132|   144k|    }
_ZN17pgp_ed25519_key_t12clear_secretEv:
  189|  6.39k|    {
  190|  6.39k|        secure_clear(priv.data(), priv.size());
  191|  6.39k|        priv.resize(0);
  192|  6.39k|    }
_ZN17pgp_ed25519_key_tD2Ev:
  195|  5.61k|    {
  196|  5.61k|        clear_secret();
  197|  5.61k|    }
_ZN16pgp_x25519_key_t12clear_secretEv:
  213|  28.8k|    {
  214|  28.8k|        secure_clear(priv.data(), priv.size());
  215|  28.8k|        priv.resize(0);
  216|  28.8k|    }
_ZN16pgp_x25519_key_tD2Ev:
  219|  25.2k|    {
  220|  25.2k|        clear_secret();
  221|  25.2k|    }

_ZN3pgp2ec5Curve6by_OIDERKNSt3__16vectorIhNS2_9allocatorIhEEEE:
  299|  28.6k|{
  300|   179k|    for (size_t i = 0; i < PGP_CURVE_MAX; i++) {
  ------------------
  |  Branch (300:24): [True: 177k, False: 1.34k]
  ------------------
  301|   177k|        if (oid == ec_curves[i].OID) {
  ------------------
  |  Branch (301:13): [True: 27.2k, False: 150k]
  ------------------
  302|  27.2k|            return static_cast<pgp_curve_t>(i);
  303|  27.2k|        }
  304|   177k|    }
  305|  1.34k|    return PGP_CURVE_MAX;
  306|  28.6k|}
_ZN3pgp2ec5Curve3getE11pgp_curve_t:
  322|  45.3k|{
  323|  45.3k|    return (curve_id < PGP_CURVE_MAX && curve_id > 0) ? &ec_curves[curve_id] : NULL;
  ------------------
  |  Branch (323:13): [True: 45.3k, False: 0]
  |  Branch (323:41): [True: 45.3k, False: 1]
  ------------------
  324|  45.3k|}
_ZN3pgp2ec5Curve12is_supportedE11pgp_curve_t:
  347|  6.32k|{
  348|  6.32k|    auto info = Curve::get(curve);
  349|  6.32k|    return info && info->supported;
  ------------------
  |  Branch (349:12): [True: 6.32k, False: 0]
  |  Branch (349:20): [True: 6.32k, False: 0]
  ------------------
  350|  6.32k|}

_ZN3pgp5ecdsa15padding_str_forE14pgp_hash_alg_t:
  107|  6.25k|{
  108|  6.25k|    switch (hash_alg) {
  109|    224|    case PGP_HASH_MD5:
  ------------------
  |  Branch (109:5): [True: 224, False: 6.02k]
  ------------------
  110|    224|        return "Raw(MD5)";
  111|    115|    case PGP_HASH_SHA1:
  ------------------
  |  Branch (111:5): [True: 115, False: 6.13k]
  ------------------
  112|    115|        return "Raw(SHA-1)";
  113|     13|    case PGP_HASH_RIPEMD:
  ------------------
  |  Branch (113:5): [True: 13, False: 6.23k]
  ------------------
  114|     13|        return "Raw(RIPEMD-160)";
  115|  5.39k|    case PGP_HASH_SHA256:
  ------------------
  |  Branch (115:5): [True: 5.39k, False: 861]
  ------------------
  116|  5.39k|        return "Raw(SHA-256)";
  117|     14|    case PGP_HASH_SHA384:
  ------------------
  |  Branch (117:5): [True: 14, False: 6.23k]
  ------------------
  118|     14|        return "Raw(SHA-384)";
  119|    125|    case PGP_HASH_SHA512:
  ------------------
  |  Branch (119:5): [True: 125, False: 6.12k]
  ------------------
  120|    125|        return "Raw(SHA-512)";
  121|     24|    case PGP_HASH_SHA224:
  ------------------
  |  Branch (121:5): [True: 24, False: 6.22k]
  ------------------
  122|     24|        return "Raw(SHA-224)";
  123|    308|    case PGP_HASH_SHA3_256:
  ------------------
  |  Branch (123:5): [True: 308, False: 5.94k]
  ------------------
  124|    308|        return "Raw(SHA-3(256))";
  125|     34|    case PGP_HASH_SHA3_512:
  ------------------
  |  Branch (125:5): [True: 34, False: 6.21k]
  ------------------
  126|     34|        return "Raw(SHA-3(512))";
  127|      4|    case PGP_HASH_SM3:
  ------------------
  |  Branch (127:5): [True: 4, False: 6.24k]
  ------------------
  128|      4|        return "Raw(SM3)";
  129|      0|    default:
  ------------------
  |  Branch (129:5): [True: 0, False: 6.25k]
  ------------------
  130|      0|        return "Raw";
  131|  6.25k|    }
  132|  6.25k|}
_ZN3pgp5ecdsa6verifyERKNS_2ec9SignatureE14pgp_hash_alg_tRKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEERKNS1_3KeyE:
  179|  6.29k|{
  180|  6.29k|    auto curve = ec::Curve::get(key.curve);
  181|  6.29k|    if (!curve) {
  ------------------
  |  Branch (181:9): [True: 0, False: 6.29k]
  ------------------
  182|      0|        RNP_LOG("unknown curve");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  183|      0|        return RNP_ERROR_BAD_PARAMETERS;
  184|      0|    }
  185|       |
  186|  6.29k|    size_t curve_order = curve->bytes();
  187|  6.29k|    size_t r_blen = sig.r.size();
  188|  6.29k|    size_t s_blen = sig.s.size();
  189|  6.29k|    if ((r_blen > curve_order) || (s_blen > curve_order) ||
  ------------------
  |  Branch (189:9): [True: 1, False: 6.29k]
  |  Branch (189:35): [True: 1, False: 6.29k]
  ------------------
  190|  6.29k|        (curve_order > MAX_CURVE_BYTELEN)) {
  ------------------
  |  |   40|  6.29k|#define MAX_CURVE_BYTELEN ((MAX_CURVE_BIT_SIZE + 7) / 8)
  |  |  ------------------
  |  |  |  |   38|  6.29k|#define MAX_CURVE_BIT_SIZE 521 // secp521r1
  |  |  ------------------
  ------------------
  |  Branch (190:9): [True: 0, False: 6.29k]
  ------------------
  191|      2|        return RNP_ERROR_BAD_PARAMETERS;
  192|      2|    }
  193|       |
  194|  6.29k|    rnp::botan::Pubkey pub;
  195|  6.29k|    if (!load_public_key(pub, key)) {
  ------------------
  |  Branch (195:9): [True: 44, False: 6.25k]
  ------------------
  196|     44|        return RNP_ERROR_SIGNATURE_INVALID;
  197|     44|    }
  198|       |
  199|  6.25k|    rnp::botan::op::Verify verifier;
  200|  6.25k|    auto                   pad = padding_str_for(hash_alg);
  201|  6.25k|    if (botan_pk_op_verify_create(&verifier.get(), pub.get(), pad, 0) ||
  ------------------
  |  Branch (201:9): [True: 0, False: 6.25k]
  ------------------
  202|  6.25k|        botan_pk_op_verify_update(verifier.get(), hash.data(), hash.size())) {
  ------------------
  |  Branch (202:9): [True: 0, False: 6.25k]
  ------------------
  203|      0|        return RNP_ERROR_SIGNATURE_INVALID;
  204|      0|    }
  205|       |
  206|  6.25k|    std::vector<uint8_t> sign_buf(2 * curve_order, 0);
  207|       |    // Both can't fail
  208|  6.25k|    sig.r.copy(sign_buf.data() + curve_order - r_blen);
  209|  6.25k|    sig.s.copy(sign_buf.data() + 2 * curve_order - s_blen);
  210|       |
  211|  6.25k|    if (botan_pk_op_verify_finish(verifier.get(), sign_buf.data(), sign_buf.size())) {
  ------------------
  |  Branch (211:9): [True: 6.18k, False: 68]
  ------------------
  212|  6.18k|        return RNP_ERROR_SIGNATURE_INVALID;
  213|  6.18k|    }
  214|     68|    return RNP_SUCCESS;
  215|  6.25k|}
ecdsa.cpp:_ZN3pgp5ecdsaL15load_public_keyERN3rnp5botan6PubkeyERKNS_2ec3KeyE:
   38|  6.29k|{
   39|  6.29k|    auto curve = ec::Curve::get(keydata.curve);
   40|  6.29k|    if (!curve) {
  ------------------
  |  Branch (40:9): [True: 0, False: 6.29k]
  ------------------
   41|      0|        RNP_LOG("unknown curve");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   42|      0|        return false;
   43|      0|    }
   44|  6.29k|    if (!keydata.p.size() || (keydata.p[0] != 0x04)) {
  ------------------
  |  Branch (44:9): [True: 0, False: 6.29k]
  |  Branch (44:30): [True: 3, False: 6.29k]
  ------------------
   45|      3|        RNP_LOG("Failed to load public key: %02x", keydata.p[0]);
  ------------------
  |  |   84|      3|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      3|    do {                                                                                 \
  |  |  |  |   77|      3|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      3|            break;                                                                       \
  |  |  |  |   79|      3|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   46|      3|        return false;
   47|      3|    }
   48|  6.29k|    const size_t curve_order = curve->bytes();
   49|  6.29k|    if (keydata.p.size() != 2 * curve_order + 1) {
  ------------------
  |  Branch (49:9): [True: 0, False: 6.29k]
  ------------------
   50|      0|        return false;
   51|      0|    }
   52|  6.29k|    rnp::bn px(&keydata.p[1], curve_order);
   53|  6.29k|    rnp::bn py(&keydata.p[1] + curve_order, curve_order);
   54|       |
   55|  6.29k|    if (!px || !py) {
  ------------------
  |  Branch (55:9): [True: 0, False: 6.29k]
  |  Branch (55:16): [True: 0, False: 6.29k]
  ------------------
   56|      0|        return false;
   57|      0|    }
   58|       |
   59|  6.29k|    bool res = !botan_pubkey_load_ecdsa(&pubkey.get(), px.get(), py.get(), curve->botan_name);
   60|  6.29k|    if (!res) {
  ------------------
  |  Branch (60:9): [True: 41, False: 6.25k]
  ------------------
   61|     41|        RNP_LOG("failed to load ecdsa %s public key", curve->botan_name);
  ------------------
  |  |   84|     41|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     41|    do {                                                                                 \
  |  |  |  |   77|     41|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 41, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     41|            break;                                                                       \
  |  |  |  |   79|     41|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   62|     41|    }
   63|  6.29k|    return res;
   64|  6.29k|}

_ZN3pgp5eddsa6verifyERKNS_2ec9SignatureERKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEERKNS1_3KeyE:
  147|  3.09k|{
  148|       |    // Unexpected size for Ed25519 signature
  149|  3.09k|    if ((sig.r.size() > 32) || (sig.s.size() > 32)) {
  ------------------
  |  Branch (149:9): [True: 11, False: 3.08k]
  |  Branch (149:32): [True: 0, False: 3.08k]
  ------------------
  150|     11|        return RNP_ERROR_SIGNATURE_INVALID;
  151|     11|    }
  152|       |
  153|  3.08k|    rnp::botan::Pubkey eddsa;
  154|  3.08k|    if (!load_public_key(eddsa, key)) {
  ------------------
  |  Branch (154:9): [True: 0, False: 3.08k]
  ------------------
  155|      0|        return RNP_ERROR_BAD_PARAMETERS;
  156|      0|    }
  157|       |
  158|  3.08k|    rnp::botan::op::Verify verify_op;
  159|  3.08k|    if (botan_pk_op_verify_create(&verify_op.get(), eddsa.get(), "Pure", 0) ||
  ------------------
  |  Branch (159:9): [True: 0, False: 3.08k]
  ------------------
  160|  3.08k|        botan_pk_op_verify_update(verify_op.get(), hash.data(), hash.size())) {
  ------------------
  |  Branch (160:9): [True: 0, False: 3.08k]
  ------------------
  161|      0|        return RNP_ERROR_SIGNATURE_INVALID;
  162|      0|    }
  163|       |
  164|  3.08k|    uint8_t bn_buf[64] = {0};
  165|  3.08k|    sig.r.copy(bn_buf + 32 - sig.r.size());
  166|  3.08k|    sig.s.copy(bn_buf + 64 - sig.s.size());
  167|       |
  168|  3.08k|    if (botan_pk_op_verify_finish(verify_op.get(), bn_buf, 64)) {
  ------------------
  |  Branch (168:9): [True: 2.84k, False: 241]
  ------------------
  169|  2.84k|        return RNP_ERROR_SIGNATURE_INVALID;
  170|  2.84k|    }
  171|    241|    return RNP_SUCCESS;
  172|  3.08k|}
eddsa.cpp:_ZN3pgp5eddsaL15load_public_keyERN3rnp5botan6PubkeyERKNS_2ec3KeyE:
   41|  3.08k|{
   42|  3.08k|    if (keydata.curve != PGP_CURVE_ED25519) {
  ------------------
  |  Branch (42:9): [True: 0, False: 3.08k]
  ------------------
   43|      0|        return false;
   44|      0|    }
   45|       |    /*
   46|       |     * See draft-ietf-openpgp-rfc4880bis-01 section 13.3
   47|       |     */
   48|  3.08k|    if ((keydata.p.size() != 33) || (keydata.p[0] != 0x40)) {
  ------------------
  |  Branch (48:9): [True: 0, False: 3.08k]
  |  Branch (48:37): [True: 0, False: 3.08k]
  ------------------
   49|      0|        return false;
   50|      0|    }
   51|  3.08k|    if (botan_pubkey_load_ed25519(&pubkey.get(), &keydata.p[1])) {
  ------------------
  |  Branch (51:9): [True: 0, False: 3.08k]
  ------------------
   52|      0|        return false;
   53|      0|    }
   54|  3.08k|    return true;
   55|  3.08k|}

_ZNK3pgp2eg3Key13encrypt_pkcs1ERN3rnp3RNGERNS0_9EncryptedERKNSt3__16vectorIhNS2_16secure_allocatorIhEEEE:
  141|     41|{
  142|     41|    rnp::botan::Pubkey b_key;
  143|     41|    if (!load_public_key(b_key, *this)) {
  ------------------
  |  Branch (143:9): [True: 0, False: 41]
  ------------------
  144|      0|        RNP_LOG("Failed to load public key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  145|      0|        return RNP_ERROR_BAD_PARAMETERS;
  146|      0|    }
  147|       |
  148|       |    /* Size of output buffer must be equal to twice the size of key byte len.
  149|       |     * as ElGamal encryption outputs concatenation of two components, both
  150|       |     * of size equal to size of public key byte len.
  151|       |     * Successful call to botan's ElGamal encryption will return output that's
  152|       |     * always 2*pubkey size.
  153|       |     */
  154|     41|    size_t                  p_len = p.size() * 2;
  155|     41|    std::vector<uint8_t>    enc_buf(p_len, 0);
  156|     41|    rnp::botan::op::Encrypt op_ctx;
  157|       |
  158|     41|    if (botan_pk_op_encrypt_create(&op_ctx.get(), b_key.get(), "PKCS1v15", 0) ||
  ------------------
  |  Branch (158:9): [True: 0, False: 41]
  ------------------
  159|     41|        botan_pk_op_encrypt(
  ------------------
  |  Branch (159:9): [True: 0, False: 41]
  ------------------
  160|     41|          op_ctx.get(), rng.handle(), enc_buf.data(), &p_len, in.data(), in.size())) {
  161|      0|        RNP_LOG("Failed to create operation context");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  162|      0|        return RNP_ERROR_BAD_PARAMETERS;
  163|      0|    }
  164|       |
  165|       |    /*
  166|       |     * Botan's ElGamal formats the g^k and msg*(y^k) together into a single byte string.
  167|       |     * We have to parse out the two values after encryption, as rnp stores those values
  168|       |     * separately.
  169|       |     *
  170|       |     * We don't trim zeros from octet string as it is done before final marshalling
  171|       |     * (add_packet_body_mpi)
  172|       |     *
  173|       |     * We must assume that botan copies even number of bytes to output buffer (to avoid
  174|       |     * memory corruption)
  175|       |     */
  176|     41|    p_len /= 2;
  177|     41|    out.g.assign(enc_buf.data(), p_len);
  178|     41|    out.m.assign(enc_buf.data() + p_len, p_len);
  179|     41|    return RNP_SUCCESS;
  180|     41|}
elgamal.cpp:_ZN3pgp2egL15load_public_keyERN3rnp5botan6PubkeyERKNS0_3KeyE:
   44|     41|{
   45|       |    // Check if provided public key byte size is not greater than ELGAMAL_MAX_P_BYTELEN.
   46|     41|    if (key.p.size() > ELGAMAL_MAX_P_BYTELEN) {
  ------------------
  |  |   37|     41|#define ELGAMAL_MAX_P_BYTELEN BITS_TO_BYTES(PGP_MPINT_BITS)
  |  |  ------------------
  |  |  |  |   56|     41|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  |  |  ------------------
  ------------------
  |  Branch (46:9): [True: 0, False: 41]
  ------------------
   47|      0|        return false;
   48|      0|    }
   49|       |
   50|     41|    rnp::bn p(key.p);
   51|     41|    rnp::bn g(key.g);
   52|     41|    rnp::bn y(key.y);
   53|       |
   54|     41|    if (!p || !g || !y) {
  ------------------
  |  Branch (54:9): [True: 0, False: 41]
  |  Branch (54:15): [True: 0, False: 41]
  |  Branch (54:21): [True: 0, False: 41]
  ------------------
   55|      0|        return false;
   56|      0|    }
   57|     41|    return !botan_pubkey_load_elgamal(&pubkey.get(), p.get(), g.get(), y.get());
   58|     41|}

_ZN3pgp2eg3Key12clear_secretEv:
   62|  2.46k|    {
   63|  2.46k|        x.forget();
   64|  2.46k|    }
_ZN3pgp2eg3KeyD2Ev:
   67|  2.26k|    {
   68|  2.26k|        clear_secret();
   69|  2.26k|    }

_ZN8ec_key_tD2Ev:
  117|  1.64k|{
  118|  1.64k|}
_ZN8ec_key_tC2E11pgp_curve_t:
  120|     55|ec_key_t::ec_key_t(pgp_curve_t curve) : curve_(curve)
  121|     55|{
  122|     55|}
_ZN21ecdh_kem_public_key_tC2EPhm11pgp_curve_t:
  127|     23|    : ec_key_t(curve), key_(std::vector<uint8_t>(key_buf, key_buf + key_buf_len))
  128|     23|{
  129|     23|}
_ZN22ecdh_kem_private_key_tC2EPhm11pgp_curve_t:
  138|      4|    : ec_key_t(curve), key_(key_buf, key_buf + key_buf_len)
  139|      4|{
  140|      4|}
_ZN22ecdh_kem_private_key_tC2ENSt3__16vectorIhNS0_9allocatorIhEEEE11pgp_curve_t:
  142|      4|    : ec_key_t(curve), key_(std::move(key))
  143|      4|{
  144|      4|}
_ZN18exdsa_public_key_tC2EPhm11pgp_curve_t:
  290|     18|    : ec_key_t(curve), key_(key_buf, key_buf + key_buf_len)
  291|     18|{
  292|     18|}
_ZN19exdsa_private_key_tC2EPhm11pgp_curve_t:
  301|      3|    : ec_key_t(curve), key_(key_buf, key_buf + key_buf_len)
  302|      3|{
  303|      3|}
_ZN19exdsa_private_key_tC2ENSt3__16vectorIhNS0_9allocatorIhEEEE11pgp_curve_t:
  305|      3|    : ec_key_t(curve), key_(std::move(key))
  306|      3|{
  307|      3|}

_ZNK8ec_key_t9get_curveEv:
   61|      7|    {
   62|      7|        return curve_;
   63|      7|    }
_ZNK21ecdh_kem_public_key_t11get_encodedEv:
   85|     12|    {
   86|     12|        return key_;
   87|     12|    }
_ZNK22ecdh_kem_private_key_t11get_encodedEv:
  107|      4|    {
  108|      4|        return key_.unlock();
  109|      4|    }
_ZNK18exdsa_public_key_t11get_encodedEv:
  142|     14|    {
  143|     14|        return key_;
  144|     14|    }
_ZNK19exdsa_private_key_t11get_encodedEv:
  166|      3|    {
  167|      3|        return key_.unlock();
  168|      3|    }
_ZN8ec_key_tC2Ev:
   48|  1.43k|    ec_key_t() = default;
_ZN21ecdh_kem_public_key_tC2Ev:
   73|    315|    ecdh_kem_public_key_t() = default;
_ZN18exdsa_public_key_tC2Ev:
  130|  1.11k|    exdsa_public_key_t() = default;

_ZN3rnp10Hash_BotanC2E14pgp_hash_alg_t:
   49|  24.1k|Hash_Botan::Hash_Botan(pgp_hash_alg_t alg) : Hash(alg)
   50|  24.1k|{
   51|  24.1k|    auto name = Hash_Botan::name_backend(alg);
   52|  24.1k|    if (!name) {
  ------------------
  |  Branch (52:9): [True: 0, False: 24.1k]
  ------------------
   53|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   54|      0|    }
   55|       |
   56|  24.1k|    if (botan_hash_init(&fn_, name, 0)) {
  ------------------
  |  Branch (56:9): [True: 101, False: 24.0k]
  ------------------
   57|    101|        RNP_LOG("Error creating hash object for '%s'", name);
  ------------------
  |  |   84|    101|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    101|    do {                                                                                 \
  |  |  |  |   77|    101|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 101, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    101|            break;                                                                       \
  |  |  |  |   79|    101|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   58|    101|        fn_ = nullptr;
   59|    101|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   60|    101|    }
   61|       |
   62|  24.0k|    size_t outlen = 0;
   63|  24.0k|    botan_hash_output_length(fn_, &outlen);
   64|       |    assert(size_ == outlen);
   65|  24.0k|}
_ZN3rnp10Hash_BotanD2Ev:
   78|  24.0k|{
   79|  24.0k|    if (fn_) {
  ------------------
  |  Branch (79:9): [True: 5.81k, False: 18.2k]
  ------------------
   80|  5.81k|        botan_hash_destroy(fn_);
   81|  5.81k|    }
   82|  24.0k|}
_ZN3rnp10Hash_Botan6createE14pgp_hash_alg_t:
   86|  24.1k|{
   87|  24.1k|    return std::unique_ptr<Hash_Botan>(new Hash_Botan(alg));
   88|  24.1k|}
_ZN3rnp10Hash_Botan3addEPKvm:
   98|  27.4M|{
   99|  27.4M|    if (!fn_) {
  ------------------
  |  Branch (99:9): [True: 0, False: 27.4M]
  ------------------
  100|      0|        throw rnp_exception(RNP_ERROR_NULL_POINTER);
  101|      0|    }
  102|  27.4M|    if (botan_hash_update(fn_, static_cast<const uint8_t *>(buf), len)) {
  ------------------
  |  Branch (102:9): [True: 0, False: 27.4M]
  ------------------
  103|      0|        throw rnp_exception(RNP_ERROR_GENERIC);
  104|      0|    }
  105|  27.4M|}
_ZN3rnp10Hash_Botan6finishEPh:
  109|  18.2k|{
  110|  18.2k|    assert(fn_);
  111|  18.2k|    if (!fn_) {
  ------------------
  |  Branch (111:9): [True: 0, False: 18.2k]
  ------------------
  112|      0|        return;
  113|      0|    }
  114|  18.2k|    if (digest) {
  ------------------
  |  Branch (114:9): [True: 18.2k, False: 0]
  ------------------
  115|  18.2k|        botan_hash_final(fn_, digest);
  116|  18.2k|    }
  117|  18.2k|    botan_hash_destroy(fn_);
  118|  18.2k|    fn_ = nullptr;
  119|  18.2k|    size_ = 0;
  120|  18.2k|}
_ZN3rnp10Hash_Botan12name_backendE14pgp_hash_alg_t:
  124|  51.6k|{
  125|  51.6k|    return id_str_pair::lookup(botan_alg_map, alg);
  126|  51.6k|}
_ZN3rnp11CRC24_BotanC2Ev:
  129|  16.3k|{
  130|  16.3k|    if (botan_hash_init(&fn_, "CRC24", 0)) {
  ------------------
  |  Branch (130:9): [True: 0, False: 16.3k]
  ------------------
  131|      0|        RNP_LOG("Error creating CRC24 object");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  132|      0|        fn_ = nullptr;
  133|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  134|      0|    }
  135|  16.3k|    size_t outlen = 0;
  136|  16.3k|    botan_hash_output_length(fn_, &outlen);
  137|       |    assert(3 == outlen);
  138|  16.3k|}
_ZN3rnp11CRC24_BotanD2Ev:
  141|  16.3k|{
  142|  16.3k|    if (fn_) {
  ------------------
  |  Branch (142:9): [True: 8.24k, False: 8.15k]
  ------------------
  143|  8.24k|        botan_hash_destroy(fn_);
  144|  8.24k|    }
  145|  16.3k|}
_ZN3rnp11CRC24_Botan6createEv:
  149|  16.3k|{
  150|  16.3k|    return std::unique_ptr<CRC24_Botan>(new CRC24_Botan());
  151|  16.3k|}
_ZN3rnp11CRC24_Botan3addEPKvm:
  155|  18.7k|{
  156|  18.7k|    if (!fn_) {
  ------------------
  |  Branch (156:9): [True: 0, False: 18.7k]
  ------------------
  157|      0|        throw rnp_exception(RNP_ERROR_NULL_POINTER);
  158|      0|    }
  159|  18.7k|    if (botan_hash_update(fn_, static_cast<const uint8_t *>(buf), len)) {
  ------------------
  |  Branch (159:9): [True: 0, False: 18.7k]
  ------------------
  160|      0|        throw rnp_exception(RNP_ERROR_GENERIC);
  161|      0|    }
  162|  18.7k|}
_ZN3rnp11CRC24_Botan6finishEv:
  166|  8.15k|{
  167|  8.15k|    if (!fn_) {
  ------------------
  |  Branch (167:9): [True: 0, False: 8.15k]
  ------------------
  168|      0|        throw rnp_exception(RNP_ERROR_NULL_POINTER);
  169|      0|    }
  170|  8.15k|    std::array<uint8_t, 3> crc{};
  171|  8.15k|    botan_hash_final(fn_, crc.data());
  172|  8.15k|    botan_hash_destroy(fn_);
  173|  8.15k|    fn_ = nullptr;
  174|  8.15k|    return crc;
  175|  8.15k|}

_ZN3rnp4HashC2E14pgp_hash_alg_t:
   48|   179k|    Hash(pgp_hash_alg_t alg) : alg_(alg)
   49|   179k|    {
   50|   179k|        size_ = Hash::size(alg);
   51|   179k|    };
_ZN3rnp5CRC24C2Ev:
   81|  16.3k|    CRC24(){};
_ZN3rnp5CRC24D2Ev:
   89|  16.3k|    virtual ~CRC24(){};

_ZNK3rnp4Hash3algEv:
   62|  19.9k|{
   63|  19.9k|    return alg_;
   64|  19.9k|}
_ZNK3rnp4Hash4sizeEv:
   68|  11.3k|{
   69|  11.3k|    return Hash::size(alg_);
   70|  11.3k|}
_ZN3rnp4Hash6createE14pgp_hash_alg_t:
   74|   179k|{
   75|   179k|    if (alg == PGP_HASH_SHA1) {
  ------------------
  |  Branch (75:9): [True: 154k, False: 24.1k]
  ------------------
   76|   154k|        return Hash_SHA1CD::create();
   77|   154k|    }
   78|       |#if !defined(ENABLE_SM2)
   79|       |    if (alg == PGP_HASH_SM3) {
   80|       |        RNP_LOG("SM3 hash is not available.");
   81|       |        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   82|       |    }
   83|       |#endif
   84|       |#if defined(CRYPTO_BACKEND_OPENSSL)
   85|       |    return Hash_OpenSSL::create(alg);
   86|       |#elif defined(CRYPTO_BACKEND_BOTAN)
   87|  24.1k|    return Hash_Botan::create(alg);
   88|       |#else
   89|       |#error "Crypto backend not specified"
   90|       |#endif
   91|   179k|}
_ZN3rnp5CRC246createEv:
   95|  16.3k|{
   96|       |#if defined(CRYPTO_BACKEND_OPENSSL)
   97|       |    return CRC24_RNP::create();
   98|       |#elif defined(CRYPTO_BACKEND_BOTAN)
   99|       |    return CRC24_Botan::create();
  100|       |#else
  101|       |#error "Crypto backend not specified"
  102|       |#endif
  103|  16.3k|}
_ZN3rnp4Hash3addERKNSt3__16vectorIhNS1_9allocatorIhEEEE:
  107|   226k|{
  108|   226k|    add(val.data(), val.size());
  109|   226k|}
_ZN3rnp4Hash3addEj:
  113|  12.6k|{
  114|  12.6k|    uint8_t ibuf[4];
  115|  12.6k|    write_uint32(ibuf, val);
  116|  12.6k|    add(ibuf, sizeof(ibuf));
  117|  12.6k|}
_ZN3rnp4Hash3addERKN3pgp3mpiE:
  121|  12.6k|{
  122|  12.6k|    size_t len = val.size();
  123|  12.6k|    size_t idx = 0;
  124|  16.4k|    while ((idx < len) && (!val[idx])) {
  ------------------
  |  Branch (124:12): [True: 13.1k, False: 3.25k]
  |  Branch (124:27): [True: 3.81k, False: 9.35k]
  ------------------
  125|  3.81k|        idx++;
  126|  3.81k|    }
  127|       |
  128|  12.6k|    if (idx >= len) {
  ------------------
  |  Branch (128:9): [True: 3.25k, False: 9.35k]
  ------------------
  129|  3.25k|        add(0);
  130|  3.25k|        return;
  131|  3.25k|    }
  132|       |
  133|  9.35k|    add(len - idx);
  134|  9.35k|    if (val[idx] & 0x80) {
  ------------------
  |  Branch (134:9): [True: 3.02k, False: 6.32k]
  ------------------
  135|  3.02k|        uint8_t padbyte = 0;
  136|  3.02k|        add(&padbyte, 1);
  137|  3.02k|    }
  138|  9.35k|    add(val.data() + idx, len - idx);
  139|  9.35k|}
_ZN3rnp4Hash6finishEv:
  143|  35.2k|{
  144|  35.2k|    std::vector<uint8_t> res(size_, 0);
  145|  35.2k|    finish(res.data());
  146|  35.2k|    return res;
  147|  35.2k|}
_ZN3rnp4HashD2Ev:
  158|   179k|{
  159|   179k|}
_ZN3rnp4Hash4sizeE14pgp_hash_alg_t:
  185|   197k|{
  186|   197k|    size_t val = 0;
  187|   197k|    ARRAY_LOOKUP_BY_ID(hash_alg_map, type, len, alg, val);
  ------------------
  |  |   45|   197k|    do {                                                                  \
  |  |   46|   484k|        for (size_t i__ = 0; i__ < ARRAY_SIZE(array); i__++) {            \
  |  |  ------------------
  |  |  |  |   34|   484k|#define ARRAY_SIZE(a) (sizeof(a) / sizeof(*(a)))
  |  |  ------------------
  |  |  |  Branch (46:30): [True: 484k, False: 101]
  |  |  ------------------
  |  |   47|   484k|            if ((array)[i__].id_field == (lookup_value)) {                \
  |  |  ------------------
  |  |  |  Branch (47:17): [True: 197k, False: 287k]
  |  |  ------------------
  |  |   48|   197k|                (ret) = (array)[i__].ret_field;                           \
  |  |   49|   197k|                break;                                                    \
  |  |   50|   197k|            }                                                             \
  |  |   51|   484k|        }                                                                 \
  |  |   52|   197k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (52:14): [Folded, False: 197k]
  |  |  ------------------
  ------------------
  188|   197k|    return val;
  189|   197k|}
_ZN3rnp8HashList7add_algE14pgp_hash_alg_t:
  193|  8.20k|{
  194|  8.20k|    if (!get(alg)) {
  ------------------
  |  Branch (194:9): [True: 5.35k, False: 2.85k]
  ------------------
  195|  5.35k|        hashes.emplace_back(std::make_pair(rnp::Hash::create(alg), std::vector<uint8_t>()));
  196|  5.35k|    }
  197|  8.20k|}
_ZNK3rnp8HashList3getE14pgp_hash_alg_t:
  201|  8.20k|{
  202|  8.20k|    for (auto &hash : hashes) {
  ------------------
  |  Branch (202:21): [True: 5.04k, False: 5.35k]
  ------------------
  203|  5.04k|        if (hash.first->alg() == alg && hash.second.empty()) {
  ------------------
  |  Branch (203:13): [True: 3.84k, False: 1.20k]
  |  Branch (203:41): [True: 2.85k, False: 992]
  ------------------
  204|  2.85k|            return hash.first.get();
  205|  2.85k|        }
  206|  5.04k|    }
  207|  5.35k|    return nullptr;
  208|  8.20k|}
_ZN3rnp8HashList3addEPKvm:
  212|  29.5M|{
  213|  29.5M|    for (auto &hash : hashes) {
  ------------------
  |  Branch (213:21): [True: 29.5M, False: 29.5M]
  ------------------
  214|  29.5M|        hash.first->add(buf, len);
  215|  29.5M|    }
  216|  29.5M|}
_ZN3rnp8HashList7add_algE14pgp_hash_alg_tNSt3__16vectorIhNS2_9allocatorIhEEEE:
  234|  2.06k|{
  235|  2.06k|    if (!get(alg, salt)) {
  ------------------
  |  Branch (235:9): [True: 1.85k, False: 215]
  ------------------
  236|  1.85k|        hashes.emplace_back(std::make_pair(rnp::Hash::create(alg), salt));
  237|  1.85k|        hashes.back().first->add(salt); // consume salt as first input
  238|  1.85k|    }
  239|  2.06k|}
_ZNK3rnp8HashList3getE14pgp_hash_alg_tNSt3__16vectorIhNS2_9allocatorIhEEEE:
  243|  2.06k|{
  244|  3.58k|    for (auto &hash : hashes) {
  ------------------
  |  Branch (244:21): [True: 3.58k, False: 1.85k]
  ------------------
  245|  3.58k|        if (hash.first->alg() == alg && hash.second == salt) {
  ------------------
  |  Branch (245:13): [True: 2.85k, False: 732]
  |  Branch (245:41): [True: 215, False: 2.63k]
  ------------------
  246|    215|            return hash.first.get();
  247|    215|        }
  248|  3.58k|    }
  249|  1.85k|    return NULL;
  250|  2.06k|}

_ZN3rnp11Hash_SHA1CDC2Ev:
   35|   154k|Hash_SHA1CD::Hash_SHA1CD() : Hash(PGP_HASH_SHA1)
   36|   154k|{
   37|       |    assert(size_ == 20);
   38|   154k|    SHA1DCInit(&ctx_);
   39|   154k|}
_ZN3rnp11Hash_SHA1CDD2Ev:
   47|   154k|{
   48|   154k|}
_ZN3rnp11Hash_SHA1CD6createEv:
   52|   154k|{
   53|   154k|    return std::unique_ptr<Hash_SHA1CD>(new Hash_SHA1CD());
   54|   154k|}
_ZN3rnp11Hash_SHA1CD3addEPKvm:
   69|  2.84M|{
   70|  2.84M|    SHA1DCUpdate(&ctx_, (const char *) buf, len);
   71|  2.84M|}
_ZN3rnp11Hash_SHA1CD6finishEPh:
   78|   153k|{
   79|   153k|    unsigned char fixed_digest[20];
   80|   153k|    int           res = SHA1DCFinal(fixed_digest, &ctx_);
   81|   153k|    if (res && digest) {
  ------------------
  |  Branch (81:9): [True: 0, False: 153k]
  |  Branch (81:16): [True: 0, False: 0]
  ------------------
   82|       |        /* Show warning only if digest is non-null */
   83|      0|        RNP_LOG("Warning! SHA1 collision detected and mitigated.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   84|      0|    }
   85|       |    /* On collision fixed_digest holds the safe (mitigated) hash, never leave digest unset */
   86|   153k|    if (digest) {
  ------------------
  |  Branch (86:9): [True: 153k, False: 0]
  ------------------
   87|   153k|        memcpy(digest, fixed_digest, 20);
   88|   153k|    }
   89|   153k|}

_ZN3rnp4Hkdf6createE14pgp_hash_alg_t:
   44|  6.79k|{
   45|       |#if defined(CRYPTO_BACKEND_OPENSSL)
   46|       |    return Hkdf_OpenSSL::create(alg);
   47|       |#elif defined(CRYPTO_BACKEND_BOTAN)
   48|       |    return Hkdf_Botan::create(alg);
   49|       |#else
   50|       |#error "Crypto backend not specified"
   51|       |#endif
   52|  6.79k|}
_ZNK3rnp4Hkdf3algEv:
   62|  6.79k|{
   63|  6.79k|    return hash_alg_;
   64|  6.79k|}
_ZN3rnp4HkdfD2Ev:
   67|  6.79k|{
   68|  6.79k|}

_ZN3rnp4HkdfC2E14pgp_hash_alg_t:
   47|  6.79k|    Hkdf(pgp_hash_alg_t hash_alg) : hash_alg_(hash_alg)
   48|  6.79k|    {
   49|  6.79k|        size_ = Hash::size(hash_alg);
   50|  6.79k|    };

_ZN3rnp10Hkdf_BotanC2E14pgp_hash_alg_t:
   39|  6.79k|Hkdf_Botan::Hkdf_Botan(pgp_hash_alg_t hash_alg) : Hkdf(hash_alg)
   40|  6.79k|{
   41|  6.79k|}
_ZN3rnp10Hkdf_Botan6createE14pgp_hash_alg_t:
   45|  6.79k|{
   46|  6.79k|    return std::unique_ptr<Hkdf_Botan>(new Hkdf_Botan(alg));
   47|  6.79k|}
_ZNK3rnp10Hkdf_Botan3algEv:
   51|  6.79k|{
   52|  6.79k|    return std::string("HKDF(") + Hash_Botan::name_backend(Hkdf::alg()) + ")";
   53|  6.79k|}
_ZN3rnp10Hkdf_Botan14extract_expandEPKhmS2_mS2_mPhm:
   64|  6.79k|{
   65|  6.79k|    if (botan_kdf(Hkdf_Botan::alg().c_str(),
  ------------------
  |  Branch (65:9): [True: 0, False: 6.79k]
  ------------------
   66|  6.79k|                  output_buf,
   67|  6.79k|                  output_length,
   68|  6.79k|                  ikm,
   69|  6.79k|                  ikm_len,
   70|  6.79k|                  salt,
   71|  6.79k|                  salt_len,
   72|  6.79k|                  info,
   73|  6.79k|                  info_len)) {
   74|      0|        RNP_LOG("HKDF derivation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   75|      0|        throw rnp_exception(RNP_ERROR_GENERIC);
   76|      0|    }
   77|  6.79k|}
_ZN3rnp10Hkdf_BotanD2Ev:
   80|  6.79k|{
   81|  6.79k|}

_ZNK23pgp_kyber_private_key_t11get_encodedEv:
   60|      4|    {
   61|      4|        return key_encoded_.unlock();
   62|      4|    };
_ZNK23pgp_kyber_private_key_t5paramEv:
   66|      4|    {
   67|      4|        return kyber_mode_;
   68|      4|    }
_ZNK22pgp_kyber_public_key_t11get_encodedEv:
   95|     12|    {
   96|     12|        return key_encoded_;
   97|     12|    };
_ZN22pgp_kyber_public_key_tC2Ev:
   82|    315|    pgp_kyber_public_key_t() = default;

_Z18kyber_privkey_sizev:
   34|      8|{
   35|       |    /* seed format */
   36|      8|    return 64;
   37|      8|}
_Z17kyber_pubkey_size17kyber_parameter_e:
   41|    285|{
   42|    285|    switch (parameter) {
   43|    195|    case kyber_768:
  ------------------
  |  Branch (43:5): [True: 195, False: 90]
  ------------------
   44|    195|        return 1184;
   45|     90|    case kyber_1024:
  ------------------
  |  Branch (45:5): [True: 90, False: 195]
  ------------------
   46|     90|        return 1568;
   47|      0|    default:
  ------------------
  |  Branch (47:5): [True: 0, False: 285]
  ------------------
   48|      0|        RNP_LOG("invalid parameter given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   49|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   50|    285|    }
   51|    285|}
_Z21kyber_ciphertext_size17kyber_parameter_e:
   55|    114|{
   56|    114|    switch (parameter) {
   57|     52|    case kyber_768:
  ------------------
  |  Branch (57:5): [True: 52, False: 62]
  ------------------
   58|     52|        return 1088;
   59|     62|    case kyber_1024:
  ------------------
  |  Branch (59:5): [True: 62, False: 52]
  ------------------
   60|     62|        return 1568;
   61|      0|    default:
  ------------------
  |  Branch (61:5): [True: 0, False: 114]
  ------------------
   62|      0|        RNP_LOG("invalid parameter given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   63|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   64|    114|    }
   65|    114|}
_ZN22pgp_kyber_public_key_tC2EPKhm17kyber_parameter_e:
   70|     23|    : key_encoded_(key_encoded, key_encoded + key_encoded_len), kyber_mode_(mode),
   71|     23|      is_initialized_(true)
   72|     23|{
   73|     23|}
_ZN23pgp_kyber_private_key_tC2EPKhm17kyber_parameter_e:
   84|      4|    : key_encoded_(key_encoded, key_encoded + key_encoded_len), kyber_mode_(mode),
   85|      4|      is_initialized_(true)
   86|      4|{
   87|      4|}
_ZN23pgp_kyber_private_key_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE17kyber_parameter_e:
   91|      4|    : key_encoded_(key_encoded), kyber_mode_(mode), is_initialized_(true)
   92|      4|{
   93|      4|}

_ZN30pgp_kyber_ecdh_composite_key_tD2Ev:
   47|    757|{
   48|    757|}
_ZNK30pgp_kyber_ecdh_composite_key_t20initialized_or_throwEv:
   52|     12|{
   53|     12|    if (!is_initialized()) {
  ------------------
  |  Branch (53:9): [True: 0, False: 12]
  ------------------
   54|      0|        RNP_LOG("Trying to use uninitialized kyber-ecdh key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   55|      0|        throw rnp::rnp_exception(RNP_ERROR_GENERIC); /* TODO better return error */
   56|      0|    }
   57|     12|}
_ZN30pgp_kyber_ecdh_composite_key_t23ecdh_curve_privkey_sizeE11pgp_curve_t:
   88|     12|{
   89|     12|    switch (curve) {
   90|      0|    case PGP_CURVE_25519:
  ------------------
  |  Branch (90:5): [True: 0, False: 12]
  ------------------
   91|      0|        return 32;
   92|      0|#if defined(ENABLE_CRYPTO_REFRESH)
   93|      0|    case PGP_CURVE_448:
  ------------------
  |  Branch (93:5): [True: 0, False: 12]
  ------------------
   94|      0|        return 56;
   95|      0|#endif
   96|      0|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (96:5): [True: 0, False: 12]
  ------------------
   97|      0|        return 48;
   98|      3|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (98:5): [True: 3, False: 9]
  ------------------
   99|      3|        return 66;
  100|      0|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (100:5): [True: 0, False: 12]
  ------------------
  101|      0|        return 48;
  102|      9|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (102:5): [True: 9, False: 3]
  ------------------
  103|      9|        return 64;
  104|      0|    default:
  ------------------
  |  Branch (104:5): [True: 0, False: 12]
  ------------------
  105|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  106|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  107|     12|    }
  108|     12|}
_ZN30pgp_kyber_ecdh_composite_key_t22ecdh_curve_pubkey_sizeE11pgp_curve_t:
  112|    308|{
  113|    308|    switch (curve) {
  114|    142|    case PGP_CURVE_25519:
  ------------------
  |  Branch (114:5): [True: 142, False: 166]
  ------------------
  115|    142|        return 32;
  116|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  117|     13|    case PGP_CURVE_448:
  ------------------
  |  Branch (117:5): [True: 13, False: 295]
  ------------------
  118|     13|        return 56;
  119|      0|#endif
  120|     41|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (120:5): [True: 41, False: 267]
  ------------------
  121|     41|        return 97;
  122|     20|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (122:5): [True: 20, False: 288]
  ------------------
  123|     20|        return 133;
  124|     16|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (124:5): [True: 16, False: 292]
  ------------------
  125|     16|        return 97;
  126|     76|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (126:5): [True: 76, False: 232]
  ------------------
  127|     76|        return 129;
  128|      0|    default:
  ------------------
  |  Branch (128:5): [True: 0, False: 308]
  ------------------
  129|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  130|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  131|    308|    }
  132|    308|}
_ZN30pgp_kyber_ecdh_composite_key_t25ecdh_curve_ephemeral_sizeE11pgp_curve_t:
  136|    114|{
  137|    114|    switch (curve) {
  138|     10|    case PGP_CURVE_25519:
  ------------------
  |  Branch (138:5): [True: 10, False: 104]
  ------------------
  139|     10|        return 32;
  140|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  141|     21|    case PGP_CURVE_448:
  ------------------
  |  Branch (141:5): [True: 21, False: 93]
  ------------------
  142|     21|        return 56;
  143|      0|#endif
  144|     24|    case PGP_CURVE_NIST_P_384:
  ------------------
  |  Branch (144:5): [True: 24, False: 90]
  ------------------
  145|     24|        return 97;
  146|     25|    case PGP_CURVE_NIST_P_521:
  ------------------
  |  Branch (146:5): [True: 25, False: 89]
  ------------------
  147|     25|        return 133;
  148|     18|    case PGP_CURVE_BP384:
  ------------------
  |  Branch (148:5): [True: 18, False: 96]
  ------------------
  149|     18|        return 97;
  150|     16|    case PGP_CURVE_BP512:
  ------------------
  |  Branch (150:5): [True: 16, False: 98]
  ------------------
  151|     16|        return 129;
  152|      0|    default:
  ------------------
  |  Branch (152:5): [True: 0, False: 114]
  ------------------
  153|      0|        RNP_LOG("invalid curve given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  154|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  155|    114|    }
  156|    114|}
_ZN30pgp_kyber_ecdh_composite_key_t18pk_alg_to_kyber_idE16pgp_pubkey_alg_t:
  184|    426|{
  185|    426|    switch (pk_alg) {
  186|    152|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (186:5): [True: 152, False: 274]
  ------------------
  187|    152|#if defined(ENABLE_CRYPTO_REFRESH)
  188|    152|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    152|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  189|    217|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (189:5): [True: 65, False: 361]
  ------------------
  190|    217|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    217|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  191|    251|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (191:5): [True: 34, False: 392]
  ------------------
  192|    251|#endif
  193|    251|        return kyber_768;
  194|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  195|     34|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (195:5): [True: 34, False: 392]
  ------------------
  196|     34|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     34|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  197|    129|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (197:5): [True: 95, False: 331]
  ------------------
  198|    129|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    129|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  199|    175|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (199:5): [True: 46, False: 380]
  ------------------
  200|    175|        return kyber_1024;
  201|      0|#endif
  202|      0|    default:
  ------------------
  |  Branch (202:5): [True: 0, False: 426]
  ------------------
  203|      0|        RNP_LOG("invalid PK alg given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  204|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  205|    426|    }
  206|    426|}
_ZN30pgp_kyber_ecdh_composite_key_t18pk_alg_to_curve_idE16pgp_pubkey_alg_t:
  210|    461|{
  211|    461|    switch (pk_alg) {
  212|    152|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (212:5): [True: 152, False: 309]
  ------------------
  213|    152|        return PGP_CURVE_25519;
  214|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  215|     66|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (215:5): [True: 66, False: 395]
  ------------------
  216|     66|        return PGP_CURVE_NIST_P_384;
  217|     37|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (217:5): [True: 37, False: 424]
  ------------------
  218|     37|        return PGP_CURVE_BP384;
  219|     34|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (219:5): [True: 34, False: 427]
  ------------------
  220|     34|        return PGP_CURVE_448;
  221|    120|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (221:5): [True: 120, False: 341]
  ------------------
  222|    120|        return PGP_CURVE_BP512;
  223|     52|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (223:5): [True: 52, False: 409]
  ------------------
  224|     52|        return PGP_CURVE_NIST_P_521;
  225|      0|#endif
  226|      0|    default:
  ------------------
  |  Branch (226:5): [True: 0, False: 461]
  ------------------
  227|      0|        RNP_LOG("invalid PK alg given");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  228|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  229|    461|    }
  230|    461|}
_ZN38pgp_kyber_ecdh_composite_private_key_tC2EPKhm16pgp_pubkey_alg_t:
  234|      4|    : pk_alg_(pk_alg)
  235|      4|{
  236|      4|    parse_component_keys(std::vector<uint8_t>(key_encoded, key_encoded + key_encoded_len));
  237|      4|}
_ZN38pgp_kyber_ecdh_composite_private_key_taSERKS_:
  271|     77|{
  272|     77|    pgp_kyber_ecdh_composite_key_t::operator=(other);
  273|     77|    pk_alg_ = other.pk_alg_;
  274|     77|    if (other.is_initialized() && other.kyber_key_) {
  ------------------
  |  Branch (274:9): [True: 4, False: 73]
  |  Branch (274:35): [True: 4, False: 0]
  ------------------
  275|      4|        kyber_key_ = std::unique_ptr<pgp_kyber_private_key_t>(new pgp_kyber_private_key_t(
  276|      4|          other.kyber_key_->get_encoded(), other.kyber_key_->param()));
  277|      4|    }
  278|     77|    if (other.is_initialized() && other.ecdh_key_) {
  ------------------
  |  Branch (278:9): [True: 4, False: 73]
  |  Branch (278:35): [True: 4, False: 0]
  ------------------
  279|      4|        ecdh_key_ = std::unique_ptr<ecdh_kem_private_key_t>(new ecdh_kem_private_key_t(
  280|      4|          other.ecdh_key_->get_encoded(), other.ecdh_key_->get_curve()));
  281|      4|    }
  282|       |
  283|     77|    return *this;
  284|     77|}
_ZN38pgp_kyber_ecdh_composite_private_key_tC2ERKS_:
  288|     73|{
  289|     73|    *this = other;
  290|     73|}
_ZN38pgp_kyber_ecdh_composite_private_key_t12encoded_sizeE16pgp_pubkey_alg_t:
  294|      8|{
  295|      8|    pgp_curve_t curve = pk_alg_to_curve_id(pk_alg);
  296|      8|    return ecdh_curve_privkey_size(curve) + kyber_privkey_size();
  297|      8|}
_ZN38pgp_kyber_ecdh_composite_private_key_t20parse_component_keysENSt3__16vectorIhNS0_9allocatorIhEEEE:
  301|      4|{
  302|      4|    if (key_encoded.size() != encoded_size(pk_alg_)) {
  ------------------
  |  Branch (302:9): [True: 0, False: 4]
  ------------------
  303|      0|        RNP_LOG("ML-KEM composite key format invalid: length mismatch");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  304|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  305|      0|    }
  306|       |
  307|      4|    kyber_parameter_e kyber_param = pk_alg_to_kyber_id(pk_alg_);
  308|      4|    pgp_curve_t       ecdh_curve = pk_alg_to_curve_id(pk_alg_);
  309|      4|    size_t            split_at = ecdh_curve_privkey_size(pk_alg_to_curve_id(pk_alg_));
  310|       |
  311|      4|    kyber_key_ = std::unique_ptr<pgp_kyber_private_key_t>(new pgp_kyber_private_key_t(
  312|      4|      key_encoded.data() + split_at, key_encoded.size() - split_at, kyber_param));
  313|      4|    ecdh_key_ = std::unique_ptr<ecdh_kem_private_key_t>(
  314|      4|      new ecdh_kem_private_key_t(key_encoded.data(), split_at, ecdh_curve));
  315|       |
  316|      4|    is_initialized_ = true;
  317|      4|}
_ZN38pgp_kyber_ecdh_composite_private_key_t12secure_clearEv:
  444|     10|{
  445|       |    // private key buffer is stored in a secure_vector and will be securely erased by the
  446|       |    // destructor.
  447|     10|    kyber_key_.reset();
  448|     10|    ecdh_key_.reset();
  449|     10|    is_initialized_ = false;
  450|     10|}
_ZN37pgp_kyber_ecdh_composite_public_key_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE16pgp_pubkey_alg_t:
  474|     23|    : pk_alg_(pk_alg)
  475|     23|{
  476|     23|    parse_component_keys(key_encoded);
  477|     23|}
_ZN37pgp_kyber_ecdh_composite_public_key_t12encoded_sizeE16pgp_pubkey_alg_t:
  496|    285|{
  497|    285|    kyber_parameter_e kyber_param = pk_alg_to_kyber_id(pk_alg);
  498|    285|    pgp_curve_t       curve = pk_alg_to_curve_id(pk_alg);
  499|    285|    return ecdh_curve_pubkey_size(curve) + kyber_pubkey_size(kyber_param);
  500|    285|}
_ZN37pgp_kyber_ecdh_composite_public_key_t20parse_component_keysENSt3__16vectorIhNS0_9allocatorIhEEEE:
  504|     23|{
  505|     23|    if (key_encoded.size() != encoded_size(pk_alg_)) {
  ------------------
  |  Branch (505:9): [True: 0, False: 23]
  ------------------
  506|      0|        RNP_LOG("ML-KEM composite key format invalid: length mismatch");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  507|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  508|      0|    }
  509|       |
  510|     23|    kyber_parameter_e kyber_param = pk_alg_to_kyber_id(pk_alg_);
  511|     23|    pgp_curve_t       ecdh_curve = pk_alg_to_curve_id(pk_alg_);
  512|     23|    size_t            split_at = ecdh_curve_pubkey_size(pk_alg_to_curve_id(pk_alg_));
  513|       |
  514|     23|    kyber_key_ = pgp_kyber_public_key_t(
  515|     23|      key_encoded.data() + split_at, key_encoded.size() - split_at, kyber_param);
  516|     23|    ecdh_key_ = ecdh_kem_public_key_t(key_encoded.data(), split_at, ecdh_curve);
  517|       |
  518|     23|    is_initialized_ = true;
  519|     23|}
_ZNK37pgp_kyber_ecdh_composite_public_key_t11get_encodedEv:
  612|     12|{
  613|     12|    initialized_or_throw();
  614|     12|    std::vector<uint8_t> result;
  615|     12|    std::vector<uint8_t> ecdh_key_encoded = ecdh_key_.get_encoded();
  616|     12|    std::vector<uint8_t> kyber_key_encoded = kyber_key_.get_encoded();
  617|       |
  618|     12|    result.insert(result.end(), std::begin(ecdh_key_encoded), std::end(ecdh_key_encoded));
  619|     12|    result.insert(result.end(), std::begin(kyber_key_encoded), std::end(kyber_key_encoded));
  620|     12|    return result;
  621|     12|};

_ZNK30pgp_kyber_ecdh_composite_key_t14is_initializedEv:
   61|    166|    {
   62|    166|        return is_initialized_;
   63|    166|    }
_ZN38pgp_kyber_ecdh_composite_private_key_tC2Ev:
   98|    292|    pgp_kyber_ecdh_composite_private_key_t() = default;
_ZN37pgp_kyber_ecdh_composite_public_key_tC2Ev:
  142|    292|    pgp_kyber_ecdh_composite_public_key_t() = default;

_Z12secure_clearPvm:
   35|  1.44M|{
   36|  1.44M|    botan_scrub_mem(vp, size);
   37|  1.44M|}
_ZN3rnp10hex_encodeEPKhmPcmNS_9HexFormatE:
   43|  55.3k|{
   44|  55.3k|    uint32_t flags = format == HexFormat::Lowercase ? BOTAN_FFI_HEX_LOWER_CASE : 0;
  ------------------
  |  Branch (44:22): [True: 17.9k, False: 37.3k]
  ------------------
   45|       |
   46|  55.3k|    if (hex_len < (buf_len * 2 + 1)) {
  ------------------
  |  Branch (46:9): [True: 0, False: 55.3k]
  ------------------
   47|      0|        return false;
   48|      0|    }
   49|  55.3k|    hex[buf_len * 2] = '\0';
   50|  55.3k|    return botan_hex_encode(buf, buf_len, hex, flags) == 0;
   51|  55.3k|}
_ZN3rnp10hex_decodeEPKcPhm:
   55|   134k|{
   56|   134k|    size_t hexlen = strlen(hex);
   57|       |
   58|       |    /* check for 0x prefix */
   59|   134k|    if ((hexlen >= 2) && (hex[0] == '0') && ((hex[1] == 'x') || (hex[1] == 'X'))) {
  ------------------
  |  Branch (59:9): [True: 134k, False: 0]
  |  Branch (59:26): [True: 127k, False: 6.70k]
  |  Branch (59:46): [True: 127k, False: 486]
  |  Branch (59:65): [True: 0, False: 486]
  ------------------
   60|   127k|        hex += 2;
   61|   127k|        hexlen -= 2;
   62|   127k|    }
   63|   134k|    if (botan_hex_decode(hex, hexlen, buf, &buf_len) != 0) {
  ------------------
  |  Branch (63:9): [True: 0, False: 134k]
  ------------------
   64|      0|        RNP_LOG("Hex decode failed on string: %s", hex);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   65|      0|        return 0;
   66|      0|    }
   67|   134k|    return buf_len;
   68|   134k|}

_ZN3rnp10bin_to_hexEPKhmNS_9HexFormatE:
  222|  55.3k|{
  223|  55.3k|    std::string res(len * 2 + 1, '\0');
  224|  55.3k|    (void) hex_encode(data, len, &res.front(), res.size(), format);
  225|  55.3k|    res.resize(len * 2);
  226|  55.3k|    return res;
  227|  55.3k|}
_ZN3rnp10hex_to_binERKNSt3__112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE:
  237|   134k|{
  238|   134k|    if (str.empty() || !is_hex(str)) {
  ------------------
  |  Branch (238:9): [True: 0, False: 134k]
  |  Branch (238:24): [True: 0, False: 134k]
  ------------------
  239|      0|        return {};
  240|      0|    }
  241|       |    /* 1 extra char for case of non-even input , 1 for terminating zero */
  242|   134k|    std::vector<uint8_t> res(str.size() / 2 + 2);
  243|   134k|    size_t               len = hex_decode(str.c_str(), res.data(), res.size());
  244|   134k|    res.resize(len);
  245|   134k|    return res;
  246|   134k|}
_ZN3rnp12secure_arrayIhLm32EED2Ev:
  200|  16.8k|    {
  201|  16.8k|#if defined(CRYPTO_BACKEND_BOTAN)
  202|  16.8k|        botan_scrub_mem(&data_[0], sizeof(data_));
  203|       |#elif defined(CRYPTO_BACKEND_OPENSSL)
  204|       |        OPENSSL_cleanse(&data_[0], sizeof(data_));
  205|       |#else
  206|       |#error "Unsupported crypto backend."
  207|       |#endif
  208|  16.8k|    }
_ZN3rnp12secure_arrayIhLm32EEC2Ev:
  165|  8.42k|    secure_array() : data_({0})
  166|  8.42k|    {
  167|  8.42k|    }
_ZN3rnp12secure_arrayIhLm32EE4dataEv:
  171|  17.0k|    {
  172|  17.0k|        return &data_[0];
  173|  17.0k|    }
_ZNK3rnp12secure_arrayIhLm32EE4sizeEv:
  183|  8.42k|    {
  184|  8.42k|        return data_.size();
  185|  8.42k|    }
_ZN3rnp16secure_allocatorIhE8allocateEm:
   67|  2.01M|    {
   68|  2.01M|        if (!n) {
  ------------------
  |  Branch (68:13): [True: 0, False: 2.01M]
  ------------------
   69|      0|            return nullptr;
   70|      0|        }
   71|  2.01M|        T *ptr = static_cast<T *>(std::calloc(n, sizeof(T)));
   72|  2.01M|        if (!ptr)
  ------------------
  |  Branch (72:13): [True: 0, False: 2.01M]
  ------------------
   73|      0|            throw std::bad_alloc();
   74|  2.01M|        return ptr;
   75|  2.01M|    }
_ZN3rnp16secure_allocatorIhE10deallocateEPhm:
   79|  2.01M|    {
   80|  2.01M|        if (!p) {
  ------------------
  |  Branch (80:13): [True: 0, False: 2.01M]
  ------------------
   81|      0|            return;
   82|      0|        }
   83|  2.01M|        botan_scrub_mem(p, n * sizeof(T));
   84|  2.01M|        std::free(p);
   85|  2.01M|    }
_ZN3rnp12secure_arrayItLm1EEC2Ev:
  165|     41|    secure_array() : data_({0})
  166|     41|    {
  167|     41|    }
_ZN3rnp12secure_arrayItLm1EEixEm:
  195|  1.11k|    {
  196|  1.11k|        return data_[idx];
  197|  1.11k|    }
_ZN3rnp12secure_arrayItLm1EED2Ev:
  200|     41|    {
  201|     41|#if defined(CRYPTO_BACKEND_BOTAN)
  202|     41|        botan_scrub_mem(&data_[0], sizeof(data_));
  203|       |#elif defined(CRYPTO_BACKEND_OPENSSL)
  204|       |        OPENSSL_cleanse(&data_[0], sizeof(data_));
  205|       |#else
  206|       |#error "Unsupported crypto backend."
  207|       |#endif
  208|     41|    }
_ZN3rnp12secure_arrayIcLm256EEC2Ev:
  165|  8.46k|    secure_array() : data_({0})
  166|  8.46k|    {
  167|  8.46k|    }
_ZN3rnp12secure_arrayIcLm256EE4dataEv:
  171|  17.6k|    {
  172|  17.6k|        return &data_[0];
  173|  17.6k|    }
_ZNK3rnp12secure_arrayIcLm256EE4sizeEv:
  183|  8.81k|    {
  184|  8.81k|        return data_.size();
  185|  8.81k|    }
_ZN3rnp12secure_arrayIhLm33EEC2Ev:
  165|  13.4k|    secure_array() : data_({0})
  166|  13.4k|    {
  167|  13.4k|    }
_ZN3rnp12secure_arrayIhLm33EE4dataEv:
  171|  45.3k|    {
  172|  45.3k|        return &data_[0];
  173|  45.3k|    }
_ZN3rnp12secure_arrayIhLm33EEixEm:
  195|  3.20k|    {
  196|  3.20k|        return data_[idx];
  197|  3.20k|    }
_ZNK3rnp12secure_arrayIhLm33EE4sizeEv:
  183|  1.92k|    {
  184|  1.92k|        return data_.size();
  185|  1.92k|    }
_ZN3rnp12secure_arrayIhLm33EED2Ev:
  200|  13.4k|    {
  201|  13.4k|#if defined(CRYPTO_BACKEND_BOTAN)
  202|  13.4k|        botan_scrub_mem(&data_[0], sizeof(data_));
  203|       |#elif defined(CRYPTO_BACKEND_OPENSSL)
  204|       |        OPENSSL_cleanse(&data_[0], sizeof(data_));
  205|       |#else
  206|       |#error "Unsupported crypto backend."
  207|       |#endif
  208|  13.4k|    }
_ZN3rnp12secure_arrayIcLm256EED2Ev:
  200|  8.46k|    {
  201|  8.46k|#if defined(CRYPTO_BACKEND_BOTAN)
  202|  8.46k|        botan_scrub_mem(&data_[0], sizeof(data_));
  203|       |#elif defined(CRYPTO_BACKEND_OPENSSL)
  204|       |        OPENSSL_cleanse(&data_[0], sizeof(data_));
  205|       |#else
  206|       |#error "Unsupported crypto backend."
  207|       |#endif
  208|  8.46k|    }
_ZNK3rnp12secure_arrayIhLm32EE4dataEv:
  177|  5.94k|    {
  178|  5.94k|        return &data_[0];
  179|  5.94k|    }
_ZN3rnp16secure_allocatorIcE8allocateEm:
   67|  8.42k|    {
   68|  8.42k|        if (!n) {
  ------------------
  |  Branch (68:13): [True: 0, False: 8.42k]
  ------------------
   69|      0|            return nullptr;
   70|      0|        }
   71|  8.42k|        T *ptr = static_cast<T *>(std::calloc(n, sizeof(T)));
   72|  8.42k|        if (!ptr)
  ------------------
  |  Branch (72:13): [True: 0, False: 8.42k]
  ------------------
   73|      0|            throw std::bad_alloc();
   74|  8.42k|        return ptr;
   75|  8.42k|    }
_ZN3rnp16secure_allocatorIcE10deallocateEPcm:
   79|  8.42k|    {
   80|  8.42k|        if (!p) {
  ------------------
  |  Branch (80:13): [True: 0, False: 8.42k]
  ------------------
   81|      0|            return;
   82|      0|        }
   83|  8.42k|        botan_scrub_mem(p, n * sizeof(T));
   84|  8.42k|        std::free(p);
   85|  8.42k|    }

_ZNK3pgp3mpi4bitsEv:
   37|   142k|{
   38|   142k|    size_t  bits = 0;
   39|   142k|    size_t  idx = 0;
   40|   142k|    uint8_t bt;
   41|       |
   42|   164k|    for (idx = 0; (idx < size()) && !data_[idx]; idx++)
  ------------------
  |  Branch (42:19): [True: 158k, False: 6.06k]
  |  Branch (42:37): [True: 22.2k, False: 136k]
  ------------------
   43|  22.2k|        ;
   44|       |
   45|   142k|    if (idx < size()) {
  ------------------
  |  Branch (45:9): [True: 136k, False: 6.06k]
  ------------------
   46|  1.08M|        for (bits = (size() - idx - 1) << 3, bt = data_[idx]; bt; bits++, bt = bt >> 1)
  ------------------
  |  Branch (46:63): [True: 953k, False: 136k]
  ------------------
   47|   953k|            ;
   48|   136k|    }
   49|       |
   50|   142k|    return bits;
   51|   142k|}
_ZNK3pgp3mpi4sizeEv:
   55|   700k|{
   56|   700k|    return data_.size();
   57|   700k|}
_ZN3pgp3mpi4dataEv:
   61|   200k|{
   62|   200k|    return data_.data();
   63|   200k|}
_ZNK3pgp3mpi4dataEv:
   67|   165k|{
   68|   165k|    return data_.data();
   69|   165k|}
_ZN3pgp3mpiixEm:
   95|  21.2k|{
   96|  21.2k|    return data_.at(idx);
   97|  21.2k|}
_ZNK3pgp3mpiixEm:
  101|   454k|{
  102|   454k|    return data_.at(idx);
  103|   454k|}
_ZN3pgp3mpi6assignEPKhm:
  107|  84.9k|{
  108|  84.9k|    data_.assign(val, val + size);
  109|  84.9k|}
_ZNK3pgp3mpi4copyEPh:
  113|  20.8k|{
  114|  20.8k|    memcpy(dst, data_.data(), data_.size());
  115|  20.8k|}
_ZN3pgp3mpi6resizeEmh:
  119|   179k|{
  120|   179k|    data_.resize(size, fill);
  121|   179k|}
_ZN3pgp3mpi6forgetEv:
  125|   447k|{
  126|   447k|    secure_clear(data_.data(), data_.size());
  127|   447k|    data_.resize(0);
  128|   447k|}

_ZN3rnp3RNGC2ENS0_4TypeE:
   34|  12.7k|{
   35|  12.7k|    if (botan_rng_init(&botan_rng, type == Type::DRBG ? "user" : NULL)) {
  ------------------
  |  Branch (35:9): [True: 0, False: 12.7k]
  |  Branch (35:36): [True: 12.7k, False: 0]
  ------------------
   36|      0|        throw rnp::rnp_exception(RNP_ERROR_RNG);
   37|      0|    }
   38|  12.7k|}
_ZN3rnp3RNGD2Ev:
   41|  12.7k|{
   42|  12.7k|    (void) botan_rng_destroy(botan_rng);
   43|  12.7k|}
_ZN3rnp3RNG3getEPhm:
   47|  26.4k|{
   48|  26.4k|    if (botan_rng_get(botan_rng, data, len)) {
  ------------------
  |  Branch (48:9): [True: 0, False: 26.4k]
  ------------------
   49|       |        // This should never happen
   50|      0|        throw rnp::rnp_exception(RNP_ERROR_RNG);
   51|      0|    }
   52|  26.4k|}
_ZN3rnp3RNG6handleEv:
   56|     41|{
   57|     41|    return botan_rng;
   58|     41|}

_ZNK3pgp3rsa3Key12verify_pkcs1ERKNS0_9SignatureE14pgp_hash_alg_tRKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEE:
  115|    429|{
  116|    429|    rnp::botan::Pubkey rsa_key;
  117|    429|    if (!load_public_key(rsa_key, *this)) {
  ------------------
  |  Branch (117:9): [True: 81, False: 348]
  ------------------
  118|     81|        RNP_LOG("failed to load key");
  ------------------
  |  |   84|     81|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     81|    do {                                                                                 \
  |  |  |  |   77|     81|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 81, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     81|            break;                                                                       \
  |  |  |  |   79|     81|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  119|     81|        return RNP_ERROR_OUT_OF_MEMORY;
  120|     81|    }
  121|       |
  122|    348|    char pad[64] = {0};
  123|    348|    snprintf(
  124|    348|      pad, sizeof(pad), "EMSA-PKCS1-v1_5(Raw,%s)", rnp::Hash_Botan::name_backend(hash_alg));
  125|       |
  126|    348|    rnp::botan::op::Verify verify_op;
  127|    348|    if (botan_pk_op_verify_create(&verify_op.get(), rsa_key.get(), pad, 0) ||
  ------------------
  |  Branch (127:9): [True: 0, False: 348]
  ------------------
  128|    348|        botan_pk_op_verify_update(verify_op.get(), hash.data(), hash.size())) {
  ------------------
  |  Branch (128:9): [True: 0, False: 348]
  ------------------
  129|      0|        return RNP_ERROR_SIGNATURE_INVALID;
  130|      0|    }
  131|    348|    if (sig.s.size() < n.size()) {
  ------------------
  |  Branch (131:9): [True: 0, False: 348]
  ------------------
  132|       |        /* Botan 3.13+ requires signature to be exactly the length of the modulus, while
  133|       |         * OpenPGP MPIs have leading zero bytes stripped. */
  134|      0|        rnp::secure_bytes padded(n.size() - sig.s.size(), 0);
  135|      0|        padded.insert(padded.end(), sig.s.data(), sig.s.data() + sig.s.size());
  136|      0|        if (botan_pk_op_verify_finish(verify_op.get(), padded.data(), padded.size())) {
  ------------------
  |  Branch (136:13): [True: 0, False: 0]
  ------------------
  137|      0|            return RNP_ERROR_SIGNATURE_INVALID;
  138|      0|        }
  139|      0|        return RNP_SUCCESS;
  140|      0|    }
  141|    348|    if (botan_pk_op_verify_finish(verify_op.get(), sig.s.data(), sig.s.size())) {
  ------------------
  |  Branch (141:9): [True: 324, False: 24]
  ------------------
  142|    324|        return RNP_ERROR_SIGNATURE_INVALID;
  143|    324|    }
  144|     24|    return RNP_SUCCESS;
  145|    348|}
rsa.cpp:_ZN3pgp3rsaL15load_public_keyERN3rnp5botan6PubkeyERKNS0_3KeyE:
   41|    429|{
   42|    429|    rnp::bn n(key.n);
   43|    429|    rnp::bn e(key.e);
   44|       |
   45|    429|    if (!n || !e) {
  ------------------
  |  Branch (45:9): [True: 0, False: 429]
  |  Branch (45:15): [True: 0, False: 429]
  ------------------
   46|      0|        RNP_LOG("out of memory");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   47|      0|        return false;
   48|      0|    }
   49|    429|    return !botan_pubkey_load_rsa(&bkey.get(), n.get(), e.get());
   50|    429|}

_ZN3pgp3rsa3Key12clear_secretEv:
   61|  71.9k|    {
   62|  71.9k|        d.forget();
   63|  71.9k|        p.forget();
   64|  71.9k|        q.forget();
   65|  71.9k|        u.forget();
   66|  71.9k|    }
_ZN3pgp3rsa3KeyD2Ev:
   69|  66.7k|    {
   70|  66.7k|        clear_secret();
   71|  66.7k|    }

_Z18pgp_s2k_derive_keyP9pgp_s2k_tPKcPhi:
   55|  20.8k|{
   56|  20.8k|    uint8_t *saltptr = NULL;
   57|  20.8k|    unsigned iterations = 1;
   58|       |
   59|  20.8k|    switch (s2k->specifier) {
   60|    731|    case PGP_S2KS_SIMPLE:
  ------------------
  |  Branch (60:5): [True: 731, False: 20.1k]
  ------------------
   61|    731|        break;
   62|  1.47k|    case PGP_S2KS_SALTED:
  ------------------
  |  Branch (62:5): [True: 1.47k, False: 19.4k]
  ------------------
   63|  1.47k|        saltptr = s2k->salt;
   64|  1.47k|        break;
   65|  18.1k|    case PGP_S2KS_ITERATED_AND_SALTED:
  ------------------
  |  Branch (65:5): [True: 18.1k, False: 2.73k]
  ------------------
   66|  18.1k|        saltptr = s2k->salt;
   67|  18.1k|        if (s2k->iterations < 256) {
  ------------------
  |  Branch (67:13): [True: 18.1k, False: 0]
  ------------------
   68|  18.1k|            iterations = pgp_s2k_decode_iterations(s2k->iterations);
   69|  18.1k|        } else {
   70|      0|            iterations = s2k->iterations;
   71|      0|        }
   72|  18.1k|        break;
   73|      0|#if defined(ENABLE_CRYPTO_REFRESH)
   74|    447|    case PGP_S2KS_ARGON2:
  ------------------
  |  Branch (74:5): [True: 447, False: 20.4k]
  ------------------
   75|    447|        saltptr = s2k->salt;
   76|    447|        break;
   77|      0|#endif
   78|     91|    default:
  ------------------
  |  Branch (78:5): [True: 91, False: 20.8k]
  ------------------
   79|     91|        return false;
   80|  20.8k|    }
   81|       |
   82|  20.8k|#if defined(ENABLE_CRYPTO_REFRESH)
   83|  20.8k|    if (s2k->specifier == PGP_S2KS_ARGON2) {
  ------------------
  |  Branch (83:9): [True: 447, False: 20.3k]
  ------------------
   84|    447|        if (pgp_s2k_argon2(key,
  ------------------
  |  Branch (84:13): [True: 236, False: 211]
  ------------------
   85|    447|                           keysize,
   86|    447|                           password,
   87|    447|                           saltptr,
   88|    447|                           s2k->argon2_t,
   89|    447|                           s2k->argon2_p,
   90|    447|                           s2k->argon2_encoded_m)) {
   91|    236|            RNP_LOG("s2k argon2 failed");
  ------------------
  |  |   84|    236|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    236|    do {                                                                                 \
  |  |  |  |   77|    236|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 236, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    236|            break;                                                                       \
  |  |  |  |   79|    236|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   92|    236|            return false;
   93|    236|        }
   94|    447|    } else
   95|  20.3k|#endif
   96|  20.3k|      if (pgp_s2k_iterated(s2k->hash_alg, key, keysize, password, saltptr, iterations)) {
  ------------------
  |  Branch (96:11): [True: 386, False: 19.9k]
  ------------------
   97|    386|        RNP_LOG("s2k failed");
  ------------------
  |  |   84|    386|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    386|    do {                                                                                 \
  |  |  |  |   77|    386|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 386, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    386|            break;                                                                       \
  |  |  |  |   79|    386|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   98|    386|        return false;
   99|    386|    }
  100|       |
  101|  20.1k|    return true;
  102|  20.8k|}
_Z14pgp_s2k_argon2PhmPKcPKhhhh:
  114|    447|{
  115|    447|    const size_t argon2_salt_size = 16;
  116|       |
  117|       |    /* check constraints on p and t */
  118|    447|    if (!p || !t) {
  ------------------
  |  Branch (118:9): [True: 40, False: 407]
  |  Branch (118:15): [True: 101, False: 306]
  ------------------
  119|    141|        RNP_LOG("Argon2 t and p must be non-zero");
  ------------------
  |  |   84|    141|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    141|    do {                                                                                 \
  |  |  |  |   77|    141|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 141, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    141|            break;                                                                       \
  |  |  |  |   79|    141|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  120|    141|        return -1;
  121|    141|    }
  122|       |    /* check constraints on m. Floating point calculation is fine due to restricted data range
  123|       |     * (uint8_t) */
  124|    306|    if (encoded_m < (3 + (uint8_t) std::ceil(std::log2(p))) || encoded_m > 31) {
  ------------------
  |  Branch (124:9): [True: 31, False: 275]
  |  Branch (124:64): [True: 34, False: 241]
  ------------------
  125|     65|        RNP_LOG("Argon2 encoded_m must be between 3+ceil(log2(p)) and 31");
  ------------------
  |  |   84|     65|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     65|    do {                                                                                 \
  |  |  |  |   77|     65|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 65, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     65|            break;                                                                       \
  |  |  |  |   79|     65|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  126|     65|        return -1;
  127|     65|    }
  128|       |
  129|    241|    if (botan_pwdhash("Argon2id",
  ------------------
  |  Branch (129:9): [True: 30, False: 211]
  ------------------
  130|    241|                      ((size_t) 1) << encoded_m,
  131|    241|                      t,
  132|    241|                      p,
  133|    241|                      out,
  134|    241|                      output_len,
  135|    241|                      password,
  136|    241|                      std::strlen(password),
  137|    241|                      salt,
  138|    241|                      argon2_salt_size)) {
  139|     30|        RNP_LOG("Argon2 key derivation failed");
  ------------------
  |  |   84|     30|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     30|    do {                                                                                 \
  |  |  |  |   77|     30|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 30, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     30|            break;                                                                       \
  |  |  |  |   79|     30|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  140|     30|        return -1;
  141|     30|    }
  142|    211|    return 0;
  143|    241|}
_Z16pgp_s2k_iterated14pgp_hash_alg_tPhmPKcPKhm:
  153|  20.3k|{
  154|  20.3k|    char s2k_algo_str[128];
  155|  20.3k|    snprintf(s2k_algo_str,
  156|  20.3k|             sizeof(s2k_algo_str),
  157|  20.3k|             "OpenPGP-S2K(%s)",
  158|  20.3k|             rnp::Hash_Botan::name_backend(alg));
  159|       |
  160|  20.3k|    return botan_pwdhash(s2k_algo_str,
  161|  20.3k|                         iterations,
  162|  20.3k|                         0,
  163|  20.3k|                         0,
  164|  20.3k|                         out,
  165|  20.3k|                         output_len,
  166|  20.3k|                         password,
  167|  20.3k|                         0,
  168|  20.3k|                         salt,
  169|  20.3k|                         salt ? PGP_SALT_SIZE : 0);
  ------------------
  |  |   92|  19.6k|#define PGP_SALT_SIZE 8
  ------------------
  |  Branch (169:26): [True: 19.6k, False: 731]
  ------------------
  170|  20.3k|}
_Z25pgp_s2k_decode_iterationsh:
  175|   160k|{
  176|       |    // See RFC 4880 section 3.7.1.3
  177|   160k|    return (16 + (c & 0x0F)) << ((c >> 4) + 6);
  178|   160k|}
_Z25pgp_s2k_encode_iterationsm:
  188|  8.42k|{
  189|       |    /* For compatibility, when an S2K specifier is used, the special value
  190|       |     * 254 or 255 is stored in the position where the hash algorithm octet
  191|       |     * would have been in the old data structure. This is then followed
  192|       |     * immediately by a one-octet algorithm identifier, and then by the S2K
  193|       |     * specifier as encoded above.
  194|       |     * 0:           secret data is unencrypted (no password)
  195|       |     * 255 or 254:  followed by algorithm octet and S2K specifier
  196|       |     * Cipher alg:  use Simple S2K algorithm using MD5 hash
  197|       |     * For more info refer to rfc 4880 section 3.7.2.1.
  198|       |     */
  199|   127k|    for (uint16_t c = 0; c < 256; ++c) {
  ------------------
  |  Branch (199:26): [True: 127k, False: 0]
  ------------------
  200|       |        // This could be a binary search
  201|   127k|        if (pgp_s2k_decode_iterations(c) >= iterations) {
  ------------------
  |  Branch (201:13): [True: 8.42k, False: 119k]
  ------------------
  202|  8.42k|            return c;
  203|  8.42k|        }
  204|   127k|    }
  205|      0|    return 255;
  206|  8.42k|}
_ZN9pgp_s2k_t9salt_sizeE19pgp_s2k_specifier_t:
  271|  32.2k|{
  272|  32.2k|#if defined(ENABLE_CRYPTO_REFRESH)
  273|  32.2k|    return (specifier == PGP_S2KS_ARGON2 ? PGP_MAX_S2K_SALT_SIZE : PGP_SALT_SIZE);
  ------------------
  |  |   96|    997|#define PGP_MAX_S2K_SALT_SIZE 16
  ------------------
                  return (specifier == PGP_S2KS_ARGON2 ? PGP_MAX_S2K_SALT_SIZE : PGP_SALT_SIZE);
  ------------------
  |  |   92|  31.2k|#define PGP_SALT_SIZE 8
  ------------------
  |  Branch (273:13): [True: 997, False: 31.2k]
  ------------------
  274|       |#else
  275|       |    (void) specifier;
  276|       |    return PGP_SALT_SIZE;
  277|       |#endif
  278|  32.2k|}
_ZN9pgp_s2k_t13specifier_lenE19pgp_s2k_specifier_t:
  282|  3.59k|{
  283|  3.59k|    switch (specifier) {
  284|  1.83k|    case PGP_S2KS_SIMPLE:
  ------------------
  |  Branch (284:5): [True: 1.83k, False: 1.76k]
  ------------------
  285|  1.83k|        return 2;
  286|     21|    case PGP_S2KS_SALTED:
  ------------------
  |  Branch (286:5): [True: 21, False: 3.57k]
  ------------------
  287|     21|        return 10;
  288|  1.70k|    case PGP_S2KS_ITERATED_AND_SALTED:
  ------------------
  |  Branch (288:5): [True: 1.70k, False: 1.89k]
  ------------------
  289|  1.70k|        return 11;
  290|      6|    case PGP_S2KS_EXPERIMENTAL:
  ------------------
  |  Branch (290:5): [True: 6, False: 3.58k]
  ------------------
  291|      6|        return 0; /* not used */
  292|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  293|     34|    case PGP_S2KS_ARGON2:
  ------------------
  |  Branch (293:5): [True: 34, False: 3.55k]
  ------------------
  294|     34|        return 20;
  295|      0|#endif
  296|      0|    default:
  ------------------
  |  Branch (296:5): [True: 0, False: 3.59k]
  ------------------
  297|      0|        RNP_LOG("invalid specifier");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  298|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  299|  3.59k|    }
  300|  3.59k|}

_ZN3rnp11secure_wipeEPvm:
   33|  13.9k|{
   34|  13.9k|    volatile auto *p = static_cast<volatile uint8_t *>(ptr);
   35|  15.9k|    while (len--) {
  ------------------
  |  Branch (35:12): [True: 1.91k, False: 13.9k]
  ------------------
   36|  1.91k|        *p++ = 0;
   37|  1.91k|    }
   38|  13.9k|}

_ZN3rnp11SecureBytesC2EPKhS2_:
   48|     20|    SecureBytes(const uint8_t *first, const uint8_t *last) : data_(first, last)
   49|     20|    {
   50|     20|    }
_ZN3rnp11SecureBytesC2ERKNSt3__16vectorIhNS1_9allocatorIhEEEE:
   55|      7|    SecureBytes(const std::vector<uint8_t> &v) : data_(v)
   56|      7|    {
   57|      7|    }
_ZN3rnp11SecureBytesC2EONSt3__16vectorIhNS1_9allocatorIhEEEE:
   58|      7|    SecureBytes(std::vector<uint8_t> &&v) noexcept : data_(std::move(v))
   59|      7|    {
   60|      7|    }
_ZN3rnp11SecureBytesD2Ev:
   63|  13.0k|    {
   64|  13.0k|        secure_wipe(data_.data(), data_.size());
   65|  13.0k|    }
_ZN3rnp11SecureBytesaSEOS0_:
   75|    952|    {
   76|    952|        secure_wipe(data_.data(), data_.size());
   77|    952|        data_ = std::move(o.data_);
   78|    952|        return *this;
   79|    952|    }
_ZNK3rnp11SecureBytes6unlockEv:
  125|     14|    {
  126|     14|        return data_;
  127|     14|    }
_ZN3rnp11SecureBytesC2Ev:
   46|  3.70k|    SecureBytes() = default;
_ZN3rnp11SecureBytesC2ERKS0_:
   67|  9.29k|    SecureBytes(const SecureBytes &) = default;

sha1_compression_states:
  465|  2.38M|{
  466|  2.38M|    uint32_t a = ihv[0], b = ihv[1], c = ihv[2], d = ihv[3], e = ihv[4];
  467|  2.38M|    uint32_t temp;
  468|       |
  469|       |#ifdef DOSTORESTATE00
  470|       |    SHA1_STORE_STATE(0)
  471|       |#endif
  472|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(a, b, c, d, e, m, W, 0, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  473|       |
  474|       |#ifdef DOSTORESTATE01
  475|       |    SHA1_STORE_STATE(1)
  476|       |#endif
  477|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(e, a, b, c, d, m, W, 1, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  478|       |
  479|       |#ifdef DOSTORESTATE02
  480|       |    SHA1_STORE_STATE(2)
  481|       |#endif
  482|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(d, e, a, b, c, m, W, 2, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  483|       |
  484|       |#ifdef DOSTORESTATE03
  485|       |    SHA1_STORE_STATE(3)
  486|       |#endif
  487|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(c, d, e, a, b, m, W, 3, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  488|       |
  489|       |#ifdef DOSTORESTATE04
  490|       |    SHA1_STORE_STATE(4)
  491|       |#endif
  492|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(b, c, d, e, a, m, W, 4, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  493|       |
  494|       |#ifdef DOSTORESTATE05
  495|       |    SHA1_STORE_STATE(5)
  496|       |#endif
  497|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(a, b, c, d, e, m, W, 5, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  498|       |
  499|       |#ifdef DOSTORESTATE06
  500|       |    SHA1_STORE_STATE(6)
  501|       |#endif
  502|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(e, a, b, c, d, m, W, 6, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  503|       |
  504|       |#ifdef DOSTORESTATE07
  505|       |    SHA1_STORE_STATE(7)
  506|       |#endif
  507|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(d, e, a, b, c, m, W, 7, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  508|       |
  509|       |#ifdef DOSTORESTATE08
  510|       |    SHA1_STORE_STATE(8)
  511|       |#endif
  512|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(c, d, e, a, b, m, W, 8, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  513|       |
  514|       |#ifdef DOSTORESTATE09
  515|       |    SHA1_STORE_STATE(9)
  516|       |#endif
  517|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(b, c, d, e, a, m, W, 9, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  518|       |
  519|       |#ifdef DOSTORESTATE10
  520|       |    SHA1_STORE_STATE(10)
  521|       |#endif
  522|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(a, b, c, d, e, m, W, 10, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  523|       |
  524|       |#ifdef DOSTORESTATE11
  525|       |    SHA1_STORE_STATE(11)
  526|       |#endif
  527|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(e, a, b, c, d, m, W, 11, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  528|       |
  529|       |#ifdef DOSTORESTATE12
  530|       |    SHA1_STORE_STATE(12)
  531|       |#endif
  532|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(d, e, a, b, c, m, W, 12, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  533|       |
  534|       |#ifdef DOSTORESTATE13
  535|       |    SHA1_STORE_STATE(13)
  536|       |#endif
  537|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(c, d, e, a, b, m, W, 13, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  538|       |
  539|       |#ifdef DOSTORESTATE14
  540|       |    SHA1_STORE_STATE(14)
  541|       |#endif
  542|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(b, c, d, e, a, m, W, 14, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  543|       |
  544|       |#ifdef DOSTORESTATE15
  545|       |    SHA1_STORE_STATE(15)
  546|       |#endif
  547|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_LOAD(a, b, c, d, e, m, W, 15, temp);
  ------------------
  |  |  208|  2.38M|    {                                                                    \
  |  |  209|  2.38M|        sha1_load(m, t, temp);                                           \
  |  |  ------------------
  |  |  |  |  152|  2.38M|    {                         \
  |  |  |  |  153|  2.38M|        temp = m[t];          \
  |  |  |  |  154|  2.38M|        sha1_bswap32(temp);   \
  |  |  |  |  ------------------
  |  |  |  |  |  |  138|  2.38M|    {                                                        \
  |  |  |  |  |  |  139|  2.38M|        x = ((x << 8) & 0xFF00FF00) | ((x >> 8) & 0xFF00FF); \
  |  |  |  |  |  |  140|  2.38M|        x = (x << 16) | (x >> 16);                           \
  |  |  |  |  |  |  141|  2.38M|    }
  |  |  |  |  ------------------
  |  |  |  |  155|  2.38M|    }
  |  |  ------------------
  |  |  210|  2.38M|        sha1_store(W, t, temp);                                          \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  211|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;   \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  212|  2.38M|        b = rotate_left(b, 30);                                          \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  213|  2.38M|    }
  ------------------
  548|       |
  549|       |#ifdef DOSTORESTATE16
  550|       |    SHA1_STORE_STATE(16)
  551|       |#endif
  552|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_EXPAND(e, a, b, c, d, W, 16, temp);
  ------------------
  |  |  216|  2.38M|    {                                                                   \
  |  |  217|  2.38M|        temp = sha1_mix(W, t);                                          \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  218|  2.38M|        sha1_store(W, t, temp);                                         \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  219|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  220|  2.38M|        b = rotate_left(b, 30);                                         \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  221|  2.38M|    }
  ------------------
  553|       |
  554|       |#ifdef DOSTORESTATE17
  555|       |    SHA1_STORE_STATE(17)
  556|       |#endif
  557|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_EXPAND(d, e, a, b, c, W, 17, temp);
  ------------------
  |  |  216|  2.38M|    {                                                                   \
  |  |  217|  2.38M|        temp = sha1_mix(W, t);                                          \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  218|  2.38M|        sha1_store(W, t, temp);                                         \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  219|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  220|  2.38M|        b = rotate_left(b, 30);                                         \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  221|  2.38M|    }
  ------------------
  558|       |
  559|       |#ifdef DOSTORESTATE18
  560|       |    SHA1_STORE_STATE(18)
  561|       |#endif
  562|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_EXPAND(c, d, e, a, b, W, 18, temp);
  ------------------
  |  |  216|  2.38M|    {                                                                   \
  |  |  217|  2.38M|        temp = sha1_mix(W, t);                                          \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  218|  2.38M|        sha1_store(W, t, temp);                                         \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  219|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  220|  2.38M|        b = rotate_left(b, 30);                                         \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  221|  2.38M|    }
  ------------------
  563|       |
  564|       |#ifdef DOSTORESTATE19
  565|       |    SHA1_STORE_STATE(19)
  566|       |#endif
  567|  2.38M|    SHA1COMPRESS_FULL_ROUND1_STEP_EXPAND(b, c, d, e, a, W, 19, temp);
  ------------------
  |  |  216|  2.38M|    {                                                                   \
  |  |  217|  2.38M|        temp = sha1_mix(W, t);                                          \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  218|  2.38M|        sha1_store(W, t, temp);                                         \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  219|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999;  \
  |  |  ------------------
  |  |  |  |  160|  2.38M|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  220|  2.38M|        b = rotate_left(b, 30);                                         \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  221|  2.38M|    }
  ------------------
  568|       |
  569|       |#ifdef DOSTORESTATE20
  570|       |    SHA1_STORE_STATE(20)
  571|       |#endif
  572|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(a, b, c, d, e, W, 20, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  573|       |
  574|       |#ifdef DOSTORESTATE21
  575|       |    SHA1_STORE_STATE(21)
  576|       |#endif
  577|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(e, a, b, c, d, W, 21, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  578|       |
  579|       |#ifdef DOSTORESTATE22
  580|       |    SHA1_STORE_STATE(22)
  581|       |#endif
  582|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(d, e, a, b, c, W, 22, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  583|       |
  584|       |#ifdef DOSTORESTATE23
  585|       |    SHA1_STORE_STATE(23)
  586|       |#endif
  587|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(c, d, e, a, b, W, 23, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  588|       |
  589|       |#ifdef DOSTORESTATE24
  590|       |    SHA1_STORE_STATE(24)
  591|       |#endif
  592|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(b, c, d, e, a, W, 24, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  593|       |
  594|       |#ifdef DOSTORESTATE25
  595|       |    SHA1_STORE_STATE(25)
  596|       |#endif
  597|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(a, b, c, d, e, W, 25, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  598|       |
  599|       |#ifdef DOSTORESTATE26
  600|       |    SHA1_STORE_STATE(26)
  601|       |#endif
  602|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(e, a, b, c, d, W, 26, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  603|       |
  604|       |#ifdef DOSTORESTATE27
  605|       |    SHA1_STORE_STATE(27)
  606|       |#endif
  607|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(d, e, a, b, c, W, 27, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  608|       |
  609|       |#ifdef DOSTORESTATE28
  610|       |    SHA1_STORE_STATE(28)
  611|       |#endif
  612|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(c, d, e, a, b, W, 28, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  613|       |
  614|       |#ifdef DOSTORESTATE29
  615|       |    SHA1_STORE_STATE(29)
  616|       |#endif
  617|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(b, c, d, e, a, W, 29, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  618|       |
  619|       |#ifdef DOSTORESTATE30
  620|       |    SHA1_STORE_STATE(30)
  621|       |#endif
  622|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(a, b, c, d, e, W, 30, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  623|       |
  624|       |#ifdef DOSTORESTATE31
  625|       |    SHA1_STORE_STATE(31)
  626|       |#endif
  627|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(e, a, b, c, d, W, 31, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  628|       |
  629|       |#ifdef DOSTORESTATE32
  630|       |    SHA1_STORE_STATE(32)
  631|       |#endif
  632|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(d, e, a, b, c, W, 32, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  633|       |
  634|       |#ifdef DOSTORESTATE33
  635|       |    SHA1_STORE_STATE(33)
  636|       |#endif
  637|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(c, d, e, a, b, W, 33, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  638|       |
  639|       |#ifdef DOSTORESTATE34
  640|       |    SHA1_STORE_STATE(34)
  641|       |#endif
  642|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(b, c, d, e, a, W, 34, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  643|       |
  644|       |#ifdef DOSTORESTATE35
  645|       |    SHA1_STORE_STATE(35)
  646|       |#endif
  647|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(a, b, c, d, e, W, 35, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  648|       |
  649|       |#ifdef DOSTORESTATE36
  650|       |    SHA1_STORE_STATE(36)
  651|       |#endif
  652|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(e, a, b, c, d, W, 36, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  653|       |
  654|       |#ifdef DOSTORESTATE37
  655|       |    SHA1_STORE_STATE(37)
  656|       |#endif
  657|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(d, e, a, b, c, W, 37, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  658|       |
  659|       |#ifdef DOSTORESTATE38
  660|       |    SHA1_STORE_STATE(38)
  661|       |#endif
  662|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(c, d, e, a, b, W, 38, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  663|       |
  664|       |#ifdef DOSTORESTATE39
  665|       |    SHA1_STORE_STATE(39)
  666|       |#endif
  667|  2.38M|    SHA1COMPRESS_FULL_ROUND2_STEP(b, c, d, e, a, W, 39, temp);
  ------------------
  |  |  224|  2.38M|    {                                                                  \
  |  |  225|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  226|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  227|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1; \
  |  |  ------------------
  |  |  |  |  161|  2.38M|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  228|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  229|  2.38M|    }
  ------------------
  668|       |
  669|       |#ifdef DOSTORESTATE40
  670|       |    SHA1_STORE_STATE(40)
  671|       |#endif
  672|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(a, b, c, d, e, W, 40, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  673|       |
  674|       |#ifdef DOSTORESTATE41
  675|       |    SHA1_STORE_STATE(41)
  676|       |#endif
  677|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(e, a, b, c, d, W, 41, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  678|       |
  679|       |#ifdef DOSTORESTATE42
  680|       |    SHA1_STORE_STATE(42)
  681|       |#endif
  682|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(d, e, a, b, c, W, 42, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  683|       |
  684|       |#ifdef DOSTORESTATE43
  685|       |    SHA1_STORE_STATE(43)
  686|       |#endif
  687|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(c, d, e, a, b, W, 43, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  688|       |
  689|       |#ifdef DOSTORESTATE44
  690|       |    SHA1_STORE_STATE(44)
  691|       |#endif
  692|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(b, c, d, e, a, W, 44, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  693|       |
  694|       |#ifdef DOSTORESTATE45
  695|       |    SHA1_STORE_STATE(45)
  696|       |#endif
  697|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(a, b, c, d, e, W, 45, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  698|       |
  699|       |#ifdef DOSTORESTATE46
  700|       |    SHA1_STORE_STATE(46)
  701|       |#endif
  702|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(e, a, b, c, d, W, 46, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  703|       |
  704|       |#ifdef DOSTORESTATE47
  705|       |    SHA1_STORE_STATE(47)
  706|       |#endif
  707|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(d, e, a, b, c, W, 47, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  708|       |
  709|       |#ifdef DOSTORESTATE48
  710|       |    SHA1_STORE_STATE(48)
  711|       |#endif
  712|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(c, d, e, a, b, W, 48, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  713|       |
  714|       |#ifdef DOSTORESTATE49
  715|       |    SHA1_STORE_STATE(49)
  716|       |#endif
  717|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(b, c, d, e, a, W, 49, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  718|       |
  719|       |#ifdef DOSTORESTATE50
  720|       |    SHA1_STORE_STATE(50)
  721|       |#endif
  722|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(a, b, c, d, e, W, 50, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  723|       |
  724|       |#ifdef DOSTORESTATE51
  725|       |    SHA1_STORE_STATE(51)
  726|       |#endif
  727|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(e, a, b, c, d, W, 51, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  728|       |
  729|       |#ifdef DOSTORESTATE52
  730|       |    SHA1_STORE_STATE(52)
  731|       |#endif
  732|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(d, e, a, b, c, W, 52, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  733|       |
  734|       |#ifdef DOSTORESTATE53
  735|       |    SHA1_STORE_STATE(53)
  736|       |#endif
  737|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(c, d, e, a, b, W, 53, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  738|       |
  739|       |#ifdef DOSTORESTATE54
  740|       |    SHA1_STORE_STATE(54)
  741|       |#endif
  742|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(b, c, d, e, a, W, 54, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  743|       |
  744|       |#ifdef DOSTORESTATE55
  745|       |    SHA1_STORE_STATE(55)
  746|       |#endif
  747|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(a, b, c, d, e, W, 55, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  748|       |
  749|       |#ifdef DOSTORESTATE56
  750|       |    SHA1_STORE_STATE(56)
  751|       |#endif
  752|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(e, a, b, c, d, W, 56, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  753|       |
  754|       |#ifdef DOSTORESTATE57
  755|       |    SHA1_STORE_STATE(57)
  756|       |#endif
  757|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(d, e, a, b, c, W, 57, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  758|       |
  759|  2.38M|#ifdef DOSTORESTATE58
  760|  2.38M|    SHA1_STORE_STATE(58)
  ------------------
  |  |  248|  2.38M|    states[i][0] = a;       \
  |  |  249|  2.38M|    states[i][1] = b;       \
  |  |  250|  2.38M|    states[i][2] = c;       \
  |  |  251|  2.38M|    states[i][3] = d;       \
  |  |  252|  2.38M|    states[i][4] = e;
  ------------------
  761|  2.38M|#endif
  762|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(c, d, e, a, b, W, 58, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  763|       |
  764|       |#ifdef DOSTORESTATE59
  765|       |    SHA1_STORE_STATE(59)
  766|       |#endif
  767|  2.38M|    SHA1COMPRESS_FULL_ROUND3_STEP(b, c, d, e, a, W, 59, temp);
  ------------------
  |  |  232|  2.38M|    {                                                                  \
  |  |  233|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  234|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  235|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC; \
  |  |  ------------------
  |  |  |  |  162|  2.38M|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  236|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  237|  2.38M|    }
  ------------------
  768|       |
  769|       |#ifdef DOSTORESTATE60
  770|       |    SHA1_STORE_STATE(60)
  771|       |#endif
  772|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(a, b, c, d, e, W, 60, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  773|       |
  774|       |#ifdef DOSTORESTATE61
  775|       |    SHA1_STORE_STATE(61)
  776|       |#endif
  777|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(e, a, b, c, d, W, 61, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  778|       |
  779|       |#ifdef DOSTORESTATE62
  780|       |    SHA1_STORE_STATE(62)
  781|       |#endif
  782|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(d, e, a, b, c, W, 62, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  783|       |
  784|       |#ifdef DOSTORESTATE63
  785|       |    SHA1_STORE_STATE(63)
  786|       |#endif
  787|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(c, d, e, a, b, W, 63, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  788|       |
  789|       |#ifdef DOSTORESTATE64
  790|       |    SHA1_STORE_STATE(64)
  791|       |#endif
  792|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(b, c, d, e, a, W, 64, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  793|       |
  794|  2.38M|#ifdef DOSTORESTATE65
  795|  2.38M|    SHA1_STORE_STATE(65)
  ------------------
  |  |  248|  2.38M|    states[i][0] = a;       \
  |  |  249|  2.38M|    states[i][1] = b;       \
  |  |  250|  2.38M|    states[i][2] = c;       \
  |  |  251|  2.38M|    states[i][3] = d;       \
  |  |  252|  2.38M|    states[i][4] = e;
  ------------------
  796|  2.38M|#endif
  797|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(a, b, c, d, e, W, 65, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  798|       |
  799|       |#ifdef DOSTORESTATE66
  800|       |    SHA1_STORE_STATE(66)
  801|       |#endif
  802|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(e, a, b, c, d, W, 66, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  803|       |
  804|       |#ifdef DOSTORESTATE67
  805|       |    SHA1_STORE_STATE(67)
  806|       |#endif
  807|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(d, e, a, b, c, W, 67, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  808|       |
  809|       |#ifdef DOSTORESTATE68
  810|       |    SHA1_STORE_STATE(68)
  811|       |#endif
  812|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(c, d, e, a, b, W, 68, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  813|       |
  814|       |#ifdef DOSTORESTATE69
  815|       |    SHA1_STORE_STATE(69)
  816|       |#endif
  817|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(b, c, d, e, a, W, 69, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  818|       |
  819|       |#ifdef DOSTORESTATE70
  820|       |    SHA1_STORE_STATE(70)
  821|       |#endif
  822|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(a, b, c, d, e, W, 70, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  823|       |
  824|       |#ifdef DOSTORESTATE71
  825|       |    SHA1_STORE_STATE(71)
  826|       |#endif
  827|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(e, a, b, c, d, W, 71, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  828|       |
  829|       |#ifdef DOSTORESTATE72
  830|       |    SHA1_STORE_STATE(72)
  831|       |#endif
  832|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(d, e, a, b, c, W, 72, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  833|       |
  834|       |#ifdef DOSTORESTATE73
  835|       |    SHA1_STORE_STATE(73)
  836|       |#endif
  837|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(c, d, e, a, b, W, 73, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  838|       |
  839|       |#ifdef DOSTORESTATE74
  840|       |    SHA1_STORE_STATE(74)
  841|       |#endif
  842|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(b, c, d, e, a, W, 74, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  843|       |
  844|       |#ifdef DOSTORESTATE75
  845|       |    SHA1_STORE_STATE(75)
  846|       |#endif
  847|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(a, b, c, d, e, W, 75, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  848|       |
  849|       |#ifdef DOSTORESTATE76
  850|       |    SHA1_STORE_STATE(76)
  851|       |#endif
  852|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(e, a, b, c, d, W, 76, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  853|       |
  854|       |#ifdef DOSTORESTATE77
  855|       |    SHA1_STORE_STATE(77)
  856|       |#endif
  857|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(d, e, a, b, c, W, 77, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  858|       |
  859|       |#ifdef DOSTORESTATE78
  860|       |    SHA1_STORE_STATE(78)
  861|       |#endif
  862|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(c, d, e, a, b, W, 78, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  863|       |
  864|       |#ifdef DOSTORESTATE79
  865|       |    SHA1_STORE_STATE(79)
  866|       |#endif
  867|  2.38M|    SHA1COMPRESS_FULL_ROUND4_STEP(b, c, d, e, a, W, 79, temp);
  ------------------
  |  |  240|  2.38M|    {                                                                  \
  |  |  241|  2.38M|        temp = sha1_mix(W, t);                                         \
  |  |  ------------------
  |  |  |  |  143|  2.38M|#define sha1_mix(W, t) (rotate_left(W[t - 3] ^ W[t - 8] ^ W[t - 14] ^ W[t - 16], 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  242|  2.38M|        sha1_store(W, t, temp);                                        \
  |  |  ------------------
  |  |  |  |  158|  2.38M|#define sha1_store(W, t, x) *(volatile uint32_t *) &W[t] = x
  |  |  ------------------
  |  |  243|  2.38M|        e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += temp + rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6; \
  |  |  ------------------
  |  |  |  |  163|  2.38M|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  244|  2.38M|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  2.38M|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  245|  2.38M|    }
  ------------------
  868|       |
  869|  2.38M|    ihv[0] += a;
  870|  2.38M|    ihv[1] += b;
  871|  2.38M|    ihv[2] += c;
  872|  2.38M|    ihv[3] += d;
  873|  2.38M|    ihv[4] += e;
  874|  2.38M|}
SHA1DCInit:
 2019|   154k|{
 2020|   154k|    ctx->total = 0;
 2021|   154k|    ctx->ihv[0] = 0x67452301;
 2022|   154k|    ctx->ihv[1] = 0xEFCDAB89;
 2023|   154k|    ctx->ihv[2] = 0x98BADCFE;
 2024|   154k|    ctx->ihv[3] = 0x10325476;
 2025|   154k|    ctx->ihv[4] = 0xC3D2E1F0;
 2026|   154k|    ctx->found_collision = 0;
 2027|   154k|    ctx->safe_hash = SHA1DC_INIT_SAFE_HASH_DEFAULT;
  ------------------
  |  |   23|   154k|#define SHA1DC_INIT_SAFE_HASH_DEFAULT 1
  ------------------
 2028|   154k|    ctx->ubc_check = 1;
 2029|   154k|    ctx->detect_coll = 1;
 2030|   154k|    ctx->reduced_round_coll = 0;
 2031|       |    ctx->callback = NULL;
 2032|   154k|}
SHA1DCUpdate:
 2078|  2.99M|{
 2079|  2.99M|    unsigned left, fill;
 2080|       |
 2081|  2.99M|    if (len == 0)
  ------------------
  |  Branch (2081:9): [True: 1, False: 2.99M]
  ------------------
 2082|      1|        return;
 2083|       |
 2084|  2.99M|    left = ctx->total & 63;
 2085|  2.99M|    fill = 64 - left;
 2086|       |
 2087|  2.99M|    if (left && len >= fill) {
  ------------------
  |  Branch (2087:9): [True: 2.79M, False: 197k]
  |  Branch (2087:17): [True: 325k, False: 2.47M]
  ------------------
 2088|   325k|        ctx->total += fill;
 2089|   325k|        memcpy(ctx->buffer + left, buf, fill);
 2090|   325k|        sha1_process(ctx, (uint32_t *) (ctx->buffer));
 2091|   325k|        buf += fill;
 2092|   325k|        len -= fill;
 2093|   325k|        left = 0;
 2094|   325k|    }
 2095|  4.90M|    while (len >= 64) {
  ------------------
  |  Branch (2095:12): [True: 1.91M, False: 2.99M]
  ------------------
 2096|  1.91M|        ctx->total += 64;
 2097|       |
 2098|  1.91M|#if defined(SHA1DC_ALLOW_UNALIGNED_ACCESS)
 2099|  1.91M|        sha1_process(ctx, (uint32_t *) (buf));
 2100|       |#else
 2101|       |        memcpy(ctx->buffer, buf, 64);
 2102|       |        sha1_process(ctx, (uint32_t *) (ctx->buffer));
 2103|       |#endif /* defined(SHA1DC_ALLOW_UNALIGNED_ACCESS) */
 2104|  1.91M|        buf += 64;
 2105|  1.91M|        len -= 64;
 2106|  1.91M|    }
 2107|  2.99M|    if (len > 0) {
  ------------------
  |  Branch (2107:9): [True: 2.95M, False: 43.0k]
  ------------------
 2108|  2.95M|        ctx->total += len;
 2109|  2.95M|        memcpy(ctx->buffer + left, buf, len);
 2110|  2.95M|    }
 2111|  2.99M|}
SHA1DCFinal:
 2120|   153k|{
 2121|   153k|    uint32_t last = ctx->total & 63;
 2122|   153k|    uint32_t padn = (last < 56) ? (56 - last) : (120 - last);
  ------------------
  |  Branch (2122:21): [True: 145k, False: 7.47k]
  ------------------
 2123|   153k|    uint64_t total;
 2124|   153k|    SHA1DCUpdate(ctx, (const char *) (sha1_padding), padn);
 2125|       |
 2126|   153k|    total = ctx->total - padn;
 2127|   153k|    total <<= 3;
 2128|   153k|    ctx->buffer[56] = (unsigned char) (total >> 56);
 2129|   153k|    ctx->buffer[57] = (unsigned char) (total >> 48);
 2130|   153k|    ctx->buffer[58] = (unsigned char) (total >> 40);
 2131|   153k|    ctx->buffer[59] = (unsigned char) (total >> 32);
 2132|   153k|    ctx->buffer[60] = (unsigned char) (total >> 24);
 2133|   153k|    ctx->buffer[61] = (unsigned char) (total >> 16);
 2134|   153k|    ctx->buffer[62] = (unsigned char) (total >> 8);
 2135|   153k|    ctx->buffer[63] = (unsigned char) (total);
 2136|   153k|    sha1_process(ctx, (uint32_t *) (ctx->buffer));
 2137|   153k|    output[0] = (unsigned char) (ctx->ihv[0] >> 24);
 2138|   153k|    output[1] = (unsigned char) (ctx->ihv[0] >> 16);
 2139|   153k|    output[2] = (unsigned char) (ctx->ihv[0] >> 8);
 2140|   153k|    output[3] = (unsigned char) (ctx->ihv[0]);
 2141|   153k|    output[4] = (unsigned char) (ctx->ihv[1] >> 24);
 2142|   153k|    output[5] = (unsigned char) (ctx->ihv[1] >> 16);
 2143|   153k|    output[6] = (unsigned char) (ctx->ihv[1] >> 8);
 2144|   153k|    output[7] = (unsigned char) (ctx->ihv[1]);
 2145|   153k|    output[8] = (unsigned char) (ctx->ihv[2] >> 24);
 2146|   153k|    output[9] = (unsigned char) (ctx->ihv[2] >> 16);
 2147|   153k|    output[10] = (unsigned char) (ctx->ihv[2] >> 8);
 2148|   153k|    output[11] = (unsigned char) (ctx->ihv[2]);
 2149|   153k|    output[12] = (unsigned char) (ctx->ihv[3] >> 24);
 2150|   153k|    output[13] = (unsigned char) (ctx->ihv[3] >> 16);
 2151|   153k|    output[14] = (unsigned char) (ctx->ihv[3] >> 8);
 2152|   153k|    output[15] = (unsigned char) (ctx->ihv[3]);
 2153|   153k|    output[16] = (unsigned char) (ctx->ihv[4] >> 24);
 2154|   153k|    output[17] = (unsigned char) (ctx->ihv[4] >> 16);
 2155|   153k|    output[18] = (unsigned char) (ctx->ihv[4] >> 8);
 2156|   153k|    output[19] = (unsigned char) (ctx->ihv[4]);
 2157|   153k|    return ctx->found_collision;
 2158|   153k|}
sha1.c:sha1_process:
 1963|  2.38M|{
 1964|  2.38M|    unsigned i, j;
 1965|  2.38M|    uint32_t ubc_dv_mask[DVMASKSIZE] = {0xFFFFFFFF};
 1966|  2.38M|    uint32_t ihvtmp[5];
 1967|       |
 1968|  2.38M|    ctx->ihv1[0] = ctx->ihv[0];
 1969|  2.38M|    ctx->ihv1[1] = ctx->ihv[1];
 1970|  2.38M|    ctx->ihv1[2] = ctx->ihv[2];
 1971|  2.38M|    ctx->ihv1[3] = ctx->ihv[3];
 1972|  2.38M|    ctx->ihv1[4] = ctx->ihv[4];
 1973|       |
 1974|  2.38M|    sha1_compression_states(ctx->ihv, block, ctx->m1, ctx->states);
 1975|       |
 1976|  2.38M|    if (ctx->detect_coll) {
  ------------------
  |  Branch (1976:9): [True: 2.38M, False: 0]
  ------------------
 1977|  2.38M|        if (ctx->ubc_check) {
  ------------------
  |  Branch (1977:13): [True: 2.38M, False: 0]
  ------------------
 1978|  2.38M|            ubc_check(ctx->m1, ubc_dv_mask);
 1979|  2.38M|        }
 1980|       |
 1981|  2.38M|        if (ubc_dv_mask[0] != 0) {
  ------------------
  |  Branch (1981:13): [True: 146k, False: 2.24M]
  ------------------
 1982|  4.84M|            for (i = 0; sha1_dvs[i].dvType != 0; ++i) {
  ------------------
  |  Branch (1982:25): [True: 4.69M, False: 146k]
  ------------------
 1983|  4.69M|                if (ubc_dv_mask[0] & ((uint32_t)(1) << sha1_dvs[i].maskb)) {
  ------------------
  |  Branch (1983:21): [True: 151k, False: 4.54M]
  ------------------
 1984|  12.2M|                    for (j = 0; j < 80; ++j)
  ------------------
  |  Branch (1984:33): [True: 12.1M, False: 151k]
  ------------------
 1985|  12.1M|                        ctx->m2[j] = ctx->m1[j] ^ sha1_dvs[i].dm[j];
 1986|       |
 1987|   151k|                    sha1_recompression_step(sha1_dvs[i].testt,
 1988|   151k|                                            ctx->ihv2,
 1989|   151k|                                            ihvtmp,
 1990|   151k|                                            ctx->m2,
 1991|   151k|                                            ctx->states[sha1_dvs[i].testt]);
 1992|       |
 1993|       |                    /* to verify SHA-1 collision detection code with collisions for
 1994|       |                     * reduced-step SHA-1 */
 1995|   151k|                    if ((0 == ((ihvtmp[0] ^ ctx->ihv[0]) | (ihvtmp[1] ^ ctx->ihv[1]) |
  ------------------
  |  Branch (1995:25): [True: 0, False: 151k]
  ------------------
 1996|   151k|                               (ihvtmp[2] ^ ctx->ihv[2]) | (ihvtmp[3] ^ ctx->ihv[3]) |
 1997|   151k|                               (ihvtmp[4] ^ ctx->ihv[4]))) ||
 1998|   151k|                        (ctx->reduced_round_coll &&
  ------------------
  |  Branch (1998:26): [True: 0, False: 151k]
  ------------------
 1999|      0|                         0 == ((ctx->ihv1[0] ^ ctx->ihv2[0]) | (ctx->ihv1[1] ^ ctx->ihv2[1]) |
  ------------------
  |  Branch (1999:26): [True: 0, False: 0]
  ------------------
 2000|      0|                               (ctx->ihv1[2] ^ ctx->ihv2[2]) | (ctx->ihv1[3] ^ ctx->ihv2[3]) |
 2001|      0|                               (ctx->ihv1[4] ^ ctx->ihv2[4])))) {
 2002|      0|                        ctx->found_collision = 1;
 2003|       |
 2004|      0|                        if (ctx->safe_hash) {
  ------------------
  |  Branch (2004:29): [True: 0, False: 0]
  ------------------
 2005|      0|                            sha1_compression_W(ctx->ihv, ctx->m1);
 2006|      0|                            sha1_compression_W(ctx->ihv, ctx->m1);
 2007|      0|                        }
 2008|       |
 2009|      0|                        break;
 2010|      0|                    }
 2011|   151k|                }
 2012|  4.69M|            }
 2013|   146k|        }
 2014|  2.38M|    }
 2015|  2.38M|}
sha1.c:sha1_recompression_step:
 1554|   151k|{
 1555|   151k|    switch (step) {
 1556|       |#ifdef DOSTORESTATE0
 1557|       |    case 0:
 1558|       |        sha1recompress_fast_0(ihvin, ihvout, me2, state);
 1559|       |        break;
 1560|       |#endif
 1561|       |#ifdef DOSTORESTATE1
 1562|       |    case 1:
 1563|       |        sha1recompress_fast_1(ihvin, ihvout, me2, state);
 1564|       |        break;
 1565|       |#endif
 1566|       |#ifdef DOSTORESTATE2
 1567|       |    case 2:
 1568|       |        sha1recompress_fast_2(ihvin, ihvout, me2, state);
 1569|       |        break;
 1570|       |#endif
 1571|       |#ifdef DOSTORESTATE3
 1572|       |    case 3:
 1573|       |        sha1recompress_fast_3(ihvin, ihvout, me2, state);
 1574|       |        break;
 1575|       |#endif
 1576|       |#ifdef DOSTORESTATE4
 1577|       |    case 4:
 1578|       |        sha1recompress_fast_4(ihvin, ihvout, me2, state);
 1579|       |        break;
 1580|       |#endif
 1581|       |#ifdef DOSTORESTATE5
 1582|       |    case 5:
 1583|       |        sha1recompress_fast_5(ihvin, ihvout, me2, state);
 1584|       |        break;
 1585|       |#endif
 1586|       |#ifdef DOSTORESTATE6
 1587|       |    case 6:
 1588|       |        sha1recompress_fast_6(ihvin, ihvout, me2, state);
 1589|       |        break;
 1590|       |#endif
 1591|       |#ifdef DOSTORESTATE7
 1592|       |    case 7:
 1593|       |        sha1recompress_fast_7(ihvin, ihvout, me2, state);
 1594|       |        break;
 1595|       |#endif
 1596|       |#ifdef DOSTORESTATE8
 1597|       |    case 8:
 1598|       |        sha1recompress_fast_8(ihvin, ihvout, me2, state);
 1599|       |        break;
 1600|       |#endif
 1601|       |#ifdef DOSTORESTATE9
 1602|       |    case 9:
 1603|       |        sha1recompress_fast_9(ihvin, ihvout, me2, state);
 1604|       |        break;
 1605|       |#endif
 1606|       |#ifdef DOSTORESTATE10
 1607|       |    case 10:
 1608|       |        sha1recompress_fast_10(ihvin, ihvout, me2, state);
 1609|       |        break;
 1610|       |#endif
 1611|       |#ifdef DOSTORESTATE11
 1612|       |    case 11:
 1613|       |        sha1recompress_fast_11(ihvin, ihvout, me2, state);
 1614|       |        break;
 1615|       |#endif
 1616|       |#ifdef DOSTORESTATE12
 1617|       |    case 12:
 1618|       |        sha1recompress_fast_12(ihvin, ihvout, me2, state);
 1619|       |        break;
 1620|       |#endif
 1621|       |#ifdef DOSTORESTATE13
 1622|       |    case 13:
 1623|       |        sha1recompress_fast_13(ihvin, ihvout, me2, state);
 1624|       |        break;
 1625|       |#endif
 1626|       |#ifdef DOSTORESTATE14
 1627|       |    case 14:
 1628|       |        sha1recompress_fast_14(ihvin, ihvout, me2, state);
 1629|       |        break;
 1630|       |#endif
 1631|       |#ifdef DOSTORESTATE15
 1632|       |    case 15:
 1633|       |        sha1recompress_fast_15(ihvin, ihvout, me2, state);
 1634|       |        break;
 1635|       |#endif
 1636|       |#ifdef DOSTORESTATE16
 1637|       |    case 16:
 1638|       |        sha1recompress_fast_16(ihvin, ihvout, me2, state);
 1639|       |        break;
 1640|       |#endif
 1641|       |#ifdef DOSTORESTATE17
 1642|       |    case 17:
 1643|       |        sha1recompress_fast_17(ihvin, ihvout, me2, state);
 1644|       |        break;
 1645|       |#endif
 1646|       |#ifdef DOSTORESTATE18
 1647|       |    case 18:
 1648|       |        sha1recompress_fast_18(ihvin, ihvout, me2, state);
 1649|       |        break;
 1650|       |#endif
 1651|       |#ifdef DOSTORESTATE19
 1652|       |    case 19:
 1653|       |        sha1recompress_fast_19(ihvin, ihvout, me2, state);
 1654|       |        break;
 1655|       |#endif
 1656|       |#ifdef DOSTORESTATE20
 1657|       |    case 20:
 1658|       |        sha1recompress_fast_20(ihvin, ihvout, me2, state);
 1659|       |        break;
 1660|       |#endif
 1661|       |#ifdef DOSTORESTATE21
 1662|       |    case 21:
 1663|       |        sha1recompress_fast_21(ihvin, ihvout, me2, state);
 1664|       |        break;
 1665|       |#endif
 1666|       |#ifdef DOSTORESTATE22
 1667|       |    case 22:
 1668|       |        sha1recompress_fast_22(ihvin, ihvout, me2, state);
 1669|       |        break;
 1670|       |#endif
 1671|       |#ifdef DOSTORESTATE23
 1672|       |    case 23:
 1673|       |        sha1recompress_fast_23(ihvin, ihvout, me2, state);
 1674|       |        break;
 1675|       |#endif
 1676|       |#ifdef DOSTORESTATE24
 1677|       |    case 24:
 1678|       |        sha1recompress_fast_24(ihvin, ihvout, me2, state);
 1679|       |        break;
 1680|       |#endif
 1681|       |#ifdef DOSTORESTATE25
 1682|       |    case 25:
 1683|       |        sha1recompress_fast_25(ihvin, ihvout, me2, state);
 1684|       |        break;
 1685|       |#endif
 1686|       |#ifdef DOSTORESTATE26
 1687|       |    case 26:
 1688|       |        sha1recompress_fast_26(ihvin, ihvout, me2, state);
 1689|       |        break;
 1690|       |#endif
 1691|       |#ifdef DOSTORESTATE27
 1692|       |    case 27:
 1693|       |        sha1recompress_fast_27(ihvin, ihvout, me2, state);
 1694|       |        break;
 1695|       |#endif
 1696|       |#ifdef DOSTORESTATE28
 1697|       |    case 28:
 1698|       |        sha1recompress_fast_28(ihvin, ihvout, me2, state);
 1699|       |        break;
 1700|       |#endif
 1701|       |#ifdef DOSTORESTATE29
 1702|       |    case 29:
 1703|       |        sha1recompress_fast_29(ihvin, ihvout, me2, state);
 1704|       |        break;
 1705|       |#endif
 1706|       |#ifdef DOSTORESTATE30
 1707|       |    case 30:
 1708|       |        sha1recompress_fast_30(ihvin, ihvout, me2, state);
 1709|       |        break;
 1710|       |#endif
 1711|       |#ifdef DOSTORESTATE31
 1712|       |    case 31:
 1713|       |        sha1recompress_fast_31(ihvin, ihvout, me2, state);
 1714|       |        break;
 1715|       |#endif
 1716|       |#ifdef DOSTORESTATE32
 1717|       |    case 32:
 1718|       |        sha1recompress_fast_32(ihvin, ihvout, me2, state);
 1719|       |        break;
 1720|       |#endif
 1721|       |#ifdef DOSTORESTATE33
 1722|       |    case 33:
 1723|       |        sha1recompress_fast_33(ihvin, ihvout, me2, state);
 1724|       |        break;
 1725|       |#endif
 1726|       |#ifdef DOSTORESTATE34
 1727|       |    case 34:
 1728|       |        sha1recompress_fast_34(ihvin, ihvout, me2, state);
 1729|       |        break;
 1730|       |#endif
 1731|       |#ifdef DOSTORESTATE35
 1732|       |    case 35:
 1733|       |        sha1recompress_fast_35(ihvin, ihvout, me2, state);
 1734|       |        break;
 1735|       |#endif
 1736|       |#ifdef DOSTORESTATE36
 1737|       |    case 36:
 1738|       |        sha1recompress_fast_36(ihvin, ihvout, me2, state);
 1739|       |        break;
 1740|       |#endif
 1741|       |#ifdef DOSTORESTATE37
 1742|       |    case 37:
 1743|       |        sha1recompress_fast_37(ihvin, ihvout, me2, state);
 1744|       |        break;
 1745|       |#endif
 1746|       |#ifdef DOSTORESTATE38
 1747|       |    case 38:
 1748|       |        sha1recompress_fast_38(ihvin, ihvout, me2, state);
 1749|       |        break;
 1750|       |#endif
 1751|       |#ifdef DOSTORESTATE39
 1752|       |    case 39:
 1753|       |        sha1recompress_fast_39(ihvin, ihvout, me2, state);
 1754|       |        break;
 1755|       |#endif
 1756|       |#ifdef DOSTORESTATE40
 1757|       |    case 40:
 1758|       |        sha1recompress_fast_40(ihvin, ihvout, me2, state);
 1759|       |        break;
 1760|       |#endif
 1761|       |#ifdef DOSTORESTATE41
 1762|       |    case 41:
 1763|       |        sha1recompress_fast_41(ihvin, ihvout, me2, state);
 1764|       |        break;
 1765|       |#endif
 1766|       |#ifdef DOSTORESTATE42
 1767|       |    case 42:
 1768|       |        sha1recompress_fast_42(ihvin, ihvout, me2, state);
 1769|       |        break;
 1770|       |#endif
 1771|       |#ifdef DOSTORESTATE43
 1772|       |    case 43:
 1773|       |        sha1recompress_fast_43(ihvin, ihvout, me2, state);
 1774|       |        break;
 1775|       |#endif
 1776|       |#ifdef DOSTORESTATE44
 1777|       |    case 44:
 1778|       |        sha1recompress_fast_44(ihvin, ihvout, me2, state);
 1779|       |        break;
 1780|       |#endif
 1781|       |#ifdef DOSTORESTATE45
 1782|       |    case 45:
 1783|       |        sha1recompress_fast_45(ihvin, ihvout, me2, state);
 1784|       |        break;
 1785|       |#endif
 1786|       |#ifdef DOSTORESTATE46
 1787|       |    case 46:
 1788|       |        sha1recompress_fast_46(ihvin, ihvout, me2, state);
 1789|       |        break;
 1790|       |#endif
 1791|       |#ifdef DOSTORESTATE47
 1792|       |    case 47:
 1793|       |        sha1recompress_fast_47(ihvin, ihvout, me2, state);
 1794|       |        break;
 1795|       |#endif
 1796|       |#ifdef DOSTORESTATE48
 1797|       |    case 48:
 1798|       |        sha1recompress_fast_48(ihvin, ihvout, me2, state);
 1799|       |        break;
 1800|       |#endif
 1801|       |#ifdef DOSTORESTATE49
 1802|       |    case 49:
 1803|       |        sha1recompress_fast_49(ihvin, ihvout, me2, state);
 1804|       |        break;
 1805|       |#endif
 1806|       |#ifdef DOSTORESTATE50
 1807|       |    case 50:
 1808|       |        sha1recompress_fast_50(ihvin, ihvout, me2, state);
 1809|       |        break;
 1810|       |#endif
 1811|       |#ifdef DOSTORESTATE51
 1812|       |    case 51:
 1813|       |        sha1recompress_fast_51(ihvin, ihvout, me2, state);
 1814|       |        break;
 1815|       |#endif
 1816|       |#ifdef DOSTORESTATE52
 1817|       |    case 52:
 1818|       |        sha1recompress_fast_52(ihvin, ihvout, me2, state);
 1819|       |        break;
 1820|       |#endif
 1821|       |#ifdef DOSTORESTATE53
 1822|       |    case 53:
 1823|       |        sha1recompress_fast_53(ihvin, ihvout, me2, state);
 1824|       |        break;
 1825|       |#endif
 1826|       |#ifdef DOSTORESTATE54
 1827|       |    case 54:
 1828|       |        sha1recompress_fast_54(ihvin, ihvout, me2, state);
 1829|       |        break;
 1830|       |#endif
 1831|       |#ifdef DOSTORESTATE55
 1832|       |    case 55:
 1833|       |        sha1recompress_fast_55(ihvin, ihvout, me2, state);
 1834|       |        break;
 1835|       |#endif
 1836|       |#ifdef DOSTORESTATE56
 1837|       |    case 56:
 1838|       |        sha1recompress_fast_56(ihvin, ihvout, me2, state);
 1839|       |        break;
 1840|       |#endif
 1841|       |#ifdef DOSTORESTATE57
 1842|       |    case 57:
 1843|       |        sha1recompress_fast_57(ihvin, ihvout, me2, state);
 1844|       |        break;
 1845|       |#endif
 1846|      0|#ifdef DOSTORESTATE58
 1847|   126k|    case 58:
  ------------------
  |  Branch (1847:5): [True: 126k, False: 24.8k]
  ------------------
 1848|   126k|        sha1recompress_fast_58(ihvin, ihvout, me2, state);
 1849|   126k|        break;
 1850|      0|#endif
 1851|       |#ifdef DOSTORESTATE59
 1852|       |    case 59:
 1853|       |        sha1recompress_fast_59(ihvin, ihvout, me2, state);
 1854|       |        break;
 1855|       |#endif
 1856|       |#ifdef DOSTORESTATE60
 1857|       |    case 60:
 1858|       |        sha1recompress_fast_60(ihvin, ihvout, me2, state);
 1859|       |        break;
 1860|       |#endif
 1861|       |#ifdef DOSTORESTATE61
 1862|       |    case 61:
 1863|       |        sha1recompress_fast_61(ihvin, ihvout, me2, state);
 1864|       |        break;
 1865|       |#endif
 1866|       |#ifdef DOSTORESTATE62
 1867|       |    case 62:
 1868|       |        sha1recompress_fast_62(ihvin, ihvout, me2, state);
 1869|       |        break;
 1870|       |#endif
 1871|       |#ifdef DOSTORESTATE63
 1872|       |    case 63:
 1873|       |        sha1recompress_fast_63(ihvin, ihvout, me2, state);
 1874|       |        break;
 1875|       |#endif
 1876|       |#ifdef DOSTORESTATE64
 1877|       |    case 64:
 1878|       |        sha1recompress_fast_64(ihvin, ihvout, me2, state);
 1879|       |        break;
 1880|       |#endif
 1881|      0|#ifdef DOSTORESTATE65
 1882|  24.8k|    case 65:
  ------------------
  |  Branch (1882:5): [True: 24.8k, False: 126k]
  ------------------
 1883|  24.8k|        sha1recompress_fast_65(ihvin, ihvout, me2, state);
 1884|  24.8k|        break;
 1885|      0|#endif
 1886|       |#ifdef DOSTORESTATE66
 1887|       |    case 66:
 1888|       |        sha1recompress_fast_66(ihvin, ihvout, me2, state);
 1889|       |        break;
 1890|       |#endif
 1891|       |#ifdef DOSTORESTATE67
 1892|       |    case 67:
 1893|       |        sha1recompress_fast_67(ihvin, ihvout, me2, state);
 1894|       |        break;
 1895|       |#endif
 1896|       |#ifdef DOSTORESTATE68
 1897|       |    case 68:
 1898|       |        sha1recompress_fast_68(ihvin, ihvout, me2, state);
 1899|       |        break;
 1900|       |#endif
 1901|       |#ifdef DOSTORESTATE69
 1902|       |    case 69:
 1903|       |        sha1recompress_fast_69(ihvin, ihvout, me2, state);
 1904|       |        break;
 1905|       |#endif
 1906|       |#ifdef DOSTORESTATE70
 1907|       |    case 70:
 1908|       |        sha1recompress_fast_70(ihvin, ihvout, me2, state);
 1909|       |        break;
 1910|       |#endif
 1911|       |#ifdef DOSTORESTATE71
 1912|       |    case 71:
 1913|       |        sha1recompress_fast_71(ihvin, ihvout, me2, state);
 1914|       |        break;
 1915|       |#endif
 1916|       |#ifdef DOSTORESTATE72
 1917|       |    case 72:
 1918|       |        sha1recompress_fast_72(ihvin, ihvout, me2, state);
 1919|       |        break;
 1920|       |#endif
 1921|       |#ifdef DOSTORESTATE73
 1922|       |    case 73:
 1923|       |        sha1recompress_fast_73(ihvin, ihvout, me2, state);
 1924|       |        break;
 1925|       |#endif
 1926|       |#ifdef DOSTORESTATE74
 1927|       |    case 74:
 1928|       |        sha1recompress_fast_74(ihvin, ihvout, me2, state);
 1929|       |        break;
 1930|       |#endif
 1931|       |#ifdef DOSTORESTATE75
 1932|       |    case 75:
 1933|       |        sha1recompress_fast_75(ihvin, ihvout, me2, state);
 1934|       |        break;
 1935|       |#endif
 1936|       |#ifdef DOSTORESTATE76
 1937|       |    case 76:
 1938|       |        sha1recompress_fast_76(ihvin, ihvout, me2, state);
 1939|       |        break;
 1940|       |#endif
 1941|       |#ifdef DOSTORESTATE77
 1942|       |    case 77:
 1943|       |        sha1recompress_fast_77(ihvin, ihvout, me2, state);
 1944|       |        break;
 1945|       |#endif
 1946|       |#ifdef DOSTORESTATE78
 1947|       |    case 78:
 1948|       |        sha1recompress_fast_78(ihvin, ihvout, me2, state);
 1949|       |        break;
 1950|       |#endif
 1951|       |#ifdef DOSTORESTATE79
 1952|       |    case 79:
 1953|       |        sha1recompress_fast_79(ihvin, ihvout, me2, state);
 1954|       |        break;
 1955|       |#endif
 1956|      0|    default:
  ------------------
  |  Branch (1956:5): [True: 0, False: 151k]
  ------------------
 1957|      0|        abort();
 1958|   151k|    }
 1959|   151k|}
sha1.c:sha1recompress_fast_58:
  879|   126k|    {                                                                                         \
  880|   126k|        uint32_t a = state[0], b = state[1], c = state[2], d = state[3], e = state[4];        \
  881|   126k|        if (t > 79)                                                                           \
  ------------------
  |  Branch (881:13): [Folded, False: 126k]
  ------------------
  882|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 79);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  883|   126k|        if (t > 78)                                                                           \
  ------------------
  |  Branch (883:13): [Folded, False: 126k]
  ------------------
  884|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 78);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  885|   126k|        if (t > 77)                                                                           \
  ------------------
  |  Branch (885:13): [Folded, False: 126k]
  ------------------
  886|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 77);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  887|   126k|        if (t > 76)                                                                           \
  ------------------
  |  Branch (887:13): [Folded, False: 126k]
  ------------------
  888|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 76);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  889|   126k|        if (t > 75)                                                                           \
  ------------------
  |  Branch (889:13): [Folded, False: 126k]
  ------------------
  890|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 75);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  891|   126k|        if (t > 74)                                                                           \
  ------------------
  |  Branch (891:13): [Folded, False: 126k]
  ------------------
  892|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 74);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  893|   126k|        if (t > 73)                                                                           \
  ------------------
  |  Branch (893:13): [Folded, False: 126k]
  ------------------
  894|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 73);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  895|   126k|        if (t > 72)                                                                           \
  ------------------
  |  Branch (895:13): [Folded, False: 126k]
  ------------------
  896|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 72);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  897|   126k|        if (t > 71)                                                                           \
  ------------------
  |  Branch (897:13): [Folded, False: 126k]
  ------------------
  898|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 71);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  899|   126k|        if (t > 70)                                                                           \
  ------------------
  |  Branch (899:13): [Folded, False: 126k]
  ------------------
  900|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 70);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  901|   126k|        if (t > 69)                                                                           \
  ------------------
  |  Branch (901:13): [Folded, False: 126k]
  ------------------
  902|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 69);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  903|   126k|        if (t > 68)                                                                           \
  ------------------
  |  Branch (903:13): [Folded, False: 126k]
  ------------------
  904|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 68);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  905|   126k|        if (t > 67)                                                                           \
  ------------------
  |  Branch (905:13): [Folded, False: 126k]
  ------------------
  906|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 67);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  907|   126k|        if (t > 66)                                                                           \
  ------------------
  |  Branch (907:13): [Folded, False: 126k]
  ------------------
  908|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 66);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  909|   126k|        if (t > 65)                                                                           \
  ------------------
  |  Branch (909:13): [Folded, False: 126k]
  ------------------
  910|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 65);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  911|   126k|        if (t > 64)                                                                           \
  ------------------
  |  Branch (911:13): [Folded, False: 126k]
  ------------------
  912|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 64);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  913|   126k|        if (t > 63)                                                                           \
  ------------------
  |  Branch (913:13): [Folded, False: 126k]
  ------------------
  914|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 63);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  915|   126k|        if (t > 62)                                                                           \
  ------------------
  |  Branch (915:13): [Folded, False: 126k]
  ------------------
  916|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 62);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  917|   126k|        if (t > 61)                                                                           \
  ------------------
  |  Branch (917:13): [Folded, False: 126k]
  ------------------
  918|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 61);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  919|   126k|        if (t > 60)                                                                           \
  ------------------
  |  Branch (919:13): [Folded, False: 126k]
  ------------------
  920|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 60);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  921|   126k|        if (t > 59)                                                                           \
  ------------------
  |  Branch (921:13): [Folded, False: 126k]
  ------------------
  922|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 59);                    \
  ------------------
  |  |  197|      0|    {                                                                  \
  |  |  198|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|      0|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|      0|    }
  ------------------
  923|   126k|        if (t > 58)                                                                           \
  ------------------
  |  Branch (923:13): [Folded, False: 126k]
  ------------------
  924|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 58);                    \
  ------------------
  |  |  197|      0|    {                                                                  \
  |  |  198|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|      0|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|      0|    }
  ------------------
  925|   126k|        if (t > 57)                                                                           \
  ------------------
  |  Branch (925:13): [True: 126k, Folded]
  ------------------
  926|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 57);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  927|   126k|        if (t > 56)                                                                           \
  ------------------
  |  Branch (927:13): [True: 126k, Folded]
  ------------------
  928|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 56);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  929|   126k|        if (t > 55)                                                                           \
  ------------------
  |  Branch (929:13): [True: 126k, Folded]
  ------------------
  930|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 55);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  931|   126k|        if (t > 54)                                                                           \
  ------------------
  |  Branch (931:13): [True: 126k, Folded]
  ------------------
  932|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 54);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  933|   126k|        if (t > 53)                                                                           \
  ------------------
  |  Branch (933:13): [True: 126k, Folded]
  ------------------
  934|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 53);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  935|   126k|        if (t > 52)                                                                           \
  ------------------
  |  Branch (935:13): [True: 126k, Folded]
  ------------------
  936|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 52);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  937|   126k|        if (t > 51)                                                                           \
  ------------------
  |  Branch (937:13): [True: 126k, Folded]
  ------------------
  938|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 51);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  939|   126k|        if (t > 50)                                                                           \
  ------------------
  |  Branch (939:13): [True: 126k, Folded]
  ------------------
  940|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 50);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  941|   126k|        if (t > 49)                                                                           \
  ------------------
  |  Branch (941:13): [True: 126k, Folded]
  ------------------
  942|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 49);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  943|   126k|        if (t > 48)                                                                           \
  ------------------
  |  Branch (943:13): [True: 126k, Folded]
  ------------------
  944|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 48);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  945|   126k|        if (t > 47)                                                                           \
  ------------------
  |  Branch (945:13): [True: 126k, Folded]
  ------------------
  946|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 47);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  947|   126k|        if (t > 46)                                                                           \
  ------------------
  |  Branch (947:13): [True: 126k, Folded]
  ------------------
  948|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 46);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  949|   126k|        if (t > 45)                                                                           \
  ------------------
  |  Branch (949:13): [True: 126k, Folded]
  ------------------
  950|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 45);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  951|   126k|        if (t > 44)                                                                           \
  ------------------
  |  Branch (951:13): [True: 126k, Folded]
  ------------------
  952|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 44);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  953|   126k|        if (t > 43)                                                                           \
  ------------------
  |  Branch (953:13): [True: 126k, Folded]
  ------------------
  954|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 43);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  955|   126k|        if (t > 42)                                                                           \
  ------------------
  |  Branch (955:13): [True: 126k, Folded]
  ------------------
  956|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 42);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  957|   126k|        if (t > 41)                                                                           \
  ------------------
  |  Branch (957:13): [True: 126k, Folded]
  ------------------
  958|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 41);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  959|   126k|        if (t > 40)                                                                           \
  ------------------
  |  Branch (959:13): [True: 126k, Folded]
  ------------------
  960|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 40);                    \
  ------------------
  |  |  197|   126k|    {                                                                  \
  |  |  198|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|   126k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|   126k|    }
  ------------------
  961|   126k|        if (t > 39)                                                                           \
  ------------------
  |  Branch (961:13): [True: 126k, Folded]
  ------------------
  962|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 39);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  963|   126k|        if (t > 38)                                                                           \
  ------------------
  |  Branch (963:13): [True: 126k, Folded]
  ------------------
  964|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 38);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  965|   126k|        if (t > 37)                                                                           \
  ------------------
  |  Branch (965:13): [True: 126k, Folded]
  ------------------
  966|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 37);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  967|   126k|        if (t > 36)                                                                           \
  ------------------
  |  Branch (967:13): [True: 126k, Folded]
  ------------------
  968|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 36);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  969|   126k|        if (t > 35)                                                                           \
  ------------------
  |  Branch (969:13): [True: 126k, Folded]
  ------------------
  970|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 35);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  971|   126k|        if (t > 34)                                                                           \
  ------------------
  |  Branch (971:13): [True: 126k, Folded]
  ------------------
  972|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 34);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  973|   126k|        if (t > 33)                                                                           \
  ------------------
  |  Branch (973:13): [True: 126k, Folded]
  ------------------
  974|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 33);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  975|   126k|        if (t > 32)                                                                           \
  ------------------
  |  Branch (975:13): [True: 126k, Folded]
  ------------------
  976|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 32);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  977|   126k|        if (t > 31)                                                                           \
  ------------------
  |  Branch (977:13): [True: 126k, Folded]
  ------------------
  978|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 31);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  979|   126k|        if (t > 30)                                                                           \
  ------------------
  |  Branch (979:13): [True: 126k, Folded]
  ------------------
  980|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 30);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  981|   126k|        if (t > 29)                                                                           \
  ------------------
  |  Branch (981:13): [True: 126k, Folded]
  ------------------
  982|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 29);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  983|   126k|        if (t > 28)                                                                           \
  ------------------
  |  Branch (983:13): [True: 126k, Folded]
  ------------------
  984|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 28);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  985|   126k|        if (t > 27)                                                                           \
  ------------------
  |  Branch (985:13): [True: 126k, Folded]
  ------------------
  986|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 27);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  987|   126k|        if (t > 26)                                                                           \
  ------------------
  |  Branch (987:13): [True: 126k, Folded]
  ------------------
  988|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 26);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  989|   126k|        if (t > 25)                                                                           \
  ------------------
  |  Branch (989:13): [True: 126k, Folded]
  ------------------
  990|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 25);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  991|   126k|        if (t > 24)                                                                           \
  ------------------
  |  Branch (991:13): [True: 126k, Folded]
  ------------------
  992|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 24);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  993|   126k|        if (t > 23)                                                                           \
  ------------------
  |  Branch (993:13): [True: 126k, Folded]
  ------------------
  994|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 23);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  995|   126k|        if (t > 22)                                                                           \
  ------------------
  |  Branch (995:13): [True: 126k, Folded]
  ------------------
  996|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 22);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  997|   126k|        if (t > 21)                                                                           \
  ------------------
  |  Branch (997:13): [True: 126k, Folded]
  ------------------
  998|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 21);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
  999|   126k|        if (t > 20)                                                                           \
  ------------------
  |  Branch (999:13): [True: 126k, Folded]
  ------------------
 1000|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 20);                    \
  ------------------
  |  |  192|   126k|    {                                                                  \
  |  |  193|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|   126k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|   126k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|   126k|    }
  ------------------
 1001|   126k|        if (t > 19)                                                                           \
  ------------------
  |  Branch (1001:13): [True: 126k, Folded]
  ------------------
 1002|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 19);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1003|   126k|        if (t > 18)                                                                           \
  ------------------
  |  Branch (1003:13): [True: 126k, Folded]
  ------------------
 1004|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 18);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1005|   126k|        if (t > 17)                                                                           \
  ------------------
  |  Branch (1005:13): [True: 126k, Folded]
  ------------------
 1006|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 17);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1007|   126k|        if (t > 16)                                                                           \
  ------------------
  |  Branch (1007:13): [True: 126k, Folded]
  ------------------
 1008|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 16);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1009|   126k|        if (t > 15)                                                                           \
  ------------------
  |  Branch (1009:13): [True: 126k, Folded]
  ------------------
 1010|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 15);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1011|   126k|        if (t > 14)                                                                           \
  ------------------
  |  Branch (1011:13): [True: 126k, Folded]
  ------------------
 1012|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 14);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1013|   126k|        if (t > 13)                                                                           \
  ------------------
  |  Branch (1013:13): [True: 126k, Folded]
  ------------------
 1014|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 13);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1015|   126k|        if (t > 12)                                                                           \
  ------------------
  |  Branch (1015:13): [True: 126k, Folded]
  ------------------
 1016|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 12);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1017|   126k|        if (t > 11)                                                                           \
  ------------------
  |  Branch (1017:13): [True: 126k, Folded]
  ------------------
 1018|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 11);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1019|   126k|        if (t > 10)                                                                           \
  ------------------
  |  Branch (1019:13): [True: 126k, Folded]
  ------------------
 1020|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 10);                    \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1021|   126k|        if (t > 9)                                                                            \
  ------------------
  |  Branch (1021:13): [True: 126k, Folded]
  ------------------
 1022|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 9);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1023|   126k|        if (t > 8)                                                                            \
  ------------------
  |  Branch (1023:13): [True: 126k, Folded]
  ------------------
 1024|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 8);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1025|   126k|        if (t > 7)                                                                            \
  ------------------
  |  Branch (1025:13): [True: 126k, Folded]
  ------------------
 1026|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 7);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1027|   126k|        if (t > 6)                                                                            \
  ------------------
  |  Branch (1027:13): [True: 126k, Folded]
  ------------------
 1028|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 6);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1029|   126k|        if (t > 5)                                                                            \
  ------------------
  |  Branch (1029:13): [True: 126k, Folded]
  ------------------
 1030|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 5);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1031|   126k|        if (t > 4)                                                                            \
  ------------------
  |  Branch (1031:13): [True: 126k, Folded]
  ------------------
 1032|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 4);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1033|   126k|        if (t > 3)                                                                            \
  ------------------
  |  Branch (1033:13): [True: 126k, Folded]
  ------------------
 1034|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 3);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1035|   126k|        if (t > 2)                                                                            \
  ------------------
  |  Branch (1035:13): [True: 126k, Folded]
  ------------------
 1036|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 2);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1037|   126k|        if (t > 1)                                                                            \
  ------------------
  |  Branch (1037:13): [True: 126k, Folded]
  ------------------
 1038|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 1);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1039|   126k|        if (t > 0)                                                                            \
  ------------------
  |  Branch (1039:13): [True: 126k, Folded]
  ------------------
 1040|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 0);                     \
  ------------------
  |  |  187|   126k|    {                                                                  \
  |  |  188|   126k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|   126k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|   126k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|   126k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|   126k|    }
  ------------------
 1041|   126k|        ihvin[0] = a;                                                                         \
 1042|   126k|        ihvin[1] = b;                                                                         \
 1043|   126k|        ihvin[2] = c;                                                                         \
 1044|   126k|        ihvin[3] = d;                                                                         \
 1045|   126k|        ihvin[4] = e;                                                                         \
 1046|   126k|        a = state[0];                                                                         \
 1047|   126k|        b = state[1];                                                                         \
 1048|   126k|        c = state[2];                                                                         \
 1049|   126k|        d = state[3];                                                                         \
 1050|   126k|        e = state[4];                                                                         \
 1051|   126k|        if (t <= 0)                                                                           \
  ------------------
  |  Branch (1051:13): [Folded, False: 126k]
  ------------------
 1052|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 0);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1053|   126k|        if (t <= 1)                                                                           \
  ------------------
  |  Branch (1053:13): [Folded, False: 126k]
  ------------------
 1054|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 1);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1055|   126k|        if (t <= 2)                                                                           \
  ------------------
  |  Branch (1055:13): [Folded, False: 126k]
  ------------------
 1056|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 2);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1057|   126k|        if (t <= 3)                                                                           \
  ------------------
  |  Branch (1057:13): [Folded, False: 126k]
  ------------------
 1058|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 3);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1059|   126k|        if (t <= 4)                                                                           \
  ------------------
  |  Branch (1059:13): [Folded, False: 126k]
  ------------------
 1060|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 4);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1061|   126k|        if (t <= 5)                                                                           \
  ------------------
  |  Branch (1061:13): [Folded, False: 126k]
  ------------------
 1062|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 5);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1063|   126k|        if (t <= 6)                                                                           \
  ------------------
  |  Branch (1063:13): [Folded, False: 126k]
  ------------------
 1064|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 6);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1065|   126k|        if (t <= 7)                                                                           \
  ------------------
  |  Branch (1065:13): [Folded, False: 126k]
  ------------------
 1066|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 7);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1067|   126k|        if (t <= 8)                                                                           \
  ------------------
  |  Branch (1067:13): [Folded, False: 126k]
  ------------------
 1068|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 8);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1069|   126k|        if (t <= 9)                                                                           \
  ------------------
  |  Branch (1069:13): [Folded, False: 126k]
  ------------------
 1070|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 9);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1071|   126k|        if (t <= 10)                                                                          \
  ------------------
  |  Branch (1071:13): [Folded, False: 126k]
  ------------------
 1072|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 10);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1073|   126k|        if (t <= 11)                                                                          \
  ------------------
  |  Branch (1073:13): [Folded, False: 126k]
  ------------------
 1074|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 11);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1075|   126k|        if (t <= 12)                                                                          \
  ------------------
  |  Branch (1075:13): [Folded, False: 126k]
  ------------------
 1076|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 12);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1077|   126k|        if (t <= 13)                                                                          \
  ------------------
  |  Branch (1077:13): [Folded, False: 126k]
  ------------------
 1078|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 13);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1079|   126k|        if (t <= 14)                                                                          \
  ------------------
  |  Branch (1079:13): [Folded, False: 126k]
  ------------------
 1080|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 14);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1081|   126k|        if (t <= 15)                                                                          \
  ------------------
  |  Branch (1081:13): [Folded, False: 126k]
  ------------------
 1082|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 15);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1083|   126k|        if (t <= 16)                                                                          \
  ------------------
  |  Branch (1083:13): [Folded, False: 126k]
  ------------------
 1084|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 16);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1085|   126k|        if (t <= 17)                                                                          \
  ------------------
  |  Branch (1085:13): [Folded, False: 126k]
  ------------------
 1086|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 17);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1087|   126k|        if (t <= 18)                                                                          \
  ------------------
  |  Branch (1087:13): [Folded, False: 126k]
  ------------------
 1088|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 18);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1089|   126k|        if (t <= 19)                                                                          \
  ------------------
  |  Branch (1089:13): [Folded, False: 126k]
  ------------------
 1090|   126k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 19);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1091|   126k|        if (t <= 20)                                                                          \
  ------------------
  |  Branch (1091:13): [Folded, False: 126k]
  ------------------
 1092|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 20);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1093|   126k|        if (t <= 21)                                                                          \
  ------------------
  |  Branch (1093:13): [Folded, False: 126k]
  ------------------
 1094|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 21);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1095|   126k|        if (t <= 22)                                                                          \
  ------------------
  |  Branch (1095:13): [Folded, False: 126k]
  ------------------
 1096|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 22);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1097|   126k|        if (t <= 23)                                                                          \
  ------------------
  |  Branch (1097:13): [Folded, False: 126k]
  ------------------
 1098|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 23);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1099|   126k|        if (t <= 24)                                                                          \
  ------------------
  |  Branch (1099:13): [Folded, False: 126k]
  ------------------
 1100|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 24);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1101|   126k|        if (t <= 25)                                                                          \
  ------------------
  |  Branch (1101:13): [Folded, False: 126k]
  ------------------
 1102|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 25);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1103|   126k|        if (t <= 26)                                                                          \
  ------------------
  |  Branch (1103:13): [Folded, False: 126k]
  ------------------
 1104|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 26);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1105|   126k|        if (t <= 27)                                                                          \
  ------------------
  |  Branch (1105:13): [Folded, False: 126k]
  ------------------
 1106|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 27);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1107|   126k|        if (t <= 28)                                                                          \
  ------------------
  |  Branch (1107:13): [Folded, False: 126k]
  ------------------
 1108|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 28);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1109|   126k|        if (t <= 29)                                                                          \
  ------------------
  |  Branch (1109:13): [Folded, False: 126k]
  ------------------
 1110|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 29);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1111|   126k|        if (t <= 30)                                                                          \
  ------------------
  |  Branch (1111:13): [Folded, False: 126k]
  ------------------
 1112|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 30);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1113|   126k|        if (t <= 31)                                                                          \
  ------------------
  |  Branch (1113:13): [Folded, False: 126k]
  ------------------
 1114|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 31);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1115|   126k|        if (t <= 32)                                                                          \
  ------------------
  |  Branch (1115:13): [Folded, False: 126k]
  ------------------
 1116|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 32);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1117|   126k|        if (t <= 33)                                                                          \
  ------------------
  |  Branch (1117:13): [Folded, False: 126k]
  ------------------
 1118|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 33);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1119|   126k|        if (t <= 34)                                                                          \
  ------------------
  |  Branch (1119:13): [Folded, False: 126k]
  ------------------
 1120|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 34);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1121|   126k|        if (t <= 35)                                                                          \
  ------------------
  |  Branch (1121:13): [Folded, False: 126k]
  ------------------
 1122|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 35);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1123|   126k|        if (t <= 36)                                                                          \
  ------------------
  |  Branch (1123:13): [Folded, False: 126k]
  ------------------
 1124|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 36);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1125|   126k|        if (t <= 37)                                                                          \
  ------------------
  |  Branch (1125:13): [Folded, False: 126k]
  ------------------
 1126|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 37);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1127|   126k|        if (t <= 38)                                                                          \
  ------------------
  |  Branch (1127:13): [Folded, False: 126k]
  ------------------
 1128|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 38);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1129|   126k|        if (t <= 39)                                                                          \
  ------------------
  |  Branch (1129:13): [Folded, False: 126k]
  ------------------
 1130|   126k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 39);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1131|   126k|        if (t <= 40)                                                                          \
  ------------------
  |  Branch (1131:13): [Folded, False: 126k]
  ------------------
 1132|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 40);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1133|   126k|        if (t <= 41)                                                                          \
  ------------------
  |  Branch (1133:13): [Folded, False: 126k]
  ------------------
 1134|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 41);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1135|   126k|        if (t <= 42)                                                                          \
  ------------------
  |  Branch (1135:13): [Folded, False: 126k]
  ------------------
 1136|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 42);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1137|   126k|        if (t <= 43)                                                                          \
  ------------------
  |  Branch (1137:13): [Folded, False: 126k]
  ------------------
 1138|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 43);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1139|   126k|        if (t <= 44)                                                                          \
  ------------------
  |  Branch (1139:13): [Folded, False: 126k]
  ------------------
 1140|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 44);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1141|   126k|        if (t <= 45)                                                                          \
  ------------------
  |  Branch (1141:13): [Folded, False: 126k]
  ------------------
 1142|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 45);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1143|   126k|        if (t <= 46)                                                                          \
  ------------------
  |  Branch (1143:13): [Folded, False: 126k]
  ------------------
 1144|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 46);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1145|   126k|        if (t <= 47)                                                                          \
  ------------------
  |  Branch (1145:13): [Folded, False: 126k]
  ------------------
 1146|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 47);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1147|   126k|        if (t <= 48)                                                                          \
  ------------------
  |  Branch (1147:13): [Folded, False: 126k]
  ------------------
 1148|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 48);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1149|   126k|        if (t <= 49)                                                                          \
  ------------------
  |  Branch (1149:13): [Folded, False: 126k]
  ------------------
 1150|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 49);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1151|   126k|        if (t <= 50)                                                                          \
  ------------------
  |  Branch (1151:13): [Folded, False: 126k]
  ------------------
 1152|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 50);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1153|   126k|        if (t <= 51)                                                                          \
  ------------------
  |  Branch (1153:13): [Folded, False: 126k]
  ------------------
 1154|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 51);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1155|   126k|        if (t <= 52)                                                                          \
  ------------------
  |  Branch (1155:13): [Folded, False: 126k]
  ------------------
 1156|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 52);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1157|   126k|        if (t <= 53)                                                                          \
  ------------------
  |  Branch (1157:13): [Folded, False: 126k]
  ------------------
 1158|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 53);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1159|   126k|        if (t <= 54)                                                                          \
  ------------------
  |  Branch (1159:13): [Folded, False: 126k]
  ------------------
 1160|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 54);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1161|   126k|        if (t <= 55)                                                                          \
  ------------------
  |  Branch (1161:13): [Folded, False: 126k]
  ------------------
 1162|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 55);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1163|   126k|        if (t <= 56)                                                                          \
  ------------------
  |  Branch (1163:13): [Folded, False: 126k]
  ------------------
 1164|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 56);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1165|   126k|        if (t <= 57)                                                                          \
  ------------------
  |  Branch (1165:13): [Folded, False: 126k]
  ------------------
 1166|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 57);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1167|   126k|        if (t <= 58)                                                                          \
  ------------------
  |  Branch (1167:13): [True: 126k, Folded]
  ------------------
 1168|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 58);                       \
  ------------------
  |  |  176|   126k|    {                                                                  \
  |  |  177|   126k|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|   126k|    }
  ------------------
 1169|   126k|        if (t <= 59)                                                                          \
  ------------------
  |  Branch (1169:13): [True: 126k, Folded]
  ------------------
 1170|   126k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 59);                       \
  ------------------
  |  |  176|   126k|    {                                                                  \
  |  |  177|   126k|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|   126k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|   126k|    }
  ------------------
 1171|   126k|        if (t <= 60)                                                                          \
  ------------------
  |  Branch (1171:13): [True: 126k, Folded]
  ------------------
 1172|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 60);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1173|   126k|        if (t <= 61)                                                                          \
  ------------------
  |  Branch (1173:13): [True: 126k, Folded]
  ------------------
 1174|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 61);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1175|   126k|        if (t <= 62)                                                                          \
  ------------------
  |  Branch (1175:13): [True: 126k, Folded]
  ------------------
 1176|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 62);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1177|   126k|        if (t <= 63)                                                                          \
  ------------------
  |  Branch (1177:13): [True: 126k, Folded]
  ------------------
 1178|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 63);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1179|   126k|        if (t <= 64)                                                                          \
  ------------------
  |  Branch (1179:13): [True: 126k, Folded]
  ------------------
 1180|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 64);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1181|   126k|        if (t <= 65)                                                                          \
  ------------------
  |  Branch (1181:13): [True: 126k, Folded]
  ------------------
 1182|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 65);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1183|   126k|        if (t <= 66)                                                                          \
  ------------------
  |  Branch (1183:13): [True: 126k, Folded]
  ------------------
 1184|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 66);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1185|   126k|        if (t <= 67)                                                                          \
  ------------------
  |  Branch (1185:13): [True: 126k, Folded]
  ------------------
 1186|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 67);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1187|   126k|        if (t <= 68)                                                                          \
  ------------------
  |  Branch (1187:13): [True: 126k, Folded]
  ------------------
 1188|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 68);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1189|   126k|        if (t <= 69)                                                                          \
  ------------------
  |  Branch (1189:13): [True: 126k, Folded]
  ------------------
 1190|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 69);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1191|   126k|        if (t <= 70)                                                                          \
  ------------------
  |  Branch (1191:13): [True: 126k, Folded]
  ------------------
 1192|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 70);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1193|   126k|        if (t <= 71)                                                                          \
  ------------------
  |  Branch (1193:13): [True: 126k, Folded]
  ------------------
 1194|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 71);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1195|   126k|        if (t <= 72)                                                                          \
  ------------------
  |  Branch (1195:13): [True: 126k, Folded]
  ------------------
 1196|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 72);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1197|   126k|        if (t <= 73)                                                                          \
  ------------------
  |  Branch (1197:13): [True: 126k, Folded]
  ------------------
 1198|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 73);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1199|   126k|        if (t <= 74)                                                                          \
  ------------------
  |  Branch (1199:13): [True: 126k, Folded]
  ------------------
 1200|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 74);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1201|   126k|        if (t <= 75)                                                                          \
  ------------------
  |  Branch (1201:13): [True: 126k, Folded]
  ------------------
 1202|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 75);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1203|   126k|        if (t <= 76)                                                                          \
  ------------------
  |  Branch (1203:13): [True: 126k, Folded]
  ------------------
 1204|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 76);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1205|   126k|        if (t <= 77)                                                                          \
  ------------------
  |  Branch (1205:13): [True: 126k, Folded]
  ------------------
 1206|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 77);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1207|   126k|        if (t <= 78)                                                                          \
  ------------------
  |  Branch (1207:13): [True: 126k, Folded]
  ------------------
 1208|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 78);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1209|   126k|        if (t <= 79)                                                                          \
  ------------------
  |  Branch (1209:13): [True: 126k, Folded]
  ------------------
 1210|   126k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 79);                       \
  ------------------
  |  |  181|   126k|    {                                                                  \
  |  |  182|   126k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|   126k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|   126k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|   126k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|   126k|    }
  ------------------
 1211|   126k|        ihvout[0] = ihvin[0] + a;                                                             \
 1212|   126k|        ihvout[1] = ihvin[1] + b;                                                             \
 1213|   126k|        ihvout[2] = ihvin[2] + c;                                                             \
 1214|   126k|        ihvout[3] = ihvin[3] + d;                                                             \
 1215|   126k|        ihvout[4] = ihvin[4] + e;                                                             \
 1216|   126k|    }
sha1.c:sha1recompress_fast_65:
  879|  24.8k|    {                                                                                         \
  880|  24.8k|        uint32_t a = state[0], b = state[1], c = state[2], d = state[3], e = state[4];        \
  881|  24.8k|        if (t > 79)                                                                           \
  ------------------
  |  Branch (881:13): [Folded, False: 24.8k]
  ------------------
  882|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 79);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  883|  24.8k|        if (t > 78)                                                                           \
  ------------------
  |  Branch (883:13): [Folded, False: 24.8k]
  ------------------
  884|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 78);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  885|  24.8k|        if (t > 77)                                                                           \
  ------------------
  |  Branch (885:13): [Folded, False: 24.8k]
  ------------------
  886|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 77);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  887|  24.8k|        if (t > 76)                                                                           \
  ------------------
  |  Branch (887:13): [Folded, False: 24.8k]
  ------------------
  888|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 76);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  889|  24.8k|        if (t > 75)                                                                           \
  ------------------
  |  Branch (889:13): [Folded, False: 24.8k]
  ------------------
  890|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 75);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  891|  24.8k|        if (t > 74)                                                                           \
  ------------------
  |  Branch (891:13): [Folded, False: 24.8k]
  ------------------
  892|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 74);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  893|  24.8k|        if (t > 73)                                                                           \
  ------------------
  |  Branch (893:13): [Folded, False: 24.8k]
  ------------------
  894|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 73);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  895|  24.8k|        if (t > 72)                                                                           \
  ------------------
  |  Branch (895:13): [Folded, False: 24.8k]
  ------------------
  896|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 72);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  897|  24.8k|        if (t > 71)                                                                           \
  ------------------
  |  Branch (897:13): [Folded, False: 24.8k]
  ------------------
  898|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 71);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  899|  24.8k|        if (t > 70)                                                                           \
  ------------------
  |  Branch (899:13): [Folded, False: 24.8k]
  ------------------
  900|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 70);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  901|  24.8k|        if (t > 69)                                                                           \
  ------------------
  |  Branch (901:13): [Folded, False: 24.8k]
  ------------------
  902|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 69);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  903|  24.8k|        if (t > 68)                                                                           \
  ------------------
  |  Branch (903:13): [Folded, False: 24.8k]
  ------------------
  904|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 68);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  905|  24.8k|        if (t > 67)                                                                           \
  ------------------
  |  Branch (905:13): [Folded, False: 24.8k]
  ------------------
  906|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 67);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  907|  24.8k|        if (t > 66)                                                                           \
  ------------------
  |  Branch (907:13): [Folded, False: 24.8k]
  ------------------
  908|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 66);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  909|  24.8k|        if (t > 65)                                                                           \
  ------------------
  |  Branch (909:13): [Folded, False: 24.8k]
  ------------------
  910|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 65);                    \
  ------------------
  |  |  202|      0|    {                                                                  \
  |  |  203|      0|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|      0|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|      0|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|      0|    }
  ------------------
  911|  24.8k|        if (t > 64)                                                                           \
  ------------------
  |  Branch (911:13): [True: 24.8k, Folded]
  ------------------
  912|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(b, c, d, e, a, me2, 64);                    \
  ------------------
  |  |  202|  24.8k|    {                                                                  \
  |  |  203|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|  24.8k|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|  24.8k|    }
  ------------------
  913|  24.8k|        if (t > 63)                                                                           \
  ------------------
  |  Branch (913:13): [True: 24.8k, Folded]
  ------------------
  914|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(c, d, e, a, b, me2, 63);                    \
  ------------------
  |  |  202|  24.8k|    {                                                                  \
  |  |  203|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|  24.8k|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|  24.8k|    }
  ------------------
  915|  24.8k|        if (t > 62)                                                                           \
  ------------------
  |  Branch (915:13): [True: 24.8k, Folded]
  ------------------
  916|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(d, e, a, b, c, me2, 62);                    \
  ------------------
  |  |  202|  24.8k|    {                                                                  \
  |  |  203|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|  24.8k|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|  24.8k|    }
  ------------------
  917|  24.8k|        if (t > 61)                                                                           \
  ------------------
  |  Branch (917:13): [True: 24.8k, Folded]
  ------------------
  918|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(e, a, b, c, d, me2, 61);                    \
  ------------------
  |  |  202|  24.8k|    {                                                                  \
  |  |  203|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|  24.8k|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|  24.8k|    }
  ------------------
  919|  24.8k|        if (t > 60)                                                                           \
  ------------------
  |  Branch (919:13): [True: 24.8k, Folded]
  ------------------
  920|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP_BW(a, b, c, d, e, me2, 60);                    \
  ------------------
  |  |  202|  24.8k|    {                                                                  \
  |  |  203|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  204|  24.8k|        e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  205|  24.8k|    }
  ------------------
  921|  24.8k|        if (t > 59)                                                                           \
  ------------------
  |  Branch (921:13): [True: 24.8k, Folded]
  ------------------
  922|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 59);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  923|  24.8k|        if (t > 58)                                                                           \
  ------------------
  |  Branch (923:13): [True: 24.8k, Folded]
  ------------------
  924|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 58);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  925|  24.8k|        if (t > 57)                                                                           \
  ------------------
  |  Branch (925:13): [True: 24.8k, Folded]
  ------------------
  926|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 57);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  927|  24.8k|        if (t > 56)                                                                           \
  ------------------
  |  Branch (927:13): [True: 24.8k, Folded]
  ------------------
  928|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 56);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  929|  24.8k|        if (t > 55)                                                                           \
  ------------------
  |  Branch (929:13): [True: 24.8k, Folded]
  ------------------
  930|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 55);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  931|  24.8k|        if (t > 54)                                                                           \
  ------------------
  |  Branch (931:13): [True: 24.8k, Folded]
  ------------------
  932|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 54);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  933|  24.8k|        if (t > 53)                                                                           \
  ------------------
  |  Branch (933:13): [True: 24.8k, Folded]
  ------------------
  934|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 53);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  935|  24.8k|        if (t > 52)                                                                           \
  ------------------
  |  Branch (935:13): [True: 24.8k, Folded]
  ------------------
  936|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 52);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  937|  24.8k|        if (t > 51)                                                                           \
  ------------------
  |  Branch (937:13): [True: 24.8k, Folded]
  ------------------
  938|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 51);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  939|  24.8k|        if (t > 50)                                                                           \
  ------------------
  |  Branch (939:13): [True: 24.8k, Folded]
  ------------------
  940|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 50);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  941|  24.8k|        if (t > 49)                                                                           \
  ------------------
  |  Branch (941:13): [True: 24.8k, Folded]
  ------------------
  942|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 49);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  943|  24.8k|        if (t > 48)                                                                           \
  ------------------
  |  Branch (943:13): [True: 24.8k, Folded]
  ------------------
  944|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 48);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  945|  24.8k|        if (t > 47)                                                                           \
  ------------------
  |  Branch (945:13): [True: 24.8k, Folded]
  ------------------
  946|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 47);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  947|  24.8k|        if (t > 46)                                                                           \
  ------------------
  |  Branch (947:13): [True: 24.8k, Folded]
  ------------------
  948|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 46);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  949|  24.8k|        if (t > 45)                                                                           \
  ------------------
  |  Branch (949:13): [True: 24.8k, Folded]
  ------------------
  950|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 45);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  951|  24.8k|        if (t > 44)                                                                           \
  ------------------
  |  Branch (951:13): [True: 24.8k, Folded]
  ------------------
  952|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(b, c, d, e, a, me2, 44);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  953|  24.8k|        if (t > 43)                                                                           \
  ------------------
  |  Branch (953:13): [True: 24.8k, Folded]
  ------------------
  954|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(c, d, e, a, b, me2, 43);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  955|  24.8k|        if (t > 42)                                                                           \
  ------------------
  |  Branch (955:13): [True: 24.8k, Folded]
  ------------------
  956|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(d, e, a, b, c, me2, 42);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  957|  24.8k|        if (t > 41)                                                                           \
  ------------------
  |  Branch (957:13): [True: 24.8k, Folded]
  ------------------
  958|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(e, a, b, c, d, me2, 41);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  959|  24.8k|        if (t > 40)                                                                           \
  ------------------
  |  Branch (959:13): [True: 24.8k, Folded]
  ------------------
  960|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP_BW(a, b, c, d, e, me2, 40);                    \
  ------------------
  |  |  197|  24.8k|    {                                                                  \
  |  |  198|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  199|  24.8k|        e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|  24.8k|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  200|  24.8k|    }
  ------------------
  961|  24.8k|        if (t > 39)                                                                           \
  ------------------
  |  Branch (961:13): [True: 24.8k, Folded]
  ------------------
  962|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 39);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  963|  24.8k|        if (t > 38)                                                                           \
  ------------------
  |  Branch (963:13): [True: 24.8k, Folded]
  ------------------
  964|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 38);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  965|  24.8k|        if (t > 37)                                                                           \
  ------------------
  |  Branch (965:13): [True: 24.8k, Folded]
  ------------------
  966|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 37);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  967|  24.8k|        if (t > 36)                                                                           \
  ------------------
  |  Branch (967:13): [True: 24.8k, Folded]
  ------------------
  968|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 36);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  969|  24.8k|        if (t > 35)                                                                           \
  ------------------
  |  Branch (969:13): [True: 24.8k, Folded]
  ------------------
  970|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 35);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  971|  24.8k|        if (t > 34)                                                                           \
  ------------------
  |  Branch (971:13): [True: 24.8k, Folded]
  ------------------
  972|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 34);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  973|  24.8k|        if (t > 33)                                                                           \
  ------------------
  |  Branch (973:13): [True: 24.8k, Folded]
  ------------------
  974|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 33);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  975|  24.8k|        if (t > 32)                                                                           \
  ------------------
  |  Branch (975:13): [True: 24.8k, Folded]
  ------------------
  976|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 32);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  977|  24.8k|        if (t > 31)                                                                           \
  ------------------
  |  Branch (977:13): [True: 24.8k, Folded]
  ------------------
  978|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 31);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  979|  24.8k|        if (t > 30)                                                                           \
  ------------------
  |  Branch (979:13): [True: 24.8k, Folded]
  ------------------
  980|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 30);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  981|  24.8k|        if (t > 29)                                                                           \
  ------------------
  |  Branch (981:13): [True: 24.8k, Folded]
  ------------------
  982|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 29);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  983|  24.8k|        if (t > 28)                                                                           \
  ------------------
  |  Branch (983:13): [True: 24.8k, Folded]
  ------------------
  984|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 28);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  985|  24.8k|        if (t > 27)                                                                           \
  ------------------
  |  Branch (985:13): [True: 24.8k, Folded]
  ------------------
  986|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 27);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  987|  24.8k|        if (t > 26)                                                                           \
  ------------------
  |  Branch (987:13): [True: 24.8k, Folded]
  ------------------
  988|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 26);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  989|  24.8k|        if (t > 25)                                                                           \
  ------------------
  |  Branch (989:13): [True: 24.8k, Folded]
  ------------------
  990|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 25);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  991|  24.8k|        if (t > 24)                                                                           \
  ------------------
  |  Branch (991:13): [True: 24.8k, Folded]
  ------------------
  992|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(b, c, d, e, a, me2, 24);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  993|  24.8k|        if (t > 23)                                                                           \
  ------------------
  |  Branch (993:13): [True: 24.8k, Folded]
  ------------------
  994|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(c, d, e, a, b, me2, 23);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  995|  24.8k|        if (t > 22)                                                                           \
  ------------------
  |  Branch (995:13): [True: 24.8k, Folded]
  ------------------
  996|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(d, e, a, b, c, me2, 22);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  997|  24.8k|        if (t > 21)                                                                           \
  ------------------
  |  Branch (997:13): [True: 24.8k, Folded]
  ------------------
  998|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(e, a, b, c, d, me2, 21);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
  999|  24.8k|        if (t > 20)                                                                           \
  ------------------
  |  Branch (999:13): [True: 24.8k, Folded]
  ------------------
 1000|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP_BW(a, b, c, d, e, me2, 20);                    \
  ------------------
  |  |  192|  24.8k|    {                                                                  \
  |  |  193|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  194|  24.8k|        e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|  24.8k|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  195|  24.8k|    }
  ------------------
 1001|  24.8k|        if (t > 19)                                                                           \
  ------------------
  |  Branch (1001:13): [True: 24.8k, Folded]
  ------------------
 1002|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 19);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1003|  24.8k|        if (t > 18)                                                                           \
  ------------------
  |  Branch (1003:13): [True: 24.8k, Folded]
  ------------------
 1004|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 18);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1005|  24.8k|        if (t > 17)                                                                           \
  ------------------
  |  Branch (1005:13): [True: 24.8k, Folded]
  ------------------
 1006|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 17);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1007|  24.8k|        if (t > 16)                                                                           \
  ------------------
  |  Branch (1007:13): [True: 24.8k, Folded]
  ------------------
 1008|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 16);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1009|  24.8k|        if (t > 15)                                                                           \
  ------------------
  |  Branch (1009:13): [True: 24.8k, Folded]
  ------------------
 1010|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 15);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1011|  24.8k|        if (t > 14)                                                                           \
  ------------------
  |  Branch (1011:13): [True: 24.8k, Folded]
  ------------------
 1012|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 14);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1013|  24.8k|        if (t > 13)                                                                           \
  ------------------
  |  Branch (1013:13): [True: 24.8k, Folded]
  ------------------
 1014|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 13);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1015|  24.8k|        if (t > 12)                                                                           \
  ------------------
  |  Branch (1015:13): [True: 24.8k, Folded]
  ------------------
 1016|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 12);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1017|  24.8k|        if (t > 11)                                                                           \
  ------------------
  |  Branch (1017:13): [True: 24.8k, Folded]
  ------------------
 1018|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 11);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1019|  24.8k|        if (t > 10)                                                                           \
  ------------------
  |  Branch (1019:13): [True: 24.8k, Folded]
  ------------------
 1020|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 10);                    \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1021|  24.8k|        if (t > 9)                                                                            \
  ------------------
  |  Branch (1021:13): [True: 24.8k, Folded]
  ------------------
 1022|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 9);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1023|  24.8k|        if (t > 8)                                                                            \
  ------------------
  |  Branch (1023:13): [True: 24.8k, Folded]
  ------------------
 1024|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 8);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1025|  24.8k|        if (t > 7)                                                                            \
  ------------------
  |  Branch (1025:13): [True: 24.8k, Folded]
  ------------------
 1026|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 7);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1027|  24.8k|        if (t > 6)                                                                            \
  ------------------
  |  Branch (1027:13): [True: 24.8k, Folded]
  ------------------
 1028|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 6);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1029|  24.8k|        if (t > 5)                                                                            \
  ------------------
  |  Branch (1029:13): [True: 24.8k, Folded]
  ------------------
 1030|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 5);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1031|  24.8k|        if (t > 4)                                                                            \
  ------------------
  |  Branch (1031:13): [True: 24.8k, Folded]
  ------------------
 1032|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(b, c, d, e, a, me2, 4);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1033|  24.8k|        if (t > 3)                                                                            \
  ------------------
  |  Branch (1033:13): [True: 24.8k, Folded]
  ------------------
 1034|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(c, d, e, a, b, me2, 3);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1035|  24.8k|        if (t > 2)                                                                            \
  ------------------
  |  Branch (1035:13): [True: 24.8k, Folded]
  ------------------
 1036|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(d, e, a, b, c, me2, 2);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1037|  24.8k|        if (t > 1)                                                                            \
  ------------------
  |  Branch (1037:13): [True: 24.8k, Folded]
  ------------------
 1038|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(e, a, b, c, d, me2, 1);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1039|  24.8k|        if (t > 0)                                                                            \
  ------------------
  |  Branch (1039:13): [True: 24.8k, Folded]
  ------------------
 1040|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP_BW(a, b, c, d, e, me2, 0);                     \
  ------------------
  |  |  187|  24.8k|    {                                                                  \
  |  |  188|  24.8k|        b = rotate_right(b, 30);                                       \
  |  |  ------------------
  |  |  |  |  134|  24.8k|#define rotate_right(x, n) (((x) >> (n)) | ((x) << (32 - (n))))
  |  |  ------------------
  |  |  189|  24.8k|        e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e -= rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|  24.8k|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  190|  24.8k|    }
  ------------------
 1041|  24.8k|        ihvin[0] = a;                                                                         \
 1042|  24.8k|        ihvin[1] = b;                                                                         \
 1043|  24.8k|        ihvin[2] = c;                                                                         \
 1044|  24.8k|        ihvin[3] = d;                                                                         \
 1045|  24.8k|        ihvin[4] = e;                                                                         \
 1046|  24.8k|        a = state[0];                                                                         \
 1047|  24.8k|        b = state[1];                                                                         \
 1048|  24.8k|        c = state[2];                                                                         \
 1049|  24.8k|        d = state[3];                                                                         \
 1050|  24.8k|        e = state[4];                                                                         \
 1051|  24.8k|        if (t <= 0)                                                                           \
  ------------------
  |  Branch (1051:13): [Folded, False: 24.8k]
  ------------------
 1052|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 0);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1053|  24.8k|        if (t <= 1)                                                                           \
  ------------------
  |  Branch (1053:13): [Folded, False: 24.8k]
  ------------------
 1054|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 1);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1055|  24.8k|        if (t <= 2)                                                                           \
  ------------------
  |  Branch (1055:13): [Folded, False: 24.8k]
  ------------------
 1056|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 2);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1057|  24.8k|        if (t <= 3)                                                                           \
  ------------------
  |  Branch (1057:13): [Folded, False: 24.8k]
  ------------------
 1058|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 3);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1059|  24.8k|        if (t <= 4)                                                                           \
  ------------------
  |  Branch (1059:13): [Folded, False: 24.8k]
  ------------------
 1060|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 4);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1061|  24.8k|        if (t <= 5)                                                                           \
  ------------------
  |  Branch (1061:13): [Folded, False: 24.8k]
  ------------------
 1062|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 5);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1063|  24.8k|        if (t <= 6)                                                                           \
  ------------------
  |  Branch (1063:13): [Folded, False: 24.8k]
  ------------------
 1064|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 6);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1065|  24.8k|        if (t <= 7)                                                                           \
  ------------------
  |  Branch (1065:13): [Folded, False: 24.8k]
  ------------------
 1066|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 7);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1067|  24.8k|        if (t <= 8)                                                                           \
  ------------------
  |  Branch (1067:13): [Folded, False: 24.8k]
  ------------------
 1068|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 8);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1069|  24.8k|        if (t <= 9)                                                                           \
  ------------------
  |  Branch (1069:13): [Folded, False: 24.8k]
  ------------------
 1070|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 9);                        \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1071|  24.8k|        if (t <= 10)                                                                          \
  ------------------
  |  Branch (1071:13): [Folded, False: 24.8k]
  ------------------
 1072|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 10);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1073|  24.8k|        if (t <= 11)                                                                          \
  ------------------
  |  Branch (1073:13): [Folded, False: 24.8k]
  ------------------
 1074|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 11);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1075|  24.8k|        if (t <= 12)                                                                          \
  ------------------
  |  Branch (1075:13): [Folded, False: 24.8k]
  ------------------
 1076|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 12);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1077|  24.8k|        if (t <= 13)                                                                          \
  ------------------
  |  Branch (1077:13): [Folded, False: 24.8k]
  ------------------
 1078|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 13);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1079|  24.8k|        if (t <= 14)                                                                          \
  ------------------
  |  Branch (1079:13): [Folded, False: 24.8k]
  ------------------
 1080|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 14);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1081|  24.8k|        if (t <= 15)                                                                          \
  ------------------
  |  Branch (1081:13): [Folded, False: 24.8k]
  ------------------
 1082|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(a, b, c, d, e, me2, 15);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1083|  24.8k|        if (t <= 16)                                                                          \
  ------------------
  |  Branch (1083:13): [Folded, False: 24.8k]
  ------------------
 1084|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(e, a, b, c, d, me2, 16);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1085|  24.8k|        if (t <= 17)                                                                          \
  ------------------
  |  Branch (1085:13): [Folded, False: 24.8k]
  ------------------
 1086|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(d, e, a, b, c, me2, 17);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1087|  24.8k|        if (t <= 18)                                                                          \
  ------------------
  |  Branch (1087:13): [Folded, False: 24.8k]
  ------------------
 1088|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(c, d, e, a, b, me2, 18);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1089|  24.8k|        if (t <= 19)                                                                          \
  ------------------
  |  Branch (1089:13): [Folded, False: 24.8k]
  ------------------
 1090|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND1_STEP(b, c, d, e, a, me2, 19);                       \
  ------------------
  |  |  166|      0|    {                                                                  \
  |  |  167|      0|        e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f1(b, c, d) + 0x5A827999 + m[t]; \
  |  |  ------------------
  |  |  |  |  160|      0|#define sha1_f1(b, c, d) ((d) ^ ((b) & ((c) ^ (d))))
  |  |  ------------------
  |  |  168|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  169|      0|    }
  ------------------
 1091|  24.8k|        if (t <= 20)                                                                          \
  ------------------
  |  Branch (1091:13): [Folded, False: 24.8k]
  ------------------
 1092|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 20);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1093|  24.8k|        if (t <= 21)                                                                          \
  ------------------
  |  Branch (1093:13): [Folded, False: 24.8k]
  ------------------
 1094|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 21);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1095|  24.8k|        if (t <= 22)                                                                          \
  ------------------
  |  Branch (1095:13): [Folded, False: 24.8k]
  ------------------
 1096|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 22);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1097|  24.8k|        if (t <= 23)                                                                          \
  ------------------
  |  Branch (1097:13): [Folded, False: 24.8k]
  ------------------
 1098|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 23);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1099|  24.8k|        if (t <= 24)                                                                          \
  ------------------
  |  Branch (1099:13): [Folded, False: 24.8k]
  ------------------
 1100|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 24);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1101|  24.8k|        if (t <= 25)                                                                          \
  ------------------
  |  Branch (1101:13): [Folded, False: 24.8k]
  ------------------
 1102|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 25);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1103|  24.8k|        if (t <= 26)                                                                          \
  ------------------
  |  Branch (1103:13): [Folded, False: 24.8k]
  ------------------
 1104|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 26);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1105|  24.8k|        if (t <= 27)                                                                          \
  ------------------
  |  Branch (1105:13): [Folded, False: 24.8k]
  ------------------
 1106|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 27);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1107|  24.8k|        if (t <= 28)                                                                          \
  ------------------
  |  Branch (1107:13): [Folded, False: 24.8k]
  ------------------
 1108|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 28);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1109|  24.8k|        if (t <= 29)                                                                          \
  ------------------
  |  Branch (1109:13): [Folded, False: 24.8k]
  ------------------
 1110|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 29);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1111|  24.8k|        if (t <= 30)                                                                          \
  ------------------
  |  Branch (1111:13): [Folded, False: 24.8k]
  ------------------
 1112|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 30);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1113|  24.8k|        if (t <= 31)                                                                          \
  ------------------
  |  Branch (1113:13): [Folded, False: 24.8k]
  ------------------
 1114|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 31);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1115|  24.8k|        if (t <= 32)                                                                          \
  ------------------
  |  Branch (1115:13): [Folded, False: 24.8k]
  ------------------
 1116|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 32);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1117|  24.8k|        if (t <= 33)                                                                          \
  ------------------
  |  Branch (1117:13): [Folded, False: 24.8k]
  ------------------
 1118|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 33);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1119|  24.8k|        if (t <= 34)                                                                          \
  ------------------
  |  Branch (1119:13): [Folded, False: 24.8k]
  ------------------
 1120|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 34);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1121|  24.8k|        if (t <= 35)                                                                          \
  ------------------
  |  Branch (1121:13): [Folded, False: 24.8k]
  ------------------
 1122|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(a, b, c, d, e, me2, 35);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1123|  24.8k|        if (t <= 36)                                                                          \
  ------------------
  |  Branch (1123:13): [Folded, False: 24.8k]
  ------------------
 1124|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(e, a, b, c, d, me2, 36);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1125|  24.8k|        if (t <= 37)                                                                          \
  ------------------
  |  Branch (1125:13): [Folded, False: 24.8k]
  ------------------
 1126|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(d, e, a, b, c, me2, 37);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1127|  24.8k|        if (t <= 38)                                                                          \
  ------------------
  |  Branch (1127:13): [Folded, False: 24.8k]
  ------------------
 1128|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(c, d, e, a, b, me2, 38);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1129|  24.8k|        if (t <= 39)                                                                          \
  ------------------
  |  Branch (1129:13): [Folded, False: 24.8k]
  ------------------
 1130|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND2_STEP(b, c, d, e, a, me2, 39);                       \
  ------------------
  |  |  171|      0|    {                                                                  \
  |  |  172|      0|        e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f2(b, c, d) + 0x6ED9EBA1 + m[t]; \
  |  |  ------------------
  |  |  |  |  161|      0|#define sha1_f2(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  173|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  174|      0|    }
  ------------------
 1131|  24.8k|        if (t <= 40)                                                                          \
  ------------------
  |  Branch (1131:13): [Folded, False: 24.8k]
  ------------------
 1132|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 40);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1133|  24.8k|        if (t <= 41)                                                                          \
  ------------------
  |  Branch (1133:13): [Folded, False: 24.8k]
  ------------------
 1134|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 41);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1135|  24.8k|        if (t <= 42)                                                                          \
  ------------------
  |  Branch (1135:13): [Folded, False: 24.8k]
  ------------------
 1136|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 42);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1137|  24.8k|        if (t <= 43)                                                                          \
  ------------------
  |  Branch (1137:13): [Folded, False: 24.8k]
  ------------------
 1138|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 43);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1139|  24.8k|        if (t <= 44)                                                                          \
  ------------------
  |  Branch (1139:13): [Folded, False: 24.8k]
  ------------------
 1140|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 44);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1141|  24.8k|        if (t <= 45)                                                                          \
  ------------------
  |  Branch (1141:13): [Folded, False: 24.8k]
  ------------------
 1142|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 45);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1143|  24.8k|        if (t <= 46)                                                                          \
  ------------------
  |  Branch (1143:13): [Folded, False: 24.8k]
  ------------------
 1144|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 46);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1145|  24.8k|        if (t <= 47)                                                                          \
  ------------------
  |  Branch (1145:13): [Folded, False: 24.8k]
  ------------------
 1146|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 47);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1147|  24.8k|        if (t <= 48)                                                                          \
  ------------------
  |  Branch (1147:13): [Folded, False: 24.8k]
  ------------------
 1148|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 48);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1149|  24.8k|        if (t <= 49)                                                                          \
  ------------------
  |  Branch (1149:13): [Folded, False: 24.8k]
  ------------------
 1150|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 49);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1151|  24.8k|        if (t <= 50)                                                                          \
  ------------------
  |  Branch (1151:13): [Folded, False: 24.8k]
  ------------------
 1152|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 50);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1153|  24.8k|        if (t <= 51)                                                                          \
  ------------------
  |  Branch (1153:13): [Folded, False: 24.8k]
  ------------------
 1154|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 51);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1155|  24.8k|        if (t <= 52)                                                                          \
  ------------------
  |  Branch (1155:13): [Folded, False: 24.8k]
  ------------------
 1156|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 52);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1157|  24.8k|        if (t <= 53)                                                                          \
  ------------------
  |  Branch (1157:13): [Folded, False: 24.8k]
  ------------------
 1158|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 53);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1159|  24.8k|        if (t <= 54)                                                                          \
  ------------------
  |  Branch (1159:13): [Folded, False: 24.8k]
  ------------------
 1160|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 54);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1161|  24.8k|        if (t <= 55)                                                                          \
  ------------------
  |  Branch (1161:13): [Folded, False: 24.8k]
  ------------------
 1162|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(a, b, c, d, e, me2, 55);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1163|  24.8k|        if (t <= 56)                                                                          \
  ------------------
  |  Branch (1163:13): [Folded, False: 24.8k]
  ------------------
 1164|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(e, a, b, c, d, me2, 56);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1165|  24.8k|        if (t <= 57)                                                                          \
  ------------------
  |  Branch (1165:13): [Folded, False: 24.8k]
  ------------------
 1166|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(d, e, a, b, c, me2, 57);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1167|  24.8k|        if (t <= 58)                                                                          \
  ------------------
  |  Branch (1167:13): [Folded, False: 24.8k]
  ------------------
 1168|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(c, d, e, a, b, me2, 58);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1169|  24.8k|        if (t <= 59)                                                                          \
  ------------------
  |  Branch (1169:13): [Folded, False: 24.8k]
  ------------------
 1170|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND3_STEP(b, c, d, e, a, me2, 59);                       \
  ------------------
  |  |  176|      0|    {                                                                  \
  |  |  177|      0|        e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f3(b, c, d) + 0x8F1BBCDC + m[t]; \
  |  |  ------------------
  |  |  |  |  162|      0|#define sha1_f3(b, c, d) (((b) & (c)) + ((d) & ((b) ^ (c))))
  |  |  ------------------
  |  |  178|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  179|      0|    }
  ------------------
 1171|  24.8k|        if (t <= 60)                                                                          \
  ------------------
  |  Branch (1171:13): [Folded, False: 24.8k]
  ------------------
 1172|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 60);                       \
  ------------------
  |  |  181|      0|    {                                                                  \
  |  |  182|      0|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|      0|    }
  ------------------
 1173|  24.8k|        if (t <= 61)                                                                          \
  ------------------
  |  Branch (1173:13): [Folded, False: 24.8k]
  ------------------
 1174|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 61);                       \
  ------------------
  |  |  181|      0|    {                                                                  \
  |  |  182|      0|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|      0|    }
  ------------------
 1175|  24.8k|        if (t <= 62)                                                                          \
  ------------------
  |  Branch (1175:13): [Folded, False: 24.8k]
  ------------------
 1176|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 62);                       \
  ------------------
  |  |  181|      0|    {                                                                  \
  |  |  182|      0|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|      0|    }
  ------------------
 1177|  24.8k|        if (t <= 63)                                                                          \
  ------------------
  |  Branch (1177:13): [Folded, False: 24.8k]
  ------------------
 1178|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 63);                       \
  ------------------
  |  |  181|      0|    {                                                                  \
  |  |  182|      0|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|      0|    }
  ------------------
 1179|  24.8k|        if (t <= 64)                                                                          \
  ------------------
  |  Branch (1179:13): [Folded, False: 24.8k]
  ------------------
 1180|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 64);                       \
  ------------------
  |  |  181|      0|    {                                                                  \
  |  |  182|      0|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|      0|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|      0|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|      0|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|      0|    }
  ------------------
 1181|  24.8k|        if (t <= 65)                                                                          \
  ------------------
  |  Branch (1181:13): [True: 24.8k, Folded]
  ------------------
 1182|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 65);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1183|  24.8k|        if (t <= 66)                                                                          \
  ------------------
  |  Branch (1183:13): [True: 24.8k, Folded]
  ------------------
 1184|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 66);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1185|  24.8k|        if (t <= 67)                                                                          \
  ------------------
  |  Branch (1185:13): [True: 24.8k, Folded]
  ------------------
 1186|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 67);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1187|  24.8k|        if (t <= 68)                                                                          \
  ------------------
  |  Branch (1187:13): [True: 24.8k, Folded]
  ------------------
 1188|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 68);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1189|  24.8k|        if (t <= 69)                                                                          \
  ------------------
  |  Branch (1189:13): [True: 24.8k, Folded]
  ------------------
 1190|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 69);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1191|  24.8k|        if (t <= 70)                                                                          \
  ------------------
  |  Branch (1191:13): [True: 24.8k, Folded]
  ------------------
 1192|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 70);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1193|  24.8k|        if (t <= 71)                                                                          \
  ------------------
  |  Branch (1193:13): [True: 24.8k, Folded]
  ------------------
 1194|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 71);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1195|  24.8k|        if (t <= 72)                                                                          \
  ------------------
  |  Branch (1195:13): [True: 24.8k, Folded]
  ------------------
 1196|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 72);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1197|  24.8k|        if (t <= 73)                                                                          \
  ------------------
  |  Branch (1197:13): [True: 24.8k, Folded]
  ------------------
 1198|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 73);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1199|  24.8k|        if (t <= 74)                                                                          \
  ------------------
  |  Branch (1199:13): [True: 24.8k, Folded]
  ------------------
 1200|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 74);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1201|  24.8k|        if (t <= 75)                                                                          \
  ------------------
  |  Branch (1201:13): [True: 24.8k, Folded]
  ------------------
 1202|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(a, b, c, d, e, me2, 75);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1203|  24.8k|        if (t <= 76)                                                                          \
  ------------------
  |  Branch (1203:13): [True: 24.8k, Folded]
  ------------------
 1204|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(e, a, b, c, d, me2, 76);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1205|  24.8k|        if (t <= 77)                                                                          \
  ------------------
  |  Branch (1205:13): [True: 24.8k, Folded]
  ------------------
 1206|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(d, e, a, b, c, me2, 77);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1207|  24.8k|        if (t <= 78)                                                                          \
  ------------------
  |  Branch (1207:13): [True: 24.8k, Folded]
  ------------------
 1208|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(c, d, e, a, b, me2, 78);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1209|  24.8k|        if (t <= 79)                                                                          \
  ------------------
  |  Branch (1209:13): [True: 24.8k, Folded]
  ------------------
 1210|  24.8k|            HASHCLASH_SHA1COMPRESS_ROUND4_STEP(b, c, d, e, a, me2, 79);                       \
  ------------------
  |  |  181|  24.8k|    {                                                                  \
  |  |  182|  24.8k|        e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |                       e += rotate_left(a, 5) + sha1_f4(b, c, d) + 0xCA62C1D6 + m[t]; \
  |  |  ------------------
  |  |  |  |  163|  24.8k|#define sha1_f4(b, c, d) ((b) ^ (c) ^ (d))
  |  |  ------------------
  |  |  183|  24.8k|        b = rotate_left(b, 30);                                        \
  |  |  ------------------
  |  |  |  |  135|  24.8k|#define rotate_left(x, n) (((x) << (n)) | ((x) >> (32 - (n))))
  |  |  ------------------
  |  |  184|  24.8k|    }
  ------------------
 1211|  24.8k|        ihvout[0] = ihvin[0] + a;                                                             \
 1212|  24.8k|        ihvout[1] = ihvin[1] + b;                                                             \
 1213|  24.8k|        ihvout[2] = ihvin[2] + c;                                                             \
 1214|  24.8k|        ihvout[3] = ihvin[3] + d;                                                             \
 1215|  24.8k|        ihvout[4] = ihvin[4] + e;                                                             \
 1216|  24.8k|    }

ubc_check:
  571|  2.38M|{
  572|  2.38M|    uint32_t mask = ~((uint32_t)(0));
  573|  2.38M|    mask &= (((((W[44] ^ W[45]) >> 29) & 1) - 1) |
  574|  2.38M|             ~(DV_I_48_0_bit | DV_I_51_0_bit | DV_I_52_0_bit | DV_II_45_0_bit |
  575|  2.38M|               DV_II_46_0_bit | DV_II_50_0_bit | DV_II_51_0_bit));
  576|  2.38M|    mask &= (((((W[49] ^ W[50]) >> 29) & 1) - 1) |
  577|  2.38M|             ~(DV_I_46_0_bit | DV_II_45_0_bit | DV_II_50_0_bit | DV_II_51_0_bit |
  578|  2.38M|               DV_II_55_0_bit | DV_II_56_0_bit));
  579|  2.38M|    mask &= (((((W[48] ^ W[49]) >> 29) & 1) - 1) |
  580|  2.38M|             ~(DV_I_45_0_bit | DV_I_52_0_bit | DV_II_49_0_bit | DV_II_50_0_bit |
  581|  2.38M|               DV_II_54_0_bit | DV_II_55_0_bit));
  582|  2.38M|    mask &= ((((W[47] ^ (W[50] >> 25)) & (1 << 4)) - (1 << 4)) |
  583|  2.38M|             ~(DV_I_47_0_bit | DV_I_49_0_bit | DV_I_51_0_bit | DV_II_45_0_bit |
  584|  2.38M|               DV_II_51_0_bit | DV_II_56_0_bit));
  585|  2.38M|    mask &= (((((W[47] ^ W[48]) >> 29) & 1) - 1) |
  586|  2.38M|             ~(DV_I_44_0_bit | DV_I_51_0_bit | DV_II_48_0_bit | DV_II_49_0_bit |
  587|  2.38M|               DV_II_53_0_bit | DV_II_54_0_bit));
  588|  2.38M|    mask &= (((((W[46] >> 4) ^ (W[49] >> 29)) & 1) - 1) |
  589|  2.38M|             ~(DV_I_46_0_bit | DV_I_48_0_bit | DV_I_50_0_bit | DV_I_52_0_bit | DV_II_50_0_bit |
  590|  2.38M|               DV_II_55_0_bit));
  591|  2.38M|    mask &= (((((W[46] ^ W[47]) >> 29) & 1) - 1) |
  592|  2.38M|             ~(DV_I_43_0_bit | DV_I_50_0_bit | DV_II_47_0_bit | DV_II_48_0_bit |
  593|  2.38M|               DV_II_52_0_bit | DV_II_53_0_bit));
  594|  2.38M|    mask &= (((((W[45] >> 4) ^ (W[48] >> 29)) & 1) - 1) |
  595|  2.38M|             ~(DV_I_45_0_bit | DV_I_47_0_bit | DV_I_49_0_bit | DV_I_51_0_bit | DV_II_49_0_bit |
  596|  2.38M|               DV_II_54_0_bit));
  597|  2.38M|    mask &= (((((W[45] ^ W[46]) >> 29) & 1) - 1) |
  598|  2.38M|             ~(DV_I_49_0_bit | DV_I_52_0_bit | DV_II_46_0_bit | DV_II_47_0_bit |
  599|  2.38M|               DV_II_51_0_bit | DV_II_52_0_bit));
  600|  2.38M|    mask &= (((((W[44] >> 4) ^ (W[47] >> 29)) & 1) - 1) |
  601|  2.38M|             ~(DV_I_44_0_bit | DV_I_46_0_bit | DV_I_48_0_bit | DV_I_50_0_bit | DV_II_48_0_bit |
  602|  2.38M|               DV_II_53_0_bit));
  603|  2.38M|    mask &= (((((W[43] >> 4) ^ (W[46] >> 29)) & 1) - 1) |
  604|  2.38M|             ~(DV_I_43_0_bit | DV_I_45_0_bit | DV_I_47_0_bit | DV_I_49_0_bit | DV_II_47_0_bit |
  605|  2.38M|               DV_II_52_0_bit));
  606|  2.38M|    mask &= (((((W[43] ^ W[44]) >> 29) & 1) - 1) |
  607|  2.38M|             ~(DV_I_47_0_bit | DV_I_50_0_bit | DV_I_51_0_bit | DV_II_45_0_bit |
  608|  2.38M|               DV_II_49_0_bit | DV_II_50_0_bit));
  609|  2.38M|    mask &= (((((W[42] >> 4) ^ (W[45] >> 29)) & 1) - 1) |
  610|  2.38M|             ~(DV_I_44_0_bit | DV_I_46_0_bit | DV_I_48_0_bit | DV_I_52_0_bit | DV_II_46_0_bit |
  611|  2.38M|               DV_II_51_0_bit));
  612|  2.38M|    mask &= (((((W[41] >> 4) ^ (W[44] >> 29)) & 1) - 1) |
  613|  2.38M|             ~(DV_I_43_0_bit | DV_I_45_0_bit | DV_I_47_0_bit | DV_I_51_0_bit | DV_II_45_0_bit |
  614|  2.38M|               DV_II_50_0_bit));
  615|  2.38M|    mask &= (((((W[40] ^ W[41]) >> 29) & 1) - 1) |
  616|  2.38M|             ~(DV_I_44_0_bit | DV_I_47_0_bit | DV_I_48_0_bit | DV_II_46_0_bit |
  617|  2.38M|               DV_II_47_0_bit | DV_II_56_0_bit));
  618|  2.38M|    mask &=
  619|  2.38M|      (((((W[54] ^ W[55]) >> 29) & 1) - 1) |
  620|  2.38M|       ~(DV_I_51_0_bit | DV_II_47_0_bit | DV_II_50_0_bit | DV_II_55_0_bit | DV_II_56_0_bit));
  621|  2.38M|    mask &=
  622|  2.38M|      (((((W[53] ^ W[54]) >> 29) & 1) - 1) |
  623|  2.38M|       ~(DV_I_50_0_bit | DV_II_46_0_bit | DV_II_49_0_bit | DV_II_54_0_bit | DV_II_55_0_bit));
  624|  2.38M|    mask &=
  625|  2.38M|      (((((W[52] ^ W[53]) >> 29) & 1) - 1) |
  626|  2.38M|       ~(DV_I_49_0_bit | DV_II_45_0_bit | DV_II_48_0_bit | DV_II_53_0_bit | DV_II_54_0_bit));
  627|  2.38M|    mask &=
  628|  2.38M|      ((((W[50] ^ (W[53] >> 25)) & (1 << 4)) - (1 << 4)) |
  629|  2.38M|       ~(DV_I_50_0_bit | DV_I_52_0_bit | DV_II_46_0_bit | DV_II_48_0_bit | DV_II_54_0_bit));
  630|  2.38M|    mask &=
  631|  2.38M|      (((((W[50] ^ W[51]) >> 29) & 1) - 1) |
  632|  2.38M|       ~(DV_I_47_0_bit | DV_II_46_0_bit | DV_II_51_0_bit | DV_II_52_0_bit | DV_II_56_0_bit));
  633|  2.38M|    mask &=
  634|  2.38M|      ((((W[49] ^ (W[52] >> 25)) & (1 << 4)) - (1 << 4)) |
  635|  2.38M|       ~(DV_I_49_0_bit | DV_I_51_0_bit | DV_II_45_0_bit | DV_II_47_0_bit | DV_II_53_0_bit));
  636|  2.38M|    mask &=
  637|  2.38M|      ((((W[48] ^ (W[51] >> 25)) & (1 << 4)) - (1 << 4)) |
  638|  2.38M|       ~(DV_I_48_0_bit | DV_I_50_0_bit | DV_I_52_0_bit | DV_II_46_0_bit | DV_II_52_0_bit));
  639|  2.38M|    mask &=
  640|  2.38M|      (((((W[42] ^ W[43]) >> 29) & 1) - 1) |
  641|  2.38M|       ~(DV_I_46_0_bit | DV_I_49_0_bit | DV_I_50_0_bit | DV_II_48_0_bit | DV_II_49_0_bit));
  642|  2.38M|    mask &=
  643|  2.38M|      (((((W[41] ^ W[42]) >> 29) & 1) - 1) |
  644|  2.38M|       ~(DV_I_45_0_bit | DV_I_48_0_bit | DV_I_49_0_bit | DV_II_47_0_bit | DV_II_48_0_bit));
  645|  2.38M|    mask &=
  646|  2.38M|      (((((W[40] >> 4) ^ (W[43] >> 29)) & 1) - 1) |
  647|  2.38M|       ~(DV_I_44_0_bit | DV_I_46_0_bit | DV_I_50_0_bit | DV_II_49_0_bit | DV_II_56_0_bit));
  648|  2.38M|    mask &=
  649|  2.38M|      (((((W[39] >> 4) ^ (W[42] >> 29)) & 1) - 1) |
  650|  2.38M|       ~(DV_I_43_0_bit | DV_I_45_0_bit | DV_I_49_0_bit | DV_II_48_0_bit | DV_II_55_0_bit));
  651|  2.38M|    if (mask &
  ------------------
  |  Branch (651:9): [True: 299k, False: 2.08M]
  ------------------
  652|  2.38M|        (DV_I_44_0_bit | DV_I_48_0_bit | DV_II_47_0_bit | DV_II_54_0_bit | DV_II_56_0_bit))
  653|   299k|        mask &= (((((W[38] >> 4) ^ (W[41] >> 29)) & 1) - 1) |
  654|   299k|                 ~(DV_I_44_0_bit | DV_I_48_0_bit | DV_II_47_0_bit | DV_II_54_0_bit |
  655|   299k|                   DV_II_56_0_bit));
  656|  2.38M|    mask &=
  657|  2.38M|      (((((W[37] >> 4) ^ (W[40] >> 29)) & 1) - 1) |
  658|  2.38M|       ~(DV_I_43_0_bit | DV_I_47_0_bit | DV_II_46_0_bit | DV_II_53_0_bit | DV_II_55_0_bit));
  659|  2.38M|    if (mask & (DV_I_52_0_bit | DV_II_48_0_bit | DV_II_51_0_bit | DV_II_56_0_bit))
  ------------------
  |  Branch (659:9): [True: 167k, False: 2.22M]
  ------------------
  660|   167k|        mask &= (((((W[55] ^ W[56]) >> 29) & 1) - 1) |
  661|   167k|                 ~(DV_I_52_0_bit | DV_II_48_0_bit | DV_II_51_0_bit | DV_II_56_0_bit));
  662|  2.38M|    if (mask & (DV_I_52_0_bit | DV_II_48_0_bit | DV_II_50_0_bit | DV_II_56_0_bit))
  ------------------
  |  Branch (662:9): [True: 102k, False: 2.28M]
  ------------------
  663|   102k|        mask &= ((((W[52] ^ (W[55] >> 25)) & (1 << 4)) - (1 << 4)) |
  664|   102k|                 ~(DV_I_52_0_bit | DV_II_48_0_bit | DV_II_50_0_bit | DV_II_56_0_bit));
  665|  2.38M|    if (mask & (DV_I_51_0_bit | DV_II_47_0_bit | DV_II_49_0_bit | DV_II_55_0_bit))
  ------------------
  |  Branch (665:9): [True: 132k, False: 2.25M]
  ------------------
  666|   132k|        mask &= ((((W[51] ^ (W[54] >> 25)) & (1 << 4)) - (1 << 4)) |
  667|   132k|                 ~(DV_I_51_0_bit | DV_II_47_0_bit | DV_II_49_0_bit | DV_II_55_0_bit));
  668|  2.38M|    if (mask & (DV_I_48_0_bit | DV_II_47_0_bit | DV_II_52_0_bit | DV_II_53_0_bit))
  ------------------
  |  Branch (668:9): [True: 206k, False: 2.18M]
  ------------------
  669|   206k|        mask &= (((((W[51] ^ W[52]) >> 29) & 1) - 1) |
  670|   206k|                 ~(DV_I_48_0_bit | DV_II_47_0_bit | DV_II_52_0_bit | DV_II_53_0_bit));
  671|  2.38M|    if (mask & (DV_I_46_0_bit | DV_I_49_0_bit | DV_II_45_0_bit | DV_II_48_0_bit))
  ------------------
  |  Branch (671:9): [True: 145k, False: 2.24M]
  ------------------
  672|   145k|        mask &= (((((W[36] >> 4) ^ (W[40] >> 29)) & 1) - 1) |
  673|   145k|                 ~(DV_I_46_0_bit | DV_I_49_0_bit | DV_II_45_0_bit | DV_II_48_0_bit));
  674|  2.38M|    if (mask & (DV_I_52_0_bit | DV_II_48_0_bit | DV_II_49_0_bit))
  ------------------
  |  Branch (674:9): [True: 74.3k, False: 2.31M]
  ------------------
  675|  74.3k|        mask &= ((0 - (((W[53] ^ W[56]) >> 29) & 1)) |
  676|  74.3k|                 ~(DV_I_52_0_bit | DV_II_48_0_bit | DV_II_49_0_bit));
  677|  2.38M|    if (mask & (DV_I_50_0_bit | DV_II_46_0_bit | DV_II_47_0_bit))
  ------------------
  |  Branch (677:9): [True: 74.3k, False: 2.31M]
  ------------------
  678|  74.3k|        mask &= ((0 - (((W[51] ^ W[54]) >> 29) & 1)) |
  679|  74.3k|                 ~(DV_I_50_0_bit | DV_II_46_0_bit | DV_II_47_0_bit));
  680|  2.38M|    if (mask & (DV_I_49_0_bit | DV_I_51_0_bit | DV_II_45_0_bit))
  ------------------
  |  Branch (680:9): [True: 84.3k, False: 2.30M]
  ------------------
  681|  84.3k|        mask &= ((0 - (((W[50] ^ W[52]) >> 29) & 1)) |
  682|  84.3k|                 ~(DV_I_49_0_bit | DV_I_51_0_bit | DV_II_45_0_bit));
  683|  2.38M|    if (mask & (DV_I_48_0_bit | DV_I_50_0_bit | DV_I_52_0_bit))
  ------------------
  |  Branch (683:9): [True: 62.2k, False: 2.32M]
  ------------------
  684|  62.2k|        mask &= ((0 - (((W[49] ^ W[51]) >> 29) & 1)) |
  685|  62.2k|                 ~(DV_I_48_0_bit | DV_I_50_0_bit | DV_I_52_0_bit));
  686|  2.38M|    if (mask & (DV_I_47_0_bit | DV_I_49_0_bit | DV_I_51_0_bit))
  ------------------
  |  Branch (686:9): [True: 72.8k, False: 2.31M]
  ------------------
  687|  72.8k|        mask &= ((0 - (((W[48] ^ W[50]) >> 29) & 1)) |
  688|  72.8k|                 ~(DV_I_47_0_bit | DV_I_49_0_bit | DV_I_51_0_bit));
  689|  2.38M|    if (mask & (DV_I_46_0_bit | DV_I_48_0_bit | DV_I_50_0_bit))
  ------------------
  |  Branch (689:9): [True: 77.7k, False: 2.31M]
  ------------------
  690|  77.7k|        mask &= ((0 - (((W[47] ^ W[49]) >> 29) & 1)) |
  691|  77.7k|                 ~(DV_I_46_0_bit | DV_I_48_0_bit | DV_I_50_0_bit));
  692|  2.38M|    if (mask & (DV_I_45_0_bit | DV_I_47_0_bit | DV_I_49_0_bit))
  ------------------
  |  Branch (692:9): [True: 97.2k, False: 2.29M]
  ------------------
  693|  97.2k|        mask &= ((0 - (((W[46] ^ W[48]) >> 29) & 1)) |
  694|  97.2k|                 ~(DV_I_45_0_bit | DV_I_47_0_bit | DV_I_49_0_bit));
  695|  2.38M|    mask &= ((((W[45] ^ W[47]) & (1 << 6)) - (1 << 6)) |
  696|  2.38M|             ~(DV_I_47_2_bit | DV_I_49_2_bit | DV_I_51_2_bit));
  697|  2.38M|    if (mask & (DV_I_44_0_bit | DV_I_46_0_bit | DV_I_48_0_bit))
  ------------------
  |  Branch (697:9): [True: 121k, False: 2.26M]
  ------------------
  698|   121k|        mask &= ((0 - (((W[45] ^ W[47]) >> 29) & 1)) |
  699|   121k|                 ~(DV_I_44_0_bit | DV_I_46_0_bit | DV_I_48_0_bit));
  700|  2.38M|    mask &=
  701|  2.38M|      (((((W[44] ^ W[46]) >> 6) & 1) - 1) | ~(DV_I_46_2_bit | DV_I_48_2_bit | DV_I_50_2_bit));
  702|  2.38M|    if (mask & (DV_I_43_0_bit | DV_I_45_0_bit | DV_I_47_0_bit))
  ------------------
  |  Branch (702:9): [True: 139k, False: 2.25M]
  ------------------
  703|   139k|        mask &= ((0 - (((W[44] ^ W[46]) >> 29) & 1)) |
  704|   139k|                 ~(DV_I_43_0_bit | DV_I_45_0_bit | DV_I_47_0_bit));
  705|  2.38M|    mask &= ((0 - ((W[41] ^ (W[42] >> 5)) & (1 << 1))) |
  706|  2.38M|             ~(DV_I_48_2_bit | DV_II_46_2_bit | DV_II_51_2_bit));
  707|  2.38M|    mask &= ((0 - ((W[40] ^ (W[41] >> 5)) & (1 << 1))) |
  708|  2.38M|             ~(DV_I_47_2_bit | DV_I_51_2_bit | DV_II_50_2_bit));
  709|  2.38M|    if (mask & (DV_I_44_0_bit | DV_I_46_0_bit | DV_II_56_0_bit))
  ------------------
  |  Branch (709:9): [True: 90.0k, False: 2.29M]
  ------------------
  710|  90.0k|        mask &= ((0 - (((W[40] ^ W[42]) >> 4) & 1)) |
  711|  90.0k|                 ~(DV_I_44_0_bit | DV_I_46_0_bit | DV_II_56_0_bit));
  712|  2.38M|    mask &= ((0 - ((W[39] ^ (W[40] >> 5)) & (1 << 1))) |
  713|  2.38M|             ~(DV_I_46_2_bit | DV_I_50_2_bit | DV_II_49_2_bit));
  714|  2.38M|    if (mask & (DV_I_43_0_bit | DV_I_45_0_bit | DV_II_55_0_bit))
  ------------------
  |  Branch (714:9): [True: 111k, False: 2.27M]
  ------------------
  715|   111k|        mask &= ((0 - (((W[39] ^ W[41]) >> 4) & 1)) |
  716|   111k|                 ~(DV_I_43_0_bit | DV_I_45_0_bit | DV_II_55_0_bit));
  717|  2.38M|    if (mask & (DV_I_44_0_bit | DV_II_54_0_bit | DV_II_56_0_bit))
  ------------------
  |  Branch (717:9): [True: 111k, False: 2.27M]
  ------------------
  718|   111k|        mask &= ((0 - (((W[38] ^ W[40]) >> 4) & 1)) |
  719|   111k|                 ~(DV_I_44_0_bit | DV_II_54_0_bit | DV_II_56_0_bit));
  720|  2.38M|    if (mask & (DV_I_43_0_bit | DV_II_53_0_bit | DV_II_55_0_bit))
  ------------------
  |  Branch (720:9): [True: 105k, False: 2.28M]
  ------------------
  721|   105k|        mask &= ((0 - (((W[37] ^ W[39]) >> 4) & 1)) |
  722|   105k|                 ~(DV_I_43_0_bit | DV_II_53_0_bit | DV_II_55_0_bit));
  723|  2.38M|    mask &= ((0 - ((W[36] ^ (W[37] >> 5)) & (1 << 1))) |
  724|  2.38M|             ~(DV_I_47_2_bit | DV_I_50_2_bit | DV_II_46_2_bit));
  725|  2.38M|    if (mask & (DV_I_45_0_bit | DV_I_48_0_bit | DV_II_47_0_bit))
  ------------------
  |  Branch (725:9): [True: 7.61k, False: 2.38M]
  ------------------
  726|  7.61k|        mask &= (((((W[35] >> 4) ^ (W[39] >> 29)) & 1) - 1) |
  727|  7.61k|                 ~(DV_I_45_0_bit | DV_I_48_0_bit | DV_II_47_0_bit));
  728|  2.38M|    if (mask & (DV_I_48_0_bit | DV_II_48_0_bit))
  ------------------
  |  Branch (728:9): [True: 1.41k, False: 2.38M]
  ------------------
  729|  1.41k|        mask &=
  730|  1.41k|          ((0 - ((W[63] ^ (W[64] >> 5)) & (1 << 0))) | ~(DV_I_48_0_bit | DV_II_48_0_bit));
  731|  2.38M|    if (mask & (DV_I_45_0_bit | DV_II_45_0_bit))
  ------------------
  |  Branch (731:9): [True: 9.54k, False: 2.38M]
  ------------------
  732|  9.54k|        mask &=
  733|  9.54k|          ((0 - ((W[63] ^ (W[64] >> 5)) & (1 << 1))) | ~(DV_I_45_0_bit | DV_II_45_0_bit));
  734|  2.38M|    if (mask & (DV_I_47_0_bit | DV_II_47_0_bit))
  ------------------
  |  Branch (734:9): [True: 1.90k, False: 2.38M]
  ------------------
  735|  1.90k|        mask &=
  736|  1.90k|          ((0 - ((W[62] ^ (W[63] >> 5)) & (1 << 0))) | ~(DV_I_47_0_bit | DV_II_47_0_bit));
  737|  2.38M|    if (mask & (DV_I_46_0_bit | DV_II_46_0_bit))
  ------------------
  |  Branch (737:9): [True: 4.96k, False: 2.38M]
  ------------------
  738|  4.96k|        mask &=
  739|  4.96k|          ((0 - ((W[61] ^ (W[62] >> 5)) & (1 << 0))) | ~(DV_I_46_0_bit | DV_II_46_0_bit));
  740|  2.38M|    mask &= ((0 - ((W[61] ^ (W[62] >> 5)) & (1 << 2))) | ~(DV_I_46_2_bit | DV_II_46_2_bit));
  741|  2.38M|    if (mask & (DV_I_45_0_bit | DV_II_45_0_bit))
  ------------------
  |  Branch (741:9): [True: 5.40k, False: 2.38M]
  ------------------
  742|  5.40k|        mask &=
  743|  5.40k|          ((0 - ((W[60] ^ (W[61] >> 5)) & (1 << 0))) | ~(DV_I_45_0_bit | DV_II_45_0_bit));
  744|  2.38M|    if (mask & (DV_II_51_0_bit | DV_II_54_0_bit))
  ------------------
  |  Branch (744:9): [True: 99.3k, False: 2.29M]
  ------------------
  745|  99.3k|        mask &= (((((W[58] ^ W[59]) >> 29) & 1) - 1) | ~(DV_II_51_0_bit | DV_II_54_0_bit));
  746|  2.38M|    if (mask & (DV_II_50_0_bit | DV_II_53_0_bit))
  ------------------
  |  Branch (746:9): [True: 76.7k, False: 2.31M]
  ------------------
  747|  76.7k|        mask &= (((((W[57] ^ W[58]) >> 29) & 1) - 1) | ~(DV_II_50_0_bit | DV_II_53_0_bit));
  748|  2.38M|    if (mask & (DV_II_52_0_bit | DV_II_54_0_bit))
  ------------------
  |  Branch (748:9): [True: 104k, False: 2.28M]
  ------------------
  749|   104k|        mask &= ((((W[56] ^ (W[59] >> 25)) & (1 << 4)) - (1 << 4)) |
  750|   104k|                 ~(DV_II_52_0_bit | DV_II_54_0_bit));
  751|  2.38M|    if (mask & (DV_II_51_0_bit | DV_II_52_0_bit))
  ------------------
  |  Branch (751:9): [True: 92.9k, False: 2.29M]
  ------------------
  752|  92.9k|        mask &= ((0 - (((W[56] ^ W[59]) >> 29) & 1)) | ~(DV_II_51_0_bit | DV_II_52_0_bit));
  753|  2.38M|    if (mask & (DV_II_49_0_bit | DV_II_52_0_bit))
  ------------------
  |  Branch (753:9): [True: 18.4k, False: 2.37M]
  ------------------
  754|  18.4k|        mask &= (((((W[56] ^ W[57]) >> 29) & 1) - 1) | ~(DV_II_49_0_bit | DV_II_52_0_bit));
  755|  2.38M|    if (mask & (DV_II_51_0_bit | DV_II_53_0_bit))
  ------------------
  |  Branch (755:9): [True: 13.4k, False: 2.37M]
  ------------------
  756|  13.4k|        mask &= ((((W[55] ^ (W[58] >> 25)) & (1 << 4)) - (1 << 4)) |
  757|  13.4k|                 ~(DV_II_51_0_bit | DV_II_53_0_bit));
  758|  2.38M|    if (mask & (DV_II_50_0_bit | DV_II_52_0_bit))
  ------------------
  |  Branch (758:9): [True: 71.6k, False: 2.31M]
  ------------------
  759|  71.6k|        mask &= ((((W[54] ^ (W[57] >> 25)) & (1 << 4)) - (1 << 4)) |
  760|  71.6k|                 ~(DV_II_50_0_bit | DV_II_52_0_bit));
  761|  2.38M|    if (mask & (DV_II_49_0_bit | DV_II_51_0_bit))
  ------------------
  |  Branch (761:9): [True: 10.5k, False: 2.37M]
  ------------------
  762|  10.5k|        mask &= ((((W[53] ^ (W[56] >> 25)) & (1 << 4)) - (1 << 4)) |
  763|  10.5k|                 ~(DV_II_49_0_bit | DV_II_51_0_bit));
  764|  2.38M|    mask &=
  765|  2.38M|      ((((W[51] ^ (W[50] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_I_50_2_bit | DV_II_46_2_bit));
  766|  2.38M|    mask &= ((((W[48] ^ W[50]) & (1 << 6)) - (1 << 6)) | ~(DV_I_50_2_bit | DV_II_46_2_bit));
  767|  2.38M|    if (mask & (DV_I_51_0_bit | DV_I_52_0_bit))
  ------------------
  |  Branch (767:9): [True: 3.00k, False: 2.38M]
  ------------------
  768|  3.00k|        mask &= ((0 - (((W[48] ^ W[55]) >> 29) & 1)) | ~(DV_I_51_0_bit | DV_I_52_0_bit));
  769|  2.38M|    mask &= ((((W[47] ^ W[49]) & (1 << 6)) - (1 << 6)) | ~(DV_I_49_2_bit | DV_I_51_2_bit));
  770|  2.38M|    mask &=
  771|  2.38M|      ((((W[48] ^ (W[47] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_I_47_2_bit | DV_II_51_2_bit));
  772|  2.38M|    mask &= ((((W[46] ^ W[48]) & (1 << 6)) - (1 << 6)) | ~(DV_I_48_2_bit | DV_I_50_2_bit));
  773|  2.38M|    mask &=
  774|  2.38M|      ((((W[47] ^ (W[46] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_I_46_2_bit | DV_II_50_2_bit));
  775|  2.38M|    mask &= ((0 - ((W[44] ^ (W[45] >> 5)) & (1 << 1))) | ~(DV_I_51_2_bit | DV_II_49_2_bit));
  776|  2.38M|    mask &= ((((W[43] ^ W[45]) & (1 << 6)) - (1 << 6)) | ~(DV_I_47_2_bit | DV_I_49_2_bit));
  777|  2.38M|    mask &= (((((W[42] ^ W[44]) >> 6) & 1) - 1) | ~(DV_I_46_2_bit | DV_I_48_2_bit));
  778|  2.38M|    mask &=
  779|  2.38M|      ((((W[43] ^ (W[42] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_II_46_2_bit | DV_II_51_2_bit));
  780|  2.38M|    mask &=
  781|  2.38M|      ((((W[42] ^ (W[41] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_I_51_2_bit | DV_II_50_2_bit));
  782|  2.38M|    mask &=
  783|  2.38M|      ((((W[41] ^ (W[40] >> 5)) & (1 << 1)) - (1 << 1)) | ~(DV_I_50_2_bit | DV_II_49_2_bit));
  784|  2.38M|    if (mask & (DV_I_52_0_bit | DV_II_51_0_bit))
  ------------------
  |  Branch (784:9): [True: 2.72k, False: 2.38M]
  ------------------
  785|  2.72k|        mask &= ((((W[39] ^ (W[43] >> 25)) & (1 << 4)) - (1 << 4)) |
  786|  2.72k|                 ~(DV_I_52_0_bit | DV_II_51_0_bit));
  787|  2.38M|    if (mask & (DV_I_51_0_bit | DV_II_50_0_bit))
  ------------------
  |  Branch (787:9): [True: 62.2k, False: 2.32M]
  ------------------
  788|  62.2k|        mask &= ((((W[38] ^ (W[42] >> 25)) & (1 << 4)) - (1 << 4)) |
  789|  62.2k|                 ~(DV_I_51_0_bit | DV_II_50_0_bit));
  790|  2.38M|    if (mask & (DV_I_48_2_bit | DV_I_51_2_bit))
  ------------------
  |  Branch (790:9): [True: 198k, False: 2.19M]
  ------------------
  791|   198k|        mask &= ((0 - ((W[37] ^ (W[38] >> 5)) & (1 << 1))) | ~(DV_I_48_2_bit | DV_I_51_2_bit));
  792|  2.38M|    if (mask & (DV_I_50_0_bit | DV_II_49_0_bit))
  ------------------
  |  Branch (792:9): [True: 4.55k, False: 2.38M]
  ------------------
  793|  4.55k|        mask &= ((((W[37] ^ (W[41] >> 25)) & (1 << 4)) - (1 << 4)) |
  794|  4.55k|                 ~(DV_I_50_0_bit | DV_II_49_0_bit));
  795|  2.38M|    if (mask & (DV_II_52_0_bit | DV_II_54_0_bit))
  ------------------
  |  Branch (795:9): [True: 12.5k, False: 2.37M]
  ------------------
  796|  12.5k|        mask &= ((0 - ((W[36] ^ W[38]) & (1 << 4))) | ~(DV_II_52_0_bit | DV_II_54_0_bit));
  797|  2.38M|    mask &= ((0 - ((W[35] ^ (W[36] >> 5)) & (1 << 1))) | ~(DV_I_46_2_bit | DV_I_49_2_bit));
  798|  2.38M|    if (mask & (DV_I_51_0_bit | DV_II_47_0_bit))
  ------------------
  |  Branch (798:9): [True: 1.09k, False: 2.38M]
  ------------------
  799|  1.09k|        mask &= ((((W[35] ^ (W[39] >> 25)) & (1 << 3)) - (1 << 3)) |
  800|  1.09k|                 ~(DV_I_51_0_bit | DV_II_47_0_bit));
  801|  2.38M|    if (mask) {
  ------------------
  |  Branch (801:9): [True: 1.06M, False: 1.32M]
  ------------------
  802|  1.06M|        if (mask & DV_I_43_0_bit)
  ------------------
  |  Branch (802:13): [True: 6.96k, False: 1.06M]
  ------------------
  803|  6.96k|            if (!((W[61] ^ (W[62] >> 5)) & (1 << 1)) ||
  ------------------
  |  Branch (803:17): [True: 3.18k, False: 3.78k]
  ------------------
  804|  3.78k|                !(!((W[59] ^ (W[63] >> 25)) & (1 << 5))) ||
  ------------------
  |  Branch (804:17): [True: 1.90k, False: 1.87k]
  ------------------
  805|  1.87k|                !((W[58] ^ (W[63] >> 30)) & (1 << 0)))
  ------------------
  |  Branch (805:17): [True: 858, False: 1.01k]
  ------------------
  806|  5.94k|                mask &= ~DV_I_43_0_bit;
  807|  1.06M|        if (mask & DV_I_44_0_bit)
  ------------------
  |  Branch (807:13): [True: 5.14k, False: 1.06M]
  ------------------
  808|  5.14k|            if (!((W[62] ^ (W[63] >> 5)) & (1 << 1)) ||
  ------------------
  |  Branch (808:17): [True: 2.26k, False: 2.88k]
  ------------------
  809|  2.88k|                !(!((W[60] ^ (W[64] >> 25)) & (1 << 5))) ||
  ------------------
  |  Branch (809:17): [True: 1.34k, False: 1.54k]
  ------------------
  810|  1.54k|                !((W[59] ^ (W[64] >> 30)) & (1 << 0)))
  ------------------
  |  Branch (810:17): [True: 961, False: 582]
  ------------------
  811|  4.56k|                mask &= ~DV_I_44_0_bit;
  812|  1.06M|        if (mask & DV_I_46_2_bit)
  ------------------
  |  Branch (812:13): [True: 44.3k, False: 1.02M]
  ------------------
  813|  44.3k|            mask &= ((~((W[40] ^ W[42]) >> 2)) | ~DV_I_46_2_bit);
  814|  1.06M|        if (mask & DV_I_47_2_bit)
  ------------------
  |  Branch (814:13): [True: 81.9k, False: 985k]
  ------------------
  815|  81.9k|            if (!((W[62] ^ (W[63] >> 5)) & (1 << 2)) || !(!((W[41] ^ W[43]) & (1 << 6))))
  ------------------
  |  Branch (815:17): [True: 36.7k, False: 45.2k]
  |  Branch (815:57): [True: 17.7k, False: 27.4k]
  ------------------
  816|  54.5k|                mask &= ~DV_I_47_2_bit;
  817|  1.06M|        if (mask & DV_I_48_2_bit)
  ------------------
  |  Branch (817:13): [True: 65.3k, False: 1.00M]
  ------------------
  818|  65.3k|            if (!((W[63] ^ (W[64] >> 5)) & (1 << 2)) ||
  ------------------
  |  Branch (818:17): [True: 31.3k, False: 33.9k]
  ------------------
  819|  33.9k|                !(!((W[48] ^ (W[49] << 5)) & (1 << 6))))
  ------------------
  |  Branch (819:17): [True: 15.9k, False: 17.9k]
  ------------------
  820|  47.3k|                mask &= ~DV_I_48_2_bit;
  821|  1.06M|        if (mask & DV_I_49_2_bit)
  ------------------
  |  Branch (821:13): [True: 146k, False: 920k]
  ------------------
  822|   146k|            if (!(!((W[49] ^ (W[50] << 5)) & (1 << 6))) || !((W[42] ^ W[50]) & (1 << 1)) ||
  ------------------
  |  Branch (822:17): [True: 73.5k, False: 73.0k]
  |  Branch (822:60): [True: 34.2k, False: 38.7k]
  ------------------
  823|  38.7k|                !(!((W[39] ^ (W[40] << 5)) & (1 << 6))) || !((W[38] ^ W[40]) & (1 << 1)))
  ------------------
  |  Branch (823:17): [True: 12.4k, False: 26.3k]
  |  Branch (823:60): [True: 7.48k, False: 18.8k]
  ------------------
  824|   127k|                mask &= ~DV_I_49_2_bit;
  825|  1.06M|        if (mask & DV_I_50_0_bit)
  ------------------
  |  Branch (825:13): [True: 963, False: 1.06M]
  ------------------
  826|    963|            mask &= ((((W[36] ^ W[37]) << 7)) | ~DV_I_50_0_bit);
  827|  1.06M|        if (mask & DV_I_50_2_bit)
  ------------------
  |  Branch (827:13): [True: 17.6k, False: 1.04M]
  ------------------
  828|  17.6k|            mask &= ((((W[43] ^ W[51]) << 11)) | ~DV_I_50_2_bit);
  829|  1.06M|        if (mask & DV_I_51_0_bit)
  ------------------
  |  Branch (829:13): [True: 363, False: 1.06M]
  ------------------
  830|    363|            mask &= ((((W[37] ^ W[38]) << 9)) | ~DV_I_51_0_bit);
  831|  1.06M|        if (mask & DV_I_51_2_bit)
  ------------------
  |  Branch (831:13): [True: 47.7k, False: 1.01M]
  ------------------
  832|  47.7k|            if (!(!((W[51] ^ (W[52] << 5)) & (1 << 6))) || !(!((W[49] ^ W[51]) & (1 << 6))) ||
  ------------------
  |  Branch (832:17): [True: 15.5k, False: 32.2k]
  |  Branch (832:60): [True: 21.7k, False: 10.4k]
  ------------------
  833|  10.4k|                !(!((W[37] ^ (W[37] >> 5)) & (1 << 1))) ||
  ------------------
  |  Branch (833:17): [True: 3.43k, False: 7.04k]
  ------------------
  834|  7.04k|                !(!((W[35] ^ (W[39] >> 25)) & (1 << 5))))
  ------------------
  |  Branch (834:17): [True: 4.06k, False: 2.98k]
  ------------------
  835|  44.8k|                mask &= ~DV_I_51_2_bit;
  836|  1.06M|        if (mask & DV_I_52_0_bit)
  ------------------
  |  Branch (836:13): [True: 424, False: 1.06M]
  ------------------
  837|    424|            mask &= ((((W[38] ^ W[39]) << 11)) | ~DV_I_52_0_bit);
  838|  1.06M|        if (mask & DV_II_46_2_bit)
  ------------------
  |  Branch (838:13): [True: 36.5k, False: 1.03M]
  ------------------
  839|  36.5k|            mask &= ((((W[47] ^ W[51]) << 17)) | ~DV_II_46_2_bit);
  840|  1.06M|        if (mask & DV_II_48_0_bit)
  ------------------
  |  Branch (840:13): [True: 1.14k, False: 1.06M]
  ------------------
  841|  1.14k|            if (!(!((W[36] ^ (W[40] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (841:17): [True: 550, False: 593]
  ------------------
  842|    593|                !((W[35] ^ (W[40] << 2)) & (1 << 30)))
  ------------------
  |  Branch (842:17): [True: 337, False: 256]
  ------------------
  843|    887|                mask &= ~DV_II_48_0_bit;
  844|  1.06M|        if (mask & DV_II_49_0_bit)
  ------------------
  |  Branch (844:13): [True: 1.59k, False: 1.06M]
  ------------------
  845|  1.59k|            if (!(!((W[37] ^ (W[41] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (845:17): [True: 486, False: 1.11k]
  ------------------
  846|  1.11k|                !((W[36] ^ (W[41] << 2)) & (1 << 30)))
  ------------------
  |  Branch (846:17): [True: 743, False: 369]
  ------------------
  847|  1.22k|                mask &= ~DV_II_49_0_bit;
  848|  1.06M|        if (mask & DV_II_49_2_bit)
  ------------------
  |  Branch (848:13): [True: 300k, False: 766k]
  ------------------
  849|   300k|            if (!(!((W[53] ^ (W[54] << 5)) & (1 << 6))) || !(!((W[51] ^ W[53]) & (1 << 6))) ||
  ------------------
  |  Branch (849:17): [True: 159k, False: 141k]
  |  Branch (849:60): [True: 62.4k, False: 78.8k]
  ------------------
  850|  78.8k|                !((W[50] ^ W[54]) & (1 << 1)) || !(!((W[45] ^ (W[46] << 5)) & (1 << 6))) ||
  ------------------
  |  Branch (850:17): [True: 44.7k, False: 34.1k]
  |  Branch (850:50): [True: 15.8k, False: 18.2k]
  ------------------
  851|  18.2k|                !(!((W[37] ^ (W[41] >> 25)) & (1 << 5))) ||
  ------------------
  |  Branch (851:17): [True: 9.13k, False: 9.08k]
  ------------------
  852|  9.08k|                !((W[36] ^ (W[41] >> 30)) & (1 << 0)))
  ------------------
  |  Branch (852:17): [True: 4.00k, False: 5.08k]
  ------------------
  853|   295k|                mask &= ~DV_II_49_2_bit;
  854|  1.06M|        if (mask & DV_II_50_0_bit)
  ------------------
  |  Branch (854:13): [True: 59.1k, False: 1.00M]
  ------------------
  855|  59.1k|            if (!((W[55] ^ W[58]) & (1 << 29)) || !(!((W[38] ^ (W[42] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (855:17): [True: 56.6k, False: 2.53k]
  |  Branch (855:51): [True: 888, False: 1.64k]
  ------------------
  856|  1.64k|                !((W[37] ^ (W[42] << 2)) & (1 << 30)))
  ------------------
  |  Branch (856:17): [True: 1.31k, False: 332]
  ------------------
  857|  58.8k|                mask &= ~DV_II_50_0_bit;
  858|  1.06M|        if (mask & DV_II_50_2_bit)
  ------------------
  |  Branch (858:13): [True: 297k, False: 769k]
  ------------------
  859|   297k|            if (!(!((W[54] ^ (W[55] << 5)) & (1 << 6))) || !(!((W[52] ^ W[54]) & (1 << 6))) ||
  ------------------
  |  Branch (859:17): [True: 146k, False: 151k]
  |  Branch (859:60): [True: 76.1k, False: 75.1k]
  ------------------
  860|  75.1k|                !((W[51] ^ W[55]) & (1 << 1)) || !((W[45] ^ W[47]) & (1 << 1)) ||
  ------------------
  |  Branch (860:17): [True: 40.4k, False: 34.6k]
  |  Branch (860:50): [True: 15.2k, False: 19.4k]
  ------------------
  861|  19.4k|                !(!((W[38] ^ (W[42] >> 25)) & (1 << 5))) ||
  ------------------
  |  Branch (861:17): [True: 10.7k, False: 8.67k]
  ------------------
  862|  8.67k|                !((W[37] ^ (W[42] >> 30)) & (1 << 0)))
  ------------------
  |  Branch (862:17): [True: 4.15k, False: 4.51k]
  ------------------
  863|   293k|                mask &= ~DV_II_50_2_bit;
  864|  1.06M|        if (mask & DV_II_51_0_bit)
  ------------------
  |  Branch (864:13): [True: 1.24k, False: 1.06M]
  ------------------
  865|  1.24k|            if (!(!((W[39] ^ (W[43] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (865:17): [True: 381, False: 865]
  ------------------
  866|    865|                !((W[38] ^ (W[43] << 2)) & (1 << 30)))
  ------------------
  |  Branch (866:17): [True: 434, False: 431]
  ------------------
  867|    815|                mask &= ~DV_II_51_0_bit;
  868|  1.06M|        if (mask & DV_II_51_2_bit)
  ------------------
  |  Branch (868:13): [True: 264k, False: 802k]
  ------------------
  869|   264k|            if (!(!((W[55] ^ (W[56] << 5)) & (1 << 6))) || !(!((W[53] ^ W[55]) & (1 << 6))) ||
  ------------------
  |  Branch (869:17): [True: 146k, False: 118k]
  |  Branch (869:60): [True: 63.8k, False: 54.6k]
  ------------------
  870|  54.6k|                !((W[52] ^ W[56]) & (1 << 1)) || !((W[46] ^ W[48]) & (1 << 1)) ||
  ------------------
  |  Branch (870:17): [True: 25.4k, False: 29.2k]
  |  Branch (870:50): [True: 14.9k, False: 14.3k]
  ------------------
  871|  14.3k|                !(!((W[39] ^ (W[43] >> 25)) & (1 << 5))) ||
  ------------------
  |  Branch (871:17): [True: 8.20k, False: 6.10k]
  ------------------
  872|  6.10k|                !((W[38] ^ (W[43] >> 30)) & (1 << 0)))
  ------------------
  |  Branch (872:17): [True: 2.58k, False: 3.51k]
  ------------------
  873|   261k|                mask &= ~DV_II_51_2_bit;
  874|  1.06M|        if (mask & DV_II_52_0_bit)
  ------------------
  |  Branch (874:13): [True: 2.70k, False: 1.06M]
  ------------------
  875|  2.70k|            if (!(!((W[59] ^ W[60]) & (1 << 29))) ||
  ------------------
  |  Branch (875:17): [True: 1.36k, False: 1.33k]
  ------------------
  876|  1.33k|                !(!((W[40] ^ (W[44] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (876:17): [True: 365, False: 970]
  ------------------
  877|    970|                !(!((W[40] ^ (W[44] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (877:17): [True: 465, False: 505]
  ------------------
  878|    505|                !((W[39] ^ (W[44] << 2)) & (1 << 30)))
  ------------------
  |  Branch (878:17): [True: 248, False: 257]
  ------------------
  879|  2.44k|                mask &= ~DV_II_52_0_bit;
  880|  1.06M|        if (mask & DV_II_53_0_bit)
  ------------------
  |  Branch (880:13): [True: 2.95k, False: 1.06M]
  ------------------
  881|  2.95k|            if (!((W[58] ^ W[61]) & (1 << 29)) || !(!((W[57] ^ (W[61] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (881:17): [True: 708, False: 2.24k]
  |  Branch (881:51): [True: 857, False: 1.38k]
  ------------------
  882|  1.38k|                !(!((W[41] ^ (W[45] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (882:17): [True: 344, False: 1.04k]
  ------------------
  883|  1.04k|                !(!((W[41] ^ (W[45] >> 25)) & (1 << 4))))
  ------------------
  |  Branch (883:17): [True: 717, False: 325]
  ------------------
  884|  2.62k|                mask &= ~DV_II_53_0_bit;
  885|  1.06M|        if (mask & DV_II_54_0_bit)
  ------------------
  |  Branch (885:13): [True: 6.66k, False: 1.06M]
  ------------------
  886|  6.66k|            if (!(!((W[58] ^ (W[62] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (886:17): [True: 4.92k, False: 1.74k]
  ------------------
  887|  1.74k|                !(!((W[42] ^ (W[46] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (887:17): [True: 1.11k, False: 630]
  ------------------
  888|    630|                !(!((W[42] ^ (W[46] >> 25)) & (1 << 4))))
  ------------------
  |  Branch (888:17): [True: 280, False: 350]
  ------------------
  889|  6.31k|                mask &= ~DV_II_54_0_bit;
  890|  1.06M|        if (mask & DV_II_55_0_bit)
  ------------------
  |  Branch (890:13): [True: 4.61k, False: 1.06M]
  ------------------
  891|  4.61k|            if (!(!((W[59] ^ (W[63] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (891:17): [True: 1.86k, False: 2.74k]
  ------------------
  892|  2.74k|                !(!((W[57] ^ (W[59] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (892:17): [True: 1.72k, False: 1.02k]
  ------------------
  893|  1.02k|                !(!((W[43] ^ (W[47] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (893:17): [True: 417, False: 610]
  ------------------
  894|    610|                !(!((W[43] ^ (W[47] >> 25)) & (1 << 4))))
  ------------------
  |  Branch (894:17): [True: 268, False: 342]
  ------------------
  895|  4.27k|                mask &= ~DV_II_55_0_bit;
  896|  1.06M|        if (mask & DV_II_56_0_bit)
  ------------------
  |  Branch (896:13): [True: 3.93k, False: 1.06M]
  ------------------
  897|  3.93k|            if (!(!((W[60] ^ (W[64] >> 25)) & (1 << 4))) ||
  ------------------
  |  Branch (897:17): [True: 1.75k, False: 2.17k]
  ------------------
  898|  2.17k|                !(!((W[44] ^ (W[48] >> 25)) & (1 << 3))) ||
  ------------------
  |  Branch (898:17): [True: 901, False: 1.27k]
  ------------------
  899|  1.27k|                !(!((W[44] ^ (W[48] >> 25)) & (1 << 4))))
  ------------------
  |  Branch (899:17): [True: 798, False: 480]
  ------------------
  900|  3.45k|                mask &= ~DV_II_56_0_bit;
  901|  1.06M|    }
  902|       |
  903|  2.38M|    dvmask[0] = mask;
  904|  2.38M|}

_Z14signature_initRK13pgp_key_pkt_tRKN3pgp3pkt9SignatureE:
   94|  11.4k|{
   95|  11.4k|    auto hash = rnp::Hash::create(sig.halg);
   96|       |
   97|  11.4k|#if defined(ENABLE_CRYPTO_REFRESH)
   98|  11.4k|    if (key.version == PGP_V6) {
  ------------------
  |  Branch (98:9): [True: 0, False: 11.4k]
  ------------------
   99|      0|        hash->add(sig.salt);
  100|      0|    }
  101|  11.4k|#endif
  102|       |
  103|  11.4k|    if (key.material->alg() == PGP_PKA_SM2) {
  ------------------
  |  Branch (103:9): [True: 0, False: 11.4k]
  ------------------
  104|      0|        auto &sm2 = dynamic_cast<pgp::SM2KeyMaterial &>(*key.material);
  105|      0|        sm2.compute_za(*hash);
  106|      0|    }
  107|  11.4k|    return hash;
  108|  11.4k|}
_Z18signature_validateRKN3pgp3pkt9SignatureERKNS_11KeyMaterialERN3rnp4HashERKNS7_15SecurityContextEPK17pgp_literal_hdr_t:
  156|  11.3k|{
  157|  11.3k|    rnp::SigValidity res;
  158|  11.3k|    if (sig.palg != key.alg()) {
  ------------------
  |  Branch (158:9): [True: 538, False: 10.8k]
  ------------------
  159|    538|        RNP_LOG(
  ------------------
  |  |   84|    538|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    538|    do {                                                                                 \
  |  |  |  |   77|    538|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 538, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    538|            break;                                                                       \
  |  |  |  |   79|    538|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  160|    538|          "Signature and key do not agree on algorithm type: %d vs %d", sig.palg, key.alg());
  161|    538|        res.add_error(RNP_ERROR_SIG_PUB_ALG_MISMATCH);
  162|    538|    }
  163|       |
  164|       |    /* Signature with an unknown critical subpacket must be treated as invalid */
  165|  11.3k|    if (sig.has_unknown_critical()) {
  ------------------
  |  Branch (165:9): [True: 987, False: 10.3k]
  ------------------
  166|    987|        RNP_LOG("Unknown critical subpacket, marking signature as invalid.");
  ------------------
  |  |   84|    987|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    987|    do {                                                                                 \
  |  |  |  |   77|    987|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 987, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    987|            break;                                                                       \
  |  |  |  |   79|    987|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  167|    987|        res.add_error(RNP_ERROR_SIG_UNHANDLED_CRITICAL);
  168|    987|    }
  169|       |
  170|       |    /* Check signature security */
  171|  11.3k|    auto action =
  172|  11.3k|      sig.is_document() ? rnp::SecurityAction::VerifyData : rnp::SecurityAction::VerifyKey;
  ------------------
  |  Branch (172:7): [True: 0, False: 11.3k]
  ------------------
  173|  11.3k|    if (ctx.profile.hash_level(sig.halg, sig.creation(), action) <
  ------------------
  |  Branch (173:9): [True: 203, False: 11.1k]
  ------------------
  174|  11.3k|        rnp::SecurityLevel::Default) {
  175|    203|        RNP_LOG("Insecure hash algorithm %d, marking signature as invalid.", sig.halg);
  ------------------
  |  |   84|    203|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    203|    do {                                                                                 \
  |  |  |  |   77|    203|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 203, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    203|            break;                                                                       \
  |  |  |  |   79|    203|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  176|    203|        res.add_error(RNP_ERROR_SIG_WEAK_HASH);
  177|    203|    }
  178|       |
  179|       |    /* check that hash matches minimum requirements */
  180|  11.3k|    if (!key.sig_hash_allowed(hash.alg())) {
  ------------------
  |  Branch (180:9): [True: 0, False: 11.3k]
  ------------------
  181|      0|        RNP_LOG("The signature's digest size is below the minimum digest size required for "
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  182|      0|                "that key.");
  183|      0|        res.add_error(RNP_ERROR_SIG_HASH_ALG_MISMATCH);
  184|      0|    }
  185|       |
  186|       |    /* Finalize hash */
  187|  11.3k|    auto hval = signature_hash_finish(sig, hash, hdr);
  188|       |    /* compare lbits */
  189|  11.3k|    bool lbits_ok = !memcmp(hval.data(), sig.lbits.data(), sig.lbits.size());
  190|       |
  191|       |    /* validate signature */
  192|       |    /* Signature material parsing was checked during the signature parsing,
  193|       |     * but the signature could also be constructed in-process */
  194|  11.3k|    auto material = sig.parse_material();
  195|  11.3k|    if (!material) {
  ------------------
  |  Branch (195:9): [True: 0, False: 11.3k]
  ------------------
  196|      0|        RNP_LOG("failed to parse signature material.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  197|      0|        res.add_error(RNP_ERROR_BAD_FORMAT);
  198|      0|        return res;
  199|      0|    }
  200|  11.3k|    auto ret = key.verify(ctx, *material, hval);
  201|       |    /* RFC 9580, 5.2.4: v6 signatures with wrong left 16 bits MUST be rejected. For older
  202|       |     * versions behaviour is not defined, and some real-world keys have broken lbits
  203|       |     * (see #2191), so do not fail a cryptographically valid signature because of them. */
  204|  11.3k|    bool lbits_strict = false;
  205|  11.3k|#if defined(ENABLE_CRYPTO_REFRESH)
  206|  11.3k|    lbits_strict = sig.version == PGP_V6;
  207|  11.3k|#endif
  208|  11.3k|    if (!lbits_ok) {
  ------------------
  |  Branch (208:9): [True: 9.63k, False: 1.73k]
  ------------------
  209|  9.63k|        if (ret || lbits_strict) {
  ------------------
  |  Branch (209:13): [True: 9.51k, False: 116]
  |  Branch (209:20): [True: 0, False: 116]
  ------------------
  210|  9.51k|            RNP_LOG("wrong lbits");
  ------------------
  |  |   84|  9.51k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  9.51k|    do {                                                                                 \
  |  |  |  |   77|  9.51k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9.51k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  9.51k|            break;                                                                       \
  |  |  |  |   79|  9.51k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  211|  9.51k|            res.add_error(RNP_ERROR_SIG_LBITS_MISMATCH);
  212|  9.51k|        } else {
  213|    116|            RNP_LOG("Warning: wrong lbits in v%d signature, ignoring.", (int) sig.version);
  ------------------
  |  |   84|    116|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    116|    do {                                                                                 \
  |  |  |  |   77|    116|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 116, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    116|            break;                                                                       \
  |  |  |  |   79|    116|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  214|    116|        }
  215|  9.63k|    }
  216|  11.3k|    if (ret) {
  ------------------
  |  Branch (216:9): [True: 10.9k, False: 444]
  ------------------
  217|  10.9k|        res.add_error(ret);
  218|  10.9k|    }
  219|  11.3k|    return res;
  220|  11.3k|}
signatures.cpp:_ZL21signature_hash_finishRKN3pgp3pkt9SignatureERN3rnp4HashEPK17pgp_literal_hdr_t:
   49|  11.3k|{
   50|  11.3k|    hash.add(sig.hashed_data);
   51|  11.3k|    switch (sig.version) {
   52|  11.3k|    case PGP_V4:
  ------------------
  |  Branch (52:5): [True: 11.3k, False: 24]
  ------------------
   53|  11.3k|#if defined(ENABLE_CRYPTO_REFRESH)
   54|  11.3k|    case PGP_V6:
  ------------------
  |  Branch (54:5): [True: 0, False: 11.3k]
  ------------------
   55|  11.3k|#endif
   56|  11.3k|    {
   57|  11.3k|        uint8_t trailer[6] = {0x00, 0xff, 0x00, 0x00, 0x00, 0x00};
   58|  11.3k|        trailer[0] = sig.version;
   59|  11.3k|        write_uint32(&trailer[2], sig.hashed_data.size());
   60|  11.3k|        hash.add(trailer, 6);
   61|  11.3k|        break;
   62|  11.3k|    }
   63|      2|    case PGP_V5: {
  ------------------
  |  Branch (63:5): [True: 2, False: 11.3k]
  ------------------
   64|      2|        uint64_t hash_len = sig.hashed_data.size();
   65|      2|        if (sig.is_document()) {
  ------------------
  |  Branch (65:13): [True: 0, False: 2]
  ------------------
   66|      0|            uint8_t doc_trailer[6] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
   67|       |            /* This data is not added to the hash_len as per spec */
   68|      0|            if (hdr) {
  ------------------
  |  Branch (68:17): [True: 0, False: 0]
  ------------------
   69|      0|                doc_trailer[0] = hdr->format;
   70|      0|                doc_trailer[1] = hdr->fname_len;
   71|      0|                write_uint32(&doc_trailer[2], hdr->timestamp);
   72|      0|                hash.add(doc_trailer, 2);
   73|      0|                hash.add(hdr->fname, hdr->fname_len);
   74|      0|                hash.add(&doc_trailer[2], 4);
   75|      0|            } else {
   76|      0|                hash.add(doc_trailer, 6);
   77|      0|            }
   78|      0|        }
   79|      2|        uint8_t trailer[10] = {0x05, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
   80|      2|        write_uint64(&trailer[2], hash_len);
   81|      2|        hash.add(trailer, 10);
   82|      2|        break;
   83|  11.3k|    }
   84|     22|    default:
  ------------------
  |  Branch (84:5): [True: 22, False: 11.3k]
  ------------------
   85|     22|        break;
   86|  11.3k|    }
   87|  11.3k|    rnp::secure_bytes res(hash.size());
   88|  11.3k|    hash.finish(res.data());
   89|  11.3k|    return res;
   90|  11.3k|}

_ZN28pgp_sphincsplus_public_key_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE16pgp_pubkey_alg_t:
   66|  1.98k|    : key_encoded_(key_encoded), pk_alg_(alg), is_initialized_(true)
   67|  1.98k|{
   68|  1.98k|}
_ZN29pgp_sphincsplus_private_key_tC2EPKhm16pgp_pubkey_alg_t:
   73|      6|    : key_encoded_(key_encoded, key_encoded + key_encoded_len), pk_alg_(alg),
   74|      6|      is_initialized_(true)
   75|      6|{
   76|      6|}
_Z24sphincsplus_privkey_size16pgp_pubkey_alg_t:
  237|     17|{
  238|     17|    return 2 * sphincsplus_pubkey_size(alg);
  239|     17|}
_Z23sphincsplus_pubkey_size16pgp_pubkey_alg_t:
  243|  2.04k|{
  244|  2.04k|    switch (alg) {
  245|  1.70k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (245:5): [True: 1.70k, False: 342]
  ------------------
  246|  1.70k|        return 32;
  247|    282|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (247:5): [True: 282, False: 1.76k]
  ------------------
  248|    282|        return 32;
  249|     60|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (249:5): [True: 60, False: 1.98k]
  ------------------
  250|     60|        return 64;
  251|      0|    default:
  ------------------
  |  Branch (251:5): [True: 0, False: 2.04k]
  ------------------
  252|      0|        RNP_LOG("invalid SLH-DSA algorithm identifier");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  253|      0|        return 0;
  254|  2.04k|    }
  255|  2.04k|}
_Z26sphincsplus_signature_size16pgp_pubkey_alg_t:
  259|    376|{
  260|    376|    switch (alg) {
  261|    156|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (261:5): [True: 156, False: 220]
  ------------------
  262|    156|        return 17088;
  263|     39|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (263:5): [True: 39, False: 337]
  ------------------
  264|     39|        return 7856;
  265|    181|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (265:5): [True: 181, False: 195]
  ------------------
  266|    181|        return 29792;
  267|      0|    default:
  ------------------
  |  Branch (267:5): [True: 0, False: 376]
  ------------------
  268|      0|        RNP_LOG("invalid SLH-DSA algorithm identifier");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  269|      0|        return 0;
  270|    376|    }
  271|    376|}

_ZN29pgp_sphincsplus_private_key_t12secure_clearEv:
   68|    946|    {
   69|    946|        key_encoded_ = rnp::SecureBytes();
   70|    946|        is_initialized_ = false;
   71|    946|    }
_ZNK28pgp_sphincsplus_public_key_t11get_encodedEv:
  113|  1.24k|    {
  114|  1.24k|        return key_encoded_;
  115|  1.24k|    };
_ZN28pgp_sphincsplus_public_key_tC2Ev:
   91|  2.75k|    pgp_sphincsplus_public_key_t() = default;
_ZN29pgp_sphincsplus_private_key_tC2Ev:
   52|  2.75k|    pgp_sphincsplus_private_key_t() = default;

_Z20pgp_cipher_cfb_startP11pgp_crypt_t14pgp_symm_alg_tPKhS3_:
  144|  12.3k|{
  145|  12.3k|    memset(crypt, 0x0, sizeof(*crypt));
  146|       |
  147|  12.3k|    const char *cipher_name = pgp_sa_to_botan_string(alg);
  148|  12.3k|    if (!cipher_name) {
  ------------------
  |  Branch (148:9): [True: 0, False: 12.3k]
  ------------------
  149|      0|        return false;
  150|      0|    }
  151|       |
  152|  12.3k|    crypt->alg = alg;
  153|  12.3k|    crypt->blocksize = pgp_block_size(alg);
  154|       |
  155|       |    // This shouldn't happen if pgp_sa_to_botan_string returned a ptr
  156|  12.3k|    if (botan_block_cipher_init(&(crypt->cfb.obj), cipher_name) != 0) {
  ------------------
  |  Branch (156:9): [True: 0, False: 12.3k]
  ------------------
  157|      0|        RNP_LOG("Block cipher '%s' not available", cipher_name);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  158|      0|        return false;
  159|      0|    }
  160|       |
  161|  12.3k|    const size_t keysize = pgp_key_size(alg);
  162|       |
  163|  12.3k|    if (botan_block_cipher_set_key(crypt->cfb.obj, key, keysize) != 0) {
  ------------------
  |  Branch (163:9): [True: 0, False: 12.3k]
  ------------------
  164|      0|        RNP_LOG("Failure setting key on block cipher object");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  165|      0|        return false;
  166|      0|    }
  167|       |
  168|  12.3k|    if (iv != NULL) {
  ------------------
  |  Branch (168:9): [True: 0, False: 12.3k]
  ------------------
  169|       |        // Otherwise left as all zeros via memset at start of function
  170|      0|        memcpy(crypt->cfb.iv, iv, crypt->blocksize);
  171|      0|    }
  172|       |
  173|  12.3k|    crypt->cfb.remaining = 0;
  174|       |
  175|  12.3k|    return true;
  176|  12.3k|}
_Z21pgp_cipher_cfb_finishP11pgp_crypt_t:
  180|  17.7k|{
  181|  17.7k|    if (!crypt) {
  ------------------
  |  Branch (181:9): [True: 0, False: 17.7k]
  ------------------
  182|      0|        return 0;
  183|      0|    }
  184|  17.7k|    if (crypt->cfb.obj) {
  ------------------
  |  Branch (184:9): [True: 12.3k, False: 5.36k]
  ------------------
  185|  12.3k|        botan_block_cipher_destroy(crypt->cfb.obj);
  186|       |        crypt->cfb.obj = NULL;
  187|  12.3k|    }
  188|  17.7k|    botan_scrub_mem((uint8_t *) crypt, sizeof(*crypt));
  189|  17.7k|    return 0;
  190|  17.7k|}
_Z24pgp_cipher_encrypt_blockP11pgp_crypt_tPhm:
  194|  3.34M|{
  195|  3.34M|    return botan_block_cipher_encrypt_blocks(crypt->cfb.obj, iv, iv, 1);
  196|  3.34M|}
_Z19pgp_is_sa_supportedib:
  200|  16.3k|{
  201|  16.3k|    return pgp_sa_to_botan_string(alg, silent);
  202|  16.3k|}
_Z20pgp_cipher_aead_initP11pgp_crypt_t14pgp_symm_alg_t14pgp_aead_alg_tPKhb:
  211|  16.0k|{
  212|  16.0k|    char     cipher_name[32];
  213|  16.0k|    uint32_t flags;
  214|       |
  215|  16.0k|    memset(crypt, 0x0, sizeof(*crypt));
  216|       |
  217|  16.0k|    if (!pgp_aead_to_botan_string(ealg, aalg, cipher_name, sizeof(cipher_name))) {
  ------------------
  |  Branch (217:9): [True: 159, False: 15.8k]
  ------------------
  218|    159|        return false;
  219|    159|    }
  220|       |
  221|  15.8k|    crypt->alg = ealg;
  222|  15.8k|    crypt->blocksize = pgp_block_size(ealg);
  223|  15.8k|    crypt->aead.alg = aalg;
  224|  15.8k|    crypt->aead.decrypt = decrypt;
  225|  15.8k|    crypt->aead.taglen = PGP_AEAD_EAX_OCB_TAG_LEN; /* it's the same for EAX and OCB */
  ------------------
  |  |   80|  15.8k|#define PGP_AEAD_EAX_OCB_TAG_LEN 16
  ------------------
  226|       |
  227|  15.8k|    flags = decrypt ? BOTAN_CIPHER_INIT_FLAG_DECRYPT : BOTAN_CIPHER_INIT_FLAG_ENCRYPT;
  ------------------
  |  Branch (227:13): [True: 7.98k, False: 7.88k]
  ------------------
  228|       |
  229|  15.8k|    if (botan_cipher_init(&(crypt->aead.obj), cipher_name, flags)) {
  ------------------
  |  Branch (229:9): [True: 369, False: 15.5k]
  ------------------
  230|    369|        RNP_LOG("cipher %s is not available", cipher_name);
  ------------------
  |  |   84|    369|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    369|    do {                                                                                 \
  |  |  |  |   77|    369|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 369, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    369|            break;                                                                       \
  |  |  |  |   79|    369|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  231|    369|        return false;
  232|    369|    }
  233|       |
  234|  15.5k|    if (botan_cipher_set_key(crypt->aead.obj, key, (size_t) pgp_key_size(ealg))) {
  ------------------
  |  Branch (234:9): [True: 0, False: 15.5k]
  ------------------
  235|      0|        RNP_LOG("failed to set key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  236|      0|        return false;
  237|      0|    }
  238|       |
  239|  15.5k|    if (botan_cipher_get_update_granularity(crypt->aead.obj, &crypt->aead.granularity)) {
  ------------------
  |  Branch (239:9): [True: 0, False: 15.5k]
  ------------------
  240|      0|        RNP_LOG("failed to get update granularity");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  241|      0|        return false;
  242|      0|    }
  243|       |
  244|  15.5k|    return true;
  245|  15.5k|}
_Z22pgp_cipher_aead_set_adP11pgp_crypt_tPKhm:
  249|   721k|{
  250|   721k|    return botan_cipher_set_associated_data(crypt->aead.obj, ad, len) == 0;
  251|   721k|}
_Z21pgp_cipher_aead_startP11pgp_crypt_tPKhm:
  255|   721k|{
  256|   721k|    return botan_cipher_start(crypt->aead.obj, nonce, len) == 0;
  257|   721k|}
_Z22pgp_cipher_aead_updateR11pgp_crypt_tPhPKhmRm:
  262|  7.49k|{
  263|  7.49k|    if (len % crypt.aead.granularity) {
  ------------------
  |  Branch (263:9): [True: 0, False: 7.49k]
  ------------------
  264|      0|        RNP_LOG("aead wrong update len");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  265|      0|        return false;
  266|      0|    }
  267|       |
  268|  7.49k|    size_t outwr = 0;
  269|  7.49k|    size_t inread = 0;
  270|  7.49k|    if (botan_cipher_update(crypt.aead.obj, 0, out, len, &outwr, in, len, &inread)) {
  ------------------
  |  Branch (270:9): [True: 0, False: 7.49k]
  ------------------
  271|      0|        RNP_LOG("aead update failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  272|      0|        return false;
  273|      0|    }
  274|       |
  275|  7.49k|    if (outwr != inread) {
  ------------------
  |  Branch (275:9): [True: 0, False: 7.49k]
  ------------------
  276|      0|        RNP_LOG("wrong aead usage: %zu vs %zu, len is %zu", outwr, inread, len);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  277|      0|        return false;
  278|      0|    }
  279|       |
  280|  7.49k|    read = inread;
  281|  7.49k|    return true;
  282|  7.49k|}
_Z21pgp_cipher_aead_resetP11pgp_crypt_t:
  286|   720k|{
  287|   720k|    botan_cipher_reset(crypt->aead.obj);
  288|   720k|}
_Z22pgp_cipher_aead_finishP11pgp_crypt_tPhPKhm:
  292|   720k|{
  293|   720k|    uint32_t flags = BOTAN_CIPHER_UPDATE_FLAG_FINAL;
  294|   720k|    size_t   inread = 0;
  295|   720k|    size_t   outwr = 0;
  296|   720k|    int      res;
  297|       |
  298|   720k|    if (crypt->aead.decrypt) {
  ------------------
  |  Branch (298:9): [True: 261k, False: 458k]
  ------------------
  299|   261k|        size_t datalen = len - crypt->aead.taglen;
  300|       |        /* for decryption we should have tag for the final update call */
  301|   261k|        res =
  302|   261k|          botan_cipher_update(crypt->aead.obj, flags, out, datalen, &outwr, in, len, &inread);
  303|   261k|        if (res != 0) {
  ------------------
  |  Branch (303:13): [True: 1.03k, False: 260k]
  ------------------
  304|  1.03k|            if (res != BOTAN_FFI_ERROR_BAD_MAC) {
  ------------------
  |  Branch (304:17): [True: 0, False: 1.03k]
  ------------------
  305|      0|                RNP_LOG("aead finish failed: %d", res);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  306|      0|            }
  307|  1.03k|            return false;
  308|  1.03k|        }
  309|       |
  310|   260k|        if ((outwr != datalen) || (inread != len)) {
  ------------------
  |  Branch (310:13): [True: 0, False: 260k]
  |  Branch (310:35): [True: 0, False: 260k]
  ------------------
  311|      0|            RNP_LOG("wrong decrypt aead finish usage");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  312|      0|            return false;
  313|      0|        }
  314|   458k|    } else {
  315|       |        /* for encryption tag will be generated */
  316|   458k|        size_t outlen = len + crypt->aead.taglen;
  317|   458k|        if (botan_cipher_update(
  ------------------
  |  Branch (317:13): [True: 0, False: 458k]
  ------------------
  318|   458k|              crypt->aead.obj, flags, out, outlen, &outwr, in, len, &inread) != 0) {
  319|      0|            RNP_LOG("aead finish failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  320|      0|            return false;
  321|      0|        }
  322|       |
  323|   458k|        if ((outwr != outlen) || (inread != len)) {
  ------------------
  |  Branch (323:13): [True: 165, False: 458k]
  |  Branch (323:34): [True: 0, False: 458k]
  ------------------
  324|    165|            RNP_LOG("wrong encrypt aead finish usage");
  ------------------
  |  |   84|    165|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    165|    do {                                                                                 \
  |  |  |  |   77|    165|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 165, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    165|            break;                                                                       \
  |  |  |  |   79|    165|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  325|    165|            return false;
  326|    165|        }
  327|   458k|    }
  328|       |
  329|   719k|    pgp_cipher_aead_reset(crypt);
  330|   719k|    return true;
  331|   720k|}
_Z23pgp_cipher_aead_destroyP11pgp_crypt_t:
  335|  19.6k|{
  336|  19.6k|    if (crypt->aead.obj) {
  ------------------
  |  Branch (336:9): [True: 15.5k, False: 4.16k]
  ------------------
  337|  15.5k|        botan_cipher_destroy(crypt->aead.obj);
  338|  15.5k|    }
  339|  19.6k|    memset(crypt, 0x0, sizeof(*crypt));
  340|  19.6k|}
symmetric.cpp:_ZL22pgp_sa_to_botan_stringib:
   41|  44.8k|{
   42|  44.8k|    switch (alg) {
   43|      0|#if defined(BOTAN_HAS_IDEA) && defined(ENABLE_IDEA)
   44|  2.97k|    case PGP_SA_IDEA:
  ------------------
  |  Branch (44:5): [True: 2.97k, False: 41.8k]
  ------------------
   45|  2.97k|        return "IDEA";
   46|      0|#endif
   47|       |
   48|      0|#if defined(BOTAN_HAS_DES)
   49|    742|    case PGP_SA_TRIPLEDES:
  ------------------
  |  Branch (49:5): [True: 742, False: 44.0k]
  ------------------
   50|    742|        return "TripleDES";
   51|      0|#endif
   52|       |
   53|      0|#if defined(BOTAN_HAS_CAST) && defined(ENABLE_CAST5)
   54|    707|    case PGP_SA_CAST5:
  ------------------
  |  Branch (54:5): [True: 707, False: 44.0k]
  ------------------
   55|    707|        return "CAST-128";
   56|      0|#endif
   57|       |
   58|      0|#if defined(BOTAN_HAS_BLOWFISH) && defined(ENABLE_BLOWFISH)
   59|    532|    case PGP_SA_BLOWFISH:
  ------------------
  |  Branch (59:5): [True: 532, False: 44.2k]
  ------------------
   60|    532|        return "Blowfish";
   61|      0|#endif
   62|       |
   63|      0|#if defined(BOTAN_HAS_AES)
   64|  6.59k|    case PGP_SA_AES_128:
  ------------------
  |  Branch (64:5): [True: 6.59k, False: 38.2k]
  ------------------
   65|  6.59k|        return "AES-128";
   66|  2.03k|    case PGP_SA_AES_192:
  ------------------
  |  Branch (66:5): [True: 2.03k, False: 42.7k]
  ------------------
   67|  2.03k|        return "AES-192";
   68|  9.46k|    case PGP_SA_AES_256:
  ------------------
  |  Branch (68:5): [True: 9.46k, False: 35.3k]
  ------------------
   69|  9.46k|        return "AES-256";
   70|      0|#endif
   71|       |
   72|      0|#if defined(BOTAN_HAS_SM4) && defined(ENABLE_SM2)
   73|  3.64k|    case PGP_SA_SM4:
  ------------------
  |  Branch (73:5): [True: 3.64k, False: 41.1k]
  ------------------
   74|  3.64k|        return "SM4";
   75|      0|#endif
   76|       |
   77|      0|#if defined(BOTAN_HAS_TWOFISH) && defined(ENABLE_TWOFISH)
   78|  3.12k|    case PGP_SA_TWOFISH:
  ------------------
  |  Branch (78:5): [True: 3.12k, False: 41.6k]
  ------------------
   79|  3.12k|        return "Twofish";
   80|      0|#endif
   81|       |
   82|      0|#if defined(BOTAN_HAS_CAMELLIA)
   83|  7.10k|    case PGP_SA_CAMELLIA_128:
  ------------------
  |  Branch (83:5): [True: 7.10k, False: 37.6k]
  ------------------
   84|  7.10k|        return "Camellia-128";
   85|  6.30k|    case PGP_SA_CAMELLIA_192:
  ------------------
  |  Branch (85:5): [True: 6.30k, False: 38.4k]
  ------------------
   86|  6.30k|        return "Camellia-192";
   87|  1.40k|    case PGP_SA_CAMELLIA_256:
  ------------------
  |  Branch (87:5): [True: 1.40k, False: 43.3k]
  ------------------
   88|  1.40k|        return "Camellia-256";
   89|      0|#endif
   90|       |
   91|    159|    default:
  ------------------
  |  Branch (91:5): [True: 159, False: 44.6k]
  ------------------
   92|    159|        if (!silent) {
  ------------------
  |  Branch (92:13): [True: 159, False: 0]
  ------------------
   93|    159|            RNP_LOG("Unsupported symmetric algorithm %d", alg);
  ------------------
  |  |   84|    159|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    159|    do {                                                                                 \
  |  |  |  |   77|    159|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 159, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    159|            break;                                                                       \
  |  |  |  |   79|    159|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   94|    159|        }
   95|       |        return NULL;
   96|  44.8k|    }
   97|  44.8k|}
symmetric.cpp:_ZL24pgp_aead_to_botan_string14pgp_symm_alg_t14pgp_aead_alg_tPcm:
  102|  16.0k|{
  103|  16.0k|    const char *ealg_name = pgp_sa_to_botan_string(ealg);
  104|  16.0k|    size_t      ealg_len;
  105|       |
  106|  16.0k|    if (!ealg_name) {
  ------------------
  |  Branch (106:9): [True: 159, False: 15.8k]
  ------------------
  107|    159|        return false;
  108|    159|    }
  109|       |
  110|  15.8k|    ealg_len = strlen(ealg_name);
  111|       |
  112|  15.8k|    if (len < ealg_len + 5) {
  ------------------
  |  Branch (112:9): [True: 0, False: 15.8k]
  ------------------
  113|      0|        RNP_LOG("buffer too small");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  114|      0|        return false;
  115|      0|    }
  116|       |
  117|  15.8k|    switch (aalg) {
  118|  4.86k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (118:5): [True: 4.86k, False: 11.0k]
  ------------------
  119|  4.86k|        memcpy(buf, ealg_name, ealg_len);
  120|  4.86k|        strncpy(buf + ealg_len, "/EAX", len - ealg_len);
  121|  4.86k|        break;
  122|  7.60k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (122:5): [True: 7.60k, False: 8.26k]
  ------------------
  123|  7.60k|        memcpy(buf, ealg_name, ealg_len);
  124|  7.60k|        strncpy(buf + ealg_len, "/OCB", len - ealg_len);
  125|  7.60k|        break;
  126|  3.39k|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (126:5): [True: 3.39k, False: 12.4k]
  ------------------
  127|  3.39k|        memcpy(buf, ealg_name, ealg_len);
  128|  3.39k|        strncpy(buf + ealg_len, "/GCM", len - ealg_len);
  129|  3.39k|        break;
  130|      0|    default:
  ------------------
  |  Branch (130:5): [True: 0, False: 15.8k]
  ------------------
  131|      0|        RNP_LOG("unsupported AEAD alg %d", (int) aalg);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  132|      0|        return false;
  133|  15.8k|    }
  134|       |
  135|  15.8k|    return true;
  136|  15.8k|}

_Z22pgp_cipher_cfb_encryptP11pgp_crypt_tPhPKhm:
   49|  13.1k|{
   50|  13.1k|    uint64_t *in64;
   51|  13.1k|    uint64_t  buf64[512]; // 4KB - page size
   52|  13.1k|    uint64_t  iv64[2];
   53|  13.1k|    size_t    blocks, blockb;
   54|  13.1k|    size_t    blsize = crypt->blocksize;
   55|       |
   56|       |    /* encrypting till the block boundary */
   57|   109k|    while (bytes && crypt->cfb.remaining) {
  ------------------
  |  Branch (57:12): [True: 109k, False: 104]
  |  Branch (57:21): [True: 96.4k, False: 13.0k]
  ------------------
   58|  96.4k|        *out = *in++ ^ crypt->cfb.iv[blsize - crypt->cfb.remaining];
   59|  96.4k|        crypt->cfb.iv[blsize - crypt->cfb.remaining] = *out++;
   60|  96.4k|        crypt->cfb.remaining--;
   61|  96.4k|        bytes--;
   62|  96.4k|    }
   63|       |
   64|  13.1k|    if (!bytes) {
  ------------------
  |  Branch (64:9): [True: 104, False: 13.0k]
  ------------------
   65|    104|        return 0;
   66|    104|    }
   67|       |
   68|       |    /* encrypting full blocks */
   69|  13.0k|    if (bytes > blsize) {
  ------------------
  |  Branch (69:9): [True: 10.0k, False: 2.93k]
  ------------------
   70|  10.0k|        memcpy(iv64, crypt->cfb.iv, blsize);
   71|  25.7k|        while ((blocks = bytes & ~(blsize - 1)) > 0) {
  ------------------
  |  Branch (71:16): [True: 15.6k, False: 10.0k]
  ------------------
   72|  15.6k|            if (blocks > sizeof(buf64)) {
  ------------------
  |  Branch (72:17): [True: 5.55k, False: 10.0k]
  ------------------
   73|  5.55k|                blocks = sizeof(buf64);
   74|  5.55k|            }
   75|  15.6k|            bytes -= blocks;
   76|  15.6k|            blockb = blocks;
   77|  15.6k|            memcpy(buf64, in, blockb);
   78|  15.6k|            in64 = buf64;
   79|       |
   80|  15.6k|            if (blsize == 16) {
  ------------------
  |  Branch (80:17): [True: 15.6k, False: 4]
  ------------------
   81|  15.6k|                blocks >>= 4;
   82|  1.72M|                while (blocks--) {
  ------------------
  |  Branch (82:24): [True: 1.70M, False: 15.6k]
  ------------------
   83|  1.70M|                    pgp_cipher_encrypt_block(crypt, (uint8_t *) iv64, 16);
   84|  1.70M|                    *in64 ^= iv64[0];
   85|  1.70M|                    iv64[0] = *in64++;
   86|  1.70M|                    *in64 ^= iv64[1];
   87|  1.70M|                    iv64[1] = *in64++;
   88|  1.70M|                }
   89|  15.6k|            } else {
   90|      4|                blocks >>= 3;
   91|     16|                while (blocks--) {
  ------------------
  |  Branch (91:24): [True: 12, False: 4]
  ------------------
   92|     12|                    pgp_cipher_encrypt_block(crypt, (uint8_t *) iv64, 8);
   93|     12|                    *in64 ^= iv64[0];
   94|     12|                    iv64[0] = *in64++;
   95|     12|                }
   96|      4|            }
   97|       |
   98|  15.6k|            memcpy(out, buf64, blockb);
   99|  15.6k|            out += blockb;
  100|  15.6k|            in += blockb;
  101|  15.6k|        }
  102|       |
  103|  10.0k|        memcpy(crypt->cfb.iv, iv64, blsize);
  104|  10.0k|    }
  105|       |
  106|  13.0k|    if (!bytes) {
  ------------------
  |  Branch (106:9): [True: 190, False: 12.8k]
  ------------------
  107|    190|        return 0;
  108|    190|    }
  109|       |
  110|  12.8k|    pgp_cipher_encrypt_block(crypt, crypt->cfb.iv, blsize);
  111|  12.8k|    crypt->cfb.remaining = blsize;
  112|       |
  113|       |    /* encrypting tail */
  114|  89.8k|    while (bytes) {
  ------------------
  |  Branch (114:12): [True: 76.9k, False: 12.8k]
  ------------------
  115|  76.9k|        *out = *in++ ^ crypt->cfb.iv[blsize - crypt->cfb.remaining];
  116|  76.9k|        crypt->cfb.iv[blsize - crypt->cfb.remaining] = *out++;
  117|  76.9k|        crypt->cfb.remaining--;
  118|  76.9k|        bytes--;
  119|  76.9k|    }
  120|       |
  121|  12.8k|    return 0;
  122|  13.0k|}
_Z22pgp_cipher_cfb_decryptP11pgp_crypt_tPhPKhm:
  127|  16.7k|{
  128|       |    /* for better code readability */
  129|  16.7k|    uint64_t *out64, *in64;
  130|  16.7k|    uint64_t  inbuf64[512]; // 4KB - page size
  131|  16.7k|    uint64_t  outbuf64[512];
  132|  16.7k|    uint64_t  iv64[2];
  133|  16.7k|    size_t    blocks, blockb;
  134|  16.7k|    size_t    blsize = crypt->blocksize;
  135|       |
  136|       |    /* decrypting till the block boundary */
  137|   112k|    while (bytes && crypt->cfb.remaining) {
  ------------------
  |  Branch (137:12): [True: 112k, False: 104]
  |  Branch (137:21): [True: 95.7k, False: 16.6k]
  ------------------
  138|  95.7k|        uint8_t c = *in++;
  139|  95.7k|        *out++ = c ^ crypt->cfb.iv[blsize - crypt->cfb.remaining];
  140|  95.7k|        crypt->cfb.iv[blsize - crypt->cfb.remaining] = c;
  141|  95.7k|        crypt->cfb.remaining--;
  142|  95.7k|        bytes--;
  143|  95.7k|    }
  144|       |
  145|  16.7k|    if (!bytes) {
  ------------------
  |  Branch (145:9): [True: 104, False: 16.6k]
  ------------------
  146|    104|        return 0;
  147|    104|    }
  148|       |
  149|       |    /* decrypting full blocks */
  150|  16.6k|    if (bytes > blsize) {
  ------------------
  |  Branch (150:9): [True: 13.3k, False: 3.28k]
  ------------------
  151|  13.3k|        memcpy(iv64, crypt->cfb.iv, blsize);
  152|       |
  153|  31.9k|        while ((blocks = bytes & ~(blsize - 1)) > 0) {
  ------------------
  |  Branch (153:16): [True: 18.5k, False: 13.3k]
  ------------------
  154|  18.5k|            if (blocks > sizeof(inbuf64)) {
  ------------------
  |  Branch (154:17): [True: 5.19k, False: 13.3k]
  ------------------
  155|  5.19k|                blocks = sizeof(inbuf64);
  156|  5.19k|            }
  157|  18.5k|            bytes -= blocks;
  158|  18.5k|            blockb = blocks;
  159|  18.5k|            memcpy(inbuf64, in, blockb);
  160|  18.5k|            out64 = outbuf64;
  161|  18.5k|            in64 = inbuf64;
  162|       |
  163|  18.5k|            if (blsize == 16) {
  ------------------
  |  Branch (163:17): [True: 17.7k, False: 766]
  ------------------
  164|  17.7k|                blocks >>= 4;
  165|  1.62M|                while (blocks--) {
  ------------------
  |  Branch (165:24): [True: 1.60M, False: 17.7k]
  ------------------
  166|  1.60M|                    pgp_cipher_encrypt_block(crypt, (uint8_t *) iv64, 16);
  167|  1.60M|                    *out64++ = *in64 ^ iv64[0];
  168|  1.60M|                    iv64[0] = *in64++;
  169|  1.60M|                    *out64++ = *in64 ^ iv64[1];
  170|  1.60M|                    iv64[1] = *in64++;
  171|  1.60M|                }
  172|  17.7k|            } else {
  173|    766|                blocks >>= 3;
  174|  2.62k|                while (blocks--) {
  ------------------
  |  Branch (174:24): [True: 1.85k, False: 766]
  ------------------
  175|  1.85k|                    pgp_cipher_encrypt_block(crypt, (uint8_t *) iv64, 8);
  176|  1.85k|                    *out64++ = *in64 ^ iv64[0];
  177|  1.85k|                    iv64[0] = *in64++;
  178|  1.85k|                }
  179|    766|            }
  180|       |
  181|  18.5k|            memcpy(out, outbuf64, blockb);
  182|  18.5k|            out += blockb;
  183|  18.5k|            in += blockb;
  184|  18.5k|        }
  185|       |
  186|  13.3k|        memcpy(crypt->cfb.iv, iv64, blsize);
  187|  13.3k|    }
  188|       |
  189|  16.6k|    if (!bytes) {
  ------------------
  |  Branch (189:9): [True: 244, False: 16.4k]
  ------------------
  190|    244|        return 0;
  191|    244|    }
  192|       |
  193|  16.4k|    pgp_cipher_encrypt_block(crypt, crypt->cfb.iv, blsize);
  194|  16.4k|    crypt->cfb.remaining = blsize;
  195|       |
  196|       |    /* decrypting tail */
  197|   102k|    while (bytes) {
  ------------------
  |  Branch (197:12): [True: 85.6k, False: 16.4k]
  ------------------
  198|  85.6k|        uint8_t c = *in++;
  199|  85.6k|        *out++ = c ^ crypt->cfb.iv[blsize - crypt->cfb.remaining];
  200|  85.6k|        crypt->cfb.iv[blsize - crypt->cfb.remaining] = c;
  201|  85.6k|        crypt->cfb.remaining--;
  202|  85.6k|        bytes--;
  203|  85.6k|    }
  204|       |
  205|  16.4k|    return 0;
  206|  16.6k|}
_Z14pgp_block_size14pgp_symm_alg_t:
  210|  68.0k|{
  211|  68.0k|    switch (alg) {
  212|  2.22k|    case PGP_SA_IDEA:
  ------------------
  |  Branch (212:5): [True: 2.22k, False: 65.8k]
  ------------------
  213|  4.59k|    case PGP_SA_TRIPLEDES:
  ------------------
  |  Branch (213:5): [True: 2.37k, False: 65.6k]
  ------------------
  214|  5.87k|    case PGP_SA_CAST5:
  ------------------
  |  Branch (214:5): [True: 1.28k, False: 66.7k]
  ------------------
  215|  6.46k|    case PGP_SA_BLOWFISH:
  ------------------
  |  Branch (215:5): [True: 588, False: 67.4k]
  ------------------
  216|  6.46k|        return 8;
  217|  8.63k|    case PGP_SA_AES_128:
  ------------------
  |  Branch (217:5): [True: 8.63k, False: 59.4k]
  ------------------
  218|  13.4k|    case PGP_SA_AES_192:
  ------------------
  |  Branch (218:5): [True: 4.83k, False: 63.2k]
  ------------------
  219|  33.0k|    case PGP_SA_AES_256:
  ------------------
  |  Branch (219:5): [True: 19.6k, False: 48.4k]
  ------------------
  220|  38.7k|    case PGP_SA_TWOFISH:
  ------------------
  |  Branch (220:5): [True: 5.63k, False: 62.4k]
  ------------------
  221|  48.2k|    case PGP_SA_CAMELLIA_128:
  ------------------
  |  Branch (221:5): [True: 9.55k, False: 58.5k]
  ------------------
  222|  55.5k|    case PGP_SA_CAMELLIA_192:
  ------------------
  |  Branch (222:5): [True: 7.27k, False: 60.7k]
  ------------------
  223|  57.6k|    case PGP_SA_CAMELLIA_256:
  ------------------
  |  Branch (223:5): [True: 2.08k, False: 65.9k]
  ------------------
  224|  61.2k|    case PGP_SA_SM4:
  ------------------
  |  Branch (224:5): [True: 3.55k, False: 64.5k]
  ------------------
  225|  61.2k|        return 16;
  226|    391|    default:
  ------------------
  |  Branch (226:5): [True: 391, False: 67.6k]
  ------------------
  227|    391|        return 0;
  228|  68.0k|    }
  229|  68.0k|}
_Z12pgp_key_size14pgp_symm_alg_t:
  233|  72.7k|{
  234|       |    /* Update MAX_SYMM_KEY_SIZE after adding algorithm
  235|       |     * with bigger key size.
  236|       |     */
  237|  72.7k|    static_assert(32 == MAX_SYMM_KEY_SIZE, "MAX_SYMM_KEY_SIZE must be updated");
  238|       |
  239|  72.7k|    switch (alg) {
  240|  3.21k|    case PGP_SA_IDEA:
  ------------------
  |  Branch (240:5): [True: 3.21k, False: 69.5k]
  ------------------
  241|  4.56k|    case PGP_SA_CAST5:
  ------------------
  |  Branch (241:5): [True: 1.35k, False: 71.4k]
  ------------------
  242|  4.84k|    case PGP_SA_BLOWFISH:
  ------------------
  |  Branch (242:5): [True: 277, False: 72.4k]
  ------------------
  243|  15.3k|    case PGP_SA_AES_128:
  ------------------
  |  Branch (243:5): [True: 10.4k, False: 62.2k]
  ------------------
  244|  25.0k|    case PGP_SA_CAMELLIA_128:
  ------------------
  |  Branch (244:5): [True: 9.71k, False: 63.0k]
  ------------------
  245|  29.2k|    case PGP_SA_SM4:
  ------------------
  |  Branch (245:5): [True: 4.23k, False: 68.5k]
  ------------------
  246|  29.2k|        return 16;
  247|       |
  248|    600|    case PGP_SA_TRIPLEDES:
  ------------------
  |  Branch (248:5): [True: 600, False: 72.1k]
  ------------------
  249|  3.23k|    case PGP_SA_AES_192:
  ------------------
  |  Branch (249:5): [True: 2.63k, False: 70.1k]
  ------------------
  250|  12.7k|    case PGP_SA_CAMELLIA_192:
  ------------------
  |  Branch (250:5): [True: 9.56k, False: 63.2k]
  ------------------
  251|  12.7k|        return 24;
  252|       |
  253|  4.85k|    case PGP_SA_TWOFISH:
  ------------------
  |  Branch (253:5): [True: 4.85k, False: 67.9k]
  ------------------
  254|  25.8k|    case PGP_SA_AES_256:
  ------------------
  |  Branch (254:5): [True: 20.9k, False: 51.7k]
  ------------------
  255|  28.2k|    case PGP_SA_CAMELLIA_256:
  ------------------
  |  Branch (255:5): [True: 2.35k, False: 70.4k]
  ------------------
  256|  28.2k|        return 32;
  257|       |
  258|  2.50k|    default:
  ------------------
  |  Branch (258:5): [True: 2.50k, False: 70.2k]
  ------------------
  259|  2.50k|        return 0;
  260|  72.7k|    }
  261|  72.7k|}
_Z27pgp_cipher_aead_granularityP11pgp_crypt_t:
  279|  14.3k|{
  280|  14.3k|    return crypt->aead.granularity;
  281|  14.3k|}
_Z21pgp_cipher_aead_nonce14pgp_aead_alg_tPKhPhm:
  285|   721k|{
  286|   721k|    switch (aalg) {
  287|   239k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (287:5): [True: 239k, False: 482k]
  ------------------
  288|       |        /* The nonce for EAX mode is computed by treating the starting
  289|       |        initialization vector as a 16-octet, big-endian value and
  290|       |        exclusive-oring the low eight octets of it with the chunk index.
  291|       |        */
  292|   239k|        memcpy(nonce, iv, PGP_AEAD_EAX_NONCE_LEN);
  ------------------
  |  |   64|   239k|#define PGP_AEAD_EAX_NONCE_LEN 16
  ------------------
  293|   652k|        for (int i = 15; (i > 7) && index; i--) {
  ------------------
  |  Branch (293:26): [True: 652k, False: 0]
  |  Branch (293:37): [True: 412k, False: 239k]
  ------------------
  294|   412k|            nonce[i] ^= index & 0xff;
  295|   412k|            index = index >> 8;
  296|   412k|        }
  297|   239k|        return PGP_AEAD_EAX_NONCE_LEN;
  ------------------
  |  |   64|   239k|#define PGP_AEAD_EAX_NONCE_LEN 16
  ------------------
  298|   379k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (298:5): [True: 379k, False: 342k]
  ------------------
  299|       |        /* The nonce for a chunk of chunk index "i" in OCB processing is defined as:
  300|       |           OCB-Nonce_{i} = IV[1..120] xor i
  301|       |        */
  302|   379k|        memcpy(nonce, iv, PGP_AEAD_OCB_NONCE_LEN);
  ------------------
  |  |   67|   379k|#define PGP_AEAD_OCB_NONCE_LEN 15
  ------------------
  303|  1.06M|        for (int i = 14; (i >= 0) && index; i--) {
  ------------------
  |  Branch (303:26): [True: 1.06M, False: 0]
  |  Branch (303:38): [True: 681k, False: 379k]
  ------------------
  304|   681k|            nonce[i] ^= index & 0xff;
  305|   681k|            index = index >> 8;
  306|   681k|        }
  307|   379k|        return PGP_AEAD_OCB_NONCE_LEN;
  ------------------
  |  |   67|   379k|#define PGP_AEAD_OCB_NONCE_LEN 15
  ------------------
  308|   102k|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (308:5): [True: 102k, False: 619k]
  ------------------
  309|       |        /* RFC 9580, 5.13.2: the leftmost N - 64 bits are the IV and the
  310|       |         * rightmost 64 bits are the chunk index, big-endian. */
  311|   102k|        memcpy(nonce, iv, PGP_AEAD_GCM_NONCE_LEN);
  ------------------
  |  |   68|   102k|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
  312|   274k|        for (int i = PGP_AEAD_GCM_NONCE_LEN - 1; (i >= PGP_AEAD_GCM_NONCE_LEN - 8) && index;
  ------------------
  |  |   68|   102k|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
                      for (int i = PGP_AEAD_GCM_NONCE_LEN - 1; (i >= PGP_AEAD_GCM_NONCE_LEN - 8) && index;
  ------------------
  |  |   68|   274k|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
  |  Branch (312:50): [True: 274k, False: 0]
  |  Branch (312:87): [True: 172k, False: 102k]
  ------------------
  313|   172k|             i--) {
  314|   172k|            nonce[i] ^= index & 0xff;
  315|   172k|            index = index >> 8;
  316|   172k|        }
  317|   102k|        return PGP_AEAD_GCM_NONCE_LEN;
  ------------------
  |  |   68|   102k|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
  318|      0|    default:
  ------------------
  |  Branch (318:5): [True: 0, False: 721k]
  ------------------
  319|      0|        return 0;
  320|   721k|    }
  321|   721k|}
_Z25pgp_cipher_aead_nonce_len14pgp_aead_alg_t:
  327|  17.5k|{
  328|  17.5k|    switch (aalg) {
  329|  6.96k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (329:5): [True: 6.96k, False: 10.6k]
  ------------------
  330|  6.96k|        return PGP_AEAD_EAX_NONCE_LEN;
  ------------------
  |  |   64|  6.96k|#define PGP_AEAD_EAX_NONCE_LEN 16
  ------------------
  331|  7.04k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (331:5): [True: 7.04k, False: 10.5k]
  ------------------
  332|  7.04k|        return PGP_AEAD_OCB_NONCE_LEN;
  ------------------
  |  |   67|  7.04k|#define PGP_AEAD_OCB_NONCE_LEN 15
  ------------------
  333|  3.55k|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (333:5): [True: 3.55k, False: 14.0k]
  ------------------
  334|  3.55k|        return PGP_AEAD_GCM_NONCE_LEN;
  ------------------
  |  |   68|  3.55k|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
  335|     27|    default:
  ------------------
  |  Branch (335:5): [True: 27, False: 17.5k]
  ------------------
  336|     27|        return 0;
  337|  17.5k|    }
  338|  17.5k|}
_Z23pgp_cipher_aead_tag_len14pgp_aead_alg_t:
  342|   726k|{
  343|   726k|    switch (aalg) {
  344|   243k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (344:5): [True: 243k, False: 482k]
  ------------------
  345|   623k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (345:5): [True: 379k, False: 346k]
  ------------------
  346|   726k|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (346:5): [True: 102k, False: 623k]
  ------------------
  347|   726k|        return PGP_AEAD_EAX_OCB_TAG_LEN;
  ------------------
  |  |   80|   726k|#define PGP_AEAD_EAX_OCB_TAG_LEN 16
  ------------------
  348|      0|    default:
  ------------------
  |  Branch (348:5): [True: 0, False: 726k]
  ------------------
  349|      0|        return 0;
  350|   726k|    }
  351|   726k|}

_ZN3pgp11EncMaterial6createE16pgp_pubkey_alg_t:
   35|    770|{
   36|    770|    switch (alg) {
   37|     59|    case PGP_PKA_RSA:
  ------------------
  |  Branch (37:5): [True: 59, False: 711]
  ------------------
   38|     63|    case PGP_PKA_RSA_ENCRYPT_ONLY:
  ------------------
  |  Branch (38:5): [True: 4, False: 766]
  ------------------
   39|     63|        return std::unique_ptr<EncMaterial>(new RSAEncMaterial());
   40|    110|    case PGP_PKA_ELGAMAL:
  ------------------
  |  Branch (40:5): [True: 110, False: 660]
  ------------------
   41|    111|    case PGP_PKA_ELGAMAL_ENCRYPT_OR_SIGN:
  ------------------
  |  Branch (41:5): [True: 1, False: 769]
  ------------------
   42|    111|        return std::unique_ptr<EncMaterial>(new EGEncMaterial());
   43|      3|    case PGP_PKA_SM2:
  ------------------
  |  Branch (43:5): [True: 3, False: 767]
  ------------------
   44|      3|        return std::unique_ptr<EncMaterial>(new SM2EncMaterial());
   45|     56|    case PGP_PKA_ECDH:
  ------------------
  |  Branch (45:5): [True: 56, False: 714]
  ------------------
   46|     56|        return std::unique_ptr<EncMaterial>(new ECDHEncMaterial());
   47|      0|#if defined(ENABLE_CRYPTO_REFRESH)
   48|    319|    case PGP_PKA_X25519:
  ------------------
  |  Branch (48:5): [True: 319, False: 451]
  ------------------
   49|    319|        return std::unique_ptr<EncMaterial>(new X25519EncMaterial());
   50|      0|#endif
   51|      0|#if defined(ENABLE_PQC)
   52|     10|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (52:5): [True: 10, False: 760]
  ------------------
   53|     10|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
   54|     10|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     10|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   55|     31|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (55:5): [True: 21, False: 749]
  ------------------
   56|     31|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     31|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   57|     55|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (57:5): [True: 24, False: 746]
  ------------------
   58|     55|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     55|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   59|     80|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (59:5): [True: 25, False: 745]
  ------------------
   60|     80|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     80|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   61|     98|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (61:5): [True: 18, False: 752]
  ------------------
   62|     98|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     98|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   63|    114|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (63:5): [True: 16, False: 754]
  ------------------
   64|    114|#endif
   65|    114|        return std::unique_ptr<EncMaterial>(new MlkemEcdhEncMaterial(alg));
   66|      0|#endif
   67|    104|    default:
  ------------------
  |  Branch (67:5): [True: 104, False: 666]
  ------------------
   68|    104|        RNP_LOG("unknown pk alg %d", alg);
  ------------------
  |  |   84|    104|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    104|    do {                                                                                 \
  |  |  |  |   77|    104|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 104, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    104|            break;                                                                       \
  |  |  |  |   79|    104|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   69|    104|        return nullptr;
   70|    770|    }
   71|    770|}
_ZN3pgp14RSAEncMaterial5parseER17pgp_packet_body_t:
   75|     63|{
   76|     63|    return pkt.get(enc.m);
   77|     63|}
_ZN3pgp13EGEncMaterial5parseER17pgp_packet_body_t:
   87|     70|{
   88|     70|    return pkt.get(enc.g) && pkt.get(enc.m);
  ------------------
  |  Branch (88:12): [True: 66, False: 4]
  |  Branch (88:30): [True: 56, False: 10]
  ------------------
   89|     70|}
_ZNK3pgp13EGEncMaterial5writeER17pgp_packet_body_t:
   93|     41|{
   94|     41|    pkt.add(enc.g);
   95|     41|    pkt.add(enc.m);
   96|     41|}
_ZN3pgp14SM2EncMaterial5parseER17pgp_packet_body_t:
  100|      3|{
  101|      3|    return pkt.get(enc.m);
  102|      3|}
_ZN3pgp15ECDHEncMaterial5parseER17pgp_packet_body_t:
  112|     56|{
  113|     56|    uint8_t sz = 0;
  114|       |    /* ECDH ephemeral point and m size */
  115|     56|    if (!pkt.get(enc.p) || !pkt.get(sz)) {
  ------------------
  |  Branch (115:9): [True: 21, False: 35]
  |  Branch (115:28): [True: 1, False: 34]
  ------------------
  116|     22|        return false;
  117|     22|    }
  118|       |    /* ECDH m */
  119|     34|    if (sz > ECDH_WRAPPED_KEY_SIZE) {
  ------------------
  |  |   38|     34|#define ECDH_WRAPPED_KEY_SIZE 48
  ------------------
  |  Branch (119:9): [True: 17, False: 17]
  ------------------
  120|     17|        RNP_LOG("wrong ecdh m len");
  ------------------
  |  |   84|     17|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     17|    do {                                                                                 \
  |  |  |  |   77|     17|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 17, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     17|            break;                                                                       \
  |  |  |  |   79|     17|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  121|     17|        return false;
  122|     17|    }
  123|     17|    enc.m.resize(sz);
  124|     17|    if (!pkt.get(enc.m.data(), sz)) {
  ------------------
  |  Branch (124:9): [True: 3, False: 14]
  ------------------
  125|      3|        return false;
  126|      3|    }
  127|     14|    return true;
  128|     17|}
_ZN3pgp17X25519EncMaterial5parseER17pgp_packet_body_t:
  141|    319|{
  142|    319|    enc.eph_key.resize(32);
  143|    319|    if (!pkt.get(enc.eph_key.data(), enc.eph_key.size())) {
  ------------------
  |  Branch (143:9): [True: 5, False: 314]
  ------------------
  144|      5|        RNP_LOG("failed to parse X25519 PKESK (eph. pubkey)");
  ------------------
  |  |   84|      5|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      5|    do {                                                                                 \
  |  |  |  |   77|      5|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      5|            break;                                                                       \
  |  |  |  |   79|      5|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  145|      5|        return false;
  146|      5|    }
  147|    314|    uint8_t sess_len = 0;
  148|    314|    if (!pkt.get(sess_len) || !sess_len) {
  ------------------
  |  Branch (148:9): [True: 11, False: 303]
  |  Branch (148:31): [True: 11, False: 292]
  ------------------
  149|     22|        RNP_LOG("failed to parse X25519 PKESK (enc sesskey length)");
  ------------------
  |  |   84|     22|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     22|    do {                                                                                 \
  |  |  |  |   77|     22|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 22, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     22|            break;                                                                       \
  |  |  |  |   79|     22|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  150|     22|        return false;
  151|     22|    }
  152|       |    /* get plaintext salg if PKESKv3 */
  153|    292|    if (version == PGP_PKSK_V3) {
  ------------------
  |  Branch (153:9): [True: 278, False: 14]
  ------------------
  154|    278|        uint8_t bt = 0;
  155|    278|        if (!pkt.get(bt)) {
  ------------------
  |  Branch (155:13): [True: 72, False: 206]
  ------------------
  156|     72|            RNP_LOG("failed to get salg");
  ------------------
  |  |   84|     72|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     72|    do {                                                                                 \
  |  |  |  |   77|     72|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 72, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     72|            break;                                                                       \
  |  |  |  |   79|     72|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  157|     72|            return false;
  158|     72|        }
  159|    206|        sess_len--;
  160|    206|        salg = (pgp_symm_alg_t) bt;
  161|    206|    }
  162|    220|    enc.enc_sess_key.resize(sess_len);
  163|    220|    if (!pkt.get(enc.enc_sess_key.data(), sess_len)) {
  ------------------
  |  Branch (163:9): [True: 28, False: 192]
  ------------------
  164|     28|        RNP_LOG("failed to parse X25519 PKESK (enc sesskey)");
  ------------------
  |  |   84|     28|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     28|    do {                                                                                 \
  |  |  |  |   77|     28|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 28, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     28|            break;                                                                       \
  |  |  |  |   79|     28|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  165|     28|        return false;
  166|     28|    }
  167|    192|    return true;
  168|    220|}
_ZN3pgp20MlkemEcdhEncMaterial5parseER17pgp_packet_body_t:
  231|    114|{
  232|       |    /* Calculate ciphertext size */
  233|    114|    auto csize =
  234|    114|      kyber_ciphertext_size(pgp_kyber_ecdh_composite_key_t::pk_alg_to_kyber_id(alg_)) +
  235|    114|      pgp_kyber_ecdh_composite_key_t::ecdh_curve_ephemeral_size(
  236|    114|        pgp_kyber_ecdh_composite_key_t::pk_alg_to_curve_id(alg_));
  237|    114|    enc.composite_ciphertext.resize(csize);
  238|       |    /* Read composite ciphertext */
  239|    114|    if (!pkt.get(enc.composite_ciphertext.data(), enc.composite_ciphertext.size())) {
  ------------------
  |  Branch (239:9): [True: 111, False: 3]
  ------------------
  240|    111|        RNP_LOG("failed to get kyber-ecdh ciphertext");
  ------------------
  |  |   84|    111|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    111|    do {                                                                                 \
  |  |  |  |   77|    111|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 111, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    111|            break;                                                                       \
  |  |  |  |   79|    111|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  241|    111|        return false;
  242|    111|    }
  243|      3|    uint8_t wrapped_key_len = 0;
  244|      3|    if (!pkt.get(wrapped_key_len) || !wrapped_key_len) {
  ------------------
  |  Branch (244:9): [True: 0, False: 3]
  |  Branch (244:38): [True: 1, False: 2]
  ------------------
  245|      1|        RNP_LOG("failed to get kyber-ecdh wrapped session key length");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  246|      1|        return false;
  247|      1|    }
  248|       |    /* get plaintext salg if PKESKv3 */
  249|      2|    if (version == PGP_PKSK_V3) {
  ------------------
  |  Branch (249:9): [True: 2, False: 0]
  ------------------
  250|      2|        uint8_t balg = 0;
  251|      2|        if (!pkt.get(balg)) {
  ------------------
  |  Branch (251:13): [True: 0, False: 2]
  ------------------
  252|      0|            RNP_LOG("failed to get salg");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  253|      0|            return false;
  254|      0|        }
  255|      2|        salg = (pgp_symm_alg_t) balg;
  256|      2|        wrapped_key_len--;
  257|      2|    }
  258|      2|    enc.wrapped_sesskey.resize(wrapped_key_len);
  259|      2|    if (!pkt.get(enc.wrapped_sesskey.data(), enc.wrapped_sesskey.size())) {
  ------------------
  |  Branch (259:9): [True: 0, False: 2]
  ------------------
  260|      0|        RNP_LOG("failed to get kyber-ecdh session key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  261|      0|        return false;
  262|      0|    }
  263|      2|    return true;
  264|      2|}

_ZN3pgp11EncMaterialD2Ev:
   43|    666|    virtual ~EncMaterial(){};
_ZN3pgp20MlkemEcdhEncMaterialC2E16pgp_pubkey_alg_t:
  108|    114|    MlkemEcdhEncMaterial(pgp_pubkey_alg_t alg) : alg_(alg)
  109|    114|    {
  110|    114|    }

_ZN17rnp_op_encrypt_stC2EP10rnp_ffi_stP12rnp_input_stP13rnp_output_st:
  273|  12.0k|        : ffi(affi), input(in), output(out),
  274|  12.0k|          rnpctx(ffi->context, ffi->key_provider, ffi->pass_provider)
  275|  12.0k|    {
  276|  12.0k|    }
_ZN14rnp_op_sign_stC2EP10rnp_ffi_stP12rnp_input_stP13rnp_output_st:
  211|    718|        : ffi(affi), input(in), output(out),
  212|    718|          rnpctx(ffi->context, ffi->key_provider, ffi->pass_provider)
  213|    718|    {
  214|    718|    }
_ZN16rnp_op_verify_stC2EP10rnp_ffi_stP12rnp_input_stP13rnp_output_st:
  251|  10.2k|        : ffi(affi), input(in), output(out),
  252|  10.2k|          rnpctx(ffi->context, ffi->key_provider, ffi->pass_provider)
  253|  10.2k|    {
  254|  10.2k|    }
_ZN25rnp_decryption_kp_param_tC2EP16rnp_op_verify_st:
  314|  10.2k|        : op(opobj), has_hidden(false), last(NULL){};
_ZN23rnp_recipient_handle_stC2Ev:
   93|     27|    rnp_recipient_handle_st() : ffi(NULL), palg(PGP_PKA_NOTHING)
   94|     27|    {
   95|     27|    }
_ZN20rnp_symenc_handle_stC2Ev:
  106|  14.7k|    rnp_symenc_handle_st() : ffi(NULL), iterations(0)
  107|  14.7k|    {
  108|  14.7k|    }
_ZN17rnp_key_handle_stC2EP10rnp_ffi_stPN3rnp3KeyES4_:
   43|  16.0k|        : ffi(affi), pub(apub), sec(asec)
   44|  16.0k|    {
   45|  16.0k|    }
_ZN26rnp_identifier_iterator_stC2EP10rnp_ffi_stN3rnp9KeySearch4TypeE:
  295|  15.8k|        : ffi(affi), type(atype)
  296|  15.8k|    {
  297|  15.8k|        store = nullptr;
  298|  15.8k|        keyp = new std::list<rnp::Key>::iterator();
  299|  15.8k|        uididx = 0;
  300|  15.8k|    }
_ZN26rnp_identifier_iterator_stD2Ev:
  303|  15.8k|    {
  304|  15.8k|        delete keyp;
  305|  15.8k|    }

_ZN3pgp11FingerprintC2Ev:
   38|   496k|Fingerprint::Fingerprint() : keyid_({})
   39|   496k|{
   40|   496k|}
_ZN3pgp11FingerprintC2EPKhm:
   42|  39.8k|Fingerprint::Fingerprint(const uint8_t *data, size_t size) : Fingerprint()
   43|  39.8k|{
   44|  39.8k|    fp_.assign(data, data + size);
   45|  39.8k|}
_ZN3pgp11FingerprintC2ERK13pgp_key_pkt_t:
   48|  35.2k|{
   49|  35.2k|    switch (key.version) {
   50|  1.51k|    case PGP_V2:
  ------------------
  |  Branch (50:5): [True: 1.51k, False: 33.6k]
  ------------------
   51|  6.30k|    case PGP_V3: {
  ------------------
  |  Branch (51:5): [True: 4.78k, False: 30.4k]
  ------------------
   52|       |        /* v2/3 fingerprint is calculated from RSA public numbers */
   53|  6.30k|        if (!is_rsa_key_alg(key.alg)) {
  ------------------
  |  Branch (53:13): [True: 0, False: 6.30k]
  ------------------
   54|      0|            RNP_LOG("bad algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   55|      0|            throw rnp::rnp_exception(RNP_ERROR_NOT_SUPPORTED);
   56|      0|        }
   57|  6.30k|        auto &rsa = dynamic_cast<const pgp::RSAKeyMaterial &>(*key.material);
   58|  6.30k|        auto  hash = rnp::Hash::create(PGP_HASH_MD5);
   59|  6.30k|        hash->add(rsa.n());
   60|  6.30k|        hash->add(rsa.e());
   61|  6.30k|        fp_ = hash->finish();
   62|       |        /* keyid just low bytes of RSA n */
   63|  6.30k|        size_t n = rsa.n().size();
   64|  6.30k|        size_t sz = std::min(rsa.n().size(), keyid_.size());
   65|  6.30k|        std::memcpy(keyid_.data(), rsa.n().data() + n - sz, sz);
   66|  6.30k|        return;
   67|  6.30k|    }
   68|  26.9k|    case PGP_V4:
  ------------------
  |  Branch (68:5): [True: 26.9k, False: 8.25k]
  ------------------
   69|  26.9k|    case PGP_V5:
  ------------------
  |  Branch (69:5): [True: 3, False: 35.2k]
  ------------------
   70|  26.9k|#if defined(ENABLE_CRYPTO_REFRESH)
   71|  28.9k|    case PGP_V6:
  ------------------
  |  Branch (71:5): [True: 1.94k, False: 33.2k]
  ------------------
   72|  28.9k|#endif
   73|  28.9k|    {
   74|  28.9k|        auto halg = key.version == PGP_V4 ? PGP_HASH_SHA1 : PGP_HASH_SHA256;
  ------------------
  |  Branch (74:21): [True: 26.9k, False: 1.94k]
  ------------------
   75|  28.9k|        auto hash = rnp::Hash::create(halg);
   76|  28.9k|        signature_hash_key(key, *hash, key.version);
   77|  28.9k|        fp_ = hash->finish();
   78|       |        /* keyid */
   79|  28.9k|        if (key.version == PGP_V4) {
  ------------------
  |  Branch (79:13): [True: 26.9k, False: 1.94k]
  ------------------
   80|  26.9k|            assert(fp_.size() == PGP_FINGERPRINT_V4_SIZE);
   81|  26.9k|            const size_t inc = PGP_FINGERPRINT_V4_SIZE - PGP_KEY_ID_SIZE;
  ------------------
  |  |   43|  26.9k|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
                          const size_t inc = PGP_FINGERPRINT_V4_SIZE - PGP_KEY_ID_SIZE;
  ------------------
  |  |   39|  26.9k|#define PGP_KEY_ID_SIZE 8
  ------------------
   82|  26.9k|            memcpy(keyid_.data(), fp_.data() + inc, keyid_.size());
   83|  26.9k|        } else {
   84|  1.94k|            memcpy(keyid_.data(), fp_.data(), keyid_.size());
   85|  1.94k|        }
   86|  28.9k|        return;
   87|  26.9k|    }
   88|      0|    default:
  ------------------
  |  Branch (88:5): [True: 0, False: 35.2k]
  ------------------
   89|      0|        RNP_LOG("unsupported key version");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   90|      0|        throw rnp::rnp_exception(RNP_ERROR_NOT_SUPPORTED);
   91|  35.2k|    }
   92|  35.2k|}
_ZNK3pgp11FingerprinteqERKS0_:
   96|   389k|{
   97|   389k|    return fp_ == src.fp_;
   98|   389k|}
_ZNK3pgp11FingerprintneERKS0_:
  102|  14.4k|{
  103|  14.4k|    return !(*this == src);
  104|  14.4k|}
_ZN3pgp11Fingerprint10size_validEm:
  108|  7.18k|{
  109|  7.18k|    return (size == PGP_FINGERPRINT_V4_SIZE) || (size == PGP_FINGERPRINT_V3_SIZE) ||
  ------------------
  |  |   43|  7.18k|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
                  return (size == PGP_FINGERPRINT_V4_SIZE) || (size == PGP_FINGERPRINT_V3_SIZE) ||
  ------------------
  |  |   42|    848|#define PGP_FINGERPRINT_V3_SIZE 16
  ------------------
  |  Branch (109:12): [True: 6.34k, False: 848]
  |  Branch (109:49): [True: 768, False: 80]
  ------------------
  110|     80|           (size == PGP_FINGERPRINT_V5_SIZE)
  ------------------
  |  |   44|     80|#define PGP_FINGERPRINT_V5_SIZE 32
  ------------------
  |  Branch (110:12): [True: 80, False: 0]
  ------------------
  111|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  112|      0|           || (size == PGP_FINGERPRINT_V6_SIZE)
  ------------------
  |  |   51|      0|#define PGP_FINGERPRINT_V6_SIZE 32
  ------------------
  |  Branch (112:15): [True: 0, False: 0]
  ------------------
  113|  7.18k|#endif
  114|  7.18k|      ;
  115|  7.18k|}
_ZNK3pgp11Fingerprint5keyidEv:
  119|  65.4k|{
  120|  65.4k|    return keyid_;
  121|  65.4k|}
_ZNK3pgp11Fingerprint4dataEv:
  131|   394k|{
  132|   394k|    return fp_.data();
  133|   394k|}
_ZNK3pgp11Fingerprint4sizeEv:
  137|   492k|{
  138|   492k|    return fp_.size();
  139|   492k|}

_ZNKSt3__14hashIN3pgp11FingerprintEEclERKS2_:
   90|   341k|    {
   91|       |        /* since fingerprint value is hash itself, we may use its low bytes */
   92|   341k|        size_t res = 0;
   93|   341k|        size_t copy = std::min(sizeof(res), fp.size());
   94|   341k|        std::memcpy(&res, fp.data(), copy);
   95|   341k|        return res;
   96|   341k|    }

_ZN3rnp4json3addERN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS2_14adl_serializerENS6_IhNSA_IhEEEEvEEPKcSJ_:
   53|  32.9k|{
   54|  32.9k|    obj[name] = value;
   55|  32.9k|    return true;
   56|  32.9k|}
_ZN3rnp4json7add_hexERN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS2_14adl_serializerENS6_IhNSA_IhEEEEvEEPKcPKhm:
   95|  16.4k|{
   96|  16.4k|    if (val_len > 1024 * 1024) {
  ------------------
  |  Branch (96:9): [True: 0, False: 16.4k]
  ------------------
   97|      0|        RNP_LOG("too large json hex field: %zu", val_len);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   98|      0|        val_len = 1024 * 1024;
   99|      0|    }
  100|  16.4k|    obj[name] = bin_to_hex(val, val_len, rnp::HexFormat::Lowercase);
  101|  16.4k|    return true;
  102|  16.4k|}
_ZN3rnp4json3addERN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS2_14adl_serializerENS6_IhNSA_IhEEEEvEEPKcRKN3pgp11FingerprintE:
  118|  16.4k|{
  119|  16.4k|    return add_hex(obj, name, fp.data(), fp.size());
  120|  16.4k|}
_ZN3rnp4json9array_addERN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS2_14adl_serializerENS6_IhNSA_IhEEEEvEESG_:
  131|  16.4k|{
  132|  16.4k|    arr.push_back(std::move(val));
  133|  16.4k|    return true;
  134|  16.4k|}
_ZN3rnp4json11dump_prettyERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS2_14adl_serializerENS6_IhNSA_IhEEEEvEE:
  213|  5.60k|{
  214|       |    /* nlohmann::ordered_json::dump(2) produces 2-space indent but with `": ` after
  215|       |     * keys. json-c uses `":` (no space). Walk the dumped string and remove
  216|       |     * the space after structural colons (colons that follow an unescaped
  217|       |     * closing quote of a key). Inside-string `":` is part of a value and
  218|       |     * is left untouched because the preceding quote is escaped (`\"`). */
  219|  5.60k|    std::string raw = jso.dump(2);
  220|  5.60k|    std::string out;
  221|  5.60k|    out.reserve(raw.size());
  222|  5.60k|    bool   in_string = false;
  223|  5.60k|    bool   escaped = false;
  224|  5.60k|    size_t i = 0;
  225|  2.09M|    while (i < raw.size()) {
  ------------------
  |  Branch (225:12): [True: 2.08M, False: 5.60k]
  ------------------
  226|  2.08M|        char c = raw[i];
  227|  2.08M|        if (escaped) {
  ------------------
  |  Branch (227:13): [True: 0, False: 2.08M]
  ------------------
  228|      0|            out.push_back(c);
  229|      0|            escaped = false;
  230|      0|            i++;
  231|      0|            continue;
  232|      0|        }
  233|  2.08M|        if (in_string) {
  ------------------
  |  Branch (233:13): [True: 1.28M, False: 806k]
  ------------------
  234|  1.28M|            if (c == '\\') {
  ------------------
  |  Branch (234:17): [True: 0, False: 1.28M]
  ------------------
  235|      0|                escaped = true;
  236|      0|                out.push_back(c);
  237|      0|                i++;
  238|      0|                continue;
  239|      0|            }
  240|  1.28M|            if (c == '"') {
  ------------------
  |  Branch (240:17): [True: 104k, False: 1.17M]
  ------------------
  241|   104k|                in_string = false;
  242|   104k|            }
  243|  1.28M|            out.push_back(c);
  244|  1.28M|            i++;
  245|  1.28M|            continue;
  246|  1.28M|        }
  247|   806k|        if (c == '"') {
  ------------------
  |  Branch (247:13): [True: 104k, False: 701k]
  ------------------
  248|   104k|            in_string = true;
  249|   104k|            out.push_back(c);
  250|   104k|            i++;
  251|   104k|            continue;
  252|   104k|        }
  253|       |        /* structural colon followed by space → drop the space */
  254|   701k|        if (c == ':' && i + 1 < raw.size() && raw[i + 1] == ' ') {
  ------------------
  |  Branch (254:13): [True: 54.9k, False: 646k]
  |  Branch (254:25): [True: 54.9k, False: 0]
  |  Branch (254:47): [True: 54.9k, False: 0]
  ------------------
  255|  54.9k|            out.push_back(':');
  256|  54.9k|            i += 2; /* skip the colon and its trailing space */
  257|  54.9k|            continue;
  258|  54.9k|        }
  259|   646k|        out.push_back(c);
  260|   646k|        i++;
  261|   646k|    }
  262|  5.60k|    return out;
  263|  5.60k|}

_ZN3rnp9KeySearch9find_typeERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE:
   42|  23.0k|{
   43|  23.0k|    static const std::map<const std::string, KeySearch::Type> types = {
   44|  23.0k|      {"keyid", Type::KeyID},
   45|  23.0k|      {"fingerprint", Type::Fingerprint},
   46|  23.0k|      {"grip", Type::Grip},
   47|  23.0k|      {"userid", Type::UserID}};
   48|  23.0k|    if (types.find(name) == types.end()) {
  ------------------
  |  Branch (48:9): [True: 0, False: 23.0k]
  ------------------
   49|      0|        return Type::Unknown;
   50|      0|    }
   51|  23.0k|    return types.at(name);
   52|  23.0k|}
_ZN3rnp9KeySearch6createERKNSt3__15arrayIhLm8EEE:
   56|  6.09k|{
   57|  6.09k|    return std::unique_ptr<KeySearch>(new KeyIDSearch(keyid));
   58|  6.09k|}
_ZN3rnp9KeySearch6createERKN3pgp11FingerprintE:
   62|  8.40k|{
   63|  8.40k|    return std::unique_ptr<KeySearch>(new KeyFingerprintSearch(fp));
   64|  8.40k|}
_ZN3rnp9KeySearch6createERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEES9_:
   80|  7.18k|{
   81|  7.18k|    auto type = find_type(name);
   82|  7.18k|    if (type == Type::Unknown) {
  ------------------
  |  Branch (82:9): [True: 0, False: 7.18k]
  ------------------
   83|      0|        return nullptr;
   84|      0|    }
   85|  7.18k|    if (type == Type::UserID) {
  ------------------
  |  Branch (85:9): [True: 0, False: 7.18k]
  ------------------
   86|      0|        return create(value);
   87|      0|    }
   88|       |    /* All the rest values are hex-encoded */
   89|  7.18k|    auto binval = hex_to_bin(value);
   90|  7.18k|    if (binval.empty()) {
  ------------------
  |  Branch (90:9): [True: 0, False: 7.18k]
  ------------------
   91|      0|        return nullptr;
   92|      0|    }
   93|  7.18k|    switch (type) {
   94|  7.18k|    case Type::Fingerprint:
  ------------------
  |  Branch (94:5): [True: 7.18k, False: 0]
  ------------------
   95|  7.18k|        if (!pgp::Fingerprint::size_valid(binval.size())) {
  ------------------
  |  Branch (95:13): [True: 0, False: 7.18k]
  ------------------
   96|      0|            RNP_LOG("Invalid fingerprint: %s", value.c_str());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   97|      0|            return nullptr;
   98|      0|        }
   99|  7.18k|        return create(pgp::Fingerprint(binval.data(), binval.size()));
  100|      0|    case Type::KeyID: {
  ------------------
  |  Branch (100:5): [True: 0, False: 7.18k]
  ------------------
  101|      0|        if (binval.size() != PGP_KEY_ID_SIZE) {
  ------------------
  |  |   39|      0|#define PGP_KEY_ID_SIZE 8
  ------------------
  |  Branch (101:13): [True: 0, False: 0]
  ------------------
  102|      0|            RNP_LOG("Invalid keyid: %s", value.c_str());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  103|      0|            return nullptr;
  104|      0|        }
  105|      0|        pgp::KeyID keyid{};
  106|      0|        memcpy(keyid.data(), binval.data(), keyid.size());
  107|      0|        return create(keyid);
  108|      0|    }
  109|      0|    case Type::Grip: {
  ------------------
  |  Branch (109:5): [True: 0, False: 7.18k]
  ------------------
  110|      0|        if (binval.size() != PGP_KEY_GRIP_SIZE) {
  ------------------
  |  |  105|      0|#define PGP_KEY_GRIP_SIZE 20
  ------------------
  |  Branch (110:13): [True: 0, False: 0]
  ------------------
  111|      0|            RNP_LOG("Invalid grip: %s", value.c_str());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  112|      0|            return nullptr;
  113|      0|        }
  114|      0|        pgp::KeyGrip grip{};
  115|      0|        memcpy(grip.data(), binval.data(), grip.size());
  116|      0|        return create(grip);
  117|      0|    }
  118|      0|    default:
  ------------------
  |  Branch (118:5): [True: 0, False: 7.18k]
  ------------------
  119|      0|        return nullptr;
  120|  7.18k|    }
  121|  7.18k|}
_ZNK3rnp11KeyIDSearch7matchesERKNS_3KeyE:
  125|  2.79k|{
  126|  2.79k|    return (key.keyid() == keyid_) || (keyid_ == pgp::KeyID({}));
  ------------------
  |  Branch (126:12): [True: 166, False: 2.62k]
  |  Branch (126:39): [True: 59, False: 2.56k]
  ------------------
  127|  2.79k|}
_ZNK3rnp11KeyIDSearch6hiddenEv:
  143|    246|{
  144|    246|    return keyid_ == pgp::KeyID({});
  145|    246|}
_ZN3rnp11KeyIDSearchC2ERKNSt3__15arrayIhLm8EEE:
  148|  6.09k|{
  149|  6.09k|    type_ = Type::KeyID;
  150|  6.09k|    keyid_ = keyid;
  151|  6.09k|}
_ZNK3rnp20KeyFingerprintSearch7matchesERKNS_3KeyE:
  155|    944|{
  156|    944|    return key.fp() == fp_;
  157|    944|}
_ZN3rnp20KeyFingerprintSearchC2ERKN3pgp11FingerprintE:
  172|  9.38k|{
  173|  9.38k|    type_ = Type::Fingerprint;
  174|  9.38k|    fp_ = fp;
  175|  9.38k|}
_ZNK3rnp20KeyFingerprintSearch6get_fpEv:
  179|  17.5k|{
  180|  17.5k|    return fp_;
  181|  17.5k|}
_ZNK3rnp11KeyProvider11request_keyERKNS_9KeySearchE8pgp_op_tb:
  233|  3.30k|{
  234|  3.30k|    Key *key = nullptr;
  235|  3.30k|    if (!callback) {
  ------------------
  |  Branch (235:9): [True: 0, False: 3.30k]
  ------------------
  236|      0|        return key;
  237|      0|    }
  238|  3.30k|    pgp_key_request_ctx_t ctx(op, secret, search);
  239|  3.30k|    if (!(key = callback(&ctx, userdata))) {
  ------------------
  |  Branch (239:9): [True: 2.35k, False: 944]
  ------------------
  240|  2.35k|        return nullptr;
  241|  2.35k|    }
  242|       |    // confirm that the key actually matches the search criteria
  243|    944|    if (!search.matches(*key) || (key->is_secret() != secret)) {
  ------------------
  |  Branch (243:9): [True: 0, False: 944]
  |  Branch (243:34): [True: 0, False: 944]
  ------------------
  244|      0|        return nullptr;
  245|      0|    }
  246|    944|    return key;
  247|    944|}

_ZNK3rnp9KeySearch4typeEv:
   49|  24.9k|    {
   50|  24.9k|        return type_;
   51|  24.9k|    }
_ZN3rnp11KeyProviderC2EPFPNS_3KeyEPK21pgp_key_request_ctx_tPvES6_:
  120|  22.9k|        : callback(cb), userdata(ud){};
_ZN21pgp_key_request_ctx_tC2E8pgp_op_tbRKN3rnp9KeySearchE:
  140|  3.30k|        : op(anop), secret(sec), search(srch)
  141|  3.30k|    {
  142|  3.30k|    }
_ZN3rnp9KeySearchD2Ev:
   55|  15.4k|    virtual ~KeySearch() = default;

_ZN14pgp_validity_t5resetEv:
   59|   148k|{
   60|   148k|    validated = false;
   61|   148k|    valid = false;
   62|   148k|    expired = false;
   63|   148k|}
_ZN3rnp17find_suitable_keyE8pgp_op_tPNS_3KeyEPNS_11KeyProviderEbb:
  358|  3.85k|{
  359|  3.85k|    if (!key || !key_provider) {
  ------------------
  |  Branch (359:9): [True: 0, False: 3.85k]
  |  Branch (359:17): [True: 0, False: 3.85k]
  ------------------
  360|      0|        return NULL;
  361|      0|    }
  362|  3.85k|    bool secret = false;
  363|  3.85k|    switch (op) {
  364|  3.48k|    case PGP_OP_ENCRYPT:
  ------------------
  |  Branch (364:5): [True: 3.48k, False: 371]
  ------------------
  365|  3.48k|        break;
  366|    371|    case PGP_OP_SIGN:
  ------------------
  |  Branch (366:5): [True: 371, False: 3.48k]
  ------------------
  367|    371|    case PGP_OP_CERTIFY:
  ------------------
  |  Branch (367:5): [True: 0, False: 3.85k]
  ------------------
  368|    371|        secret = true;
  369|    371|        break;
  370|      0|    default:
  ------------------
  |  Branch (370:5): [True: 0, False: 3.85k]
  ------------------
  371|      0|        RNP_LOG("Unsupported operation: %d", (int) op);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  372|      0|        return NULL;
  373|  3.85k|    }
  374|       |    /* Return if specified primary key fits our needs */
  375|  3.85k|    if (!no_primary && key->usable_for(op)) {
  ------------------
  |  Branch (375:9): [True: 3.85k, False: 0]
  |  Branch (375:24): [True: 74, False: 3.78k]
  ------------------
  376|     74|        return key;
  377|     74|    }
  378|       |    /* Check for the case when we need to look up for a secret key */
  379|  3.78k|    if (!no_primary && secret && key->is_public() && key->usable_for(op, true)) {
  ------------------
  |  Branch (379:9): [True: 3.78k, False: 0]
  |  Branch (379:24): [True: 371, False: 3.40k]
  |  Branch (379:34): [True: 0, False: 371]
  |  Branch (379:54): [True: 0, False: 0]
  ------------------
  380|      0|        KeyFingerprintSearch search(key->fp());
  381|      0|        Key *                sec = key_provider->request_key(search, op, secret);
  382|      0|        if (sec && sec->usable_for(op)) {
  ------------------
  |  Branch (382:13): [True: 0, False: 0]
  |  Branch (382:20): [True: 0, False: 0]
  ------------------
  383|      0|            return sec;
  384|      0|        }
  385|      0|    }
  386|       |    /* Now look up for subkeys */
  387|  3.78k|    Key *subkey = NULL;
  388|  3.78k|    for (auto &fp : key->subkey_fps()) {
  ------------------
  |  Branch (388:19): [True: 946, False: 3.78k]
  ------------------
  389|    946|        KeyFingerprintSearch search(fp);
  390|    946|        Key *                cur = key_provider->request_key(search, op, secret);
  391|    946|        if (!cur || !cur->usable_for(op)) {
  ------------------
  |  Branch (391:13): [True: 33, False: 913]
  |  Branch (391:21): [True: 904, False: 9]
  ------------------
  392|    937|            continue;
  393|    937|        }
  394|      9|#if defined(ENABLE_PQC)
  395|      9|        if (pref_pqc_sub && op == PGP_OP_ENCRYPT) {
  ------------------
  |  Branch (395:13): [True: 5, False: 4]
  |  Branch (395:29): [True: 5, False: 0]
  ------------------
  396|       |            /* prefer PQC encryption over non-PQC encryption. Assume non-PQC key is only there
  397|       |             * for backwards compatibility. */
  398|      5|            if (subkey && subkey->is_pqc() && !cur->is_pqc()) {
  ------------------
  |  Branch (398:17): [True: 0, False: 5]
  |  Branch (398:27): [True: 0, False: 0]
  |  Branch (398:47): [True: 0, False: 0]
  ------------------
  399|       |                /* do not override already found PQC key with non-PQC key */
  400|      0|                continue;
  401|      0|            }
  402|      5|            if (subkey && cur->is_pqc() && !subkey->is_pqc()) {
  ------------------
  |  Branch (402:17): [True: 0, False: 5]
  |  Branch (402:27): [True: 0, False: 0]
  |  Branch (402:44): [True: 0, False: 0]
  ------------------
  403|       |                /* override non-PQC key with PQC key */
  404|      0|                subkey = cur;
  405|      0|                continue;
  406|      0|            }
  407|      5|        }
  408|      9|#endif
  409|      9|        if (!subkey || (cur->creation() > subkey->creation())) {
  ------------------
  |  Branch (409:13): [True: 9, False: 0]
  |  Branch (409:24): [True: 0, False: 0]
  ------------------
  410|      9|            subkey = cur;
  411|      9|        }
  412|      9|    }
  413|  3.78k|    return subkey;
  414|  3.78k|}
_ZN3rnp3KeyC2ERK13pgp_key_pkt_t:
  416|  35.2k|Key::Key(const pgp_key_pkt_t &keypkt) : pkt_(keypkt)
  417|  35.2k|{
  418|  35.2k|    if (!is_key_pkt(pkt_.tag) || !pkt_.material->alg()) {
  ------------------
  |  Branch (418:9): [True: 0, False: 35.2k]
  |  Branch (418:34): [True: 0, False: 35.2k]
  ------------------
  419|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  420|      0|    }
  421|  35.2k|    fingerprint_ = pgp::Fingerprint(pkt_);
  422|  35.2k|    grip_ = pkt_.material->grip();
  423|       |
  424|       |    /* parse secret key if not encrypted */
  425|  35.2k|    if (is_secret_key_pkt(pkt_.tag)) {
  ------------------
  |  Branch (425:9): [True: 10.8k, False: 24.3k]
  ------------------
  426|  10.8k|        bool cleartext = pkt_.sec_protection.s2k.usage == PGP_S2KU_NONE;
  427|  10.8k|        if (cleartext && decrypt_secret_key(&pkt_, NULL)) {
  ------------------
  |  Branch (427:13): [True: 227, False: 10.6k]
  |  Branch (427:26): [True: 221, False: 6]
  ------------------
  428|    221|            RNP_LOG("failed to setup key fields");
  ------------------
  |  |   84|    221|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    221|    do {                                                                                 \
  |  |  |  |   77|    221|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 221, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    221|            break;                                                                       \
  |  |  |  |   79|    221|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  429|    221|            throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  430|    221|        }
  431|       |        /* decryption resets validity */
  432|  10.6k|        pkt_.material->set_validity(keypkt.material->validity());
  433|  10.6k|    }
  434|       |    /* add rawpacket */
  435|  34.9k|    rawpkt_ = RawPacket(pkt_);
  436|  34.9k|    format = KeyFormat::GPG;
  437|  34.9k|}
_ZN3rnp3KeyC2ERKS0_b:
  445|  61.7k|{
  446|       |    /* Do some checks for g10 keys */
  447|  61.7k|    if (src.format == KeyFormat::G10) {
  ------------------
  |  Branch (447:9): [True: 0, False: 61.7k]
  ------------------
  448|      0|        if (pubonly) {
  ------------------
  |  Branch (448:13): [True: 0, False: 0]
  ------------------
  449|      0|            RNP_LOG("attempt to copy public part from g10 key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  450|      0|            throw std::invalid_argument("pubonly");
  451|      0|        }
  452|      0|    }
  453|       |
  454|  61.7k|    if (pubonly) {
  ------------------
  |  Branch (454:9): [True: 20.3k, False: 41.4k]
  ------------------
  455|  20.3k|        pkt_ = pgp_key_pkt_t(src.pkt_, true);
  456|  20.3k|        rawpkt_ = RawPacket(pkt_);
  457|  41.4k|    } else {
  458|  41.4k|        pkt_ = src.pkt_;
  459|  41.4k|        rawpkt_ = src.rawpkt_;
  460|  41.4k|    }
  461|       |
  462|  61.7k|    uids_ = src.uids_;
  463|  61.7k|    sigs_ = src.sigs_;
  464|  61.7k|    sigs_map_ = src.sigs_map_;
  465|  61.7k|    keysigs_ = src.keysigs_;
  466|  61.7k|    subkey_fps_ = src.subkey_fps_;
  467|  61.7k|    primary_fp_set_ = src.primary_fp_set_;
  468|  61.7k|    primary_fp_ = src.primary_fp_;
  469|  61.7k|    expiration_ = src.expiration_;
  470|  61.7k|    flags_ = src.flags_;
  471|  61.7k|    fingerprint_ = src.fingerprint_;
  472|  61.7k|    grip_ = src.grip_;
  473|  61.7k|    uid0_ = src.uid0_;
  474|  61.7k|    uid0_set_ = src.uid0_set_;
  475|  61.7k|    revoked_ = src.revoked_;
  476|  61.7k|    revocation_ = src.revocation_;
  477|  61.7k|    revokers_ = src.revokers_;
  478|  61.7k|    format = src.format;
  479|  61.7k|    validity_ = src.validity_;
  480|  61.7k|    valid_till_ = src.valid_till_;
  481|  61.7k|}
_ZN3rnp3KeyC2ERK22pgp_transferable_key_t:
  483|  24.6k|Key::Key(const pgp_transferable_key_t &src) : Key(src.key)
  484|  24.6k|{
  485|       |    /* add direct-key signatures */
  486|  24.6k|    for (auto &sig : src.signatures) {
  ------------------
  |  Branch (486:20): [True: 3.28k, False: 24.6k]
  ------------------
  487|  3.28k|        add_sig(sig);
  488|  3.28k|    }
  489|       |
  490|       |    /* add userids and their signatures */
  491|   320k|    for (auto &uid : src.userids) {
  ------------------
  |  Branch (491:20): [True: 320k, False: 24.6k]
  ------------------
  492|   320k|        add_uid(uid);
  493|   320k|    }
  494|  24.6k|}
_ZN3rnp3KeyC2ERK25pgp_transferable_subkey_tPS0_:
  496|  10.5k|Key::Key(const pgp_transferable_subkey_t &src, Key *primary) : Key(src.subkey)
  497|  10.5k|{
  498|       |    /* add subkey binding signatures */
  499|  13.4k|    for (auto &sig : src.signatures) {
  ------------------
  |  Branch (499:20): [True: 13.4k, False: 10.5k]
  ------------------
  500|  13.4k|        add_sig(sig);
  501|  13.4k|    }
  502|       |
  503|       |    /* setup key grips if primary is available */
  504|  10.5k|    if (primary) {
  ------------------
  |  Branch (504:9): [True: 9.81k, False: 743]
  ------------------
  505|  9.81k|        primary->link_subkey_fp(*this);
  506|  9.81k|    }
  507|  10.5k|}
_ZNK3rnp3Key9sig_countEv:
  511|  42.6k|{
  512|  42.6k|    return sigs_.size();
  513|  42.6k|}
_ZNK3rnp3Key7get_sigEm:
  523|  11.7k|{
  524|  11.7k|    return get_sig(sigs_.at(idx));
  525|  11.7k|}
_ZNK3rnp3Key7has_sigERKNSt3__15arrayIhLm20EEE:
  529|  2.64M|{
  530|  2.64M|    return sigs_map_.count(id);
  531|  2.64M|}
_ZN3rnp3Key7get_sigERKNSt3__15arrayIhLm20EEE:
  535|  2.56M|{
  536|  2.56M|    if (!has_sig(id)) {
  ------------------
  |  Branch (536:9): [True: 0, False: 2.56M]
  ------------------
  537|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  538|      0|    }
  539|  2.56M|    return sigs_map_.at(id);
  540|  2.56M|}
_ZNK3rnp3Key7get_sigERKNSt3__15arrayIhLm20EEE:
  544|  17.7k|{
  545|  17.7k|    if (!has_sig(id)) {
  ------------------
  |  Branch (545:9): [True: 0, False: 17.7k]
  ------------------
  546|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  547|      0|    }
  548|  17.7k|    return sigs_map_.at(id);
  549|  17.7k|}
_ZN3rnp3Key7add_sigERKN3pgp3pkt9SignatureEmb:
  580|  40.8k|{
  581|  40.8k|    auto sigid = sig.get_id();
  582|       |    /* signature id doesn't cover the userid, so drop any earlier copy from its old place */
  583|  40.8k|    del_sig(sigid);
  584|  40.8k|    auto &res = sigs_map_.emplace(std::make_pair(sigid, sig)).first->second;
  585|  40.8k|    res.uid = uid;
  586|  40.8k|    if (uid == UserID::None) {
  ------------------
  |  Branch (586:9): [True: 17.7k, False: 23.0k]
  ------------------
  587|  17.7k|        size_t idx = begin ? 0 : keysigs_.size();
  ------------------
  |  Branch (587:22): [True: 0, False: 17.7k]
  ------------------
  588|  17.7k|        sigs_.insert(sigs_.begin() + idx, sigid);
  589|  17.7k|        keysigs_.insert(keysigs_.begin() + idx, sigid);
  590|  17.7k|        return res;
  591|  17.7k|    }
  592|       |
  593|       |    /* Calculate correct position in sigs_ */
  594|  23.0k|    size_t idx = keysigs_.size();
  595|  49.3k|    for (size_t u = 0; u < uid; u++) {
  ------------------
  |  Branch (595:24): [True: 26.3k, False: 23.0k]
  ------------------
  596|  26.3k|        idx += uids_[u].sig_count();
  597|  26.3k|    }
  598|  23.0k|    if (!begin) {
  ------------------
  |  Branch (598:9): [True: 23.0k, False: 0]
  ------------------
  599|  23.0k|        idx += uids_[uid].sig_count();
  600|  23.0k|    }
  601|  23.0k|    sigs_.insert(sigs_.begin() + idx, sigid);
  602|  23.0k|    uids_[uid].add_sig(sigid, begin);
  603|  23.0k|    return res;
  604|  40.8k|}
_ZN3rnp3Key7del_sigERKNSt3__15arrayIhLm20EEE:
  608|  40.8k|{
  609|  40.8k|    if (!has_sig(sigid)) {
  ------------------
  |  Branch (609:9): [True: 34.4k, False: 6.37k]
  ------------------
  610|  34.4k|        return false;
  611|  34.4k|    }
  612|  6.37k|    uint32_t uid = get_sig(sigid).uid;
  613|  6.37k|    if (uid == UserID::None) {
  ------------------
  |  Branch (613:9): [True: 5.37k, False: 1.00k]
  ------------------
  614|       |        /* signature over the key itself */
  615|  5.37k|        auto it = std::find(keysigs_.begin(), keysigs_.end(), sigid);
  616|  5.37k|        if (it != keysigs_.end()) {
  ------------------
  |  Branch (616:13): [True: 5.37k, False: 0]
  ------------------
  617|  5.37k|            keysigs_.erase(it);
  618|  5.37k|        }
  619|  5.37k|    } else if (uid < uids_.size()) {
  ------------------
  |  Branch (619:16): [True: 1.00k, False: 0]
  ------------------
  620|       |        /* userid-related signature */
  621|  1.00k|        uids_[uid].del_sig(sigid);
  622|  1.00k|    }
  623|  6.37k|    auto it = std::find(sigs_.begin(), sigs_.end(), sigid);
  624|  6.37k|    if (it != sigs_.end()) {
  ------------------
  |  Branch (624:9): [True: 6.37k, False: 0]
  ------------------
  625|  6.37k|        sigs_.erase(it);
  626|  6.37k|    }
  627|  6.37k|    return sigs_map_.erase(sigid);
  628|  40.8k|}
_ZNK3rnp3Key9uid_countEv:
  675|  70.0k|{
  676|  70.0k|    return uids_.size();
  677|  70.0k|}
_ZN3rnp3Key7get_uidEm:
  681|  15.4k|{
  682|  15.4k|    return uids_.at(idx);
  683|  15.4k|}
_ZNK3rnp3Key7get_uidEm:
  687|  6.22k|{
  688|  6.22k|    return uids_.at(idx);
  689|  6.22k|}
_ZNK3rnp3Key7uid_idxERK16pgp_userid_pkt_t:
  707|   287k|{
  708|  1.10M|    for (uint32_t idx = 0; idx < uids_.size(); idx++) {
  ------------------
  |  Branch (708:28): [True: 1.10M, False: 2.22k]
  ------------------
  709|  1.10M|        if (uids_[idx].pkt == uid) {
  ------------------
  |  Branch (709:13): [True: 284k, False: 815k]
  ------------------
  710|   284k|            return idx;
  711|   284k|        }
  712|  1.10M|    }
  713|  2.22k|    return UserID::None;
  714|   287k|}
_ZN3rnp3Key7add_uidERK25pgp_transferable_userid_t:
  764|   320k|{
  765|       |    /* construct userid */
  766|   320k|    uids_.emplace_back(uid.uid);
  767|       |    /* add certifications */
  768|   320k|    for (auto &sig : uid.signatures) {
  ------------------
  |  Branch (768:20): [True: 18.0k, False: 320k]
  ------------------
  769|  18.0k|        add_sig(sig, uid_count() - 1);
  770|  18.0k|    }
  771|   320k|    return uids_.back();
  772|   320k|}
_ZNK3rnp3Key7revokedEv:
  776|   119k|{
  777|   119k|    return revoked_;
  778|   119k|}
_ZN3rnp3Key13clear_revokesEv:
  791|   158k|{
  792|   158k|    revoked_ = false;
  793|   158k|    revocation_ = {};
  794|   771k|    for (auto &uid : uids_) {
  ------------------
  |  Branch (794:20): [True: 771k, False: 158k]
  ------------------
  795|   771k|        uid.revoked = false;
  796|   771k|        uid.revocation = {};
  797|   771k|    }
  798|   158k|}
_ZNK3rnp3Key3pktEv:
  828|  16.4k|{
  829|  16.4k|    return pkt_;
  830|  16.4k|}
_ZN3rnp3Key3pktEv:
  834|     41|{
  835|     41|    return pkt_;
  836|     41|}
_ZNK3rnp3Key8materialEv:
  846|  12.5k|{
  847|  12.5k|    return pkt_.material.get();
  848|  12.5k|}
_ZNK3rnp3Key3algEv:
  858|   161k|{
  859|   161k|    return pkt_.alg;
  860|   161k|}
_ZNK3rnp3Key7versionEv:
  870|     31|{
  871|     31|    return pkt().version;
  872|     31|}
_ZNK3rnp3Key9encryptedEv:
  882|  6.26k|{
  883|  6.26k|    return is_secret() && material() && !material()->secret();
  ------------------
  |  Branch (883:12): [True: 6.26k, False: 0]
  |  Branch (883:27): [True: 6.26k, False: 0]
  |  Branch (883:41): [True: 6.26k, False: 0]
  ------------------
  884|  6.26k|}
_ZNK3rnp3Key8can_signEv:
  894|    520|{
  895|    520|    return flags_ & PGP_KF_SIGN;
  896|    520|}
_ZNK3rnp3Key11can_encryptEv:
  906|  4.24k|{
  907|  4.24k|    return flags_ & PGP_KF_ENCRYPT;
  908|  4.24k|}
_ZN3rnp3Key10is_pqc_algE16pgp_pubkey_alg_t:
  938|  54.3k|{
  939|  54.3k|    switch (alg) {
  940|    142|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (940:5): [True: 142, False: 54.1k]
  ------------------
  941|    142|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
  942|    142|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    142|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  943|    155|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (943:5): [True: 13, False: 54.2k]
  ------------------
  944|    155|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    155|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  945|    195|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (945:5): [True: 40, False: 54.2k]
  ------------------
  946|    195|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    195|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  947|    211|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (947:5): [True: 16, False: 54.2k]
  ------------------
  948|    211|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    211|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  949|    228|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (949:5): [True: 17, False: 54.2k]
  ------------------
  950|    228|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    228|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  951|    277|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (951:5): [True: 49, False: 54.2k]
  ------------------
  952|    277|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    277|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  953|    328|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (953:5): [True: 51, False: 54.2k]
  ------------------
  954|    328|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    328|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  955|    346|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (955:5): [True: 18, False: 54.2k]
  ------------------
  956|    346|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    346|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  957|    361|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (957:5): [True: 15, False: 54.2k]
  ------------------
  958|    361|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    361|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  959|    377|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (959:5): [True: 16, False: 54.2k]
  ------------------
  960|    377|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    377|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  961|    718|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (961:5): [True: 341, False: 53.9k]
  ------------------
  962|    718|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    718|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  963|    772|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (963:5): [True: 54, False: 54.2k]
  ------------------
  964|    772|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    772|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  965|  2.46k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (965:5): [True: 1.69k, False: 52.6k]
  ------------------
  966|  2.46k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  2.46k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  967|  2.74k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (967:5): [True: 280, False: 54.0k]
  ------------------
  968|  2.74k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  2.74k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  969|  2.80k|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (969:5): [True: 59, False: 54.2k]
  ------------------
  970|  2.80k|#endif
  971|  2.80k|        return true;
  972|  51.5k|    default:
  ------------------
  |  Branch (972:5): [True: 51.5k, False: 2.80k]
  ------------------
  973|  51.5k|        return false;
  974|  54.3k|    }
  975|  54.3k|}
_ZNK3rnp3Key10usable_forE8pgp_op_tb:
  986|  4.76k|{
  987|  4.76k|    switch (op) {
  988|      0|    case PGP_OP_ADD_SUBKEY:
  ------------------
  |  Branch (988:5): [True: 0, False: 4.76k]
  ------------------
  989|      0|        return is_primary() && can_sign() && (if_secret || has_secret());
  ------------------
  |  Branch (989:16): [True: 0, False: 0]
  |  Branch (989:32): [True: 0, False: 0]
  |  Branch (989:47): [True: 0, False: 0]
  |  Branch (989:60): [True: 0, False: 0]
  ------------------
  990|    520|    case PGP_OP_SIGN:
  ------------------
  |  Branch (990:5): [True: 520, False: 4.24k]
  ------------------
  991|    520|        return can_sign() && valid() && (if_secret || has_secret());
  ------------------
  |  Branch (991:16): [True: 251, False: 269]
  |  Branch (991:30): [True: 0, False: 251]
  |  Branch (991:42): [True: 0, False: 0]
  |  Branch (991:55): [True: 0, False: 0]
  ------------------
  992|      0|    case PGP_OP_CERTIFY:
  ------------------
  |  Branch (992:5): [True: 0, False: 4.76k]
  ------------------
  993|      0|        return can_certify() && valid() && (if_secret || has_secret());
  ------------------
  |  Branch (993:16): [True: 0, False: 0]
  |  Branch (993:33): [True: 0, False: 0]
  |  Branch (993:45): [True: 0, False: 0]
  |  Branch (993:58): [True: 0, False: 0]
  ------------------
  994|      0|    case PGP_OP_DECRYPT:
  ------------------
  |  Branch (994:5): [True: 0, False: 4.76k]
  ------------------
  995|      0|        return can_encrypt() && valid() && (if_secret || has_secret());
  ------------------
  |  Branch (995:16): [True: 0, False: 0]
  |  Branch (995:33): [True: 0, False: 0]
  |  Branch (995:45): [True: 0, False: 0]
  |  Branch (995:58): [True: 0, False: 0]
  ------------------
  996|      0|    case PGP_OP_UNLOCK:
  ------------------
  |  Branch (996:5): [True: 0, False: 4.76k]
  ------------------
  997|      0|    case PGP_OP_PROTECT:
  ------------------
  |  Branch (997:5): [True: 0, False: 4.76k]
  ------------------
  998|      0|    case PGP_OP_UNPROTECT:
  ------------------
  |  Branch (998:5): [True: 0, False: 4.76k]
  ------------------
  999|      0|        return has_secret();
 1000|      0|    case PGP_OP_VERIFY:
  ------------------
  |  Branch (1000:5): [True: 0, False: 4.76k]
  ------------------
 1001|      0|        return can_sign() && valid();
  ------------------
  |  Branch (1001:16): [True: 0, False: 0]
  |  Branch (1001:30): [True: 0, False: 0]
  ------------------
 1002|      0|    case PGP_OP_ADD_USERID:
  ------------------
  |  Branch (1002:5): [True: 0, False: 4.76k]
  ------------------
 1003|      0|        return is_primary() && can_sign() && (if_secret || has_secret());
  ------------------
  |  Branch (1003:16): [True: 0, False: 0]
  |  Branch (1003:32): [True: 0, False: 0]
  |  Branch (1003:47): [True: 0, False: 0]
  |  Branch (1003:60): [True: 0, False: 0]
  ------------------
 1004|  4.24k|    case PGP_OP_ENCRYPT:
  ------------------
  |  Branch (1004:5): [True: 4.24k, False: 520]
  ------------------
 1005|  4.24k|        return can_encrypt() && valid();
  ------------------
  |  Branch (1005:16): [True: 2.58k, False: 1.66k]
  |  Branch (1005:33): [True: 83, False: 2.50k]
  ------------------
 1006|      0|    default:
  ------------------
  |  Branch (1006:5): [True: 0, False: 4.76k]
  ------------------
 1007|      0|        return false;
 1008|  4.76k|    }
 1009|  4.76k|}
_ZNK3rnp3Key10expirationEv:
 1013|   134k|{
 1014|   134k|    if (pkt_.version >= 4) {
  ------------------
  |  Branch (1014:9): [True: 100k, False: 33.1k]
  ------------------
 1015|   100k|        return expiration_;
 1016|   100k|    }
 1017|       |    /* too large value for pkt.v3_days may overflow uint32_t */
 1018|  33.1k|    if (pkt_.v3_days > (0xffffffffu / 86400)) {
  ------------------
  |  Branch (1018:9): [True: 3.62k, False: 29.4k]
  ------------------
 1019|  3.62k|        return 0xffffffffu;
 1020|  3.62k|    }
 1021|  29.4k|    return (uint32_t) pkt_.v3_days * 86400;
 1022|  33.1k|}
_ZNK3rnp3Key7expiredEv:
 1026|   278k|{
 1027|   278k|    return validity_.expired;
 1028|   278k|}
_ZNK3rnp3Key8creationEv:
 1032|  23.2k|{
 1033|  23.2k|    return pkt_.creation_time;
 1034|  23.2k|}
_ZNK3rnp3Key9is_publicEv:
 1038|    371|{
 1039|    371|    return is_public_key_pkt(pkt_.tag);
 1040|    371|}
_ZNK3rnp3Key9is_secretEv:
 1044|  79.4k|{
 1045|  79.4k|    return is_secret_key_pkt(pkt_.tag);
 1046|  79.4k|}
_ZNK3rnp3Key10is_primaryEv:
 1050|   297k|{
 1051|   297k|    return is_primary_key_pkt(pkt_.tag);
 1052|   297k|}
_ZNK3rnp3Key9is_subkeyEv:
 1056|   424k|{
 1057|   424k|    return is_subkey_pkt(pkt_.tag);
 1058|   424k|}
_ZNK3rnp3Key9is_lockedEv:
 1062|  6.26k|{
 1063|  6.26k|    if (!is_secret()) {
  ------------------
  |  Branch (1063:9): [True: 0, False: 6.26k]
  ------------------
 1064|      0|        RNP_LOG("key is not a secret key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1065|      0|        return false;
 1066|      0|    }
 1067|  6.26k|    return encrypted();
 1068|  6.26k|}
_ZNK3rnp3Key5validEv:
 1082|   175k|{
 1083|   175k|    return validity_.validated && validity_.valid && !validity_.expired;
  ------------------
  |  Branch (1083:12): [True: 175k, False: 0]
  |  Branch (1083:35): [True: 3.66k, False: 171k]
  |  Branch (1083:54): [True: 3.66k, False: 0]
  ------------------
 1084|   175k|}
_ZNK3rnp3Key9validatedEv:
 1088|   162k|{
 1089|   162k|    return validity_.validated;
 1090|   162k|}
_ZNK3rnp3Key17valid_till_commonEb:
 1094|   158k|{
 1095|   158k|    if (!validated()) {
  ------------------
  |  Branch (1095:9): [True: 38.0k, False: 120k]
  ------------------
 1096|  38.0k|        return 0;
 1097|  38.0k|    }
 1098|   120k|    uint64_t till = expiration() ? (uint64_t) creation() + expiration() : UINT64_MAX;
  ------------------
  |  Branch (1098:21): [True: 11.4k, False: 108k]
  ------------------
 1099|   120k|    if (valid()) {
  ------------------
  |  Branch (1099:9): [True: 1.12k, False: 119k]
  ------------------
 1100|  1.12k|        return till;
 1101|  1.12k|    }
 1102|   119k|    if (revoked()) {
  ------------------
  |  Branch (1102:9): [True: 0, False: 119k]
  ------------------
 1103|       |        /* we should not believe to the compromised key at all */
 1104|      0|        if (revocation_.code == PGP_REVOCATION_COMPROMISED) {
  ------------------
  |  Branch (1104:13): [True: 0, False: 0]
  ------------------
 1105|      0|            return 0;
 1106|      0|        }
 1107|      0|        auto &revsig = get_sig(revocation_.sigid);
 1108|      0|        if (revsig.sig.creation() > creation()) {
  ------------------
  |  Branch (1108:13): [True: 0, False: 0]
  ------------------
 1109|       |            /* pick less time from revocation time and expiration time */
 1110|      0|            return std::min((uint64_t) revsig.sig.creation(), till);
 1111|      0|        }
 1112|      0|        return 0;
 1113|      0|    }
 1114|       |    /* if key is not marked as expired then it wasn't valid at all */
 1115|   119k|    return expiry ? till : 0;
  ------------------
  |  Branch (1115:12): [True: 68, False: 118k]
  ------------------
 1116|   119k|}
_ZNK3rnp3Key10valid_tillEv:
 1120|  70.2k|{
 1121|  70.2k|    return valid_till_;
 1122|  70.2k|}
_ZNK3rnp3Key5keyidEv:
 1134|  4.34k|{
 1135|  4.34k|    return fingerprint_.keyid();
 1136|  4.34k|}
_ZNK3rnp3Key2fpEv:
 1140|   456k|{
 1141|   456k|    return fingerprint_;
 1142|   456k|}
_ZNK3rnp3Key10primary_fpEv:
 1152|  40.7k|{
 1153|  40.7k|    if (!primary_fp_set_) {
  ------------------
  |  Branch (1153:9): [True: 0, False: 40.7k]
  ------------------
 1154|      0|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1155|      0|    }
 1156|  40.7k|    return primary_fp_;
 1157|  40.7k|}
_ZNK3rnp3Key14has_primary_fpEv:
 1161|  79.4k|{
 1162|  79.4k|    return primary_fp_set_;
 1163|  79.4k|}
_ZN3rnp3Key16unset_primary_fpEv:
 1167|    244|{
 1168|    244|    primary_fp_set_ = false;
 1169|    244|    primary_fp_ = {};
 1170|    244|}
_ZN3rnp3Key14link_subkey_fpERS0_:
 1174|  27.5k|{
 1175|  27.5k|    if (!is_primary() || !subkey.is_subkey()) {
  ------------------
  |  Branch (1175:9): [True: 26, False: 27.5k]
  |  Branch (1175:26): [True: 52, False: 27.4k]
  ------------------
 1176|     78|        throw rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1177|     78|    }
 1178|  27.4k|    subkey.primary_fp_ = fp();
 1179|  27.4k|    subkey.primary_fp_set_ = true;
 1180|  27.4k|    add_subkey_fp(subkey.fp());
 1181|  27.4k|}
_ZN3rnp3Key13add_subkey_fpERKN3pgp11FingerprintE:
 1185|  28.9k|{
 1186|  28.9k|    if (std::find(subkey_fps_.begin(), subkey_fps_.end(), fp) == subkey_fps_.end()) {
  ------------------
  |  Branch (1186:9): [True: 6.60k, False: 22.3k]
  ------------------
 1187|  6.60k|        subkey_fps_.push_back(fp);
 1188|  6.60k|    }
 1189|  28.9k|}
_ZNK3rnp3Key12subkey_countEv:
 1193|   224k|{
 1194|   224k|    return subkey_fps_.size();
 1195|   224k|}
_ZN3rnp3Key16remove_subkey_fpERKN3pgp11FingerprintE:
 1199|    958|{
 1200|    958|    auto it = std::find(subkey_fps_.begin(), subkey_fps_.end(), fp);
 1201|    958|    if (it != subkey_fps_.end()) {
  ------------------
  |  Branch (1201:9): [True: 958, False: 0]
  ------------------
 1202|    958|        subkey_fps_.erase(it);
 1203|    958|    }
 1204|    958|}
_ZNK3rnp3Key13get_subkey_fpEm:
 1208|  89.2k|{
 1209|  89.2k|    return subkey_fps_[idx];
 1210|  89.2k|}
_ZNK3rnp3Key10subkey_fpsEv:
 1214|  19.3k|{
 1215|  19.3k|    return subkey_fps_;
 1216|  19.3k|}
_ZNK3rnp3Key12rawpkt_countEv:
 1220|  28.1k|{
 1221|  28.1k|    if (format == KeyFormat::G10) {
  ------------------
  |  Branch (1221:9): [True: 0, False: 28.1k]
  ------------------
 1222|      0|        return 1;
 1223|      0|    }
 1224|  28.1k|    return 1 + uid_count() + sig_count();
 1225|  28.1k|}
_ZNK3rnp3Key6rawpktEv:
 1235|     75|{
 1236|     75|    return rawpkt_;
 1237|     75|}
_ZN3rnp3Key14latest_selfsigEjb:
 1528|   398k|{
 1529|   398k|    uint32_t   latest = 0;
 1530|   398k|    Signature *res = nullptr;
 1531|       |
 1532|  1.06M|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (1532:22): [True: 1.06M, False: 398k]
  ------------------
 1533|  1.06M|        auto &sig = get_sig(sigid);
 1534|  1.06M|        if (validated && !sig.validity.valid()) {
  ------------------
  |  Branch (1534:13): [True: 1.06M, False: 0]
  |  Branch (1534:26): [True: 992k, False: 70.0k]
  ------------------
 1535|   992k|            continue;
 1536|   992k|        }
 1537|  70.0k|        bool skip = false;
 1538|  70.0k|        switch (uid) {
 1539|  23.3k|        case UserID::None:
  ------------------
  |  Branch (1539:9): [True: 23.3k, False: 46.6k]
  ------------------
 1540|  23.3k|            skip = (sig.uid != UserID::None) || !is_direct_self(sig);
  ------------------
  |  Branch (1540:20): [True: 23.3k, False: 0]
  |  Branch (1540:49): [True: 0, False: 0]
  ------------------
 1541|  23.3k|            break;
 1542|  23.3k|        case UserID::Primary: {
  ------------------
  |  Branch (1542:9): [True: 23.3k, False: 46.6k]
  ------------------
 1543|  23.3k|            skip = !is_self_cert(sig) ||
  ------------------
  |  Branch (1543:20): [True: 20.9k, False: 2.41k]
  ------------------
 1544|  2.41k|                   !sig.sig.get_subpkt(pgp::pkt::sigsub::Type::PrimaryUserID) ||
  ------------------
  |  Branch (1544:20): [True: 2.41k, False: 0]
  ------------------
 1545|      0|                   !sig.sig.primary_uid() || (sig.uid == UserID::None);
  ------------------
  |  Branch (1545:20): [True: 0, False: 0]
  |  Branch (1545:46): [True: 0, False: 0]
  ------------------
 1546|  23.3k|            break;
 1547|      0|        }
 1548|  23.3k|        case UserID::Any:
  ------------------
  |  Branch (1548:9): [True: 23.3k, False: 46.6k]
  ------------------
 1549|  23.3k|            skip = !is_self_cert(sig) || (sig.uid == UserID::None);
  ------------------
  |  Branch (1549:20): [True: 20.9k, False: 2.41k]
  |  Branch (1549:42): [True: 0, False: 2.41k]
  ------------------
 1550|  23.3k|            break;
 1551|      0|        default:
  ------------------
  |  Branch (1551:9): [True: 0, False: 70.0k]
  ------------------
 1552|      0|            skip = (sig.uid != uid) || !is_self_cert(sig);
  ------------------
  |  Branch (1552:20): [True: 0, False: 0]
  |  Branch (1552:40): [True: 0, False: 0]
  ------------------
 1553|      0|            break;
 1554|  70.0k|        }
 1555|  70.0k|        if (skip) {
  ------------------
  |  Branch (1555:13): [True: 67.5k, False: 2.41k]
  ------------------
 1556|  67.5k|            continue;
 1557|  67.5k|        }
 1558|       |
 1559|  2.41k|        uint32_t creation = sig.sig.creation();
 1560|  2.41k|        if (creation >= latest) {
  ------------------
  |  Branch (1560:13): [True: 2.24k, False: 168]
  ------------------
 1561|  2.24k|            latest = creation;
 1562|  2.24k|            res = &sig;
 1563|  2.24k|        }
 1564|  2.41k|    }
 1565|       |
 1566|       |    /* if there is later self-sig for the same uid without primary flag, then drop res */
 1567|   398k|    if ((uid == UserID::Primary) && res) {
  ------------------
  |  Branch (1567:9): [True: 132k, False: 265k]
  |  Branch (1567:37): [True: 0, False: 132k]
  ------------------
 1568|      0|        auto overres = latest_selfsig(res->uid, validated);
 1569|      0|        if (overres && (overres->sig.creation() > res->sig.creation())) {
  ------------------
  |  Branch (1569:13): [True: 0, False: 0]
  |  Branch (1569:24): [True: 0, False: 0]
  ------------------
 1570|      0|            res = nullptr;
 1571|      0|        }
 1572|      0|    }
 1573|   398k|    return res;
 1574|   398k|}
_ZN3rnp3Key14latest_bindingEb:
 1578|   125k|{
 1579|   125k|    uint32_t   latest = 0;
 1580|   125k|    Signature *res = nullptr;
 1581|       |
 1582|   125k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (1582:22): [True: 79.5k, False: 125k]
  ------------------
 1583|  79.5k|        auto &sig = get_sig(sigid);
 1584|  79.5k|        if (validated && !sig.validity.valid()) {
  ------------------
  |  Branch (1584:13): [True: 72.8k, False: 6.75k]
  |  Branch (1584:26): [True: 72.2k, False: 533]
  ------------------
 1585|  72.2k|            continue;
 1586|  72.2k|        }
 1587|  7.28k|        if (!is_binding(sig) || !is_authorized(sig)) {
  ------------------
  |  Branch (1587:13): [True: 3.01k, False: 4.27k]
  |  Branch (1587:33): [True: 103, False: 4.16k]
  ------------------
 1588|  3.11k|            continue;
 1589|  3.11k|        }
 1590|       |
 1591|  4.16k|        uint32_t creation = sig.sig.creation();
 1592|  4.16k|        if (creation >= latest) {
  ------------------
  |  Branch (1592:13): [True: 2.73k, False: 1.43k]
  ------------------
 1593|  2.73k|            latest = creation;
 1594|  2.73k|            res = &sig;
 1595|  2.73k|        }
 1596|  4.16k|    }
 1597|   125k|    return res;
 1598|   125k|}
_ZNK3rnp3Key9is_signerERKNS_9SignatureE:
 1645|   149k|{
 1646|   149k|    return is_issuer(sig.sig, fp());
 1647|   149k|}
_ZNK3rnp3Key13is_authorizedERKNS_9SignatureE:
 1651|  19.6k|{
 1652|       |    /* subkey binding and revocation must be issued by the primary key. Without known primary
 1653|       |     * key subkey is not valid anyway. */
 1654|  19.6k|    if (is_subkey()) {
  ------------------
  |  Branch (1654:9): [True: 4.27k, False: 15.4k]
  ------------------
 1655|  4.27k|        return !has_primary_fp() || is_issuer(sig.sig, primary_fp());
  ------------------
  |  Branch (1655:16): [True: 3.74k, False: 532]
  |  Branch (1655:37): [True: 429, False: 103]
  ------------------
 1656|  4.27k|    }
 1657|  15.4k|    if (is_signer(sig)) {
  ------------------
  |  Branch (1657:9): [True: 15.4k, False: 0]
  ------------------
 1658|  15.4k|        return true;
 1659|  15.4k|    }
 1660|       |    /* key revocation may be issued by the designated revoker as well */
 1661|      0|    return (sig.sig.type() == PGP_SIG_REV_KEY) && sig.sig.has_keyfp() &&
  ------------------
  |  Branch (1661:12): [True: 0, False: 0]
  |  Branch (1661:51): [True: 0, False: 0]
  ------------------
 1662|      0|           has_revoker(sig.sig.keyfp());
  ------------------
  |  Branch (1662:12): [True: 0, False: 0]
  ------------------
 1663|  15.4k|}
_ZNK3rnp3Key12expired_withERKNS_9SignatureEm:
 1667|    982|{
 1668|       |    /* key expiration: absence of subpkt or 0 means it never expires */
 1669|    982|    uint64_t expiration = sig.sig.key_expiration();
 1670|    982|    if (!expiration) {
  ------------------
  |  Branch (1670:9): [True: 631, False: 351]
  ------------------
 1671|    631|        return false;
 1672|    631|    }
 1673|    351|    return expiration + creation() < at;
 1674|    982|}
_ZNK3rnp3Key12is_self_certERKNS_9SignatureE:
 1678|  69.0k|{
 1679|  69.0k|    return is_primary() && sig.is_cert() && is_signer(sig);
  ------------------
  |  Branch (1679:12): [True: 62.6k, False: 6.38k]
  |  Branch (1679:28): [True: 13.1k, False: 49.5k]
  |  Branch (1679:45): [True: 13.1k, False: 0]
  ------------------
 1680|  69.0k|}
_ZNK3rnp3Key14is_direct_selfERKNS_9SignatureE:
 1684|  32.8k|{
 1685|  32.8k|    return is_primary() && (sig.sig.type() == PGP_SIG_DIRECT) && is_signer(sig);
  ------------------
  |  Branch (1685:12): [True: 32.8k, False: 0]
  |  Branch (1685:28): [True: 68, False: 32.7k]
  |  Branch (1685:66): [True: 68, False: 0]
  ------------------
 1686|  32.8k|}
_ZNK3rnp3Key13is_revocationERKNS_9SignatureE:
 1690|  29.7k|{
 1691|  29.7k|    return is_primary() ? (sig.sig.type() == PGP_SIG_REV_KEY) :
  ------------------
  |  Branch (1691:12): [True: 26.5k, False: 3.21k]
  ------------------
 1692|  29.7k|                          (sig.sig.type() == PGP_SIG_REV_SUBKEY);
 1693|  29.7k|}
_ZNK3rnp3Key17is_uid_revocationERKNS_9SignatureE:
 1697|  20.6k|{
 1698|  20.6k|    return is_primary() && (sig.sig.type() == PGP_SIG_REV_CERT);
  ------------------
  |  Branch (1698:12): [True: 20.6k, False: 0]
  |  Branch (1698:28): [True: 15.9k, False: 4.71k]
  ------------------
 1699|  20.6k|}
_ZNK3rnp3Key10is_bindingERKNS_9SignatureE:
 1703|  25.1k|{
 1704|  25.1k|    return is_subkey() && (sig.sig.type() == PGP_SIG_SUBKEY);
  ------------------
  |  Branch (1704:12): [True: 22.7k, False: 2.37k]
  |  Branch (1704:27): [True: 16.9k, False: 5.81k]
  ------------------
 1705|  25.1k|}
_ZNK3rnp3Key12validate_sigERKS0_RNS_9SignatureERKNS_15SecurityContextE:
 1709|  12.9k|{
 1710|  12.9k|    sig.validity.reset();
 1711|       |
 1712|  12.9k|    SignatureInfo sinfo;
 1713|  12.9k|    sinfo.sig = &sig.sig;
 1714|  12.9k|    sinfo.signer_valid = true;
 1715|  12.9k|    sinfo.ignore_expiry = key.is_self_cert(sig) || key.is_binding(sig);
  ------------------
  |  Branch (1715:27): [True: 4.15k, False: 8.76k]
  |  Branch (1715:52): [True: 6.35k, False: 2.40k]
  ------------------
 1716|  12.9k|    sinfo.ignore_sig_expiry = sig.is_revocation();
 1717|       |
 1718|  12.9k|    pgp_sig_type_t stype = sig.sig.type();
 1719|  12.9k|    try {
 1720|  12.9k|        switch (stype) {
 1721|      0|        case PGP_SIG_BINARY:
  ------------------
  |  Branch (1721:9): [True: 0, False: 12.9k]
  ------------------
 1722|      0|        case PGP_SIG_TEXT:
  ------------------
  |  Branch (1722:9): [True: 0, False: 12.9k]
  ------------------
 1723|      0|        case PGP_SIG_STANDALONE:
  ------------------
  |  Branch (1723:9): [True: 0, False: 12.9k]
  ------------------
 1724|      0|        case PGP_SIG_PRIMARY:
  ------------------
  |  Branch (1724:9): [True: 0, False: 12.9k]
  ------------------
 1725|      0|            RNP_LOG("Invalid key signature type: %d", (int) stype);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1726|      0|            sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_KEY_SIG);
 1727|      0|            break;
 1728|     22|        case PGP_CERT_GENERIC:
  ------------------
  |  Branch (1728:9): [True: 22, False: 12.8k]
  ------------------
 1729|     29|        case PGP_CERT_PERSONA:
  ------------------
  |  Branch (1729:9): [True: 7, False: 12.9k]
  ------------------
 1730|     45|        case PGP_CERT_CASUAL:
  ------------------
  |  Branch (1730:9): [True: 16, False: 12.9k]
  ------------------
 1731|  4.15k|        case PGP_CERT_POSITIVE:
  ------------------
  |  Branch (1731:9): [True: 4.11k, False: 8.80k]
  ------------------
 1732|  6.23k|        case PGP_SIG_REV_CERT: {
  ------------------
  |  Branch (1732:9): [True: 2.07k, False: 10.8k]
  ------------------
 1733|  6.23k|            if (sig.uid >= key.uid_count()) {
  ------------------
  |  Branch (1733:17): [True: 15, False: 6.22k]
  ------------------
 1734|     15|                RNP_LOG("Userid not found");
  ------------------
  |  |   84|     15|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     15|    do {                                                                                 \
  |  |  |  |   77|     15|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     15|            break;                                                                       \
  |  |  |  |   79|     15|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1735|     15|                sinfo.validity.add_error(RNP_ERROR_SIG_UID_MISSING);
 1736|     15|                break;
 1737|     15|            }
 1738|  6.22k|            validate_cert(sinfo, key.pkt(), key.get_uid(sig.uid).pkt, ctx);
 1739|  6.22k|            break;
 1740|  6.23k|        }
 1741|  6.35k|        case PGP_SIG_SUBKEY:
  ------------------
  |  Branch (1741:9): [True: 6.35k, False: 6.56k]
  ------------------
 1742|  6.35k|            if (!is_signer(sig)) {
  ------------------
  |  Branch (1742:17): [True: 1.47k, False: 4.87k]
  ------------------
 1743|  1.47k|                RNP_LOG("Invalid subkey binding's signer.");
  ------------------
  |  |   84|  1.47k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.47k|    do {                                                                                 \
  |  |  |  |   77|  1.47k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.47k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.47k|            break;                                                                       \
  |  |  |  |   79|  1.47k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1744|  1.47k|                sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_BINDING);
 1745|  1.47k|                break;
 1746|  1.47k|            }
 1747|  4.87k|            validate_binding(sinfo, key, ctx);
 1748|  4.87k|            break;
 1749|     68|        case PGP_SIG_DIRECT:
  ------------------
  |  Branch (1749:9): [True: 68, False: 12.8k]
  ------------------
 1750|     68|            if (!is_signer(sig)) {
  ------------------
  |  Branch (1750:17): [True: 0, False: 68]
  ------------------
 1751|      0|                RNP_LOG("Invalid direct key signer.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1752|      0|                sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_DIRECT);
 1753|      0|                break;
 1754|      0|            }
 1755|     68|            validate_direct(sinfo, ctx);
 1756|     68|            break;
 1757|    231|        case PGP_SIG_REV_KEY:
  ------------------
  |  Branch (1757:9): [True: 231, False: 12.6k]
  ------------------
 1758|    231|            if (!is_signer(sig)) {
  ------------------
  |  Branch (1758:17): [True: 0, False: 231]
  ------------------
 1759|      0|                RNP_LOG("Invalid key revocation signer.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1760|      0|                sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_REV);
 1761|      0|                break;
 1762|      0|            }
 1763|    231|            validate_key_rev(sinfo, key.pkt(), ctx);
 1764|    231|            break;
 1765|     29|        case PGP_SIG_REV_SUBKEY:
  ------------------
  |  Branch (1765:9): [True: 29, False: 12.8k]
  ------------------
 1766|     29|            if (!is_signer(sig)) {
  ------------------
  |  Branch (1766:17): [True: 12, False: 17]
  ------------------
 1767|     12|                RNP_LOG("Invalid subkey revocation's signer.");
  ------------------
  |  |   84|     12|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     12|    do {                                                                                 \
  |  |  |  |   77|     12|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 12, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     12|            break;                                                                       \
  |  |  |  |   79|     12|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1768|     12|                sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_REV);
 1769|     12|                break;
 1770|     12|            }
 1771|     17|            validate_sub_rev(sinfo, key.pkt(), ctx);
 1772|     17|            break;
 1773|      0|        default:
  ------------------
  |  Branch (1773:9): [True: 0, False: 12.9k]
  ------------------
 1774|      0|            RNP_LOG("Unsupported key signature type: %d", (int) stype);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1775|      0|            sinfo.validity.add_error(RNP_ERROR_SIG_UNSUPPORTED);
 1776|      0|            break;
 1777|  12.9k|        }
 1778|  12.9k|    } catch (const std::exception &e) {
 1779|     48|        RNP_LOG("Key signature validation failed: %s", e.what());
  ------------------
  |  |   84|     48|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     48|    do {                                                                                 \
  |  |  |  |   77|     48|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 48, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     48|            break;                                                                       \
  |  |  |  |   79|     48|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1780|     48|        sinfo.validity.add_error(RNP_ERROR_SIG_ERROR);
 1781|     48|    }
 1782|       |
 1783|  12.9k|    sinfo.validity.mark_validated();
 1784|  12.9k|    sig.validity = std::move(sinfo.validity);
 1785|  12.9k|}
_ZNK3rnp3Key12validate_sigERNS_13SignatureInfoERNS_4HashERKNS_15SecurityContextEPK17pgp_literal_hdr_t:
 1792|  11.3k|{
 1793|       |    /* Validate signature itself */
 1794|  11.3k|    auto res = signature_validate(*sinfo.sig, *pkt_.material, hash, ctx, hdr);
 1795|  11.3k|    if (!sinfo.signer_valid && !valid_at(sinfo.sig->creation())) {
  ------------------
  |  Branch (1795:9): [True: 0, False: 11.3k]
  |  Branch (1795:32): [True: 0, False: 0]
  ------------------
 1796|      0|        RNP_LOG("invalid or untrusted key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1797|      0|        res.add_error(RNP_ERROR_SIG_SIGNER_UNTRUSTED);
 1798|      0|    }
 1799|       |
 1800|       |    /* Check signature's expiration time */
 1801|  11.3k|    uint32_t now = ctx.time();
 1802|  11.3k|    uint32_t create = sinfo.sig->creation();
 1803|  11.3k|    uint32_t expiry = sinfo.sig->expiration();
 1804|  11.3k|    if (create > now) {
  ------------------
  |  Branch (1804:9): [True: 137, False: 11.2k]
  ------------------
 1805|       |        /* signature created later then now */
 1806|    137|        RNP_LOG("signature created %d seconds in future", (int) (create - now));
  ------------------
  |  |   84|    137|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    137|    do {                                                                                 \
  |  |  |  |   77|    137|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 137, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    137|            break;                                                                       \
  |  |  |  |   79|    137|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1807|    137|        if (!sinfo.ignore_sig_expiry) {
  ------------------
  |  Branch (1807:13): [True: 110, False: 27]
  ------------------
 1808|    110|            res.add_error(RNP_ERROR_SIG_FROM_FUTURE);
 1809|    110|        }
 1810|    137|    }
 1811|  11.3k|    if (create && expiry && (create + expiry < now)) {
  ------------------
  |  Branch (1811:9): [True: 10.5k, False: 773]
  |  Branch (1811:19): [True: 1.58k, False: 9.00k]
  |  Branch (1811:29): [True: 1.52k, False: 63]
  ------------------
 1812|       |        /* signature expired */
 1813|  1.52k|        RNP_LOG("signature expired");
  ------------------
  |  |   84|  1.52k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.52k|    do {                                                                                 \
  |  |  |  |   77|  1.52k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.52k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.52k|            break;                                                                       \
  |  |  |  |   79|  1.52k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1814|  1.52k|        if (!sinfo.ignore_sig_expiry) {
  ------------------
  |  Branch (1814:13): [True: 1.32k, False: 194]
  ------------------
 1815|  1.32k|            res.add_error(RNP_ERROR_SIG_EXPIRED);
 1816|  1.32k|        }
 1817|  1.52k|    }
 1818|       |
 1819|       |    /* check key creation time vs signature creation */
 1820|  11.3k|    if (creation() > create) {
  ------------------
  |  Branch (1820:9): [True: 1.38k, False: 9.98k]
  ------------------
 1821|  1.38k|        RNP_LOG("key is newer than signature");
  ------------------
  |  |   84|  1.38k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.38k|    do {                                                                                 \
  |  |  |  |   77|  1.38k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.38k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.38k|            break;                                                                       \
  |  |  |  |   79|  1.38k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1822|  1.38k|        res.add_error(RNP_ERROR_SIG_OLDER_KEY);
 1823|  1.38k|    }
 1824|       |
 1825|       |    /* check whether key was not expired when sig created */
 1826|  11.3k|    if (!sinfo.ignore_expiry && expiration() && (creation() + expiration() < create)) {
  ------------------
  |  Branch (1826:9): [True: 2.38k, False: 8.98k]
  |  Branch (1826:33): [True: 20, False: 2.36k]
  |  Branch (1826:49): [True: 7, False: 13]
  ------------------
 1827|      7|        RNP_LOG("signature made after key expiration");
  ------------------
  |  |   84|      7|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      7|    do {                                                                                 \
  |  |  |  |   77|      7|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      7|            break;                                                                       \
  |  |  |  |   79|      7|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1828|      7|        res.add_error(RNP_ERROR_SIG_EXPIRED_KEY);
 1829|      7|    }
 1830|       |
 1831|       |    /* Check signer's fingerprint. RNP_ERROR_SIG_FP_MISMATCH stays "bytes differ".
 1832|       |     * A v4/v6 version-octet mismatch is a malformed issuer fingerprint (RFC 9580
 1833|       |     * §5.2.3.35) and is reported as a general signature error, without a new code. */
 1834|  11.3k|    if (sinfo.sig->has_keyfp()) {
  ------------------
  |  Branch (1834:9): [True: 8.62k, False: 2.73k]
  ------------------
 1835|  8.62k|        if (!sinfo.sig->issuer_fp_version_matches()) {
  ------------------
  |  Branch (1835:13): [True: 0, False: 8.62k]
  ------------------
 1836|      0|            RNP_LOG("issuer fingerprint version does not match signature version");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1837|      0|            res.add_error(RNP_ERROR_SIG_ERROR);
 1838|  8.62k|        } else if (sinfo.sig->keyfp() != fp()) {
  ------------------
  |  Branch (1838:20): [True: 0, False: 8.62k]
  ------------------
 1839|      0|            RNP_LOG("issuer fingerprint doesn't match signer's one");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1840|      0|            res.add_error(RNP_ERROR_SIG_FP_MISMATCH);
 1841|      0|        }
 1842|  8.62k|    }
 1843|       |
 1844|       |    /* Check for unknown critical notations, unhashed ones may be added by anyone */
 1845|  71.3k|    for (auto &subpkt : sinfo.sig->subpkts) {
  ------------------
  |  Branch (1845:23): [True: 71.3k, False: 11.3k]
  ------------------
 1846|  71.3k|        if (!subpkt->hashed() || !subpkt->critical() ||
  ------------------
  |  Branch (1846:13): [True: 11.3k, False: 60.0k]
  |  Branch (1846:34): [True: 58.8k, False: 1.19k]
  ------------------
 1847|  71.2k|            (subpkt->type() != pgp::pkt::sigsub::Type::NotationData)) {
  ------------------
  |  Branch (1847:13): [True: 1.09k, False: 108]
  ------------------
 1848|  71.2k|            continue;
 1849|  71.2k|        }
 1850|    108|        auto &notation = dynamic_cast<pgp::pkt::sigsub::NotationData &>(*subpkt);
 1851|    108|        RNP_LOG("unknown critical notation: %s", notation.name().c_str());
  ------------------
  |  |   84|    108|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    108|    do {                                                                                 \
  |  |  |  |   77|    108|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 108, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    108|            break;                                                                       \
  |  |  |  |   79|    108|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1852|    108|        res.add_error(RNP_ERROR_SIG_UNKNOWN_NOTATION);
 1853|    108|    }
 1854|       |
 1855|  25.1k|    for (auto &err : res.errors()) {
  ------------------
  |  Branch (1855:20): [True: 25.1k, False: 11.3k]
  ------------------
 1856|  25.1k|        sinfo.validity.add_error(err);
 1857|  25.1k|    }
 1858|  11.3k|    sinfo.validity.mark_validated();
 1859|  11.3k|}
_ZNK3rnp3Key13validate_certERNS_13SignatureInfoERK13pgp_key_pkt_tRK16pgp_userid_pkt_tRKNS_15SecurityContextE:
 1866|  6.22k|{
 1867|  6.22k|    auto hash = signature_hash_certification(*sinfo.sig, key, uid);
 1868|  6.22k|    validate_sig(sinfo, *hash, ctx);
 1869|  6.22k|}
_ZNK3rnp3Key16validate_bindingERNS_13SignatureInfoERKS0_RKNS_15SecurityContextE:
 1875|  4.87k|{
 1876|  4.87k|    if (!is_primary() || !subkey.is_subkey()) {
  ------------------
  |  Branch (1876:9): [True: 0, False: 4.87k]
  |  Branch (1876:26): [True: 0, False: 4.87k]
  ------------------
 1877|      0|        RNP_LOG("Invalid binding signature key type(s)");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1878|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_ERROR);
 1879|      0|        sinfo.validity.mark_validated();
 1880|      0|        return;
 1881|      0|    }
 1882|       |    /* RFC 9980 §7.2: Subkey binding signatures (Signature Type 0x18) over
 1883|       |     * PQ(/T) algorithms MUST NOT be made with MD5, SHA-1, or RIPEMD-160.
 1884|       |     * A receiving implementation MUST treat such a signature as invalid. */
 1885|  4.87k|#if defined(ENABLE_PQC)
 1886|  4.87k|    if (Key::is_pqc_alg(subkey.alg())) {
  ------------------
  |  Branch (1886:9): [True: 0, False: 4.87k]
  ------------------
 1887|      0|        auto halg = sinfo.sig->halg;
 1888|      0|        if (halg == PGP_HASH_MD5 || halg == PGP_HASH_SHA1 || halg == PGP_HASH_RIPEMD) {
  ------------------
  |  Branch (1888:13): [True: 0, False: 0]
  |  Branch (1888:37): [True: 0, False: 0]
  |  Branch (1888:62): [True: 0, False: 0]
  ------------------
 1889|      0|            RNP_LOG("Weak hash algorithm %d in PQ subkey binding signature (RFC 9980 §7.2)",
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1890|      0|                    (int) halg);
 1891|      0|            sinfo.validity.add_error(RNP_ERROR_SIG_WEAK_HASH);
 1892|      0|            sinfo.validity.mark_validated();
 1893|      0|            return;
 1894|      0|        }
 1895|      0|    }
 1896|  4.87k|#endif
 1897|  4.87k|    auto hash = signature_hash_binding(*sinfo.sig, pkt(), subkey.pkt());
 1898|  4.87k|    validate_sig(sinfo, *hash, ctx);
 1899|       |    /* Check whether subkey is capable of signing and return otherwise. Without key flags
 1900|       |     * the subkey gets the algorithm's capabilities, see refresh_data(). */
 1901|  4.87k|    pgp_key_flags_t realkf = (pgp_key_flags_t) sinfo.sig->key_flags();
 1902|  4.87k|    if (!sinfo.sig->has_subpkt(PGP_SIG_SUBPKT_KEY_FLAGS)) {
  ------------------
  |  Branch (1902:9): [True: 83, False: 4.79k]
  ------------------
 1903|     83|        realkf = pgp_pk_alg_capabilities(subkey.alg());
 1904|     83|    }
 1905|  4.87k|    if (!sinfo.validity.valid() || !(realkf & PGP_KF_SIGN)) {
  ------------------
  |  Branch (1905:9): [True: 4.82k, False: 52]
  |  Branch (1905:36): [True: 52, False: 0]
  ------------------
 1906|  4.84k|        return;
 1907|  4.84k|    }
 1908|       |
 1909|       |    /* check primary key binding signature if any */
 1910|     33|    auto sub = dynamic_cast<pgp::pkt::sigsub::EmbeddedSignature *>(
 1911|     33|      sinfo.sig->get_subpkt(pgp::pkt::sigsub::Type::EmbeddedSignature, false));
 1912|     33|    if (!sub) {
  ------------------
  |  Branch (1912:9): [True: 0, False: 33]
  ------------------
 1913|      0|        RNP_LOG("error! no primary key binding signature");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1914|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_NO_PRIMARY_BINDING);
 1915|      0|        return;
 1916|      0|    }
 1917|     33|    if (!sub->signature()) {
  ------------------
  |  Branch (1917:9): [True: 0, False: 33]
  ------------------
 1918|      0|        RNP_LOG("invalid embedded signature subpacket");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1919|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_BINDING_PARSE);
 1920|      0|        return;
 1921|      0|    }
 1922|     33|    if (sub->signature()->type() != PGP_SIG_PRIMARY) {
  ------------------
  |  Branch (1922:9): [True: 0, False: 33]
  ------------------
 1923|      0|        RNP_LOG("invalid primary key binding signature");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1924|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_BIND_TYPE);
 1925|      0|        return;
 1926|      0|    }
 1927|     33|    if (sub->signature()->version < PGP_V4) {
  ------------------
  |  Branch (1927:9): [True: 0, False: 33]
  ------------------
 1928|      0|        RNP_LOG("invalid primary key binding signature version");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1929|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_WRONG_BIND_TYPE);
 1930|      0|        return;
 1931|      0|    }
 1932|       |
 1933|     33|    hash = signature_hash_binding(*sub->signature(), pkt(), subkey.pkt());
 1934|     33|    SignatureInfo bindinfo;
 1935|     33|    bindinfo.sig = sub->signature();
 1936|     33|    bindinfo.signer_valid = true;
 1937|     33|    bindinfo.ignore_expiry = true;
 1938|     33|    subkey.validate_sig(bindinfo, *hash, ctx);
 1939|     33|    if (!bindinfo.validity.valid()) {
  ------------------
  |  Branch (1939:9): [True: 0, False: 33]
  ------------------
 1940|      0|        sinfo.validity.add_error(RNP_ERROR_SIG_INVALID_BINDING);
 1941|      0|        for (auto &err : bindinfo.validity.errors()) {
  ------------------
  |  Branch (1941:24): [True: 0, False: 0]
  ------------------
 1942|      0|            sinfo.validity.add_error(err);
 1943|      0|        }
 1944|      0|    }
 1945|     33|}
_ZNK3rnp3Key16validate_sub_revERNS_13SignatureInfoERK13pgp_key_pkt_tRKNS_15SecurityContextE:
 1951|     17|{
 1952|     17|    auto hash = signature_hash_binding(*sinfo.sig, pkt(), subkey);
 1953|     17|    validate_sig(sinfo, *hash, ctx);
 1954|     17|}
_ZNK3rnp3Key15validate_directERNS_13SignatureInfoERKNS_15SecurityContextE:
 1958|     68|{
 1959|     68|    auto hash = signature_hash_direct(*sinfo.sig, pkt());
 1960|     68|    validate_sig(sinfo, *hash, ctx);
 1961|     68|}
_ZNK3rnp3Key16validate_key_revERNS_13SignatureInfoERK13pgp_key_pkt_tRKNS_15SecurityContextE:
 1967|    231|{
 1968|    231|    auto hash = signature_hash_direct(*sinfo.sig, key);
 1969|    231|    validate_sig(sinfo, *hash, ctx);
 1970|    231|}
_ZN3rnp3Key24validate_self_signaturesERKNS_15SecurityContextE:
 1974|   132k|{
 1975|   353k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (1975:22): [True: 353k, False: 132k]
  ------------------
 1976|   353k|        auto &sig = get_sig(sigid);
 1977|   353k|        if (sig.validity.validated()) {
  ------------------
  |  Branch (1977:13): [True: 241k, False: 112k]
  ------------------
 1978|   241k|            continue;
 1979|   241k|        }
 1980|   112k|        if (!is_signer(sig)) {
  ------------------
  |  Branch (1980:13): [True: 102k, False: 9.52k]
  ------------------
 1981|   102k|            continue;
 1982|   102k|        }
 1983|       |
 1984|  9.52k|        if (is_direct_self(sig) || is_self_cert(sig) || is_uid_revocation(sig) ||
  ------------------
  |  Branch (1984:13): [True: 68, False: 9.45k]
  |  Branch (1984:36): [True: 4.15k, False: 5.29k]
  |  Branch (1984:57): [True: 2.07k, False: 3.21k]
  ------------------
 1985|  6.53k|            is_revocation(sig)) {
  ------------------
  |  Branch (1985:13): [True: 231, False: 2.98k]
  ------------------
 1986|  6.53k|            validate_sig(*this, sig, ctx);
 1987|  6.53k|        }
 1988|  9.52k|    }
 1989|   132k|}
_ZN3rnp3Key24validate_self_signaturesERS0_RKNS_15SecurityContextE:
 1993|   122k|{
 1994|   122k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (1994:22): [True: 72.8k, False: 122k]
  ------------------
 1995|  72.8k|        auto &sig = get_sig(sigid);
 1996|  72.8k|        if (sig.validity.validated()) {
  ------------------
  |  Branch (1996:13): [True: 63.6k, False: 9.12k]
  ------------------
 1997|  63.6k|            continue;
 1998|  63.6k|        }
 1999|       |
 2000|  9.12k|        if (is_binding(sig) || is_revocation(sig)) {
  ------------------
  |  Branch (2000:13): [True: 6.35k, False: 2.77k]
  |  Branch (2000:32): [True: 29, False: 2.74k]
  ------------------
 2001|  6.38k|            primary.validate_sig(*this, sig, ctx);
 2002|  6.38k|        }
 2003|  9.12k|    }
 2004|   122k|}
_ZN3rnp3Key22validate_desig_revokesERNS_8KeyStoreE:
 2008|   223k|{
 2009|   223k|    if (revokers_.empty()) {
  ------------------
  |  Branch (2009:9): [True: 223k, False: 0]
  ------------------
 2010|   223k|        return false;
 2011|   223k|    }
 2012|      0|    bool refresh = false;
 2013|      0|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2013:22): [True: 0, False: 0]
  ------------------
 2014|      0|        auto &sig = get_sig(sigid);
 2015|      0|        if (!is_revocation(sig) || is_signer(sig)) {
  ------------------
  |  Branch (2015:13): [True: 0, False: 0]
  |  Branch (2015:36): [True: 0, False: 0]
  ------------------
 2016|      0|            continue;
 2017|      0|        }
 2018|       |        /* Don't think we should deal with sigs without issuer's fingerprint */
 2019|      0|        if (!sig.sig.has_keyfp() || !has_revoker(sig.sig.keyfp())) {
  ------------------
  |  Branch (2019:13): [True: 0, False: 0]
  |  Branch (2019:13): [True: 0, False: 0]
  |  Branch (2019:37): [True: 0, False: 0]
  ------------------
 2020|      0|            continue;
 2021|      0|        }
 2022|       |        /* If signature was validated and valid, do not re-validate it */
 2023|      0|        if (sig.validity.valid()) {
  ------------------
  |  Branch (2023:13): [True: 0, False: 0]
  ------------------
 2024|      0|            continue;
 2025|      0|        }
 2026|       |
 2027|      0|        auto revoker = keyring.get_signer(sig.sig);
 2028|      0|        if (!revoker) {
  ------------------
  |  Branch (2028:13): [True: 0, False: 0]
  ------------------
 2029|      0|            continue;
 2030|      0|        }
 2031|       |
 2032|      0|        revoker->validate_sig(*this, sig, keyring.secctx);
 2033|      0|        if (sig.validity.valid()) {
  ------------------
  |  Branch (2033:13): [True: 0, False: 0]
  ------------------
 2034|       |            /* return true only if new valid revocation was added */
 2035|      0|            refresh = true;
 2036|      0|        }
 2037|      0|    }
 2038|       |
 2039|      0|    return refresh;
 2040|   223k|}
_ZN3rnp3Key16validate_primaryERNS_8KeyStoreE:
 2044|  47.0k|{
 2045|       |    /* validate signatures if needed */
 2046|  47.0k|    validate_self_signatures(keyring.secctx);
 2047|       |    /* designated revokers may have changed */
 2048|  47.0k|    refresh_revokers();
 2049|       |
 2050|       |    /* consider public key as valid on this level if it is not expired and has at least one
 2051|       |     * valid self-signature, and is not revoked */
 2052|  47.0k|    validity_.reset();
 2053|  47.0k|    validity_.validated = true;
 2054|  47.0k|    bool has_cert = false;
 2055|  47.0k|    bool has_expired = false;
 2056|       |    /* check whether key is revoked */
 2057|   119k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2057:22): [True: 119k, False: 47.0k]
  ------------------
 2058|   119k|        auto &sig = get_sig(sigid);
 2059|   119k|        if (!sig.validity.valid()) {
  ------------------
  |  Branch (2059:13): [True: 111k, False: 7.92k]
  ------------------
 2060|   111k|            continue;
 2061|   111k|        }
 2062|  7.92k|        if (is_revocation(sig) && is_authorized(sig)) {
  ------------------
  |  Branch (2062:13): [True: 0, False: 7.92k]
  |  Branch (2062:35): [True: 0, False: 0]
  ------------------
 2063|      0|            return;
 2064|      0|        }
 2065|  7.92k|    }
 2066|       |    /* if we have direct-key signature, then it has higher priority for expiration check */
 2067|  47.0k|    uint64_t now = keyring.secctx.time();
 2068|  47.0k|    auto     dirsig = latest_selfsig(UserID::None);
 2069|  47.0k|    if (dirsig) {
  ------------------
  |  Branch (2069:9): [True: 0, False: 47.0k]
  ------------------
 2070|      0|        has_expired = expired_with(*dirsig, now);
 2071|      0|        has_cert = !has_expired;
 2072|      0|    }
 2073|       |    /* if we have primary uid and it is more restrictive, then use it as well */
 2074|  47.0k|    Signature *prisig = nullptr;
 2075|  47.0k|    if (!has_expired && (prisig = latest_selfsig(UserID::Primary))) {
  ------------------
  |  Branch (2075:9): [True: 47.0k, False: 0]
  |  Branch (2075:25): [True: 0, False: 47.0k]
  ------------------
 2076|      0|        has_expired = expired_with(*prisig, now);
 2077|      0|        has_cert = !has_expired;
 2078|      0|    }
 2079|       |    /* if we don't have direct-key sig and primary uid, use the latest self-cert */
 2080|  47.0k|    Signature *latest = nullptr;
 2081|  47.0k|    if (!dirsig && !prisig && (latest = latest_selfsig(UserID::Any))) {
  ------------------
  |  Branch (2081:9): [True: 47.0k, False: 0]
  |  Branch (2081:20): [True: 47.0k, False: 0]
  |  Branch (2081:31): [True: 786, False: 46.2k]
  ------------------
 2082|    786|        has_expired = expired_with(*latest, now);
 2083|    786|        has_cert = !has_expired;
 2084|    786|    }
 2085|       |
 2086|       |    /* we have at least one non-expiring key self-signature */
 2087|  47.0k|    if (has_cert) {
  ------------------
  |  Branch (2087:9): [True: 760, False: 46.2k]
  ------------------
 2088|    760|        validity_.valid = true;
 2089|    760|        return;
 2090|    760|    }
 2091|       |    /* we have valid self-signature which expires key */
 2092|  46.2k|    if (has_expired) {
  ------------------
  |  Branch (2092:9): [True: 26, False: 46.2k]
  ------------------
 2093|     26|        validity_.expired = true;
 2094|     26|        return;
 2095|     26|    }
 2096|       |
 2097|       |    /* let's check whether key has at least one valid subkey binding */
 2098|   135k|    for (size_t i = 0; i < subkey_count(); i++) {
  ------------------
  |  Branch (2098:24): [True: 89.0k, False: 46.1k]
  ------------------
 2099|  89.0k|        Key *sub = keyring.get_subkey(*this, i);
 2100|  89.0k|        if (!sub) {
  ------------------
  |  Branch (2100:13): [True: 38.7k, False: 50.2k]
  ------------------
 2101|  38.7k|            continue;
 2102|  38.7k|        }
 2103|  50.2k|        sub->validate_self_signatures(*this, keyring.secctx);
 2104|  50.2k|        auto sig = sub->latest_binding();
 2105|  50.2k|        if (!sig) {
  ------------------
  |  Branch (2105:13): [True: 50.1k, False: 68]
  ------------------
 2106|  50.1k|            continue;
 2107|  50.1k|        }
 2108|       |        /* check whether subkey is expired - then do not mark key as valid */
 2109|     68|        if (sub->expired_with(*sig, now)) {
  ------------------
  |  Branch (2109:13): [True: 2, False: 66]
  ------------------
 2110|      2|            continue;
 2111|      2|        }
 2112|     66|        validity_.valid = true;
 2113|     66|        return;
 2114|     68|    }
 2115|  46.2k|}
_ZN3rnp3Key15validate_subkeyEPS0_RKNS_15SecurityContextE:
 2119|  54.7k|{
 2120|       |    /* consider subkey as valid on this level if it has valid primary key, its latest binding
 2121|       |     * signature is not expired, and it is not revoked. */
 2122|  54.7k|    validity_.reset();
 2123|  54.7k|    validity_.validated = true;
 2124|  54.7k|    if (!primary || (!primary->valid() && !primary->expired())) {
  ------------------
  |  Branch (2124:9): [True: 2.20k, False: 52.5k]
  |  Branch (2124:22): [True: 50.1k, False: 2.33k]
  |  Branch (2124:43): [True: 50.1k, False: 24]
  ------------------
 2125|  52.3k|        return;
 2126|  52.3k|    }
 2127|       |    /* validate signatures if needed */
 2128|  2.35k|    validate_self_signatures(*primary, ctx);
 2129|       |
 2130|  2.35k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2130:22): [True: 1.03k, False: 2.35k]
  ------------------
 2131|  1.03k|        auto &sig = get_sig(sigid);
 2132|  1.03k|        if (sig.validity.valid() && is_revocation(sig) && is_authorized(sig)) {
  ------------------
  |  Branch (2132:13): [True: 128, False: 910]
  |  Branch (2132:37): [True: 0, False: 128]
  |  Branch (2132:59): [True: 0, False: 0]
  ------------------
 2133|      0|            return;
 2134|      0|        }
 2135|  1.03k|    }
 2136|       |    /* expiration is taken from the latest binding, see refresh_data() */
 2137|  2.35k|    auto binding = latest_binding();
 2138|  2.35k|    if (!binding) {
  ------------------
  |  Branch (2138:9): [True: 2.22k, False: 128]
  ------------------
 2139|  2.22k|        return;
 2140|  2.22k|    }
 2141|    128|    if (expired_with(*binding, ctx.time())) {
  ------------------
  |  Branch (2141:9): [True: 4, False: 124]
  ------------------
 2142|      4|        validity_.expired = true;
 2143|      4|        return;
 2144|      4|    }
 2145|    124|    validity_.valid = primary->valid();
 2146|    124|}
_ZN3rnp3Key8validateERNS_8KeyStoreE:
 2150|  47.0k|{
 2151|  47.0k|    validity_.reset();
 2152|  47.0k|    if (!is_subkey()) {
  ------------------
  |  Branch (2152:9): [True: 47.0k, False: 0]
  ------------------
 2153|  47.0k|        validate_primary(keyring);
 2154|  47.0k|        return;
 2155|  47.0k|    }
 2156|      0|    Key *primary = nullptr;
 2157|      0|    if (has_primary_fp()) {
  ------------------
  |  Branch (2157:9): [True: 0, False: 0]
  ------------------
 2158|      0|        primary = keyring.get_key(primary_fp());
 2159|      0|    }
 2160|      0|    validate_subkey(primary, keyring.secctx);
 2161|      0|}
_ZN3rnp3Key10revalidateERNS_8KeyStoreE:
 2165|  56.9k|{
 2166|  56.9k|    if (is_subkey()) {
  ------------------
  |  Branch (2166:9): [True: 9.94k, False: 47.0k]
  ------------------
 2167|  9.94k|        Key *primary = keyring.primary_key(*this);
 2168|  9.94k|        if (primary) {
  ------------------
  |  Branch (2168:13): [True: 8.35k, False: 1.59k]
  ------------------
 2169|  8.35k|            primary->revalidate(keyring);
 2170|  8.35k|        } else {
 2171|  1.59k|            validate_subkey(NULL, keyring.secctx);
 2172|  1.59k|        }
 2173|  9.94k|        return;
 2174|  9.94k|    }
 2175|       |
 2176|  47.0k|    validate_desig_revokes(keyring);
 2177|  47.0k|    validate(keyring);
 2178|  47.0k|    if (!refresh_data(keyring.secctx)) {
  ------------------
  |  Branch (2178:9): [True: 0, False: 47.0k]
  ------------------
 2179|      0|        RNP_LOG("Failed to refresh key data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2180|      0|    }
 2181|       |    /* validate/re-validate all subkeys as well */
 2182|  92.0k|    for (auto &fp : subkey_fps_) {
  ------------------
  |  Branch (2182:19): [True: 92.0k, False: 47.0k]
  ------------------
 2183|  92.0k|        Key *subkey = keyring.get_key(fp);
 2184|  92.0k|        if (subkey) {
  ------------------
  |  Branch (2184:13): [True: 52.5k, False: 39.5k]
  ------------------
 2185|  52.5k|            subkey->validate_subkey(this, keyring.secctx);
 2186|  52.5k|            if (!subkey->refresh_data(this, keyring.secctx)) {
  ------------------
  |  Branch (2186:17): [True: 0, False: 52.5k]
  ------------------
 2187|      0|                RNP_LOG("Failed to refresh subkey data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2188|      0|            }
 2189|  52.5k|        }
 2190|  92.0k|    }
 2191|  47.0k|}
_ZN3rnp3Key16refresh_revokersEv:
 2433|   132k|{
 2434|   132k|    revokers_.clear();
 2435|   353k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2435:22): [True: 353k, False: 132k]
  ------------------
 2436|   353k|        auto &sig = get_sig(sigid);
 2437|       |        /* pick designated revokers only from direct-key signatures */
 2438|   353k|        if (!sig.validity.valid() || !is_direct_self(sig)) {
  ------------------
  |  Branch (2438:13): [True: 330k, False: 23.3k]
  |  Branch (2438:38): [True: 23.3k, False: 0]
  ------------------
 2439|   353k|            continue;
 2440|   353k|        }
 2441|      0|        if (!sig.sig.has_revoker()) {
  ------------------
  |  Branch (2441:13): [True: 0, False: 0]
  ------------------
 2442|      0|            continue;
 2443|      0|        }
 2444|      0|        add_revoker(sig.sig.revoker());
 2445|      0|    }
 2446|   132k|}
_ZN3rnp3Key19refresh_revocationsEv:
 2450|  85.8k|{
 2451|  85.8k|    clear_revokes();
 2452|   234k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2452:22): [True: 234k, False: 85.8k]
  ------------------
 2453|   234k|        auto &sig = get_sig(sigid);
 2454|   234k|        if (!sig.validity.valid() || !is_authorized(sig)) {
  ------------------
  |  Branch (2454:13): [True: 218k, False: 15.4k]
  |  Branch (2454:38): [True: 0, False: 15.4k]
  ------------------
 2455|   218k|            continue;
 2456|   218k|        }
 2457|  15.4k|        if (is_revocation(sig)) {
  ------------------
  |  Branch (2457:13): [True: 0, False: 15.4k]
  ------------------
 2458|      0|            update_revocation(sig);
 2459|      0|            continue;
 2460|      0|        }
 2461|  15.4k|        if (is_uid_revocation(sig)) {
  ------------------
  |  Branch (2461:13): [True: 13.9k, False: 1.49k]
  ------------------
 2462|  13.9k|            if (sig.uid >= uid_count()) {
  ------------------
  |  Branch (2462:17): [True: 0, False: 13.9k]
  ------------------
 2463|      0|                RNP_LOG("Invalid uid index");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2464|      0|                continue;
 2465|      0|            }
 2466|  13.9k|            auto &uid = get_uid(sig.uid);
 2467|  13.9k|            if (uid.revoked) {
  ------------------
  |  Branch (2467:17): [True: 5.40k, False: 8.50k]
  ------------------
 2468|  5.40k|                continue;
 2469|  5.40k|            }
 2470|  8.50k|            uid.revoked = true;
 2471|  8.50k|            uid.revocation = Revocation(sig);
 2472|  8.50k|        }
 2473|  15.4k|    }
 2474|  85.8k|}
_ZN3rnp3Key12refresh_dataERKNS_15SecurityContextE:
 2478|  86.2k|{
 2479|  86.2k|    if (!is_primary()) {
  ------------------
  |  Branch (2479:9): [True: 414, False: 85.8k]
  ------------------
 2480|    414|        RNP_LOG("key must be primary");
  ------------------
  |  |   84|    414|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    414|    do {                                                                                 \
  |  |  |  |   77|    414|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 414, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    414|            break;                                                                       \
  |  |  |  |   79|    414|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2481|    414|        return false;
 2482|    414|    }
 2483|       |    /* validate self-signatures if not done yet */
 2484|  85.8k|    validate_self_signatures(ctx);
 2485|       |    /* key expiration */
 2486|  85.8k|    expiration_ = 0;
 2487|       |    /* if we have direct-key signature, then it has higher priority */
 2488|  85.8k|    auto dirsig = latest_selfsig(UserID::None);
 2489|  85.8k|    if (dirsig) {
  ------------------
  |  Branch (2489:9): [True: 0, False: 85.8k]
  ------------------
 2490|      0|        expiration_ = dirsig->sig.key_expiration();
 2491|      0|    }
 2492|       |    /* if we have primary uid and it is more restrictive, then use it as well */
 2493|  85.8k|    auto prisig = latest_selfsig(UserID::Primary);
 2494|  85.8k|    if (prisig && prisig->sig.key_expiration() &&
  ------------------
  |  Branch (2494:9): [True: 0, False: 85.8k]
  |  Branch (2494:19): [True: 0, False: 0]
  ------------------
 2495|      0|        (!expiration_ || (prisig->sig.key_expiration() < expiration_))) {
  ------------------
  |  Branch (2495:10): [True: 0, False: 0]
  |  Branch (2495:26): [True: 0, False: 0]
  ------------------
 2496|      0|        expiration_ = prisig->sig.key_expiration();
 2497|      0|    }
 2498|       |    /* if we don't have direct-key sig and primary uid, use the latest self-cert */
 2499|  85.8k|    auto latest = latest_selfsig(UserID::Any);
 2500|  85.8k|    if (!dirsig && !prisig && latest) {
  ------------------
  |  Branch (2500:9): [True: 85.8k, False: 0]
  |  Branch (2500:20): [True: 85.8k, False: 0]
  |  Branch (2500:31): [True: 1.30k, False: 84.5k]
  ------------------
 2501|  1.30k|        expiration_ = latest->sig.key_expiration();
 2502|  1.30k|    }
 2503|       |    /* key flags: check in direct-key sig first, then primary uid, and then latest */
 2504|  85.8k|    if (dirsig && dirsig->sig.has_subpkt(PGP_SIG_SUBPKT_KEY_FLAGS)) {
  ------------------
  |  Branch (2504:9): [True: 0, False: 85.8k]
  |  Branch (2504:19): [True: 0, False: 0]
  ------------------
 2505|      0|        flags_ = dirsig->sig.key_flags();
 2506|  85.8k|    } else if (prisig && prisig->sig.has_subpkt(PGP_SIG_SUBPKT_KEY_FLAGS)) {
  ------------------
  |  Branch (2506:16): [True: 0, False: 85.8k]
  |  Branch (2506:26): [True: 0, False: 0]
  ------------------
 2507|      0|        flags_ = prisig->sig.key_flags();
 2508|  85.8k|    } else if (latest && latest->sig.has_subpkt(PGP_SIG_SUBPKT_KEY_FLAGS)) {
  ------------------
  |  Branch (2508:16): [True: 1.30k, False: 84.5k]
  |  Branch (2508:26): [True: 1.30k, False: 0]
  ------------------
 2509|  1.30k|        flags_ = latest->sig.key_flags();
 2510|  84.5k|    } else {
 2511|  84.5k|        flags_ = pgp_pk_alg_capabilities(alg());
 2512|  84.5k|    }
 2513|       |    /* designated revokers */
 2514|  85.8k|    refresh_revokers();
 2515|       |    /* revocation(s) */
 2516|  85.8k|    refresh_revocations();
 2517|       |    /* valid till */
 2518|  85.8k|    valid_till_ = valid_till_common(expired());
 2519|       |    /* userid validities */
 2520|   769k|    for (auto &uid : uids_) {
  ------------------
  |  Branch (2520:20): [True: 769k, False: 85.8k]
  ------------------
 2521|   769k|        uid.valid = false;
 2522|   769k|    }
 2523|   234k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2523:22): [True: 234k, False: 85.8k]
  ------------------
 2524|   234k|        auto &sig = get_sig(sigid);
 2525|       |        /* consider userid as valid if it has at least one non-expired self-sig */
 2526|   234k|        if (!sig.validity.valid() || !sig.is_cert() || !is_signer(sig) ||
  ------------------
  |  Branch (2526:13): [True: 218k, False: 15.4k]
  |  Branch (2526:38): [True: 13.9k, False: 1.49k]
  |  Branch (2526:56): [True: 0, False: 1.49k]
  ------------------
 2527|   232k|            sig.expired(ctx.time())) {
  ------------------
  |  Branch (2527:13): [True: 0, False: 1.49k]
  ------------------
 2528|   232k|            continue;
 2529|   232k|        }
 2530|  1.49k|        if (sig.uid >= uid_count()) {
  ------------------
  |  Branch (2530:13): [True: 0, False: 1.49k]
  ------------------
 2531|      0|            continue;
 2532|      0|        }
 2533|  1.49k|        get_uid(sig.uid).valid = true;
 2534|  1.49k|    }
 2535|       |    /* check whether uid is revoked */
 2536|   769k|    for (auto &uid : uids_) {
  ------------------
  |  Branch (2536:20): [True: 769k, False: 85.8k]
  ------------------
 2537|   769k|        if (uid.revoked) {
  ------------------
  |  Branch (2537:13): [True: 8.50k, False: 761k]
  ------------------
 2538|  8.50k|            uid.valid = false;
 2539|  8.50k|        }
 2540|   769k|    }
 2541|       |    /* primary userid: use latest one which is not overridden by later non-primary selfsig */
 2542|  85.8k|    uid0_set_ = false;
 2543|  85.8k|    if (prisig && get_uid(prisig->uid).valid) {
  ------------------
  |  Branch (2543:9): [True: 0, False: 85.8k]
  |  Branch (2543:19): [True: 0, False: 0]
  ------------------
 2544|      0|        uid0_ = prisig->uid;
 2545|      0|        uid0_set_ = true;
 2546|      0|    }
 2547|  85.8k|    return true;
 2548|  86.2k|}
_ZN3rnp3Key12refresh_dataEPS0_RKNS_15SecurityContextE:
 2552|  72.4k|{
 2553|       |    /* validate self-signatures if not done yet */
 2554|  72.4k|    if (primary) {
  ------------------
  |  Branch (2554:9): [True: 70.2k, False: 2.20k]
  ------------------
 2555|  70.2k|        validate_self_signatures(*primary, ctx);
 2556|  70.2k|    }
 2557|  72.4k|    auto sig = latest_binding(primary);
 2558|       |    /* subkey expiration */
 2559|  72.4k|    expiration_ = sig ? sig->sig.key_expiration() : 0;
  ------------------
  |  Branch (2559:19): [True: 1.39k, False: 71.0k]
  ------------------
 2560|       |    /* subkey flags */
 2561|  72.4k|    if (sig && sig->sig.has_subpkt(PGP_SIG_SUBPKT_KEY_FLAGS)) {
  ------------------
  |  Branch (2561:9): [True: 1.39k, False: 71.0k]
  |  Branch (2561:16): [True: 319, False: 1.07k]
  ------------------
 2562|    319|        flags_ = sig->sig.key_flags();
 2563|  72.1k|    } else {
 2564|  72.1k|        flags_ = pgp_pk_alg_capabilities(alg());
 2565|  72.1k|    }
 2566|       |    /* revocation */
 2567|  72.4k|    clear_revokes();
 2568|  72.4k|    for (auto &sigid : sigs_) {
  ------------------
  |  Branch (2568:22): [True: 51.4k, False: 72.4k]
  ------------------
 2569|  51.4k|        auto &rev = get_sig(sigid);
 2570|  51.4k|        if (!rev.validity.valid() || !is_revocation(rev) || !is_authorized(rev)) {
  ------------------
  |  Branch (2570:13): [True: 51.1k, False: 316]
  |  Branch (2570:38): [True: 316, False: 0]
  |  Branch (2570:61): [True: 0, False: 0]
  ------------------
 2571|  51.4k|            continue;
 2572|  51.4k|        }
 2573|      0|        try {
 2574|      0|            update_revocation(rev);
 2575|      0|        } catch (const std::exception &e) {
 2576|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2577|      0|            return false;
 2578|      0|        }
 2579|      0|    }
 2580|       |    /* valid till */
 2581|  72.4k|    if (primary) {
  ------------------
  |  Branch (2581:9): [True: 70.2k, False: 2.20k]
  ------------------
 2582|  70.2k|        valid_till_ =
 2583|  70.2k|          std::min(primary->valid_till(), valid_till_common(expired() || primary->expired()));
  ------------------
  |  Branch (2583:61): [True: 6, False: 70.2k]
  |  Branch (2583:74): [True: 28, False: 70.1k]
  ------------------
 2584|  70.2k|    } else {
 2585|  2.20k|        valid_till_ = valid_till_common(expired());
 2586|  2.20k|    }
 2587|  72.4k|    return true;
 2588|  72.4k|}
_ZN3rnp3Key14merge_validityERK14pgp_validity_t:
 2592|  21.6k|{
 2593|  21.6k|    validity_.valid = validity_.valid && src.valid;
  ------------------
  |  Branch (2593:23): [True: 283, False: 21.3k]
  |  Branch (2593:42): [True: 0, False: 283]
  ------------------
 2594|       |    /* We may safely leave validated status only if both merged keys are valid && validated.
 2595|       |     * Otherwise we'll need to revalidate. For instance, one validated but invalid key may add
 2596|       |     * revocation signature, or valid key may add certification to the invalid one. */
 2597|  21.6k|    validity_.validated = validity_.valid && validity_.validated && src.validated;
  ------------------
  |  Branch (2597:27): [True: 0, False: 21.6k]
  |  Branch (2597:46): [True: 0, False: 0]
  |  Branch (2597:69): [True: 0, False: 0]
  ------------------
 2598|       |    /* if expired is true at least in one case then valid and validated are false */
 2599|  21.6k|    validity_.expired = false;
 2600|  21.6k|}
_ZN3rnp3Key5mergeERKS0_:
 2604|  15.5k|{
 2605|  15.5k|    assert(!is_subkey());
 2606|  15.5k|    assert(!src.is_subkey());
 2607|       |
 2608|       |    /* if src is secret key then merged key will become secret as well. */
 2609|  15.5k|    if (src.is_secret() && !is_secret()) {
  ------------------
  |  Branch (2609:9): [True: 3.52k, False: 12.0k]
  |  Branch (2609:28): [True: 46, False: 3.47k]
  ------------------
 2610|     46|        pkt_ = src.pkt();
 2611|     46|        rawpkt_ = src.rawpkt();
 2612|       |        /* no subkey processing here - they are separated from the main key */
 2613|     46|    }
 2614|       |
 2615|       |    /* merge direct-key signatures */
 2616|  15.5k|    for (auto &sigid : src.keysigs_) {
  ------------------
  |  Branch (2616:22): [True: 2.43k, False: 15.5k]
  ------------------
 2617|  2.43k|        if (has_sig(sigid)) {
  ------------------
  |  Branch (2617:13): [True: 1.86k, False: 571]
  ------------------
 2618|  1.86k|            continue;
 2619|  1.86k|        }
 2620|    571|        add_sig(src.get_sig(sigid).sig);
 2621|    571|    }
 2622|       |
 2623|       |    /* merge user ids and their signatures */
 2624|   287k|    for (auto &srcuid : src.uids_) {
  ------------------
  |  Branch (2624:23): [True: 287k, False: 15.5k]
  ------------------
 2625|       |        /* check whether we have this uid and add if needed */
 2626|   287k|        auto uididx = uid_idx(srcuid.pkt);
 2627|   287k|        if (uididx == UserID::None) {
  ------------------
  |  Branch (2627:13): [True: 2.22k, False: 284k]
  ------------------
 2628|  2.22k|            uididx = uid_count();
 2629|  2.22k|            uids_.emplace_back(srcuid.pkt);
 2630|  2.22k|        }
 2631|       |        /* add uid signatures */
 2632|   301k|        for (size_t idx = 0; idx < srcuid.sig_count(); idx++) {
  ------------------
  |  Branch (2632:30): [True: 13.9k, False: 287k]
  ------------------
 2633|  13.9k|            auto &sigid = srcuid.get_sig(idx);
 2634|  13.9k|            if (has_sig(sigid)) {
  ------------------
  |  Branch (2634:17): [True: 8.94k, False: 4.96k]
  ------------------
 2635|  8.94k|                continue;
 2636|  8.94k|            }
 2637|  4.96k|            add_sig(src.get_sig(sigid).sig, uididx);
 2638|  4.96k|        }
 2639|   287k|    }
 2640|       |
 2641|       |    /* Update subkey fingerprints */
 2642|  15.5k|    for (auto &fp : src.subkey_fps()) {
  ------------------
  |  Branch (2642:19): [True: 1.48k, False: 15.5k]
  ------------------
 2643|  1.48k|        add_subkey_fp(fp);
 2644|  1.48k|    }
 2645|       |
 2646|       |    /* check whether key was unlocked and assign secret key data */
 2647|  15.5k|    if (src.is_secret() && !src.is_locked() && (!is_secret() || is_locked())) {
  ------------------
  |  Branch (2647:9): [True: 3.52k, False: 12.0k]
  |  Branch (2647:28): [True: 0, False: 3.52k]
  |  Branch (2647:49): [True: 0, False: 0]
  |  Branch (2647:65): [True: 0, False: 0]
  ------------------
 2648|      0|        pkt().material = src.pkt().material->clone();
 2649|      0|    }
 2650|       |    /* copy validity status */
 2651|  15.5k|    merge_validity(src.validity_);
 2652|  15.5k|    return true;
 2653|  15.5k|}
_ZN3rnp3Key5mergeERKS0_PS0_:
 2657|  6.05k|{
 2658|  6.05k|    assert(is_subkey());
 2659|  6.05k|    assert(src.is_subkey());
 2660|       |
 2661|       |    /* if src is secret key then merged key will become secret as well. */
 2662|  6.05k|    if (src.is_secret() && !is_secret()) {
  ------------------
  |  Branch (2662:9): [True: 2.74k, False: 3.31k]
  |  Branch (2662:28): [True: 29, False: 2.71k]
  ------------------
 2663|     29|        pkt_ = src.pkt();
 2664|     29|        rawpkt_ = src.rawpkt();
 2665|     29|    }
 2666|       |
 2667|       |    /* add subkey binding signatures */
 2668|  6.05k|    for (auto &sigid : src.keysigs_) {
  ------------------
  |  Branch (2668:22): [True: 1.99k, False: 6.05k]
  ------------------
 2669|  1.99k|        if (has_sig(sigid)) {
  ------------------
  |  Branch (2669:13): [True: 1.54k, False: 443]
  ------------------
 2670|  1.54k|            continue;
 2671|  1.54k|        }
 2672|    443|        add_sig(src.get_sig(sigid).sig);
 2673|    443|    }
 2674|       |
 2675|       |    /* check whether key was unlocked and assign secret key data */
 2676|  6.05k|    if (src.is_secret() && !src.is_locked() && (!is_secret() || is_locked())) {
  ------------------
  |  Branch (2676:9): [True: 2.74k, False: 3.31k]
  |  Branch (2676:28): [True: 0, False: 2.74k]
  |  Branch (2676:49): [True: 0, False: 0]
  |  Branch (2676:65): [True: 0, False: 0]
  ------------------
 2677|      0|        pkt().material = src.pkt().material->clone();
 2678|      0|    }
 2679|       |    /* copy validity status */
 2680|  6.05k|    merge_validity(src.validity_);
 2681|       |    /* link subkey fps */
 2682|  6.05k|    if (primary) {
  ------------------
  |  Branch (2682:9): [True: 5.58k, False: 472]
  ------------------
 2683|  5.58k|        primary->link_subkey_fp(*this);
 2684|  5.58k|    }
 2685|  6.05k|    return true;
 2686|  6.05k|}
_Z23pgp_pk_alg_capabilities16pgp_pubkey_alg_t:
 2691|   156k|{
 2692|   156k|    switch (alg) {
 2693|  4.49k|    case PGP_PKA_RSA:
  ------------------
  |  Branch (2693:5): [True: 4.49k, False: 152k]
  ------------------
 2694|  4.49k|        return pgp_key_flags_t(PGP_KF_SIGN | PGP_KF_CERTIFY | PGP_KF_AUTH | PGP_KF_ENCRYPT);
 2695|       |
 2696|  7.86k|    case PGP_PKA_RSA_SIGN_ONLY:
  ------------------
  |  Branch (2696:5): [True: 7.86k, False: 148k]
  ------------------
 2697|       |        // deprecated, but still usable
 2698|  7.86k|        return PGP_KF_SIGN;
 2699|       |
 2700|  24.0k|    case PGP_PKA_RSA_ENCRYPT_ONLY:
  ------------------
  |  Branch (2700:5): [True: 24.0k, False: 132k]
  ------------------
 2701|       |        // deprecated, but still usable
 2702|  24.0k|        return PGP_KF_ENCRYPT;
 2703|       |
 2704|    568|    case PGP_PKA_ELGAMAL_ENCRYPT_OR_SIGN: /* deprecated */
  ------------------
  |  Branch (2704:5): [True: 568, False: 156k]
  ------------------
 2705|       |        // These are no longer permitted per the RFC
 2706|    568|        return PGP_KF_NONE;
 2707|       |
 2708|  1.94k|    case PGP_PKA_DSA:
  ------------------
  |  Branch (2708:5): [True: 1.94k, False: 154k]
  ------------------
 2709|  16.6k|    case PGP_PKA_ECDSA:
  ------------------
  |  Branch (2709:5): [True: 14.7k, False: 141k]
  ------------------
 2710|  55.9k|    case PGP_PKA_EDDSA:
  ------------------
  |  Branch (2710:5): [True: 39.2k, False: 117k]
  ------------------
 2711|  55.9k|        return pgp_key_flags_t(PGP_KF_SIGN | PGP_KF_CERTIFY | PGP_KF_AUTH);
 2712|       |
 2713|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 2714|  5.74k|    case PGP_PKA_ED25519:
  ------------------
  |  Branch (2714:5): [True: 5.74k, False: 150k]
  ------------------
 2715|  6.25k|    case PGP_PKA_ED448:
  ------------------
  |  Branch (2715:5): [True: 511, False: 156k]
  ------------------
 2716|  6.25k|        return pgp_key_flags_t(PGP_KF_SIGN | PGP_KF_CERTIFY | PGP_KF_AUTH);
 2717|  10.9k|    case PGP_PKA_X25519:
  ------------------
  |  Branch (2717:5): [True: 10.9k, False: 145k]
  ------------------
 2718|  15.3k|    case PGP_PKA_X448:
  ------------------
  |  Branch (2718:5): [True: 4.33k, False: 152k]
  ------------------
 2719|  15.3k|        return PGP_KF_ENCRYPT;
 2720|      0|#endif
 2721|       |
 2722|     86|    case PGP_PKA_SM2:
  ------------------
  |  Branch (2722:5): [True: 86, False: 156k]
  ------------------
 2723|     86|        return pgp_key_flags_t(PGP_KF_SIGN | PGP_KF_CERTIFY | PGP_KF_AUTH | PGP_KF_ENCRYPT);
 2724|       |
 2725|  19.9k|    case PGP_PKA_ECDH:
  ------------------
  |  Branch (2725:5): [True: 19.9k, False: 136k]
  ------------------
 2726|  20.2k|    case PGP_PKA_ELGAMAL:
  ------------------
  |  Branch (2726:5): [True: 321, False: 156k]
  ------------------
 2727|  20.2k|        return PGP_KF_ENCRYPT;
 2728|       |
 2729|      0|#if defined(ENABLE_PQC)
 2730|      0|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (2730:5): [True: 0, False: 156k]
  ------------------
 2731|      0|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
 2732|      0|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|      0|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2733|      0|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (2733:5): [True: 0, False: 156k]
  ------------------
 2734|      0|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|      0|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2735|      8|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (2735:5): [True: 8, False: 156k]
  ------------------
 2736|      8|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|      8|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2737|     18|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (2737:5): [True: 10, False: 156k]
  ------------------
 2738|     18|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     18|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2739|     26|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (2739:5): [True: 8, False: 156k]
  ------------------
 2740|     26|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     26|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2741|     41|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (2741:5): [True: 15, False: 156k]
  ------------------
 2742|     41|#endif
 2743|     41|        return PGP_KF_ENCRYPT;
 2744|      0|#endif
 2745|       |
 2746|      0|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
 2747|     16|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (2747:5): [True: 16, False: 156k]
  ------------------
 2748|     16|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     16|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2749|     28|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (2749:5): [True: 12, False: 156k]
  ------------------
 2750|     28|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     28|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2751|     43|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (2751:5): [True: 15, False: 156k]
  ------------------
 2752|     43|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     43|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2753|     55|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (2753:5): [True: 12, False: 156k]
  ------------------
 2754|     55|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     55|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2755|     55|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (2755:5): [True: 0, False: 156k]
  ------------------
 2756|     55|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     55|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2757|     63|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (2757:5): [True: 8, False: 156k]
  ------------------
 2758|     63|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     63|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2759|  20.2k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (2759:5): [True: 20.2k, False: 136k]
  ------------------
 2760|  20.2k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  20.2k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2761|  20.6k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (2761:5): [True: 315, False: 156k]
  ------------------
 2762|  20.6k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  20.6k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 2763|  21.8k|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (2763:5): [True: 1.21k, False: 155k]
  ------------------
 2764|  21.8k|        return pgp_key_flags_t(PGP_KF_SIGN | PGP_KF_CERTIFY | PGP_KF_AUTH);
 2765|      0|#endif
 2766|       |
 2767|      0|    default:
  ------------------
  |  Branch (2767:5): [True: 0, False: 156k]
  ------------------
 2768|      0|        RNP_LOG("unknown pk alg: %d\n", alg);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2769|      0|        return PGP_KF_NONE;
 2770|   156k|    }
 2771|   156k|}
key.cpp:_ZN3rnpL9is_issuerERKN3pgp3pkt9SignatureERKNS0_11FingerprintE:
 1630|   149k|{
 1631|       |    /* A present issuer fingerprint is authoritative. A bad version octet must not
 1632|       |     * fall through to the key id, which is weaker and, for a parsed v5/v6 fingerprint,
 1633|       |     * may be all zeros. */
 1634|   149k|    if (sig.has_keyfp()) {
  ------------------
  |  Branch (1634:9): [True: 86.0k, False: 63.7k]
  ------------------
 1635|  86.0k|        return sig.issuer_fp_version_matches() && (sig.keyfp() == fp);
  ------------------
  |  Branch (1635:16): [True: 83.3k, False: 2.72k]
  |  Branch (1635:51): [True: 35.5k, False: 47.7k]
  ------------------
 1636|  86.0k|    }
 1637|  63.7k|    if (!sig.has_keyid()) {
  ------------------
  |  Branch (1637:9): [True: 3.17k, False: 60.5k]
  ------------------
 1638|  3.17k|        return false;
 1639|  3.17k|    }
 1640|  60.5k|    return fp.keyid() == sig.keyid();
 1641|  63.7k|}

_ZN3rnp3KeyC2Ev:
   90|  37.5k|    Key() = default;
_ZN3rnp3KeyaSEOS0_:
   97|  37.5k|    Key &operator=(Key &&) = default;

_ZN3pgp11KeyMaterialD2Ev:
  252|   261k|{
  253|   261k|}
_ZNK3pgp11KeyMaterial3algEv:
  257|  63.1k|{
  258|  63.1k|    return alg_;
  259|  63.1k|}
_ZNK3pgp11KeyMaterial6secretEv:
  263|  6.26k|{
  264|  6.26k|    return secret_;
  265|  6.26k|}
_ZNK3pgp11KeyMaterial8validityEv:
  291|  10.6k|{
  292|  10.6k|    return validity_;
  293|  10.6k|}
_ZN3pgp11KeyMaterial12set_validityERK14pgp_validity_t:
  297|  10.6k|{
  298|  10.6k|    validity_ = val;
  299|  10.6k|}
_ZN3pgp11KeyMaterial14reset_validityEv:
  303|    227|{
  304|    227|    validity_.reset();
  305|    227|}
_ZN3pgp11KeyMaterial12clear_secretEv:
  309|  20.3k|{
  310|  20.3k|    secret_ = false;
  311|  20.3k|}
_ZNK3pgp11KeyMaterial6verifyERKN3rnp15SecurityContextERKNS_11SigMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
  348|      2|{
  349|      2|    return RNP_ERROR_NOT_SUPPORTED;
  350|      2|}
_ZNK3pgp11KeyMaterial16sig_hash_allowedE14pgp_hash_alg_t:
  368|  11.3k|{
  369|  11.3k|    return true;
  370|  11.3k|}
_ZNK3pgp11KeyMaterial4gripEv:
  380|  35.2k|{
  381|  35.2k|    auto hash = rnp::Hash::create(PGP_HASH_SHA1);
  382|  35.2k|    grip_update(*hash);
  383|  35.2k|    KeyGrip res{};
  384|  35.2k|    hash->finish(res.data());
  385|  35.2k|    return res;
  386|  35.2k|}
_ZN3pgp11KeyMaterial6createE16pgp_pubkey_alg_t:
  390|  54.0k|{
  391|  54.0k|    switch (alg) {
  392|  3.63k|    case PGP_PKA_RSA:
  ------------------
  |  Branch (392:5): [True: 3.63k, False: 50.4k]
  ------------------
  393|  11.6k|    case PGP_PKA_RSA_ENCRYPT_ONLY:
  ------------------
  |  Branch (393:5): [True: 8.02k, False: 46.0k]
  ------------------
  394|  13.5k|    case PGP_PKA_RSA_SIGN_ONLY:
  ------------------
  |  Branch (394:5): [True: 1.91k, False: 52.1k]
  ------------------
  395|  13.5k|        return std::unique_ptr<KeyMaterial>(new RSAKeyMaterial(alg));
  396|    410|    case PGP_PKA_ELGAMAL:
  ------------------
  |  Branch (396:5): [True: 410, False: 53.6k]
  ------------------
  397|    618|    case PGP_PKA_ELGAMAL_ENCRYPT_OR_SIGN:
  ------------------
  |  Branch (397:5): [True: 208, False: 53.8k]
  ------------------
  398|    618|        return std::unique_ptr<KeyMaterial>(new EGKeyMaterial(alg));
  399|    629|    case PGP_PKA_DSA:
  ------------------
  |  Branch (399:5): [True: 629, False: 53.4k]
  ------------------
  400|    629|        return std::unique_ptr<KeyMaterial>(new DSAKeyMaterial());
  401|  4.23k|    case PGP_PKA_ECDH:
  ------------------
  |  Branch (401:5): [True: 4.23k, False: 49.8k]
  ------------------
  402|  4.23k|        return std::unique_ptr<KeyMaterial>(new ECDHKeyMaterial());
  403|  6.53k|    case PGP_PKA_ECDSA:
  ------------------
  |  Branch (403:5): [True: 6.53k, False: 47.5k]
  ------------------
  404|  6.53k|        return std::unique_ptr<KeyMaterial>(new ECDSAKeyMaterial());
  405|  18.0k|    case PGP_PKA_EDDSA:
  ------------------
  |  Branch (405:5): [True: 18.0k, False: 36.0k]
  ------------------
  406|  18.0k|        return std::unique_ptr<KeyMaterial>(new EDDSAKeyMaterial());
  407|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  408|    662|    case PGP_PKA_ED25519:
  ------------------
  |  Branch (408:5): [True: 662, False: 53.4k]
  ------------------
  409|    662|        return std::unique_ptr<KeyMaterial>(new Ed25519KeyMaterial());
  410|  2.87k|    case PGP_PKA_X25519:
  ------------------
  |  Branch (410:5): [True: 2.87k, False: 51.2k]
  ------------------
  411|  2.87k|        return std::unique_ptr<KeyMaterial>(new X25519KeyMaterial());
  412|    241|    case PGP_PKA_ED448:
  ------------------
  |  Branch (412:5): [True: 241, False: 53.8k]
  ------------------
  413|    241|        return std::unique_ptr<KeyMaterial>(new Ed448KeyMaterial());
  414|    879|    case PGP_PKA_X448:
  ------------------
  |  Branch (414:5): [True: 879, False: 53.2k]
  ------------------
  415|    879|        return std::unique_ptr<KeyMaterial>(new X448KeyMaterial());
  416|      0|#endif
  417|     64|    case PGP_PKA_SM2:
  ------------------
  |  Branch (417:5): [True: 64, False: 54.0k]
  ------------------
  418|     64|        return std::unique_ptr<KeyMaterial>(new SM2KeyMaterial());
  419|      0|#if defined(ENABLE_PQC)
  420|    142|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (420:5): [True: 142, False: 53.9k]
  ------------------
  421|    142|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
  422|    142|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    142|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  423|    155|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (423:5): [True: 13, False: 54.0k]
  ------------------
  424|    155|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    155|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  425|    197|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (425:5): [True: 42, False: 54.0k]
  ------------------
  426|    197|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    197|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  427|    216|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (427:5): [True: 19, False: 54.0k]
  ------------------
  428|    216|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    216|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  429|    234|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (429:5): [True: 18, False: 54.0k]
  ------------------
  430|    234|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    234|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  431|    292|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (431:5): [True: 58, False: 54.0k]
  ------------------
  432|    292|#endif
  433|    292|        return std::unique_ptr<KeyMaterial>(new MlkemEcdhKeyMaterial(alg));
  434|      0|#endif
  435|      0|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
  436|     68|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (436:5): [True: 68, False: 54.0k]
  ------------------
  437|     68|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     68|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  438|     95|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (438:5): [True: 27, False: 54.0k]
  ------------------
  439|     95|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     95|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  440|    677|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (440:5): [True: 582, False: 53.5k]
  ------------------
  441|    677|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    677|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  442|    700|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (442:5): [True: 23, False: 54.0k]
  ------------------
  443|    700|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    700|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  444|  1.04k|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (444:5): [True: 344, False: 53.7k]
  ------------------
  445|  1.04k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  1.04k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  446|  1.09k|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (446:5): [True: 54, False: 54.0k]
  ------------------
  447|  1.09k|        return std::unique_ptr<KeyMaterial>(new DilithiumEccKeyMaterial(alg));
  448|  1.69k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (448:5): [True: 1.69k, False: 52.3k]
  ------------------
  449|  1.69k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  1.69k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  450|  1.99k|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (450:5): [True: 291, False: 53.8k]
  ------------------
  451|  1.99k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  1.99k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  452|  2.75k|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (452:5): [True: 769, False: 53.3k]
  ------------------
  453|  2.75k|        return std::unique_ptr<KeyMaterial>(new SlhdsaKeyMaterial(alg));
  454|      0|#endif
  455|  1.58k|    default:
  ------------------
  |  Branch (455:5): [True: 1.58k, False: 52.5k]
  ------------------
  456|  1.58k|        return nullptr;
  457|  54.0k|    }
  458|  54.0k|}
_ZN3pgp14RSAKeyMaterial5cloneEv:
  497|  53.1k|{
  498|  53.1k|    return std::unique_ptr<KeyMaterial>(new RSAKeyMaterial(*this));
  499|  53.1k|}
_ZNK3pgp14RSAKeyMaterial11grip_updateERN3rnp4HashE:
  503|  8.19k|{
  504|       |    /* keygrip is subjectKeyHash from pkcs#15 for RSA. */
  505|  8.19k|    grip_hash_mpi(hash, key_.n, '\0');
  506|  8.19k|}
_ZN3pgp14RSAKeyMaterial12clear_secretEv:
  516|  5.28k|{
  517|  5.28k|    key_.clear_secret();
  518|  5.28k|    KeyMaterial::clear_secret();
  519|  5.28k|}
_ZN3pgp14RSAKeyMaterial5parseER17pgp_packet_body_t:
  523|  11.9k|{
  524|  11.9k|    secret_ = false;
  525|  11.9k|    return pkt.get(key_.n) && pkt.get(key_.e);
  ------------------
  |  Branch (525:12): [True: 11.6k, False: 276]
  |  Branch (525:31): [True: 11.3k, False: 253]
  ------------------
  526|  11.9k|}
_ZN3pgp14RSAKeyMaterial12parse_secretER17pgp_packet_body_t:
  530|     10|{
  531|     10|    if (!pkt.get(key_.d) || !pkt.get(key_.p) || !pkt.get(key_.q) || !pkt.get(key_.u)) {
  ------------------
  |  Branch (531:9): [True: 6, False: 4]
  |  Branch (531:29): [True: 1, False: 3]
  |  Branch (531:49): [True: 1, False: 2]
  |  Branch (531:69): [True: 1, False: 1]
  ------------------
  532|      9|        RNP_LOG("failed to parse rsa secret key data");
  ------------------
  |  |   84|      9|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      9|    do {                                                                                 \
  |  |  |  |   77|      9|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      9|            break;                                                                       \
  |  |  |  |   79|      9|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  533|      9|        return false;
  534|      9|    }
  535|      1|    secret_ = true;
  536|      1|    return true;
  537|     10|}
_ZNK3pgp14RSAKeyMaterial6verifyERKN3rnp15SecurityContextERKNS_11SigMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
  598|    446|{
  599|    446|    if (alg() == PGP_PKA_RSA_ENCRYPT_ONLY) {
  ------------------
  |  Branch (599:9): [True: 15, False: 431]
  ------------------
  600|     15|        RNP_LOG("RSA encrypt-only signature considered as invalid.");
  ------------------
  |  |   84|     15|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     15|    do {                                                                                 \
  |  |  |  |   77|     15|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     15|            break;                                                                       \
  |  |  |  |   79|     15|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  601|     15|        return RNP_ERROR_SIGNATURE_INVALID;
  602|     15|    }
  603|    431|    auto rsa = dynamic_cast<const RSASigMaterial *>(&sig);
  604|    431|    if (!rsa) {
  ------------------
  |  Branch (604:9): [True: 2, False: 429]
  ------------------
  605|      2|        return RNP_ERROR_BAD_PARAMETERS;
  606|      2|    }
  607|    429|    return key_.verify_pkcs1(rsa->sig, rsa->halg, hash);
  608|    431|}
_ZNK3pgp14RSAKeyMaterial1nEv:
  640|  25.2k|{
  641|  25.2k|    return key_.n;
  642|  25.2k|}
_ZNK3pgp14RSAKeyMaterial1eEv:
  646|  6.30k|{
  647|  6.30k|    return key_.e;
  648|  6.30k|}
_ZN3pgp14DSAKeyMaterial5cloneEv:
  676|  2.80k|{
  677|  2.80k|    return std::unique_ptr<KeyMaterial>(new DSAKeyMaterial(*this));
  678|  2.80k|}
_ZNK3pgp14DSAKeyMaterial11grip_updateERN3rnp4HashE:
  682|    522|{
  683|    522|    grip_hash_mpi(hash, key_.p, 'p');
  684|    522|    grip_hash_mpi(hash, key_.q, 'q');
  685|    522|    grip_hash_mpi(hash, key_.g, 'g');
  686|    522|    grip_hash_mpi(hash, key_.y, 'y');
  687|    522|}
_ZN3pgp14DSAKeyMaterial12clear_secretEv:
  697|    472|{
  698|    472|    key_.clear_secret();
  699|    472|    KeyMaterial::clear_secret();
  700|    472|}
_ZN3pgp14DSAKeyMaterial5parseER17pgp_packet_body_t:
  704|    628|{
  705|    628|    secret_ = false;
  706|    628|    return pkt.get(key_.p) && pkt.get(key_.q) && pkt.get(key_.g) && pkt.get(key_.y);
  ------------------
  |  Branch (706:12): [True: 614, False: 14]
  |  Branch (706:31): [True: 591, False: 23]
  |  Branch (706:50): [True: 572, False: 19]
  |  Branch (706:69): [True: 569, False: 3]
  ------------------
  707|    628|}
_ZN3pgp14DSAKeyMaterial12parse_secretER17pgp_packet_body_t:
  711|      2|{
  712|      2|    if (!pkt.get(key_.x)) {
  ------------------
  |  Branch (712:9): [True: 1, False: 1]
  ------------------
  713|      1|        RNP_LOG("failed to parse dsa secret key data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  714|      1|        return false;
  715|      1|    }
  716|      1|    secret_ = true;
  717|      1|    return true;
  718|      2|}
_ZNK3pgp14DSAKeyMaterial6verifyERKN3rnp15SecurityContextERKNS_11SigMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
  750|  1.09k|{
  751|  1.09k|    auto dsa = dynamic_cast<const DSASigMaterial *>(&sig);
  752|  1.09k|    if (!dsa) {
  ------------------
  |  Branch (752:9): [True: 9, False: 1.08k]
  ------------------
  753|      9|        return RNP_ERROR_BAD_PARAMETERS;
  754|      9|    }
  755|  1.08k|    return key_.verify(dsa->sig, hash);
  756|  1.09k|}
_ZN3pgp13EGKeyMaterial5cloneEv:
  831|  1.64k|{
  832|  1.64k|    return std::unique_ptr<KeyMaterial>(new EGKeyMaterial(*this));
  833|  1.64k|}
_ZNK3pgp13EGKeyMaterial11grip_updateERN3rnp4HashE:
  837|    300|{
  838|    300|    grip_hash_mpi(hash, key_.p, 'p');
  839|    300|    grip_hash_mpi(hash, key_.g, 'g');
  840|    300|    grip_hash_mpi(hash, key_.y, 'y');
  841|    300|}
_ZN3pgp13EGKeyMaterial12clear_secretEv:
  851|    207|{
  852|    207|    key_.clear_secret();
  853|    207|    KeyMaterial::clear_secret();
  854|    207|}
_ZN3pgp13EGKeyMaterial5parseER17pgp_packet_body_t:
  858|    579|{
  859|    579|    secret_ = false;
  860|    579|    return pkt.get(key_.p) && pkt.get(key_.g) && pkt.get(key_.y);
  ------------------
  |  Branch (860:12): [True: 376, False: 203]
  |  Branch (860:31): [True: 330, False: 46]
  |  Branch (860:50): [True: 326, False: 4]
  ------------------
  861|    579|}
_ZN3pgp13EGKeyMaterial12parse_secretER17pgp_packet_body_t:
  865|      2|{
  866|      2|    if (!pkt.get(key_.x)) {
  ------------------
  |  Branch (866:9): [True: 1, False: 1]
  ------------------
  867|      1|        RNP_LOG("failed to parse eg secret key data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  868|      1|        return false;
  869|      1|    }
  870|      1|    secret_ = true;
  871|      1|    return true;
  872|      2|}
_ZNK3pgp13EGKeyMaterial7encryptERN3rnp15SecurityContextERNS_11EncMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
  907|     41|{
  908|     41|    auto eg = dynamic_cast<EGEncMaterial *>(&out);
  909|     41|    if (!eg) {
  ------------------
  |  Branch (909:9): [True: 0, False: 41]
  ------------------
  910|      0|        return RNP_ERROR_BAD_PARAMETERS;
  911|      0|    }
  912|     41|    return key_.encrypt_pkcs1(ctx.rng, eg->enc, data);
  913|     41|}
_ZNK3pgp13ECKeyMaterial11grip_updateERN3rnp4HashE:
  975|  21.2k|{
  976|  21.2k|    grip_hash_ec(hash, key_);
  977|  21.2k|}
_ZN3pgp13ECKeyMaterial12clear_secretEv:
  981|  9.10k|{
  982|  9.10k|    key_.clear_secret();
  983|  9.10k|    KeyMaterial::clear_secret();
  984|  9.10k|}
_ZN3pgp13ECKeyMaterial5parseER17pgp_packet_body_t:
 1008|  28.8k|{
 1009|  28.8k|    secret_ = false;
 1010|  28.8k|    if (!pkt.get(key_.curve) || !pkt.get(key_.p)) {
  ------------------
  |  Branch (1010:9): [True: 1.59k, False: 27.2k]
  |  Branch (1010:33): [True: 176, False: 27.1k]
  ------------------
 1011|  1.76k|        return false;
 1012|  1.76k|    }
 1013|  27.1k|    return true;
 1014|  28.8k|}
_ZN3pgp13ECKeyMaterial12parse_secretER17pgp_packet_body_t:
 1018|      3|{
 1019|      3|    if (!pkt.get(key_.x)) {
  ------------------
  |  Branch (1019:9): [True: 1, False: 2]
  ------------------
 1020|      1|        RNP_LOG("failed to parse ecc secret key data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1021|      1|        return false;
 1022|      1|    }
 1023|      2|    secret_ = true;
 1024|      2|    return true;
 1025|      3|}
_ZN3pgp16ECDSAKeyMaterial5cloneEv:
 1101|  23.8k|{
 1102|  23.8k|    return std::unique_ptr<KeyMaterial>(new ECDSAKeyMaterial(*this));
 1103|  23.8k|}
_ZNK3pgp16ECDSAKeyMaterial6verifyERKN3rnp15SecurityContextERKNS_11SigMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
 1109|  6.32k|{
 1110|  6.32k|    if (!ec::Curve::is_supported(key_.curve)) {
  ------------------
  |  Branch (1110:9): [True: 0, False: 6.32k]
  ------------------
 1111|      0|        RNP_LOG("Curve %d is not supported.", key_.curve);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1112|      0|        return RNP_ERROR_NOT_SUPPORTED;
 1113|      0|    }
 1114|  6.32k|    auto ec = dynamic_cast<const ECSigMaterial *>(&sig);
 1115|  6.32k|    if (!ec) {
  ------------------
  |  Branch (1115:9): [True: 23, False: 6.29k]
  ------------------
 1116|     23|        return RNP_ERROR_BAD_PARAMETERS;
 1117|     23|    }
 1118|  6.29k|    return ecdsa::verify(ec->sig, ec->halg, hash, key_);
 1119|  6.32k|}
_ZN3pgp15ECDHKeyMaterial5cloneEv:
 1160|  19.7k|{
 1161|  19.7k|    return std::unique_ptr<KeyMaterial>(new ECDHKeyMaterial(*this));
 1162|  19.7k|}
_ZN3pgp15ECDHKeyMaterial5parseER17pgp_packet_body_t:
 1166|  4.23k|{
 1167|  4.23k|    if (!ECKeyMaterial::parse(pkt)) {
  ------------------
  |  Branch (1167:9): [True: 219, False: 4.01k]
  ------------------
 1168|    219|        return false;
 1169|    219|    }
 1170|       |    /* Additional ECDH fields */
 1171|       |    /* Read KDF parameters. At the moment should be 0x03 0x01 halg ealg */
 1172|  4.01k|    uint8_t len = 0, halg = 0, walg = 0;
 1173|  4.01k|    if (!pkt.get(len) || (len != 3)) {
  ------------------
  |  Branch (1173:9): [True: 15, False: 4.00k]
  |  Branch (1173:26): [True: 139, False: 3.86k]
  ------------------
 1174|    154|        return false;
 1175|    154|    }
 1176|  3.86k|    if (!pkt.get(len) || (len != 1)) {
  ------------------
  |  Branch (1176:9): [True: 1, False: 3.86k]
  |  Branch (1176:26): [True: 20, False: 3.84k]
  ------------------
 1177|     21|        return false;
 1178|     21|    }
 1179|  3.84k|    if (!pkt.get(halg) || !pkt.get(walg)) {
  ------------------
  |  Branch (1179:9): [True: 1, False: 3.83k]
  |  Branch (1179:27): [True: 1, False: 3.83k]
  ------------------
 1180|      2|        return false;
 1181|      2|    }
 1182|  3.83k|    key_.kdf_hash_alg = (pgp_hash_alg_t) halg;
 1183|  3.83k|    key_.key_wrap_alg = (pgp_symm_alg_t) walg;
 1184|  3.83k|    return true;
 1185|  3.84k|}
_ZN3pgp16EDDSAKeyMaterial5cloneEv:
 1285|  71.5k|{
 1286|  71.5k|    return std::unique_ptr<KeyMaterial>(new EDDSAKeyMaterial(*this));
 1287|  71.5k|}
_ZNK3pgp16EDDSAKeyMaterial6verifyERKN3rnp15SecurityContextERKNS_11SigMaterialERKNSt3__16vectorIhNS1_16secure_allocatorIhEEEE:
 1303|  3.50k|{
 1304|  3.50k|    auto ec = dynamic_cast<const ECSigMaterial *>(&sig);
 1305|  3.50k|    if (!ec) {
  ------------------
  |  Branch (1305:9): [True: 408, False: 3.09k]
  ------------------
 1306|    408|        return RNP_ERROR_BAD_PARAMETERS;
 1307|    408|    }
 1308|  3.09k|    return eddsa::verify(ec->sig, hash, key_);
 1309|  3.50k|}
_ZN3pgp14SM2KeyMaterial5cloneEv:
 1336|    176|{
 1337|    176|    return std::unique_ptr<KeyMaterial>(new SM2KeyMaterial(*this));
 1338|    176|}
_ZN3pgp18Ed25519KeyMaterial5cloneEv:
 1430|  3.91k|{
 1431|  3.91k|    return std::unique_ptr<KeyMaterial>(new Ed25519KeyMaterial(*this));
 1432|  3.91k|}
_ZNK3pgp18Ed25519KeyMaterial11grip_updateERN3rnp4HashE:
 1436|    434|{
 1437|       |    // TODO: if GnuPG would ever support v6, check whether this works correctly.
 1438|    434|    hash.add(pub());
 1439|    434|}
_ZN3pgp18Ed25519KeyMaterial12clear_secretEv:
 1449|    669|{
 1450|    669|    key_.clear_secret();
 1451|    669|    KeyMaterial::clear_secret();
 1452|    669|}
_ZN3pgp18Ed25519KeyMaterial5parseER17pgp_packet_body_t:
 1456|    661|{
 1457|    661|    secret_ = false;
 1458|    661|    auto                 ec_desc = ec::Curve::get(PGP_CURVE_ED25519);
 1459|    661|    std::vector<uint8_t> buf(ec_desc->bytes());
 1460|    661|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (1460:9): [True: 73, False: 588]
  ------------------
 1461|     73|        RNP_LOG("failed to parse Ed25519 public key data");
  ------------------
  |  |   84|     73|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     73|    do {                                                                                 \
  |  |  |  |   77|     73|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 73, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     73|            break;                                                                       \
  |  |  |  |   79|     73|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1462|     73|        return false;
 1463|     73|    }
 1464|    588|    key_.pub = buf;
 1465|    588|    return true;
 1466|    661|}
_ZN3pgp18Ed25519KeyMaterial12parse_secretER17pgp_packet_body_t:
 1470|      3|{
 1471|      3|    auto ec_desc = ec::Curve::get(PGP_CURVE_ED25519);
 1472|      3|    if (!pkt.get(key_.priv, ec_desc->bytes())) {
  ------------------
  |  Branch (1472:9): [True: 1, False: 2]
  ------------------
 1473|      1|        RNP_LOG("failed to parse Ed25519 secret key data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1474|      1|        return false;
 1475|      1|    }
 1476|      2|    secret_ = true;
 1477|      2|    return true;
 1478|      3|}
_ZNK3pgp18Ed25519KeyMaterial3pubEv:
 1556|    434|{
 1557|    434|    return key_.pub;
 1558|    434|}
_ZN3pgp17X25519KeyMaterial5cloneEv:
 1568|  16.1k|{
 1569|  16.1k|    return std::unique_ptr<KeyMaterial>(new X25519KeyMaterial(*this));
 1570|  16.1k|}
_ZNK3pgp17X25519KeyMaterial11grip_updateERN3rnp4HashE:
 1574|  2.51k|{
 1575|       |    // TODO: if GnuPG would ever support v6, check whether this works correctly.
 1576|  2.51k|    hash.add(pub());
 1577|  2.51k|}
_ZN3pgp17X25519KeyMaterial12clear_secretEv:
 1587|  2.53k|{
 1588|  2.53k|    key_.clear_secret();
 1589|  2.53k|    KeyMaterial::clear_secret();
 1590|  2.53k|}
_ZN3pgp17X25519KeyMaterial5parseER17pgp_packet_body_t:
 1594|  2.86k|{
 1595|  2.86k|    secret_ = false;
 1596|  2.86k|    auto                 ec_desc = ec::Curve::get(PGP_CURVE_25519);
 1597|  2.86k|    std::vector<uint8_t> buf(ec_desc->bytes());
 1598|  2.86k|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (1598:9): [True: 18, False: 2.84k]
  ------------------
 1599|     18|        RNP_LOG("failed to parse X25519 public key data");
  ------------------
  |  |   84|     18|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     18|    do {                                                                                 \
  |  |  |  |   77|     18|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 18, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     18|            break;                                                                       \
  |  |  |  |   79|     18|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1600|     18|        return false;
 1601|     18|    }
 1602|  2.84k|    key_.pub = buf;
 1603|  2.84k|    return true;
 1604|  2.86k|}
_ZN3pgp17X25519KeyMaterial12parse_secretER17pgp_packet_body_t:
 1608|      3|{
 1609|      3|    auto ec_desc = ec::Curve::get(PGP_CURVE_25519);
 1610|      3|    if (!pkt.get(key_.priv, ec_desc->bytes())) {
  ------------------
  |  Branch (1610:9): [True: 1, False: 2]
  ------------------
 1611|      1|        RNP_LOG("failed to parse X25519 secret key data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1612|      1|        return false;
 1613|      1|    }
 1614|      2|    secret_ = true;
 1615|      2|    return true;
 1616|      3|}
_ZNK3pgp17X25519KeyMaterial3pubEv:
 1684|  2.51k|{
 1685|  2.51k|    return key_.pub;
 1686|  2.51k|}
_ZN3pgp16Ed448KeyMaterial5cloneEv:
 1696|    793|{
 1697|    793|    return std::unique_ptr<KeyMaterial>(new Ed448KeyMaterial(*this));
 1698|    793|}
_ZNK3pgp16Ed448KeyMaterial11grip_updateERN3rnp4HashE:
 1702|     88|{
 1703|       |    // TODO: if GnuPG would ever support v6, check whether this works correctly.
 1704|     88|    hash.add(pub());
 1705|     88|}
_ZN3pgp16Ed448KeyMaterial12clear_secretEv:
 1715|    116|{
 1716|    116|    key_.clear_secret();
 1717|    116|    KeyMaterial::clear_secret();
 1718|    116|}
_ZN3pgp16Ed448KeyMaterial5parseER17pgp_packet_body_t:
 1722|    238|{
 1723|    238|    secret_ = false;
 1724|    238|    auto                 ec_desc = ec::Curve::get(PGP_CURVE_ED448);
 1725|    238|    std::vector<uint8_t> buf(BITS_TO_BYTES(ec_desc->bitlen));
  ------------------
  |  |   56|    238|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  ------------------
 1726|    238|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (1726:9): [True: 77, False: 161]
  ------------------
 1727|     77|        RNP_LOG("failed to parse Ed448 public key data");
  ------------------
  |  |   84|     77|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     77|    do {                                                                                 \
  |  |  |  |   77|     77|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 77, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     77|            break;                                                                       \
  |  |  |  |   79|     77|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1728|     77|        return false;
 1729|     77|    }
 1730|    161|    key_.pub = buf;
 1731|    161|    return true;
 1732|    238|}
_ZN3pgp16Ed448KeyMaterial12parse_secretER17pgp_packet_body_t:
 1736|      3|{
 1737|      3|    auto ec_desc = ec::Curve::get(PGP_CURVE_ED448);
 1738|      3|    if (!pkt.get(key_.priv, BITS_TO_BYTES(ec_desc->bitlen))) {
  ------------------
  |  |   56|      3|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  ------------------
  |  Branch (1738:9): [True: 2, False: 1]
  ------------------
 1739|      2|        RNP_LOG("failed to parse Ed448 secret key data");
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1740|      2|        return false;
 1741|      2|    }
 1742|      1|    secret_ = true;
 1743|      1|    return true;
 1744|      3|}
_ZNK3pgp16Ed448KeyMaterial3pubEv:
 1821|     88|{
 1822|     88|    return key_.pub;
 1823|     88|}
_ZN3pgp15X448KeyMaterial5cloneEv:
 1833|  5.41k|{
 1834|  5.41k|    return std::unique_ptr<KeyMaterial>(new X448KeyMaterial(*this));
 1835|  5.41k|}
_ZNK3pgp15X448KeyMaterial11grip_updateERN3rnp4HashE:
 1839|    681|{
 1840|       |    // TODO: if GnuPG would ever support v6, check whether this works correctly.
 1841|    681|    hash.add(pub());
 1842|    681|}
_ZN3pgp15X448KeyMaterial12clear_secretEv:
 1852|    972|{
 1853|    972|    key_.clear_secret();
 1854|    972|    KeyMaterial::clear_secret();
 1855|    972|}
_ZN3pgp15X448KeyMaterial5parseER17pgp_packet_body_t:
 1859|    877|{
 1860|    877|    secret_ = false;
 1861|    877|    auto                 ec_desc = ec::Curve::get(PGP_CURVE_448);
 1862|    877|    std::vector<uint8_t> buf(BITS_TO_BYTES(ec_desc->bitlen));
  ------------------
  |  |   56|    877|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  ------------------
 1863|    877|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (1863:9): [True: 18, False: 859]
  ------------------
 1864|     18|        RNP_LOG("failed to parse X448 public key data");
  ------------------
  |  |   84|     18|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     18|    do {                                                                                 \
  |  |  |  |   77|     18|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 18, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     18|            break;                                                                       \
  |  |  |  |   79|     18|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1865|     18|        return false;
 1866|     18|    }
 1867|    859|    key_.pub = buf;
 1868|    859|    return true;
 1869|    877|}
_ZN3pgp15X448KeyMaterial12parse_secretER17pgp_packet_body_t:
 1873|     12|{
 1874|     12|    auto ec_desc = ec::Curve::get(PGP_CURVE_448);
 1875|     12|    if (!pkt.get(key_.priv, BITS_TO_BYTES(ec_desc->bitlen))) {
  ------------------
  |  |   56|     12|#define BITS_TO_BYTES(b) (((b) + (CHAR_BIT - 1)) / CHAR_BIT)
  ------------------
  |  Branch (1875:9): [True: 11, False: 1]
  ------------------
 1876|     11|        RNP_LOG("failed to parse X448 secret key data");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1877|     11|        return false;
 1878|     11|    }
 1879|      1|    secret_ = true;
 1880|      1|    return true;
 1881|     12|}
_ZNK3pgp15X448KeyMaterial3pubEv:
 1949|    681|{
 1950|    681|    return key_.pub;
 1951|    681|}
_ZN3pgp20MlkemEcdhKeyMaterial5cloneEv:
 1963|     73|{
 1964|     73|    return std::unique_ptr<KeyMaterial>(new MlkemEcdhKeyMaterial(*this));
 1965|     73|}
_ZNK3pgp20MlkemEcdhKeyMaterial11grip_updateERN3rnp4HashE:
 1969|     12|{
 1970|     12|    hash.add(pub().get_encoded());
 1971|     12|}
_ZN3pgp20MlkemEcdhKeyMaterial12clear_secretEv:
 1981|     10|{
 1982|     10|    key_.priv.secure_clear();
 1983|     10|    KeyMaterial::clear_secret();
 1984|     10|}
_ZN3pgp20MlkemEcdhKeyMaterial5parseER17pgp_packet_body_t:
 1988|    262|{
 1989|    262|    secret_ = false;
 1990|    262|    std::vector<uint8_t> buf(pgp_kyber_ecdh_composite_public_key_t::encoded_size(alg()));
 1991|    262|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (1991:9): [True: 239, False: 23]
  ------------------
 1992|    239|        RNP_LOG("failed to parse mlkem-ecdh public key data");
  ------------------
  |  |   84|    239|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    239|    do {                                                                                 \
  |  |  |  |   77|    239|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 239, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    239|            break;                                                                       \
  |  |  |  |   79|    239|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1993|    239|        return false;
 1994|    239|    }
 1995|     23|    key_.pub = pgp_kyber_ecdh_composite_public_key_t(buf, alg());
 1996|     23|    return true;
 1997|    262|}
_ZN3pgp20MlkemEcdhKeyMaterial12parse_secretER17pgp_packet_body_t:
 2001|      4|{
 2002|      4|    rnp::secure_bytes buf(pgp_kyber_ecdh_composite_private_key_t::encoded_size(alg()));
 2003|      4|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (2003:9): [True: 0, False: 4]
  ------------------
 2004|      0|        RNP_LOG("failed to parse mkem-ecdh secret key data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2005|      0|        return false;
 2006|      0|    }
 2007|      4|    key_.priv = pgp_kyber_ecdh_composite_private_key_t(buf.data(), buf.size(), alg());
 2008|      4|    secret_ = true;
 2009|      4|    return true;
 2010|      4|}
_ZNK3pgp20MlkemEcdhKeyMaterial3pubEv:
 2072|     12|{
 2073|     12|    return key_.pub;
 2074|     12|}
_ZN3pgp23DilithiumEccKeyMaterial5cloneEv:
 2086|     86|{
 2087|     86|    return std::unique_ptr<KeyMaterial>(new DilithiumEccKeyMaterial(*this));
 2088|     86|}
_ZNK3pgp23DilithiumEccKeyMaterial11grip_updateERN3rnp4HashE:
 2092|     14|{
 2093|     14|    hash.add(pub().get_encoded());
 2094|     14|}
_ZN3pgp23DilithiumEccKeyMaterial12clear_secretEv:
 2104|     18|{
 2105|     18|    key_.priv.secure_clear();
 2106|     18|    KeyMaterial::clear_secret();
 2107|     18|}
_ZN3pgp23DilithiumEccKeyMaterial5parseER17pgp_packet_body_t:
 2111|    413|{
 2112|    413|    secret_ = false;
 2113|    413|    std::vector<uint8_t> buf(pgp_dilithium_exdsa_composite_public_key_t::encoded_size(alg()));
 2114|    413|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (2114:9): [True: 395, False: 18]
  ------------------
 2115|    395|        RNP_LOG("failed to parse mldsa-ecdsa/eddsa public key data");
  ------------------
  |  |   84|    395|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    395|    do {                                                                                 \
  |  |  |  |   77|    395|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 395, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    395|            break;                                                                       \
  |  |  |  |   79|    395|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2116|    395|        return false;
 2117|    395|    }
 2118|     18|    key_.pub = pgp_dilithium_exdsa_composite_public_key_t(buf, alg());
 2119|     18|    return true;
 2120|    413|}
_ZN3pgp23DilithiumEccKeyMaterial12parse_secretER17pgp_packet_body_t:
 2124|      3|{
 2125|      3|    rnp::secure_bytes buf(pgp_dilithium_exdsa_composite_private_key_t::encoded_size(alg()));
 2126|      3|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (2126:9): [True: 0, False: 3]
  ------------------
 2127|      0|        RNP_LOG("failed to parse mldsa-ecdsa/eddsa secret key data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2128|      0|        return false;
 2129|      0|    }
 2130|      3|    key_.priv = pgp_dilithium_exdsa_composite_private_key_t(buf.data(), buf.size(), alg());
 2131|      3|    secret_ = true;
 2132|      3|    return true;
 2133|      3|}
_ZNK3pgp23DilithiumEccKeyMaterial3pubEv:
 2205|     14|{
 2206|     14|    return key_.pub;
 2207|     14|}
_ZN3pgp17SlhdsaKeyMaterial5cloneEv:
 2217|  9.29k|{
 2218|  9.29k|    return std::unique_ptr<KeyMaterial>(new SlhdsaKeyMaterial(*this));
 2219|  9.29k|}
_ZNK3pgp17SlhdsaKeyMaterial11grip_updateERN3rnp4HashE:
 2223|  1.24k|{
 2224|  1.24k|    hash.add(pub().get_encoded());
 2225|  1.24k|}
_ZN3pgp17SlhdsaKeyMaterial12clear_secretEv:
 2235|    946|{
 2236|    946|    key_.priv.secure_clear();
 2237|    946|    KeyMaterial::clear_secret();
 2238|    946|}
_ZN3pgp17SlhdsaKeyMaterial5parseER17pgp_packet_body_t:
 2242|  2.02k|{
 2243|  2.02k|    secret_ = false;
 2244|  2.02k|    auto size = sphincsplus_pubkey_size(alg());
 2245|  2.02k|    if (!size) {
  ------------------
  |  Branch (2245:9): [True: 0, False: 2.02k]
  ------------------
 2246|      0|        RNP_LOG("invalid algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2247|      0|        return false;
 2248|      0|    }
 2249|  2.02k|    std::vector<uint8_t> buf(size);
 2250|  2.02k|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (2250:9): [True: 40, False: 1.98k]
  ------------------
 2251|     40|        RNP_LOG("failed to parse SLH-DSA public key data");
  ------------------
  |  |   84|     40|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     40|    do {                                                                                 \
  |  |  |  |   77|     40|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 40, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     40|            break;                                                                       \
  |  |  |  |   79|     40|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2252|     40|        return false;
 2253|     40|    }
 2254|  1.98k|    key_.pub = pgp_sphincsplus_public_key_t(buf, alg());
 2255|  1.98k|    return true;
 2256|  2.02k|}
_ZN3pgp17SlhdsaKeyMaterial12parse_secretER17pgp_packet_body_t:
 2260|     17|{
 2261|     17|    rnp::secure_bytes buf(sphincsplus_privkey_size(alg()));
 2262|     17|    if (!pkt.get(buf.data(), buf.size())) {
  ------------------
  |  Branch (2262:9): [True: 11, False: 6]
  ------------------
 2263|     11|        RNP_LOG("failed to parse SLH-DSA secret key data");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2264|     11|        return false;
 2265|     11|    }
 2266|      6|    key_.priv = pgp_sphincsplus_private_key_t(buf.data(), buf.size(), alg());
 2267|      6|    secret_ = true;
 2268|      6|    return true;
 2269|     17|}
_ZNK3pgp17SlhdsaKeyMaterial3pubEv:
 2340|  1.24k|{
 2341|  1.24k|    return key_.pub;
 2342|  1.24k|}
key_material.cpp:_ZN12_GLOBAL__N_113grip_hash_mpiERN3rnp4HashERKN3pgp3mpiEcb:
   37|   138k|{
   38|   138k|    size_t len = val.size();
   39|   138k|    size_t idx = 0;
   40|   405k|    for (idx = 0; (idx < len) && !val[idx]; idx++)
  ------------------
  |  Branch (40:19): [True: 397k, False: 8.45k]
  |  Branch (40:34): [True: 267k, False: 129k]
  ------------------
   41|   267k|        ;
   42|       |
   43|   138k|    if (name) {
  ------------------
  |  Branch (43:9): [True: 130k, False: 8.19k]
  ------------------
   44|   130k|        size_t hlen = idx >= len ? 0 : len - idx;
  ------------------
  |  Branch (44:23): [True: 4.40k, False: 125k]
  ------------------
   45|   130k|        if ((len > idx) && lzero && (val[idx] & 0x80)) {
  ------------------
  |  Branch (45:13): [True: 125k, False: 4.40k]
  |  Branch (45:28): [True: 2.73k, False: 123k]
  |  Branch (45:37): [True: 975, False: 1.75k]
  ------------------
   46|    975|            hlen++;
   47|    975|        }
   48|       |
   49|   130k|        char buf[26] = {0};
   50|   130k|        snprintf(buf, sizeof(buf), "(1:%c%zu:", name, hlen);
   51|   130k|        hash.add(buf, strlen(buf));
   52|   130k|    }
   53|       |
   54|   138k|    if (idx < len) {
  ------------------
  |  Branch (54:9): [True: 129k, False: 8.45k]
  ------------------
   55|       |        /* gcrypt prepends mpis with zero if higher bit is set */
   56|   129k|        if (lzero && (val[idx] & 0x80)) {
  ------------------
  |  Branch (56:13): [True: 6.87k, False: 123k]
  |  Branch (56:22): [True: 3.25k, False: 3.62k]
  ------------------
   57|  3.25k|            uint8_t zero = 0;
   58|  3.25k|            hash.add(&zero, 1);
   59|  3.25k|        }
   60|   129k|        hash.add(val.data() + idx, len - idx);
   61|   129k|    }
   62|   138k|    if (name) {
  ------------------
  |  Branch (62:9): [True: 130k, False: 8.19k]
  ------------------
   63|   130k|        hash.add(")", 1);
   64|   130k|    }
   65|   138k|}
key_material.cpp:_ZN12_GLOBAL__N_112grip_hash_ecERN3rnp4HashERKN3pgp2ec3KeyE:
   85|  21.2k|{
   86|  21.2k|    auto desc = pgp::ec::Curve::get(key.curve);
   87|  21.2k|    if (!desc) {
  ------------------
  |  Branch (87:9): [True: 1, False: 21.2k]
  ------------------
   88|      1|        RNP_LOG("unknown curve %d", (int) key.curve);
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   89|      1|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   90|      1|    }
   91|       |
   92|       |    /* build uncompressed point from gx and gy */
   93|  21.2k|    auto gxbin = rnp::hex_to_bin(desc->gx);
   94|  21.2k|    auto gybin = rnp::hex_to_bin(desc->gy);
   95|  21.2k|    assert(!gxbin.empty());
   96|  21.2k|    assert(!gybin.empty());
   97|  21.2k|    pgp::mpi g;
   98|  21.2k|    g.resize(1 + gxbin.size() + gybin.size());
   99|  21.2k|    g[0] = 0x04;
  100|  21.2k|    memcpy(g.data() + 1, gxbin.data(), gxbin.size());
  101|  21.2k|    memcpy(g.data() + 1 + gxbin.size(), gybin.data(), gybin.size());
  102|       |
  103|       |    /* p, a, b, g, n, q */
  104|  21.2k|    grip_hash_ecc_hex(hash, desc->p, 'p');
  105|  21.2k|    grip_hash_ecc_hex(hash, desc->a, 'a');
  106|  21.2k|    grip_hash_ecc_hex(hash, desc->b, 'b');
  107|  21.2k|    grip_hash_mpi(hash, g, 'g', false);
  108|  21.2k|    grip_hash_ecc_hex(hash, desc->n, 'n');
  109|       |
  110|  21.2k|    if ((key.curve == PGP_CURVE_ED25519) || (key.curve == PGP_CURVE_25519)) {
  ------------------
  |  Branch (110:9): [True: 13.1k, False: 8.06k]
  |  Branch (110:45): [True: 1.33k, False: 6.73k]
  ------------------
  111|  14.4k|        if (g.size() < 1) {
  ------------------
  |  Branch (111:13): [True: 0, False: 14.4k]
  ------------------
  112|      0|            RNP_LOG("wrong 25519 p");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  113|      0|            throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  114|      0|        }
  115|  14.4k|        g.resize(key.p.size() - 1);
  116|  14.4k|        memcpy(g.data(), key.p.data() + 1, g.size());
  117|  14.4k|        grip_hash_mpi(hash, g, 'q', false);
  118|  14.4k|    } else {
  119|  6.73k|        grip_hash_mpi(hash, key.p, 'q', false);
  120|  6.73k|    }
  121|  21.2k|}
key_material.cpp:_ZN12_GLOBAL__N_117grip_hash_ecc_hexERN3rnp4HashEPKcc:
   69|  84.8k|{
   70|  84.8k|    auto bin = rnp::hex_to_bin(hex);
   71|  84.8k|    if (bin.empty()) {
  ------------------
  |  Branch (71:9): [True: 0, False: 84.8k]
  ------------------
   72|      0|        RNP_LOG("wrong hex mpi");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   73|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
   74|      0|    }
   75|       |
   76|  84.8k|    pgp::mpi mpi;
   77|  84.8k|    mpi.assign(bin.data(), bin.size());
   78|       |
   79|       |    /* libgcrypt doesn't add leading zero when hashes ecc mpis */
   80|  84.8k|    return grip_hash_mpi(hash, mpi, name, false);
   81|  84.8k|}

_ZN3pgp11KeyMaterialC2E16pgp_pubkey_alg_tb:
  180|  52.5k|        : validity_({}), alg_(kalg), secret_(secret){};
_ZN3pgp14RSAKeyMaterialC2E16pgp_pubkey_alg_t:
  232|  13.5k|    RSAKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};
_ZN3pgp14DSAKeyMaterialC2Ev:
  275|    629|    DSAKeyMaterial() : KeyMaterial(PGP_PKA_DSA), key_{} {};
_ZN3pgp13EGKeyMaterialC2E16pgp_pubkey_alg_t:
  312|    618|    EGKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};
_ZN3pgp13ECKeyMaterialC2E16pgp_pubkey_alg_t:
  350|  28.8k|    ECKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};
_ZN3pgp16ECDSAKeyMaterialC2Ev:
  373|  6.53k|    ECDSAKeyMaterial() : ECKeyMaterial(PGP_PKA_ECDSA){};
_ZN3pgp15ECDHKeyMaterialC2Ev:
  392|  4.23k|    ECDHKeyMaterial() : ECKeyMaterial(PGP_PKA_ECDH){};
_ZN3pgp16EDDSAKeyMaterialC2Ev:
  418|  18.0k|    EDDSAKeyMaterial() : ECKeyMaterial(PGP_PKA_EDDSA){};
_ZN3pgp14SM2KeyMaterialC2Ev:
  437|     64|    SM2KeyMaterial() : ECKeyMaterial(PGP_PKA_SM2){};
_ZN3pgp18Ed25519KeyMaterialC2Ev:
  466|    662|    Ed25519KeyMaterial() : KeyMaterial(PGP_PKA_ED25519), key_{} {};
_ZN3pgp17X25519KeyMaterialC2Ev:
  498|  2.87k|    X25519KeyMaterial() : KeyMaterial(PGP_PKA_X25519), key_{} {};
_ZN3pgp16Ed448KeyMaterialC2Ev:
  528|    241|    Ed448KeyMaterial() : KeyMaterial(PGP_PKA_ED448), key_{} {};
_ZN3pgp15X448KeyMaterialC2Ev:
  561|    879|    X448KeyMaterial() : KeyMaterial(PGP_PKA_X448), key_{} {};
_ZN3pgp20MlkemEcdhKeyMaterialC2E16pgp_pubkey_alg_t:
  593|    292|    MlkemEcdhKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};
_ZN3pgp23DilithiumEccKeyMaterialC2E16pgp_pubkey_alg_t:
  624|  1.09k|    DilithiumEccKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};
_ZN3pgp17SlhdsaKeyMaterialC2E16pgp_pubkey_alg_t:
  657|  2.75k|    SlhdsaKeyMaterial(pgp_pubkey_alg_t kalg) : KeyMaterial(kalg), key_{} {};

_Z14rnp_log_switchv:
   53|   745k|{
   54|   745k|    if (_rnp_log_switch < 0) {
  ------------------
  |  Branch (54:9): [True: 1, False: 745k]
  ------------------
   55|      1|        const char *var = getenv(RNP_LOG_CONSOLE);
   56|      1|        _rnp_log_switch = (var && strcmp(var, "0")) ? 1 : 0;
  ------------------
  |  Branch (56:28): [True: 0, False: 1]
  |  Branch (56:35): [True: 0, False: 0]
  ------------------
   57|      1|    }
   58|   745k|    return !_rnp_log_disable && !!_rnp_log_switch;
  ------------------
  |  Branch (58:12): [True: 745k, False: 0]
  |  Branch (58:33): [True: 0, False: 745k]
  ------------------
   59|   745k|}

_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE9push_backEOSE_:
22391|  16.4k|    {
22392|       |        // push_back only works for null objects or arrays
22393|  16.4k|        if (JSON_HEDLEY_UNLIKELY(!(is_null() || is_array())))
  ------------------
  |  | 1677|  32.9k|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 16.4k]
  |  |  |  Branch (1677:94): [True: 0, False: 16.4k]
  |  |  |  Branch (1677:94): [True: 16.4k, False: 0]
  |  |  ------------------
  ------------------
22394|      0|        {
22395|      0|            JSON_THROW(type_error::create(308, detail::concat("cannot use push_back() with ", type_name()), this));
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
22396|      0|        }
22397|       |
22398|       |        // transform null object into an array
22399|  16.4k|        if (is_null())
  ------------------
  |  Branch (22399:13): [True: 0, False: 16.4k]
  ------------------
22400|      0|        {
22401|      0|            m_data.m_type = value_t::array;
22402|      0|            m_data.m_value = value_t::array;
22403|      0|            assert_invariant();
22404|      0|        }
22405|       |
22406|       |        // add element to array (move semantics)
22407|  16.4k|        const auto old_capacity = m_data.m_value.array->capacity();
22408|  16.4k|        m_data.m_value.array->push_back(std::move(val));
22409|  16.4k|        set_parent(m_data.m_value.array->back(), old_capacity);
22410|       |        // if val is moved from, basic_json move constructor marks it null, so we do not call the destructor
22411|  16.4k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10json_valueC2ENS0_6detail7value_tE:
19756|  82.6k|        {
19757|  82.6k|            switch (t)
19758|  82.6k|            {
19759|  22.0k|                case value_t::object:
  ------------------
  |  Branch (19759:17): [True: 22.0k, False: 60.5k]
  ------------------
19760|  22.0k|                {
19761|  22.0k|                    object = create<object_t>();
19762|  22.0k|                    break;
19763|      0|                }
19764|       |
19765|      0|                case value_t::array:
  ------------------
  |  Branch (19765:17): [True: 0, False: 82.6k]
  ------------------
19766|      0|                {
19767|      0|                    array = create<array_t>();
19768|      0|                    break;
19769|      0|                }
19770|       |
19771|      0|                case value_t::string:
  ------------------
  |  Branch (19771:17): [True: 0, False: 82.6k]
  ------------------
19772|      0|                {
19773|      0|                    string = create<string_t>("");
19774|      0|                    break;
19775|      0|                }
19776|       |
19777|      0|                case value_t::binary:
  ------------------
  |  Branch (19777:17): [True: 0, False: 82.6k]
  ------------------
19778|      0|                {
19779|      0|                    binary = create<binary_t>();
19780|      0|                    break;
19781|      0|                }
19782|       |
19783|      0|                case value_t::boolean:
  ------------------
  |  Branch (19783:17): [True: 0, False: 82.6k]
  ------------------
19784|      0|                {
19785|      0|                    boolean = static_cast<boolean_t>(false);
19786|      0|                    break;
19787|      0|                }
19788|       |
19789|      0|                case value_t::number_integer:
  ------------------
  |  Branch (19789:17): [True: 0, False: 82.6k]
  ------------------
19790|      0|                {
19791|      0|                    number_integer = static_cast<number_integer_t>(0);
19792|      0|                    break;
19793|      0|                }
19794|       |
19795|      0|                case value_t::number_unsigned:
  ------------------
  |  Branch (19795:17): [True: 0, False: 82.6k]
  ------------------
19796|      0|                {
19797|      0|                    number_unsigned = static_cast<number_unsigned_t>(0);
19798|      0|                    break;
19799|      0|                }
19800|       |
19801|      0|                case value_t::number_float:
  ------------------
  |  Branch (19801:17): [True: 0, False: 82.6k]
  ------------------
19802|      0|                {
19803|      0|                    number_float = static_cast<number_float_t>(0.0);
19804|      0|                    break;
19805|      0|                }
19806|       |
19807|  60.5k|                case value_t::null:
  ------------------
  |  Branch (19807:17): [True: 60.5k, False: 22.0k]
  ------------------
19808|  60.5k|                {
19809|  60.5k|                    object = nullptr;  // silence warning, see #821
19810|  60.5k|                    break;
19811|      0|                }
19812|       |
19813|      0|                case value_t::discarded:
  ------------------
  |  Branch (19813:17): [True: 0, False: 82.6k]
  ------------------
19814|      0|                default:
  ------------------
  |  Branch (19814:17): [True: 0, False: 82.6k]
  ------------------
19815|      0|                {
19816|      0|                    object = nullptr;  // silence warning, see #821
19817|      0|                    if (JSON_HEDLEY_UNLIKELY(t == value_t::null))
  ------------------
  |  | 1677|      0|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 0]
  |  |  ------------------
  ------------------
19818|      0|                    {
19819|      0|                        JSON_THROW(other_error::create(500, "961c151d2e87f2686a955a9be24d316f1362bf21 3.11.3", nullptr)); // LCOV_EXCL_LINE
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
19820|      0|                    }
19821|      0|                    break;
19822|      0|                }
19823|  82.6k|            }
19824|  82.6k|        }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createINS2_ISA_SE_NS3_4lessIvEENS8_INS3_4pairIKSA_SE_EEEEEEJEEEPT_DpOT0_:
19681|  22.0k|    {
19682|  22.0k|        AllocatorType<T> alloc;
19683|  22.0k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  22.0k|        auto deleter = [&](T * obj)
19686|  22.0k|        {
19687|  22.0k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  22.0k|        };
19689|  22.0k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  22.0k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  22.0k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  22.0k|        return obj.release();
19693|  22.0k|    }
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEENS0_10basic_jsonIS1_NS2_6vectorES8_blmdS6_NS0_14adl_serializerENSA_IhNS6_IhEEEEvEENS2_4lessIvEENS6_INS2_4pairIKS8_SE_EEEEEC2Ev:
19050|  22.0k|    ordered_map() noexcept(noexcept(Container())) : Container{} {}
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE16assert_invariantEb:
19985|  1.91M|    {
19986|  1.91M|        JSON_ASSERT(m_data.m_type != value_t::object || m_data.m_value.object != nullptr);
  ------------------
  |  | 2552|  1.91M|    #define JSON_ASSERT(x) assert(x)
  ------------------
19987|  1.91M|        JSON_ASSERT(m_data.m_type != value_t::array || m_data.m_value.array != nullptr);
  ------------------
  |  | 2552|  1.91M|    #define JSON_ASSERT(x) assert(x)
  ------------------
19988|  1.91M|        JSON_ASSERT(m_data.m_type != value_t::string || m_data.m_value.string != nullptr);
  ------------------
  |  | 2552|  1.91M|    #define JSON_ASSERT(x) assert(x)
  ------------------
19989|  1.91M|        JSON_ASSERT(m_data.m_type != value_t::binary || m_data.m_value.binary != nullptr);
  ------------------
  |  | 2552|  1.91M|    #define JSON_ASSERT(x) assert(x)
  ------------------
19990|       |
19991|       |#if JSON_DIAGNOSTICS
19992|       |        JSON_TRY
19993|       |        {
19994|       |            // cppcheck-suppress assertWithSideEffect
19995|       |            JSON_ASSERT(!check_parents || !is_structured() || std::all_of(begin(), end(), [this](const basic_json & j)
19996|       |            {
19997|       |                return j.m_parent == this;
19998|       |            }));
19999|       |        }
20000|       |        JSON_CATCH(...) {} // LCOV_EXCL_LINE
20001|       |#endif
20002|  1.91M|        static_cast<void>(check_parents);
20003|  1.91M|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10set_parentERSE_m:
20056|  77.0k|    {
20057|       |#if JSON_DIAGNOSTICS
20058|       |        if (old_capacity != static_cast<std::size_t>(-1))
20059|       |        {
20060|       |            // see https://github.com/nlohmann/json/issues/2838
20061|       |            JSON_ASSERT(type() == value_t::array);
20062|       |            if (JSON_HEDLEY_UNLIKELY(m_data.m_value.array->capacity() != old_capacity))
20063|       |            {
20064|       |                // capacity has changed: update all parents
20065|       |                set_parents();
20066|       |                return j;
20067|       |            }
20068|       |        }
20069|       |
20070|       |        // ordered_json uses a vector internally, so pointers could have
20071|       |        // been invalidated; see https://github.com/nlohmann/json/issues/2962
20072|       |#ifdef JSON_HEDLEY_MSVC_VERSION
20073|       |#pragma warning(push )
20074|       |#pragma warning(disable : 4127) // ignore warning to replace if with if constexpr
20075|       |#endif
20076|       |        if (detail::is_ordered_map<object_t>::value)
20077|       |        {
20078|       |            set_parents();
20079|       |            return j;
20080|       |        }
20081|       |#ifdef JSON_HEDLEY_MSVC_VERSION
20082|       |#pragma warning( pop )
20083|       |#endif
20084|       |
20085|       |        j.m_parent = this;
20086|       |#else
20087|  77.0k|        static_cast<void>(j);
20088|  77.0k|        static_cast<void>(old_capacity);
20089|  77.0k|#endif
20090|  77.0k|        return j;
20091|  77.0k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE4dataC2Ev:
23510|   192k|        data() noexcept = default;
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10json_value7destroyENS0_6detail7value_tE:
19857|   660k|        {
19858|   660k|            if (
19859|   660k|                (t == value_t::object && object == nullptr) ||
  ------------------
  |  Branch (19859:18): [True: 38.5k, False: 621k]
  |  Branch (19859:42): [True: 0, False: 38.5k]
  ------------------
19860|   660k|                (t == value_t::array && array == nullptr) ||
  ------------------
  |  Branch (19860:18): [True: 5.60k, False: 654k]
  |  Branch (19860:41): [True: 0, False: 5.60k]
  ------------------
19861|   660k|                (t == value_t::string && string == nullptr) ||
  ------------------
  |  Branch (19861:18): [True: 148k, False: 512k]
  |  Branch (19861:42): [True: 0, False: 148k]
  ------------------
19862|   660k|                (t == value_t::binary && binary == nullptr)
  ------------------
  |  Branch (19862:18): [True: 0, False: 660k]
  |  Branch (19862:42): [True: 0, False: 0]
  ------------------
19863|   660k|            )
19864|      0|            {
19865|       |                //not initialized (e.g. due to exception in the ctor)
19866|      0|                return;
19867|      0|            }
19868|   660k|            if (t == value_t::array || t == value_t::object)
  ------------------
  |  Branch (19868:17): [True: 5.60k, False: 654k]
  |  Branch (19868:40): [True: 38.5k, False: 616k]
  ------------------
19869|  44.1k|            {
19870|       |                // flatten the current json_value to a heap-allocated stack
19871|  44.1k|                std::vector<basic_json> stack;
19872|       |
19873|       |                // move the top-level items to stack
19874|  44.1k|                if (t == value_t::array)
  ------------------
  |  Branch (19874:21): [True: 5.60k, False: 38.5k]
  ------------------
19875|  5.60k|                {
19876|  5.60k|                    stack.reserve(array->size());
19877|  5.60k|                    std::move(array->begin(), array->end(), std::back_inserter(stack));
19878|  5.60k|                }
19879|  38.5k|                else
19880|  38.5k|                {
19881|  38.5k|                    stack.reserve(object->size());
19882|  38.5k|                    for (auto&& it : *object)
  ------------------
  |  Branch (19882:36): [True: 54.9k, False: 38.5k]
  ------------------
19883|  54.9k|                    {
19884|  54.9k|                        stack.push_back(std::move(it.second));
19885|  54.9k|                    }
19886|  38.5k|                }
19887|       |
19888|   164k|                while (!stack.empty())
  ------------------
  |  Branch (19888:24): [True: 120k, False: 44.1k]
  ------------------
19889|   120k|                {
19890|       |                    // move the last item to local variable to be processed
19891|   120k|                    basic_json current_item(std::move(stack.back()));
19892|   120k|                    stack.pop_back();
19893|       |
19894|       |                    // if current_item is array/object, move
19895|       |                    // its children to the stack to be processed later
19896|   120k|                    if (current_item.is_array())
  ------------------
  |  Branch (19896:25): [True: 5.60k, False: 115k]
  ------------------
19897|  5.60k|                    {
19898|  5.60k|                        std::move(current_item.m_data.m_value.array->begin(), current_item.m_data.m_value.array->end(), std::back_inserter(stack));
19899|       |
19900|  5.60k|                        current_item.m_data.m_value.array->clear();
19901|  5.60k|                    }
19902|   115k|                    else if (current_item.is_object())
  ------------------
  |  Branch (19902:30): [True: 16.4k, False: 98.7k]
  ------------------
19903|  16.4k|                    {
19904|  16.4k|                        for (auto&& it : *current_item.m_data.m_value.object)
  ------------------
  |  Branch (19904:40): [True: 49.3k, False: 16.4k]
  ------------------
19905|  49.3k|                        {
19906|  49.3k|                            stack.push_back(std::move(it.second));
19907|  49.3k|                        }
19908|       |
19909|  16.4k|                        current_item.m_data.m_value.object->clear();
19910|  16.4k|                    }
19911|       |
19912|       |                    // it's now safe that current_item get destructed
19913|       |                    // since it doesn't have any children
19914|   120k|                }
19915|  44.1k|            }
19916|       |
19917|   660k|            switch (t)
19918|   660k|            {
19919|  38.5k|                case value_t::object:
  ------------------
  |  Branch (19919:17): [True: 38.5k, False: 621k]
  ------------------
19920|  38.5k|                {
19921|  38.5k|                    AllocatorType<object_t> alloc;
19922|  38.5k|                    std::allocator_traits<decltype(alloc)>::destroy(alloc, object);
19923|  38.5k|                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, object, 1);
19924|  38.5k|                    break;
19925|      0|                }
19926|       |
19927|  5.60k|                case value_t::array:
  ------------------
  |  Branch (19927:17): [True: 5.60k, False: 654k]
  ------------------
19928|  5.60k|                {
19929|  5.60k|                    AllocatorType<array_t> alloc;
19930|  5.60k|                    std::allocator_traits<decltype(alloc)>::destroy(alloc, array);
19931|  5.60k|                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, array, 1);
19932|  5.60k|                    break;
19933|      0|                }
19934|       |
19935|   148k|                case value_t::string:
  ------------------
  |  Branch (19935:17): [True: 148k, False: 512k]
  ------------------
19936|   148k|                {
19937|   148k|                    AllocatorType<string_t> alloc;
19938|   148k|                    std::allocator_traits<decltype(alloc)>::destroy(alloc, string);
19939|   148k|                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, string, 1);
19940|   148k|                    break;
19941|      0|                }
19942|       |
19943|      0|                case value_t::binary:
  ------------------
  |  Branch (19943:17): [True: 0, False: 660k]
  ------------------
19944|      0|                {
19945|      0|                    AllocatorType<binary_t> alloc;
19946|      0|                    std::allocator_traits<decltype(alloc)>::destroy(alloc, binary);
19947|      0|                    std::allocator_traits<decltype(alloc)>::deallocate(alloc, binary, 1);
19948|      0|                    break;
19949|      0|                }
19950|       |
19951|   468k|                case value_t::null:
  ------------------
  |  Branch (19951:17): [True: 468k, False: 192k]
  ------------------
19952|   468k|                case value_t::boolean:
  ------------------
  |  Branch (19952:17): [True: 0, False: 660k]
  ------------------
19953|   468k|                case value_t::number_integer:
  ------------------
  |  Branch (19953:17): [True: 0, False: 660k]
  ------------------
19954|   468k|                case value_t::number_unsigned:
  ------------------
  |  Branch (19954:17): [True: 0, False: 660k]
  ------------------
19955|   468k|                case value_t::number_float:
  ------------------
  |  Branch (19955:17): [True: 0, False: 660k]
  ------------------
19956|   468k|                case value_t::discarded:
  ------------------
  |  Branch (19956:17): [True: 0, False: 660k]
  ------------------
19957|   468k|                default:
  ------------------
  |  Branch (19957:17): [True: 0, False: 660k]
  ------------------
19958|   468k|                {
19959|   468k|                    break;
19960|   468k|                }
19961|   660k|            }
19962|   660k|        }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE9is_objectEv:
20660|   175k|    {
20661|   175k|        return m_data.m_type == value_t::object;
20662|   175k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE11set_parentsEv:
20006|   605k|    {
20007|       |#if JSON_DIAGNOSTICS
20008|       |        switch (m_data.m_type)
20009|       |        {
20010|       |            case value_t::array:
20011|       |            {
20012|       |                for (auto& element : *m_data.m_value.array)
20013|       |                {
20014|       |                    element.m_parent = this;
20015|       |                }
20016|       |                break;
20017|       |            }
20018|       |
20019|       |            case value_t::object:
20020|       |            {
20021|       |                for (auto& element : *m_data.m_value.object)
20022|       |                {
20023|       |                    element.second.m_parent = this;
20024|       |                }
20025|       |                break;
20026|       |            }
20027|       |
20028|       |            case value_t::null:
20029|       |            case value_t::string:
20030|       |            case value_t::boolean:
20031|       |            case value_t::number_integer:
20032|       |            case value_t::number_unsigned:
20033|       |            case value_t::number_float:
20034|       |            case value_t::binary:
20035|       |            case value_t::discarded:
20036|       |            default:
20037|       |                break;
20038|       |        }
20039|       |#endif
20040|   605k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEixESA_:
21422|  60.5k|    {
21423|       |        // implicitly convert null value to an empty object
21424|  60.5k|        if (is_null())
  ------------------
  |  Branch (21424:13): [True: 0, False: 60.5k]
  ------------------
21425|      0|        {
21426|      0|            m_data.m_type = value_t::object;
21427|      0|            m_data.m_value.object = create<object_t>();
21428|      0|            assert_invariant();
21429|      0|        }
21430|       |
21431|       |        // operator[] only works for objects
21432|  60.5k|        if (JSON_HEDLEY_LIKELY(is_object()))
  ------------------
  |  | 1676|  60.5k|#  define JSON_HEDLEY_LIKELY(expr)                      __builtin_expect                 (!!(expr),    1                  )
  |  |  ------------------
  |  |  |  Branch (1676:57): [True: 60.5k, False: 0]
  |  |  ------------------
  ------------------
21433|  60.5k|        {
21434|  60.5k|            auto result = m_data.m_value.object->emplace(std::move(key), nullptr);
21435|  60.5k|            return set_parent(result.first->second);
21436|  60.5k|        }
21437|       |
21438|      0|        JSON_THROW(type_error::create(305, detail::concat("cannot use operator[] with a string argument with ", type_name()), this));
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
21439|  60.5k|    }
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEENS0_10basic_jsonIS1_NS2_6vectorES8_blmdS6_NS0_14adl_serializerENSA_IhNS6_IhEEEEvEENS2_4lessIvEENS6_INS2_4pairIKS8_SE_EEEEE7emplaceERSI_OSE_:
19059|  60.5k|    {
19060|   109k|        for (auto it = this->begin(); it != this->end(); ++it)
  ------------------
  |  Branch (19060:39): [True: 54.9k, False: 54.9k]
  ------------------
19061|  54.9k|        {
19062|  54.9k|            if (m_compare(it->first, key))
  ------------------
  |  Branch (19062:17): [True: 5.60k, False: 49.3k]
  ------------------
19063|  5.60k|            {
19064|  5.60k|                return {it, false};
19065|  5.60k|            }
19066|  54.9k|        }
19067|  54.9k|        Container::emplace_back(key, std::forward<T>(t));
19068|  54.9k|        return {std::prev(this->end()), true};
19069|  60.5k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2ERKSE_:
20448|   115k|        : json_base_class_t(other)
20449|   115k|    {
20450|   115k|        m_data.m_type = other.m_data.m_type;
20451|       |        // check of passed value is valid
20452|   115k|        other.assert_invariant();
20453|       |
20454|   115k|        switch (m_data.m_type)
20455|   115k|        {
20456|  16.4k|            case value_t::object:
  ------------------
  |  Branch (20456:13): [True: 16.4k, False: 98.7k]
  ------------------
20457|  16.4k|            {
20458|  16.4k|                m_data.m_value = *other.m_data.m_value.object;
20459|  16.4k|                break;
20460|      0|            }
20461|       |
20462|      0|            case value_t::array:
  ------------------
  |  Branch (20462:13): [True: 0, False: 115k]
  ------------------
20463|      0|            {
20464|      0|                m_data.m_value = *other.m_data.m_value.array;
20465|      0|                break;
20466|      0|            }
20467|       |
20468|  98.7k|            case value_t::string:
  ------------------
  |  Branch (20468:13): [True: 98.7k, False: 16.4k]
  ------------------
20469|  98.7k|            {
20470|  98.7k|                m_data.m_value = *other.m_data.m_value.string;
20471|  98.7k|                break;
20472|      0|            }
20473|       |
20474|      0|            case value_t::boolean:
  ------------------
  |  Branch (20474:13): [True: 0, False: 115k]
  ------------------
20475|      0|            {
20476|      0|                m_data.m_value = other.m_data.m_value.boolean;
20477|      0|                break;
20478|      0|            }
20479|       |
20480|      0|            case value_t::number_integer:
  ------------------
  |  Branch (20480:13): [True: 0, False: 115k]
  ------------------
20481|      0|            {
20482|      0|                m_data.m_value = other.m_data.m_value.number_integer;
20483|      0|                break;
20484|      0|            }
20485|       |
20486|      0|            case value_t::number_unsigned:
  ------------------
  |  Branch (20486:13): [True: 0, False: 115k]
  ------------------
20487|      0|            {
20488|      0|                m_data.m_value = other.m_data.m_value.number_unsigned;
20489|      0|                break;
20490|      0|            }
20491|       |
20492|      0|            case value_t::number_float:
  ------------------
  |  Branch (20492:13): [True: 0, False: 115k]
  ------------------
20493|      0|            {
20494|      0|                m_data.m_value = other.m_data.m_value.number_float;
20495|      0|                break;
20496|      0|            }
20497|       |
20498|      0|            case value_t::binary:
  ------------------
  |  Branch (20498:13): [True: 0, False: 115k]
  ------------------
20499|      0|            {
20500|      0|                m_data.m_value = *other.m_data.m_value.binary;
20501|      0|                break;
20502|      0|            }
20503|       |
20504|      0|            case value_t::null:
  ------------------
  |  Branch (20504:13): [True: 0, False: 115k]
  ------------------
20505|      0|            case value_t::discarded:
  ------------------
  |  Branch (20505:13): [True: 0, False: 115k]
  ------------------
20506|      0|            default:
  ------------------
  |  Branch (20506:13): [True: 0, False: 115k]
  ------------------
20507|      0|                break;
20508|   115k|        }
20509|       |
20510|   115k|        set_parents();
20511|   115k|        assert_invariant();
20512|   115k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10json_valueC2ERKNS2_ISA_SE_NS3_4lessIvEENS8_INS3_4pairIKSA_SE_EEEEEE:
19833|  16.4k|        json_value(const object_t& value) : object(create<object_t>(value)) {}
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createINS2_ISA_SE_NS3_4lessIvEENS8_INS3_4pairIKSA_SE_EEEEEEJRKSM_EEEPT_DpOT0_:
19681|  16.4k|    {
19682|  16.4k|        AllocatorType<T> alloc;
19683|  16.4k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  16.4k|        auto deleter = [&](T * obj)
19686|  16.4k|        {
19687|  16.4k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  16.4k|        };
19689|  16.4k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  16.4k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  16.4k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  16.4k|        return obj.release();
19693|  16.4k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10json_valueC2ERKSA_:
19827|  98.7k|        json_value(const string_t& value) : string(create<string_t>(value)) {}
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createISA_JRKSA_EEEPT_DpOT0_:
19681|  98.7k|    {
19682|  98.7k|        AllocatorType<T> alloc;
19683|  98.7k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  98.7k|        auto deleter = [&](T * obj)
19686|  98.7k|        {
19687|  98.7k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  98.7k|        };
19689|  98.7k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  98.7k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  98.7k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  98.7k|        return obj.release();
19693|  98.7k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE4dataD2Ev:
23517|   610k|        {
23518|   610k|            m_value.destroy(m_type);
23519|   610k|        }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE7is_nullEv:
20618|  93.4k|    {
20619|  93.4k|        return m_data.m_type == value_t::null;
20620|  93.4k|    }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE8is_arrayEv:
20667|   137k|    {
20668|   137k|        return m_data.m_type == value_t::array;
20669|   137k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEixIKcEERSE_PT_:
21460|  60.5k|    {
21461|  60.5k|        return operator[](typename object_t::key_type(key));
21462|  60.5k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE5arrayESt16initializer_listINS0_6detail8json_refISE_EEE:
20308|  5.60k|    {
20309|  5.60k|        return basic_json(init, false, value_t::array);
20310|  5.60k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2ESt16initializer_listINS0_6detail8json_refISE_EEEbNSG_7value_tE:
20207|  27.6k|    {
20208|       |        // check if each element is an array with two elements whose first
20209|       |        // element is a string
20210|  27.6k|        bool is_an_object = std::all_of(init.begin(), init.end(),
20211|  27.6k|                                        [](const detail::json_ref<basic_json>& element_ref)
20212|  27.6k|        {
20213|       |            // The cast is to ensure op[size_type] is called, bearing in mind size_type may not be int;
20214|       |            // (many string types can be constructed from 0 via its null-pointer guise, so we get a
20215|       |            // broken call to op[key_type], the wrong semantics and a 4804 warning on Windows)
20216|  27.6k|            return element_ref->is_array() && element_ref->size() == 2 && (*element_ref)[static_cast<size_type>(0)].is_string();
20217|  27.6k|        });
20218|       |
20219|       |        // adjust type if type deduction is not wanted
20220|  27.6k|        if (!type_deduction)
  ------------------
  |  Branch (20220:13): [True: 27.6k, False: 0]
  ------------------
20221|  27.6k|        {
20222|       |            // if array is wanted, do not create an object though possible
20223|  27.6k|            if (manual_type == value_t::array)
  ------------------
  |  Branch (20223:17): [True: 5.60k, False: 22.0k]
  ------------------
20224|  5.60k|            {
20225|  5.60k|                is_an_object = false;
20226|  5.60k|            }
20227|       |
20228|       |            // if object is wanted but impossible, throw an exception
20229|  27.6k|            if (JSON_HEDLEY_UNLIKELY(manual_type == value_t::object && !is_an_object))
  ------------------
  |  | 1677|  49.7k|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 27.6k]
  |  |  |  Branch (1677:94): [True: 22.0k, False: 5.60k]
  |  |  |  Branch (1677:94): [True: 0, False: 22.0k]
  |  |  ------------------
  ------------------
20230|      0|            {
20231|      0|                JSON_THROW(type_error::create(301, "cannot create object from initializer list", nullptr));
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
20232|      0|            }
20233|  27.6k|        }
20234|       |
20235|  27.6k|        if (is_an_object)
  ------------------
  |  Branch (20235:13): [True: 22.0k, False: 5.60k]
  ------------------
20236|  22.0k|        {
20237|       |            // the initializer list is a list of pairs -> create object
20238|  22.0k|            m_data.m_type = value_t::object;
20239|  22.0k|            m_data.m_value = value_t::object;
20240|       |
20241|  22.0k|            for (auto& element_ref : init)
  ------------------
  |  Branch (20241:36): [True: 0, False: 22.0k]
  ------------------
20242|      0|            {
20243|      0|                auto element = element_ref.moved_or_copied();
20244|      0|                m_data.m_value.object->emplace(
20245|      0|                    std::move(*((*element.m_data.m_value.array)[0].m_data.m_value.string)),
20246|      0|                    std::move((*element.m_data.m_value.array)[1]));
20247|      0|            }
20248|  22.0k|        }
20249|  5.60k|        else
20250|  5.60k|        {
20251|       |            // the initializer list describes an array -> create array
20252|  5.60k|            m_data.m_type = value_t::array;
20253|  5.60k|            m_data.m_value.array = create<array_t>(init.begin(), init.end());
20254|  5.60k|        }
20255|       |
20256|  27.6k|        set_parents();
20257|  27.6k|        assert_invariant();
20258|  27.6k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createINS4_ISE_NS8_ISE_EEEEJPKNS0_6detail8json_refISE_EESM_EEEPT_DpOT0_:
19681|  5.60k|    {
19682|  5.60k|        AllocatorType<T> alloc;
19683|  5.60k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  5.60k|        auto deleter = [&](T * obj)
19686|  5.60k|        {
19687|  5.60k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  5.60k|        };
19689|  5.60k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  5.60k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  5.60k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  5.60k|        return obj.release();
19693|  5.60k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2EOSE_:
20517|   358k|        : json_base_class_t(std::forward<json_base_class_t>(other)),
20518|   358k|          m_data(std::move(other.m_data))
20519|   358k|    {
20520|       |        // check that passed value is valid
20521|   358k|        other.assert_invariant(false);
20522|       |
20523|       |        // invalidate payload
20524|   358k|        other.m_data.m_type = value_t::null;
20525|   358k|        other.m_data.m_value = {};
20526|       |
20527|   358k|        set_parents();
20528|   358k|        assert_invariant();
20529|   358k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvED2Ev:
20557|   610k|    {
20558|   610k|        assert_invariant(false);
20559|   610k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEaSESE_:
20540|  54.9k|    {
20541|       |        // check that passed value is valid
20542|  54.9k|        other.assert_invariant();
20543|       |
20544|  54.9k|        using std::swap;
20545|  54.9k|        swap(m_data.m_type, other.m_data.m_type);
20546|  54.9k|        swap(m_data.m_value, other.m_data.m_value);
20547|  54.9k|        json_base_class_t::operator=(std::move(other));
20548|       |
20549|  54.9k|        set_parents();
20550|  54.9k|        assert_invariant();
20551|  54.9k|        return *this;
20552|  54.9k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6objectESt16initializer_listINS0_6detail8json_refISE_EEE:
20316|  22.0k|    {
20317|  22.0k|        return basic_json(init, false, value_t::object);
20318|  22.0k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2EDn:
20126|  60.5k|        : basic_json(value_t::null)
20127|  60.5k|    {
20128|  60.5k|        assert_invariant();
20129|  60.5k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2ENS0_6detail7value_tE:
20118|  60.5k|        : m_data(v)
20119|  60.5k|    {
20120|  60.5k|        assert_invariant();
20121|  60.5k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE4dataC2ENS0_6detail7value_tE:
23500|  60.5k|            : m_type(v), m_value(v)
23501|  60.5k|        {
23502|  60.5k|        }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2IRPKcSH_TnNS3_9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISE_SK_EE5valueEiE4typeELi0EEEOT_:
20140|  32.9k|    {
20141|  32.9k|        JSONSerializer<U>::to_json(*this, std::forward<CompatibleType>(val));
20142|  32.9k|        set_parents();
20143|  32.9k|        assert_invariant();
20144|  32.9k|    }
_ZN8nlohmann16json_abi_v3_11_314adl_serializerIPKcvE7to_jsonINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS8_12basic_stringIcNS8_11char_traitsIcEENS8_9allocatorIcEEEEblmdSD_S1_NS9_IhNSD_IhEEEEvEERS3_EEDTcmclL_ZNS0_7to_jsonEEfp_clsr3stdE7forwardIT0_Efp0_EEcvv_EERT_OSK_:
 5860|  32.9k|    {
 5861|  32.9k|        ::nlohmann::to_json(j, std::forward<TargetType>(val));
 5862|  32.9k|    }
_ZNK8nlohmann16json_abi_v3_11_36detail10to_json_fnclINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS6_12basic_stringIcNS6_11char_traitsIcEENS6_9allocatorIcEEEEblmdSB_NS0_14adl_serializerENS7_IhNSB_IhEEEEvEERPKcEEDTcmcl7to_jsonfp_clsr3stdE7forwardIT0_Efp0_EEcvv_EERT_OSL_:
 5804|  32.9k|    {
 5805|  32.9k|        return to_json(j, std::forward<T>(val));
 5806|  32.9k|    }
_ZN8nlohmann16json_abi_v3_11_36detail7to_jsonINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEPKcTnNS5_9enable_ifIXsr3std16is_constructibleINT_8string_tET0_EE5valueEiE4typeELi0EEEvRSK_RKSM_:
 5663|  32.9k|{
 5664|  32.9k|    external_constructor<value_t::string>::construct(j, s);
 5665|  32.9k|}
_ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE3EE9constructINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS8_12basic_stringIcNS8_11char_traitsIcEENS8_9allocatorIcEEEEblmdSD_NS0_14adl_serializerENS9_IhNSD_IhEEEEvEEPKcTnNS8_9enable_ifIXntsr3std7is_sameIT0_NT_8string_tEEE5valueEiE4typeELi0EEEvRSO_RKSN_:
 5459|  32.9k|    {
 5460|  32.9k|        j.m_data.m_value.destroy(j.m_data.m_type);
 5461|  32.9k|        j.m_data.m_type = value_t::string;
 5462|  32.9k|        j.m_data.m_value.string = j.template create<typename BasicJsonType::string_t>(str);
 5463|  32.9k|        j.assert_invariant();
 5464|  32.9k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createISA_JRKPKcEEEPT_DpOT0_:
19681|  32.9k|    {
19682|  32.9k|        AllocatorType<T> alloc;
19683|  32.9k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  32.9k|        auto deleter = [&](T * obj)
19686|  32.9k|        {
19687|  32.9k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  32.9k|        };
19689|  32.9k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  32.9k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  32.9k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  32.9k|        return obj.release();
19693|  32.9k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEC2ISA_SA_TnNS3_9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISE_SH_EE5valueEiE4typeELi0EEEOT_:
20140|  16.4k|    {
20141|  16.4k|        JSONSerializer<U>::to_json(*this, std::forward<CompatibleType>(val));
20142|  16.4k|        set_parents();
20143|  16.4k|        assert_invariant();
20144|  16.4k|    }
_ZN8nlohmann16json_abi_v3_11_314adl_serializerINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEEvE7to_jsonINS0_10basic_jsonINS0_11ordered_mapENS2_6vectorES8_blmdS6_S1_NSD_IhNS6_IhEEEEvEES8_EEDTcmclL_ZNS0_7to_jsonEEfp_clsr3stdE7forwardIT0_Efp0_EEcvv_EERT_OSH_:
 5860|  16.4k|    {
 5861|  16.4k|        ::nlohmann::to_json(j, std::forward<TargetType>(val));
 5862|  16.4k|    }
_ZNK8nlohmann16json_abi_v3_11_36detail10to_json_fnclINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS6_12basic_stringIcNS6_11char_traitsIcEENS6_9allocatorIcEEEEblmdSB_NS0_14adl_serializerENS7_IhNSB_IhEEEEvEESD_EEDTcmcl7to_jsonfp_clsr3stdE7forwardIT0_Efp0_EEcvv_EERT_OSI_:
 5804|  16.4k|    {
 5805|  16.4k|        return to_json(j, std::forward<T>(val));
 5806|  16.4k|    }
_ZN8nlohmann16json_abi_v3_11_36detail7to_jsonINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEEEvRT_ONSH_8string_tE:
 5669|  16.4k|{
 5670|  16.4k|    external_constructor<value_t::string>::construct(j, std::move(s));
 5671|  16.4k|}
_ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE3EE9constructINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS8_12basic_stringIcNS8_11char_traitsIcEENS8_9allocatorIcEEEEblmdSD_NS0_14adl_serializerENS9_IhNSD_IhEEEEvEEEEvRT_ONSK_8string_tE:
 5448|  16.4k|    {
 5449|  16.4k|        j.m_data.m_value.destroy(j.m_data.m_type);
 5450|  16.4k|        j.m_data.m_type = value_t::string;
 5451|  16.4k|        j.m_data.m_value = std::move(s);
 5452|  16.4k|        j.assert_invariant();
 5453|  16.4k|    }
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE10json_valueC2EOSA_:
19830|  16.4k|        json_value(string_t&& value) : string(create<string_t>(std::move(value))) {}
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE6createISA_JSA_EEEPT_DpOT0_:
19681|  16.4k|    {
19682|  16.4k|        AllocatorType<T> alloc;
19683|  16.4k|        using AllocatorTraits = std::allocator_traits<AllocatorType<T>>;
19684|       |
19685|  16.4k|        auto deleter = [&](T * obj)
19686|  16.4k|        {
19687|  16.4k|            AllocatorTraits::deallocate(alloc, obj, 1);
19688|  16.4k|        };
19689|  16.4k|        std::unique_ptr<T, decltype(deleter)> obj(AllocatorTraits::allocate(alloc, 1), deleter);
19690|  16.4k|        AllocatorTraits::construct(alloc, obj.get(), std::forward<Args>(args)...);
19691|       |        JSON_ASSERT(obj != nullptr);
  ------------------
  |  | 2552|  16.4k|    #define JSON_ASSERT(x) assert(x)
  ------------------
19692|  16.4k|        return obj.release();
19693|  16.4k|    }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvE4dumpEicbNS0_6detail15error_handler_tE:
20578|  5.60k|    {
20579|  5.60k|        string_t result;
20580|  5.60k|        serializer s(detail::output_adapter<char, string_t>(result), indent_char, error_handler);
20581|       |
20582|  5.60k|        if (indent >= 0)
  ------------------
  |  Branch (20582:13): [True: 5.60k, False: 0]
  ------------------
20583|  5.60k|        {
20584|  5.60k|            s.dump(*this, true, ensure_ascii, static_cast<unsigned int>(indent));
20585|  5.60k|        }
20586|      0|        else
20587|      0|        {
20588|      0|            s.dump(*this, false, ensure_ascii, 0);
20589|      0|        }
20590|       |
20591|  5.60k|        return result;
20592|  5.60k|    }
_ZN8nlohmann16json_abi_v3_11_36detail14output_adapterIcNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEEC2ERS9_:
15049|  5.60k|        : oa(std::make_shared<output_string_adapter<CharType, StringType>>(s)) {}
_ZN8nlohmann16json_abi_v3_11_36detail21output_string_adapterIcNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEEC2ERS9_:
15017|  5.60k|        : str(s)
15018|  5.60k|    {}
_ZN8nlohmann16json_abi_v3_11_36detail23output_adapter_protocolIcEC2Ev:
14950|  5.60k|    output_adapter_protocol() = default;
_ZN8nlohmann16json_abi_v3_11_36detail23output_adapter_protocolIcED2Ev:
14948|  5.60k|    virtual ~output_adapter_protocol() = default;
_ZN8nlohmann16json_abi_v3_11_36detail21output_string_adapterIcNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEE15write_characterEc:
15021|   207k|    {
15022|   207k|        str.push_back(c);
15023|   207k|    }
_ZN8nlohmann16json_abi_v3_11_36detail21output_string_adapterIcNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEE16write_charactersEPKcm:
15027|   329k|    {
15028|   329k|        str.append(s, length);
15029|   329k|    }
_ZN8nlohmann16json_abi_v3_11_36detail14output_adapterIcNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEEcvNS3_10shared_ptrINS1_23output_adapter_protocolIcEEEEEv:
15052|  5.60k|    {
15053|  5.60k|        return oa;
15054|  5.60k|    }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEEC2ENS5_10shared_ptrINS1_23output_adapter_protocolIcEEEEcNS1_15error_handler_tE:
18077|  5.60k|        : o(std::move(s))
18078|  5.60k|        , loc(std::localeconv())
18079|  5.60k|        , thousands_sep(loc->thousands_sep == nullptr ? '\0' : std::char_traits<char>::to_char_type(* (loc->thousands_sep)))
  ------------------
  |  Branch (18079:25): [True: 0, False: 5.60k]
  ------------------
18080|  5.60k|        , decimal_point(loc->decimal_point == nullptr ? '\0' : std::char_traits<char>::to_char_type(* (loc->decimal_point)))
  ------------------
  |  Branch (18080:25): [True: 0, False: 5.60k]
  ------------------
18081|  5.60k|        , indent_char(ichar)
18082|  5.60k|        , indent_string(512, indent_char)
18083|  5.60k|        , error_handler(error_handler_)
18084|  5.60k|    {}
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEE4dumpERKSG_bbjj:
18120|  77.0k|    {
18121|  77.0k|        switch (val.m_data.m_type)
18122|  77.0k|        {
18123|  22.0k|            case value_t::object:
  ------------------
  |  Branch (18123:13): [True: 22.0k, False: 54.9k]
  ------------------
18124|  22.0k|            {
18125|  22.0k|                if (val.m_data.m_value.object->empty())
  ------------------
  |  Branch (18125:21): [True: 0, False: 22.0k]
  ------------------
18126|      0|                {
18127|      0|                    o->write_characters("{}", 2);
18128|      0|                    return;
18129|      0|                }
18130|       |
18131|  22.0k|                if (pretty_print)
  ------------------
  |  Branch (18131:21): [True: 22.0k, False: 0]
  ------------------
18132|  22.0k|                {
18133|  22.0k|                    o->write_characters("{\n", 2);
18134|       |
18135|       |                    // variable to hold indentation for recursive calls
18136|  22.0k|                    const auto new_indent = current_indent + indent_step;
18137|  22.0k|                    if (JSON_HEDLEY_UNLIKELY(indent_string.size() < new_indent))
  ------------------
  |  | 1677|  22.0k|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 22.0k]
  |  |  ------------------
  ------------------
18138|      0|                    {
18139|      0|                        indent_string.resize(indent_string.size() * 2, ' ');
18140|      0|                    }
18141|       |
18142|       |                    // first n-1 elements
18143|  22.0k|                    auto i = val.m_data.m_value.object->cbegin();
18144|  54.9k|                    for (std::size_t cnt = 0; cnt < val.m_data.m_value.object->size() - 1; ++cnt, ++i)
  ------------------
  |  Branch (18144:47): [True: 32.9k, False: 22.0k]
  ------------------
18145|  32.9k|                    {
18146|  32.9k|                        o->write_characters(indent_string.c_str(), new_indent);
18147|  32.9k|                        o->write_character('\"');
18148|  32.9k|                        dump_escaped(i->first, ensure_ascii);
18149|  32.9k|                        o->write_characters("\": ", 3);
18150|  32.9k|                        dump(i->second, true, ensure_ascii, indent_step, new_indent);
18151|  32.9k|                        o->write_characters(",\n", 2);
18152|  32.9k|                    }
18153|       |
18154|       |                    // last element
18155|  22.0k|                    JSON_ASSERT(i != val.m_data.m_value.object->cend());
  ------------------
  |  | 2552|  22.0k|    #define JSON_ASSERT(x) assert(x)
  ------------------
18156|  22.0k|                    JSON_ASSERT(std::next(i) == val.m_data.m_value.object->cend());
  ------------------
  |  | 2552|  22.0k|    #define JSON_ASSERT(x) assert(x)
  ------------------
18157|  22.0k|                    o->write_characters(indent_string.c_str(), new_indent);
18158|  22.0k|                    o->write_character('\"');
18159|  22.0k|                    dump_escaped(i->first, ensure_ascii);
18160|  22.0k|                    o->write_characters("\": ", 3);
18161|  22.0k|                    dump(i->second, true, ensure_ascii, indent_step, new_indent);
18162|       |
18163|  22.0k|                    o->write_character('\n');
18164|  22.0k|                    o->write_characters(indent_string.c_str(), current_indent);
18165|  22.0k|                    o->write_character('}');
18166|  22.0k|                }
18167|      0|                else
18168|      0|                {
18169|      0|                    o->write_character('{');
18170|       |
18171|       |                    // first n-1 elements
18172|      0|                    auto i = val.m_data.m_value.object->cbegin();
18173|      0|                    for (std::size_t cnt = 0; cnt < val.m_data.m_value.object->size() - 1; ++cnt, ++i)
  ------------------
  |  Branch (18173:47): [True: 0, False: 0]
  ------------------
18174|      0|                    {
18175|      0|                        o->write_character('\"');
18176|      0|                        dump_escaped(i->first, ensure_ascii);
18177|      0|                        o->write_characters("\":", 2);
18178|      0|                        dump(i->second, false, ensure_ascii, indent_step, current_indent);
18179|      0|                        o->write_character(',');
18180|      0|                    }
18181|       |
18182|       |                    // last element
18183|      0|                    JSON_ASSERT(i != val.m_data.m_value.object->cend());
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18184|      0|                    JSON_ASSERT(std::next(i) == val.m_data.m_value.object->cend());
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18185|      0|                    o->write_character('\"');
18186|      0|                    dump_escaped(i->first, ensure_ascii);
18187|      0|                    o->write_characters("\":", 2);
18188|      0|                    dump(i->second, false, ensure_ascii, indent_step, current_indent);
18189|       |
18190|      0|                    o->write_character('}');
18191|      0|                }
18192|       |
18193|  22.0k|                return;
18194|  22.0k|            }
18195|       |
18196|  5.60k|            case value_t::array:
  ------------------
  |  Branch (18196:13): [True: 5.60k, False: 71.4k]
  ------------------
18197|  5.60k|            {
18198|  5.60k|                if (val.m_data.m_value.array->empty())
  ------------------
  |  Branch (18198:21): [True: 730, False: 4.87k]
  ------------------
18199|    730|                {
18200|    730|                    o->write_characters("[]", 2);
18201|    730|                    return;
18202|    730|                }
18203|       |
18204|  4.87k|                if (pretty_print)
  ------------------
  |  Branch (18204:21): [True: 4.87k, False: 0]
  ------------------
18205|  4.87k|                {
18206|  4.87k|                    o->write_characters("[\n", 2);
18207|       |
18208|       |                    // variable to hold indentation for recursive calls
18209|  4.87k|                    const auto new_indent = current_indent + indent_step;
18210|  4.87k|                    if (JSON_HEDLEY_UNLIKELY(indent_string.size() < new_indent))
  ------------------
  |  | 1677|  4.87k|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 4.87k]
  |  |  ------------------
  ------------------
18211|      0|                    {
18212|      0|                        indent_string.resize(indent_string.size() * 2, ' ');
18213|      0|                    }
18214|       |
18215|       |                    // first n-1 elements
18216|  4.87k|                    for (auto i = val.m_data.m_value.array->cbegin();
18217|  16.4k|                            i != val.m_data.m_value.array->cend() - 1; ++i)
  ------------------
  |  Branch (18217:29): [True: 11.5k, False: 4.87k]
  ------------------
18218|  11.5k|                    {
18219|  11.5k|                        o->write_characters(indent_string.c_str(), new_indent);
18220|  11.5k|                        dump(*i, true, ensure_ascii, indent_step, new_indent);
18221|  11.5k|                        o->write_characters(",\n", 2);
18222|  11.5k|                    }
18223|       |
18224|       |                    // last element
18225|  4.87k|                    JSON_ASSERT(!val.m_data.m_value.array->empty());
  ------------------
  |  | 2552|  4.87k|    #define JSON_ASSERT(x) assert(x)
  ------------------
18226|  4.87k|                    o->write_characters(indent_string.c_str(), new_indent);
18227|  4.87k|                    dump(val.m_data.m_value.array->back(), true, ensure_ascii, indent_step, new_indent);
18228|       |
18229|  4.87k|                    o->write_character('\n');
18230|  4.87k|                    o->write_characters(indent_string.c_str(), current_indent);
18231|  4.87k|                    o->write_character(']');
18232|  4.87k|                }
18233|      0|                else
18234|      0|                {
18235|      0|                    o->write_character('[');
18236|       |
18237|       |                    // first n-1 elements
18238|      0|                    for (auto i = val.m_data.m_value.array->cbegin();
18239|      0|                            i != val.m_data.m_value.array->cend() - 1; ++i)
  ------------------
  |  Branch (18239:29): [True: 0, False: 0]
  ------------------
18240|      0|                    {
18241|      0|                        dump(*i, false, ensure_ascii, indent_step, current_indent);
18242|      0|                        o->write_character(',');
18243|      0|                    }
18244|       |
18245|       |                    // last element
18246|      0|                    JSON_ASSERT(!val.m_data.m_value.array->empty());
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18247|      0|                    dump(val.m_data.m_value.array->back(), false, ensure_ascii, indent_step, current_indent);
18248|       |
18249|      0|                    o->write_character(']');
18250|      0|                }
18251|       |
18252|  4.87k|                return;
18253|  5.60k|            }
18254|       |
18255|  49.3k|            case value_t::string:
  ------------------
  |  Branch (18255:13): [True: 49.3k, False: 27.6k]
  ------------------
18256|  49.3k|            {
18257|  49.3k|                o->write_character('\"');
18258|  49.3k|                dump_escaped(*val.m_data.m_value.string, ensure_ascii);
18259|  49.3k|                o->write_character('\"');
18260|  49.3k|                return;
18261|  5.60k|            }
18262|       |
18263|      0|            case value_t::binary:
  ------------------
  |  Branch (18263:13): [True: 0, False: 77.0k]
  ------------------
18264|      0|            {
18265|      0|                if (pretty_print)
  ------------------
  |  Branch (18265:21): [True: 0, False: 0]
  ------------------
18266|      0|                {
18267|      0|                    o->write_characters("{\n", 2);
18268|       |
18269|       |                    // variable to hold indentation for recursive calls
18270|      0|                    const auto new_indent = current_indent + indent_step;
18271|      0|                    if (JSON_HEDLEY_UNLIKELY(indent_string.size() < new_indent))
  ------------------
  |  | 1677|      0|#  define JSON_HEDLEY_UNLIKELY(expr)                    __builtin_expect                 (!!(expr),    0                  )
  |  |  ------------------
  |  |  |  Branch (1677:57): [True: 0, False: 0]
  |  |  ------------------
  ------------------
18272|      0|                    {
18273|      0|                        indent_string.resize(indent_string.size() * 2, ' ');
18274|      0|                    }
18275|       |
18276|      0|                    o->write_characters(indent_string.c_str(), new_indent);
18277|       |
18278|      0|                    o->write_characters("\"bytes\": [", 10);
18279|       |
18280|      0|                    if (!val.m_data.m_value.binary->empty())
  ------------------
  |  Branch (18280:25): [True: 0, False: 0]
  ------------------
18281|      0|                    {
18282|      0|                        for (auto i = val.m_data.m_value.binary->cbegin();
18283|      0|                                i != val.m_data.m_value.binary->cend() - 1; ++i)
  ------------------
  |  Branch (18283:33): [True: 0, False: 0]
  ------------------
18284|      0|                        {
18285|      0|                            dump_integer(*i);
18286|      0|                            o->write_characters(", ", 2);
18287|      0|                        }
18288|      0|                        dump_integer(val.m_data.m_value.binary->back());
18289|      0|                    }
18290|       |
18291|      0|                    o->write_characters("],\n", 3);
18292|      0|                    o->write_characters(indent_string.c_str(), new_indent);
18293|       |
18294|      0|                    o->write_characters("\"subtype\": ", 11);
18295|      0|                    if (val.m_data.m_value.binary->has_subtype())
  ------------------
  |  Branch (18295:25): [True: 0, False: 0]
  ------------------
18296|      0|                    {
18297|      0|                        dump_integer(val.m_data.m_value.binary->subtype());
18298|      0|                    }
18299|      0|                    else
18300|      0|                    {
18301|      0|                        o->write_characters("null", 4);
18302|      0|                    }
18303|      0|                    o->write_character('\n');
18304|      0|                    o->write_characters(indent_string.c_str(), current_indent);
18305|      0|                    o->write_character('}');
18306|      0|                }
18307|      0|                else
18308|      0|                {
18309|      0|                    o->write_characters("{\"bytes\":[", 10);
18310|       |
18311|      0|                    if (!val.m_data.m_value.binary->empty())
  ------------------
  |  Branch (18311:25): [True: 0, False: 0]
  ------------------
18312|      0|                    {
18313|      0|                        for (auto i = val.m_data.m_value.binary->cbegin();
18314|      0|                                i != val.m_data.m_value.binary->cend() - 1; ++i)
  ------------------
  |  Branch (18314:33): [True: 0, False: 0]
  ------------------
18315|      0|                        {
18316|      0|                            dump_integer(*i);
18317|      0|                            o->write_character(',');
18318|      0|                        }
18319|      0|                        dump_integer(val.m_data.m_value.binary->back());
18320|      0|                    }
18321|       |
18322|      0|                    o->write_characters("],\"subtype\":", 12);
18323|      0|                    if (val.m_data.m_value.binary->has_subtype())
  ------------------
  |  Branch (18323:25): [True: 0, False: 0]
  ------------------
18324|      0|                    {
18325|      0|                        dump_integer(val.m_data.m_value.binary->subtype());
18326|      0|                        o->write_character('}');
18327|      0|                    }
18328|      0|                    else
18329|      0|                    {
18330|      0|                        o->write_characters("null}", 5);
18331|      0|                    }
18332|      0|                }
18333|      0|                return;
18334|  5.60k|            }
18335|       |
18336|      0|            case value_t::boolean:
  ------------------
  |  Branch (18336:13): [True: 0, False: 77.0k]
  ------------------
18337|      0|            {
18338|      0|                if (val.m_data.m_value.boolean)
  ------------------
  |  Branch (18338:21): [True: 0, False: 0]
  ------------------
18339|      0|                {
18340|      0|                    o->write_characters("true", 4);
18341|      0|                }
18342|      0|                else
18343|      0|                {
18344|      0|                    o->write_characters("false", 5);
18345|      0|                }
18346|      0|                return;
18347|  5.60k|            }
18348|       |
18349|      0|            case value_t::number_integer:
  ------------------
  |  Branch (18349:13): [True: 0, False: 77.0k]
  ------------------
18350|      0|            {
18351|      0|                dump_integer(val.m_data.m_value.number_integer);
18352|      0|                return;
18353|  5.60k|            }
18354|       |
18355|      0|            case value_t::number_unsigned:
  ------------------
  |  Branch (18355:13): [True: 0, False: 77.0k]
  ------------------
18356|      0|            {
18357|      0|                dump_integer(val.m_data.m_value.number_unsigned);
18358|      0|                return;
18359|  5.60k|            }
18360|       |
18361|      0|            case value_t::number_float:
  ------------------
  |  Branch (18361:13): [True: 0, False: 77.0k]
  ------------------
18362|      0|            {
18363|      0|                dump_float(val.m_data.m_value.number_float);
18364|      0|                return;
18365|  5.60k|            }
18366|       |
18367|      0|            case value_t::discarded:
  ------------------
  |  Branch (18367:13): [True: 0, False: 77.0k]
  ------------------
18368|      0|            {
18369|      0|                o->write_characters("<discarded>", 11);
18370|      0|                return;
18371|  5.60k|            }
18372|       |
18373|      0|            case value_t::null:
  ------------------
  |  Branch (18373:13): [True: 0, False: 77.0k]
  ------------------
18374|      0|            {
18375|      0|                o->write_characters("null", 4);
18376|      0|                return;
18377|  5.60k|            }
18378|       |
18379|      0|            default:            // LCOV_EXCL_LINE
  ------------------
  |  Branch (18379:13): [True: 0, False: 77.0k]
  ------------------
18380|       |                JSON_ASSERT(false); // NOLINT(cert-dcl03-c,hicpp-static-assert,misc-static-assert) LCOV_EXCL_LINE
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18381|  77.0k|        }
18382|  77.0k|    }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEE12dump_escapedERKSC_b:
18400|   104k|    {
18401|   104k|        std::uint32_t codepoint{};
18402|   104k|        std::uint8_t state = UTF8_ACCEPT;
18403|   104k|        std::size_t bytes = 0;  // number of bytes written to string_buffer
18404|       |
18405|       |        // number of bytes written at the point of the last valid byte
18406|   104k|        std::size_t bytes_after_last_accept = 0;
18407|   104k|        std::size_t undumped_chars = 0;
18408|       |
18409|  1.28M|        for (std::size_t i = 0; i < s.size(); ++i)
  ------------------
  |  Branch (18409:33): [True: 1.17M, False: 104k]
  ------------------
18410|  1.17M|        {
18411|  1.17M|            const auto byte = static_cast<std::uint8_t>(s[i]);
18412|       |
18413|  1.17M|            switch (decode(state, codepoint, byte))
18414|  1.17M|            {
18415|  1.17M|                case UTF8_ACCEPT:  // decode found a new code point
  ------------------
  |  Branch (18415:17): [True: 1.17M, False: 0]
  ------------------
18416|  1.17M|                {
18417|  1.17M|                    switch (codepoint)
18418|  1.17M|                    {
18419|      0|                        case 0x08: // backspace
  ------------------
  |  Branch (18419:25): [True: 0, False: 1.17M]
  ------------------
18420|      0|                        {
18421|      0|                            string_buffer[bytes++] = '\\';
18422|      0|                            string_buffer[bytes++] = 'b';
18423|      0|                            break;
18424|      0|                        }
18425|       |
18426|      0|                        case 0x09: // horizontal tab
  ------------------
  |  Branch (18426:25): [True: 0, False: 1.17M]
  ------------------
18427|      0|                        {
18428|      0|                            string_buffer[bytes++] = '\\';
18429|      0|                            string_buffer[bytes++] = 't';
18430|      0|                            break;
18431|      0|                        }
18432|       |
18433|      0|                        case 0x0A: // newline
  ------------------
  |  Branch (18433:25): [True: 0, False: 1.17M]
  ------------------
18434|      0|                        {
18435|      0|                            string_buffer[bytes++] = '\\';
18436|      0|                            string_buffer[bytes++] = 'n';
18437|      0|                            break;
18438|      0|                        }
18439|       |
18440|      0|                        case 0x0C: // formfeed
  ------------------
  |  Branch (18440:25): [True: 0, False: 1.17M]
  ------------------
18441|      0|                        {
18442|      0|                            string_buffer[bytes++] = '\\';
18443|      0|                            string_buffer[bytes++] = 'f';
18444|      0|                            break;
18445|      0|                        }
18446|       |
18447|      0|                        case 0x0D: // carriage return
  ------------------
  |  Branch (18447:25): [True: 0, False: 1.17M]
  ------------------
18448|      0|                        {
18449|      0|                            string_buffer[bytes++] = '\\';
18450|      0|                            string_buffer[bytes++] = 'r';
18451|      0|                            break;
18452|      0|                        }
18453|       |
18454|      0|                        case 0x22: // quotation mark
  ------------------
  |  Branch (18454:25): [True: 0, False: 1.17M]
  ------------------
18455|      0|                        {
18456|      0|                            string_buffer[bytes++] = '\\';
18457|      0|                            string_buffer[bytes++] = '\"';
18458|      0|                            break;
18459|      0|                        }
18460|       |
18461|      0|                        case 0x5C: // reverse solidus
  ------------------
  |  Branch (18461:25): [True: 0, False: 1.17M]
  ------------------
18462|      0|                        {
18463|      0|                            string_buffer[bytes++] = '\\';
18464|      0|                            string_buffer[bytes++] = '\\';
18465|      0|                            break;
18466|      0|                        }
18467|       |
18468|  1.17M|                        default:
  ------------------
  |  Branch (18468:25): [True: 1.17M, False: 0]
  ------------------
18469|  1.17M|                        {
18470|       |                            // escape control characters (0x00..0x1F) or, if
18471|       |                            // ensure_ascii parameter is used, non-ASCII characters
18472|  1.17M|                            if ((codepoint <= 0x1F) || (ensure_ascii && (codepoint >= 0x7F)))
  ------------------
  |  Branch (18472:33): [True: 0, False: 1.17M]
  |  Branch (18472:57): [True: 0, False: 1.17M]
  |  Branch (18472:73): [True: 0, False: 0]
  ------------------
18473|      0|                            {
18474|      0|                                if (codepoint <= 0xFFFF)
  ------------------
  |  Branch (18474:37): [True: 0, False: 0]
  ------------------
18475|      0|                                {
18476|       |                                    // NOLINTNEXTLINE(cppcoreguidelines-pro-type-vararg,hicpp-vararg)
18477|      0|                                    static_cast<void>((std::snprintf)(string_buffer.data() + bytes, 7, "\\u%04x",
18478|      0|                                                                      static_cast<std::uint16_t>(codepoint)));
18479|      0|                                    bytes += 6;
18480|      0|                                }
18481|      0|                                else
18482|      0|                                {
18483|       |                                    // NOLINTNEXTLINE(cppcoreguidelines-pro-type-vararg,hicpp-vararg)
18484|      0|                                    static_cast<void>((std::snprintf)(string_buffer.data() + bytes, 13, "\\u%04x\\u%04x",
18485|      0|                                                                      static_cast<std::uint16_t>(0xD7C0u + (codepoint >> 10u)),
18486|      0|                                                                      static_cast<std::uint16_t>(0xDC00u + (codepoint & 0x3FFu))));
18487|      0|                                    bytes += 12;
18488|      0|                                }
18489|      0|                            }
18490|  1.17M|                            else
18491|  1.17M|                            {
18492|       |                                // copy byte to buffer (all previous bytes
18493|       |                                // been copied have in default case above)
18494|  1.17M|                                string_buffer[bytes++] = s[i];
18495|  1.17M|                            }
18496|  1.17M|                            break;
18497|      0|                        }
18498|  1.17M|                    }
18499|       |
18500|       |                    // write buffer and reset index; there must be 13 bytes
18501|       |                    // left, as this is the maximal number of bytes to be
18502|       |                    // written ("\uxxxx\uxxxx\0") for one code point
18503|  1.17M|                    if (string_buffer.size() - bytes < 13)
  ------------------
  |  Branch (18503:25): [True: 0, False: 1.17M]
  ------------------
18504|      0|                    {
18505|      0|                        o->write_characters(string_buffer.data(), bytes);
18506|      0|                        bytes = 0;
18507|      0|                    }
18508|       |
18509|       |                    // remember the byte position of this accept
18510|  1.17M|                    bytes_after_last_accept = bytes;
18511|  1.17M|                    undumped_chars = 0;
18512|  1.17M|                    break;
18513|  1.17M|                }
18514|       |
18515|      0|                case UTF8_REJECT:  // decode found invalid UTF-8 byte
  ------------------
  |  Branch (18515:17): [True: 0, False: 1.17M]
  ------------------
18516|      0|                {
18517|      0|                    switch (error_handler)
18518|      0|                    {
18519|      0|                        case error_handler_t::strict:
  ------------------
  |  Branch (18519:25): [True: 0, False: 0]
  ------------------
18520|      0|                        {
18521|      0|                            JSON_THROW(type_error::create(316, concat("invalid UTF-8 byte at index ", std::to_string(i), ": 0x", hex_bytes(byte | 0)), nullptr));
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
18522|      0|                        }
18523|       |
18524|      0|                        case error_handler_t::ignore:
  ------------------
  |  Branch (18524:25): [True: 0, False: 0]
  ------------------
18525|      0|                        case error_handler_t::replace:
  ------------------
  |  Branch (18525:25): [True: 0, False: 0]
  ------------------
18526|      0|                        {
18527|       |                            // in case we saw this character the first time, we
18528|       |                            // would like to read it again, because the byte
18529|       |                            // may be OK for itself, but just not OK for the
18530|       |                            // previous sequence
18531|      0|                            if (undumped_chars > 0)
  ------------------
  |  Branch (18531:33): [True: 0, False: 0]
  ------------------
18532|      0|                            {
18533|      0|                                --i;
18534|      0|                            }
18535|       |
18536|       |                            // reset length buffer to the last accepted index;
18537|       |                            // thus removing/ignoring the invalid characters
18538|      0|                            bytes = bytes_after_last_accept;
18539|       |
18540|      0|                            if (error_handler == error_handler_t::replace)
  ------------------
  |  Branch (18540:33): [True: 0, False: 0]
  ------------------
18541|      0|                            {
18542|       |                                // add a replacement character
18543|      0|                                if (ensure_ascii)
  ------------------
  |  Branch (18543:37): [True: 0, False: 0]
  ------------------
18544|      0|                                {
18545|      0|                                    string_buffer[bytes++] = '\\';
18546|      0|                                    string_buffer[bytes++] = 'u';
18547|      0|                                    string_buffer[bytes++] = 'f';
18548|      0|                                    string_buffer[bytes++] = 'f';
18549|      0|                                    string_buffer[bytes++] = 'f';
18550|      0|                                    string_buffer[bytes++] = 'd';
18551|      0|                                }
18552|      0|                                else
18553|      0|                                {
18554|      0|                                    string_buffer[bytes++] = detail::binary_writer<BasicJsonType, char>::to_char_type('\xEF');
18555|      0|                                    string_buffer[bytes++] = detail::binary_writer<BasicJsonType, char>::to_char_type('\xBF');
18556|      0|                                    string_buffer[bytes++] = detail::binary_writer<BasicJsonType, char>::to_char_type('\xBD');
18557|      0|                                }
18558|       |
18559|       |                                // write buffer and reset index; there must be 13 bytes
18560|       |                                // left, as this is the maximal number of bytes to be
18561|       |                                // written ("\uxxxx\uxxxx\0") for one code point
18562|      0|                                if (string_buffer.size() - bytes < 13)
  ------------------
  |  Branch (18562:37): [True: 0, False: 0]
  ------------------
18563|      0|                                {
18564|      0|                                    o->write_characters(string_buffer.data(), bytes);
18565|      0|                                    bytes = 0;
18566|      0|                                }
18567|       |
18568|      0|                                bytes_after_last_accept = bytes;
18569|      0|                            }
18570|       |
18571|      0|                            undumped_chars = 0;
18572|       |
18573|       |                            // continue processing the string
18574|      0|                            state = UTF8_ACCEPT;
18575|      0|                            break;
18576|      0|                        }
18577|       |
18578|      0|                        default:            // LCOV_EXCL_LINE
  ------------------
  |  Branch (18578:25): [True: 0, False: 0]
  ------------------
18579|      0|                            JSON_ASSERT(false); // NOLINT(cert-dcl03-c,hicpp-static-assert,misc-static-assert) LCOV_EXCL_LINE
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18580|      0|                    }
18581|      0|                    break;
18582|      0|                }
18583|       |
18584|      0|                default:  // decode found yet incomplete multi-byte code point
  ------------------
  |  Branch (18584:17): [True: 0, False: 1.17M]
  ------------------
18585|      0|                {
18586|      0|                    if (!ensure_ascii)
  ------------------
  |  Branch (18586:25): [True: 0, False: 0]
  ------------------
18587|      0|                    {
18588|       |                        // code point will not be escaped - copy byte to buffer
18589|      0|                        string_buffer[bytes++] = s[i];
18590|      0|                    }
18591|      0|                    ++undumped_chars;
18592|      0|                    break;
18593|      0|                }
18594|  1.17M|            }
18595|  1.17M|        }
18596|       |
18597|       |        // we finished processing the string
18598|   104k|        if (JSON_HEDLEY_LIKELY(state == UTF8_ACCEPT))
  ------------------
  |  | 1676|   104k|#  define JSON_HEDLEY_LIKELY(expr)                      __builtin_expect                 (!!(expr),    1                  )
  |  |  ------------------
  |  |  |  Branch (1676:57): [True: 104k, False: 0]
  |  |  ------------------
  ------------------
18599|   104k|        {
18600|       |            // write buffer
18601|   104k|            if (bytes > 0)
  ------------------
  |  Branch (18601:17): [True: 104k, False: 0]
  ------------------
18602|   104k|            {
18603|   104k|                o->write_characters(string_buffer.data(), bytes);
18604|   104k|            }
18605|   104k|        }
18606|      0|        else
18607|      0|        {
18608|       |            // we finish reading, but do not accept: string was incomplete
18609|      0|            switch (error_handler)
18610|      0|            {
18611|      0|                case error_handler_t::strict:
  ------------------
  |  Branch (18611:17): [True: 0, False: 0]
  ------------------
18612|      0|                {
18613|      0|                    JSON_THROW(type_error::create(316, concat("incomplete UTF-8 string; last byte: 0x", hex_bytes(static_cast<std::uint8_t>(s.back() | 0))), nullptr));
  ------------------
  |  | 2517|      0|    #define JSON_THROW(exception) throw exception
  ------------------
18614|      0|                }
18615|       |
18616|      0|                case error_handler_t::ignore:
  ------------------
  |  Branch (18616:17): [True: 0, False: 0]
  ------------------
18617|      0|                {
18618|       |                    // write all accepted bytes
18619|      0|                    o->write_characters(string_buffer.data(), bytes_after_last_accept);
18620|      0|                    break;
18621|      0|                }
18622|       |
18623|      0|                case error_handler_t::replace:
  ------------------
  |  Branch (18623:17): [True: 0, False: 0]
  ------------------
18624|      0|                {
18625|       |                    // write all accepted bytes
18626|      0|                    o->write_characters(string_buffer.data(), bytes_after_last_accept);
18627|       |                    // add a replacement character
18628|      0|                    if (ensure_ascii)
  ------------------
  |  Branch (18628:25): [True: 0, False: 0]
  ------------------
18629|      0|                    {
18630|      0|                        o->write_characters("\\ufffd", 6);
18631|      0|                    }
18632|      0|                    else
18633|      0|                    {
18634|      0|                        o->write_characters("\xEF\xBF\xBD", 3);
18635|      0|                    }
18636|      0|                    break;
18637|      0|                }
18638|       |
18639|      0|                default:            // LCOV_EXCL_LINE
  ------------------
  |  Branch (18639:17): [True: 0, False: 0]
  ------------------
18640|       |                    JSON_ASSERT(false); // NOLINT(cert-dcl03-c,hicpp-static-assert,misc-static-assert) LCOV_EXCL_LINE
  ------------------
  |  | 2552|      0|    #define JSON_ASSERT(x) assert(x)
  ------------------
18641|      0|            }
18642|      0|        }
18643|   104k|    }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEE6decodeERhRjh:
18909|  1.17M|    {
18910|  1.17M|        static const std::array<std::uint8_t, 400> utf8d =
18911|  1.17M|        {
18912|  1.17M|            {
18913|  1.17M|                0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 00..1F
18914|  1.17M|                0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 20..3F
18915|  1.17M|                0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 40..5F
18916|  1.17M|                0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 60..7F
18917|  1.17M|                1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, // 80..9F
18918|  1.17M|                7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, // A0..BF
18919|  1.17M|                8, 8, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, // C0..DF
18920|  1.17M|                0xA, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x4, 0x3, 0x3, // E0..EF
18921|  1.17M|                0xB, 0x6, 0x6, 0x6, 0x5, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, // F0..FF
18922|  1.17M|                0x0, 0x1, 0x2, 0x3, 0x5, 0x8, 0x7, 0x1, 0x1, 0x1, 0x4, 0x6, 0x1, 0x1, 0x1, 0x1, // s0..s0
18923|  1.17M|                1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, // s1..s2
18924|  1.17M|                1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, // s3..s4
18925|  1.17M|                1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, // s5..s6
18926|  1.17M|                1, 3, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 // s7..s8
18927|  1.17M|            }
18928|  1.17M|        };
18929|       |
18930|  1.17M|        JSON_ASSERT(byte < utf8d.size());
  ------------------
  |  | 2552|  1.17M|    #define JSON_ASSERT(x) assert(x)
  ------------------
18931|  1.17M|        const std::uint8_t type = utf8d[byte];
18932|       |
18933|  1.17M|        codep = (state != UTF8_ACCEPT)
  ------------------
  |  Branch (18933:17): [True: 0, False: 1.17M]
  ------------------
18934|  1.17M|                ? (byte & 0x3fu) | (codep << 6u)
18935|  1.17M|                : (0xFFu >> type) & (byte);
18936|       |
18937|  1.17M|        const std::size_t index = 256u + static_cast<size_t>(state) * 16u + static_cast<size_t>(type);
18938|       |        JSON_ASSERT(index < utf8d.size());
  ------------------
  |  | 2552|  1.17M|    #define JSON_ASSERT(x) assert(x)
  ------------------
18939|  1.17M|        state = utf8d[index];
18940|  1.17M|        return state;
18941|  1.17M|    }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapENSt3__16vectorENS5_12basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEEblmdSA_NS0_14adl_serializerENS6_IhNSA_IhEEEEvEEED2Ev:
18091|  5.60k|    ~serializer() = default;

_Z20pgp_request_passwordPK23pgp_password_provider_tPK18pgp_password_ctx_tPcm:
   51|  8.81k|{
   52|  8.81k|    if (!provider || !provider->callback || !ctx || !password || !password_size) {
  ------------------
  |  Branch (52:9): [True: 0, False: 8.81k]
  |  Branch (52:22): [True: 0, False: 8.81k]
  |  Branch (52:45): [True: 0, False: 8.81k]
  |  Branch (52:53): [True: 0, False: 8.81k]
  |  Branch (52:66): [True: 0, False: 8.81k]
  ------------------
   53|      0|        return false;
   54|      0|    }
   55|  8.81k|    return provider->callback(ctx, password, password_size, provider->userdata);
   56|  8.81k|}

_ZN18pgp_password_ctx_tC2EhPKN3rnp3KeyE:
   40|  8.46k|    pgp_password_ctx_t(uint8_t anop, const rnp::Key *akey = NULL) : op(anop), key(akey){};
_ZN23pgp_password_provider_tC2EPFbPK18pgp_password_ctx_tPcmPvES4_:
   52|  12.7k|        : callback(cb), userdata(ud){};

_ZN3rnp9RawPacketC2ERKN3pgp3pkt9SignatureE:
   41|  40.8k|{
   42|  40.8k|    data_ = sig.write();
   43|  40.8k|    tag_ = PGP_PKT_SIGNATURE;
   44|  40.8k|}
_ZN3rnp9RawPacketC2ER13pgp_key_pkt_t:
   47|  55.3k|{
   48|  55.3k|    rnp::MemoryDest dst;
   49|  55.3k|    key.write(dst.dst());
   50|  55.3k|    data_ = dst.to_vector();
   51|  55.3k|    tag_ = key.tag;
   52|  55.3k|}
_ZN3rnp9RawPacketC2ERK16pgp_userid_pkt_t:
   55|   322k|{
   56|   322k|    rnp::MemoryDest dst;
   57|   322k|    uid.write(dst.dst());
   58|   322k|    data_ = dst.to_vector();
   59|   322k|    tag_ = uid.tag;
   60|   322k|}

_ZN3rnp9RawPacketC2Ev:
   42|   457k|    RawPacket() : tag_(PGP_PKT_RESERVED){};

_ZN10rnp_ffi_stC2EN3rnp9KeyFormatES1_:
  622|  12.7k|{
  623|  12.7k|    errs = stderr;
  624|  12.7k|    pubring = new rnp::KeyStore("", context, pub_fmt);
  625|  12.7k|    secring = new rnp::KeyStore("", context, sec_fmt);
  626|  12.7k|    getkeycb = NULL;
  627|  12.7k|    getkeycb_ctx = NULL;
  628|  12.7k|    getpasscb = NULL;
  629|       |    getpasscb_ctx = NULL;
  630|  12.7k|    key_provider.callback = ffi_key_provider;
  631|  12.7k|    key_provider.userdata = this;
  632|  12.7k|    pass_provider.callback = rnp_password_cb_bounce;
  633|  12.7k|    pass_provider.userdata = this;
  634|  12.7k|}
_ZN10rnp_ffi_st7profileEv:
  644|  28.1k|{
  645|  28.1k|    return context.profile;
  646|  28.1k|}
rnp_ffi_create:
  650|  12.7k|try {
  651|       |    // checks
  652|  12.7k|    if (!ffi || !pub_format || !sec_format) {
  ------------------
  |  Branch (652:9): [True: 0, False: 12.7k]
  |  Branch (652:17): [True: 0, False: 12.7k]
  |  Branch (652:32): [True: 0, False: 12.7k]
  ------------------
  653|      0|        return RNP_ERROR_NULL_POINTER;
  654|      0|    }
  655|       |
  656|  12.7k|    auto pub_ks_format = rnp::KeyFormat::Unknown;
  657|  12.7k|    auto sec_ks_format = rnp::KeyFormat::Unknown;
  658|  12.7k|    if (!parse_ks_format(&pub_ks_format, pub_format) ||
  ------------------
  |  Branch (658:9): [True: 0, False: 12.7k]
  ------------------
  659|  12.7k|        !parse_ks_format(&sec_ks_format, sec_format)) {
  ------------------
  |  Branch (659:9): [True: 0, False: 12.7k]
  ------------------
  660|      0|        return RNP_ERROR_BAD_PARAMETERS;
  661|      0|    }
  662|       |
  663|  12.7k|    struct rnp_ffi_st *ob = new rnp_ffi_st(pub_ks_format, sec_ks_format);
  664|  12.7k|    *ffi = ob;
  665|  12.7k|    return RNP_SUCCESS;
  666|  12.7k|}
  667|  12.7k|FFI_GUARD
  ------------------
  |  |  619|  12.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.7k|    catch (...)                                                                     \
  |  |  |  |  615|  12.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
_ZN10rnp_ffi_stD2Ev:
  685|  12.7k|{
  686|  12.7k|    close_io_file(&errs);
  687|  12.7k|    delete pubring;
  688|  12.7k|    delete secring;
  689|  12.7k|}
rnp_ffi_destroy:
  693|  12.7k|try {
  694|  12.7k|    if (ffi) {
  ------------------
  |  Branch (694:9): [True: 12.7k, False: 0]
  ------------------
  695|  12.7k|        delete ffi;
  696|  12.7k|    }
  697|  12.7k|    return RNP_SUCCESS;
  698|  12.7k|}
  699|  12.7k|FFI_GUARD
  ------------------
  |  |  619|  12.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.7k|    catch (...)                                                                     \
  |  |  |  |  615|  12.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_ffi_set_pass_provider:
  735|  12.7k|try {
  736|  12.7k|    if (!ffi) {
  ------------------
  |  Branch (736:9): [True: 0, False: 12.7k]
  ------------------
  737|      0|        return RNP_ERROR_NULL_POINTER;
  738|      0|    }
  739|  12.7k|    ffi->getpasscb = getpasscb;
  740|  12.7k|    ffi->getpasscb_ctx = getpasscb_ctx;
  741|  12.7k|    return RNP_SUCCESS;
  742|  12.7k|}
  743|  12.7k|FFI_GUARD
  ------------------
  |  |  619|  12.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.7k|    catch (...)                                                                     \
  |  |  |  |  615|  12.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_get_security_rule:
 1372|  12.0k|try {
 1373|  12.0k|    if (!ffi || !type || !name || !level) {
  ------------------
  |  Branch (1373:9): [True: 0, False: 12.0k]
  |  Branch (1373:17): [True: 0, False: 12.0k]
  |  Branch (1373:26): [True: 0, False: 12.0k]
  |  Branch (1373:35): [True: 0, False: 12.0k]
  ------------------
 1374|      0|        return RNP_ERROR_NULL_POINTER;
 1375|      0|    }
 1376|       |    /* convert values */
 1377|  12.0k|    rnp::FeatureType ftype;
 1378|  12.0k|    int              fvalue;
 1379|  12.0k|    if (!get_feature_sec_value(ffi, type, name, ftype, fvalue)) {
  ------------------
  |  Branch (1379:9): [True: 0, False: 12.0k]
  ------------------
 1380|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1381|      0|    }
 1382|       |    /* init default rule */
 1383|  12.0k|    rnp::SecurityRule rule(ftype, fvalue, ffi->profile().def_level());
 1384|       |    /* Check whether limited usage is requested */
 1385|  12.0k|    auto action = get_security_action(flags ? *flags : 0);
  ------------------
  |  Branch (1385:39): [True: 0, False: 12.0k]
  ------------------
 1386|       |    /* check whether rule exists */
 1387|  12.0k|    if (ffi->profile().has_rule(ftype, fvalue, time, action)) {
  ------------------
  |  Branch (1387:9): [True: 4.05k, False: 7.97k]
  ------------------
 1388|  4.05k|        rule = ffi->profile().get_rule(ftype, fvalue, time, action);
 1389|  4.05k|    }
 1390|       |    /* fill the results */
 1391|  12.0k|    if (flags) {
  ------------------
  |  Branch (1391:9): [True: 0, False: 12.0k]
  ------------------
 1392|      0|        *flags = rule.override ? RNP_SECURITY_OVERRIDE : 0;
  ------------------
  |  |  134|      0|#define RNP_SECURITY_OVERRIDE (1U << 0)
  ------------------
  |  Branch (1392:18): [True: 0, False: 0]
  ------------------
 1393|      0|        switch (rule.action) {
 1394|      0|        case rnp::SecurityAction::VerifyKey:
  ------------------
  |  Branch (1394:9): [True: 0, False: 0]
  ------------------
 1395|      0|            *flags |= RNP_SECURITY_VERIFY_KEY;
  ------------------
  |  |  135|      0|#define RNP_SECURITY_VERIFY_KEY (1U << 1)
  ------------------
 1396|      0|            break;
 1397|      0|        case rnp::SecurityAction::VerifyData:
  ------------------
  |  Branch (1397:9): [True: 0, False: 0]
  ------------------
 1398|      0|            *flags |= RNP_SECURITY_VERIFY_DATA;
  ------------------
  |  |  136|      0|#define RNP_SECURITY_VERIFY_DATA (1U << 2)
  ------------------
 1399|      0|            break;
 1400|      0|        default:
  ------------------
  |  Branch (1400:9): [True: 0, False: 0]
  ------------------
 1401|      0|            break;
 1402|      0|        }
 1403|      0|    }
 1404|  12.0k|    if (from) {
  ------------------
  |  Branch (1404:9): [True: 0, False: 12.0k]
  ------------------
 1405|      0|        *from = rule.from;
 1406|      0|    }
 1407|  12.0k|    switch (rule.level) {
 1408|      0|    case rnp::SecurityLevel::Disabled:
  ------------------
  |  Branch (1408:5): [True: 0, False: 12.0k]
  ------------------
 1409|      0|        *level = RNP_SECURITY_PROHIBITED;
  ------------------
  |  |  127|      0|#define RNP_SECURITY_PROHIBITED (0U)
  ------------------
 1410|      0|        break;
 1411|  4.05k|    case rnp::SecurityLevel::Insecure:
  ------------------
  |  Branch (1411:5): [True: 4.05k, False: 7.97k]
  ------------------
 1412|  4.05k|        *level = RNP_SECURITY_INSECURE;
  ------------------
  |  |  128|  4.05k|#define RNP_SECURITY_INSECURE (1U)
  ------------------
 1413|  4.05k|        break;
 1414|  7.97k|    case rnp::SecurityLevel::Default:
  ------------------
  |  Branch (1414:5): [True: 7.97k, False: 4.05k]
  ------------------
 1415|  7.97k|        *level = RNP_SECURITY_DEFAULT;
  ------------------
  |  |  129|  7.97k|#define RNP_SECURITY_DEFAULT (2U)
  ------------------
 1416|  7.97k|        break;
 1417|      0|    default:
  ------------------
  |  Branch (1417:5): [True: 0, False: 12.0k]
  ------------------
 1418|       |        /* LCOV_EXCL_START */
 1419|      0|        FFI_LOG(ffi, "Invalid security level.");
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1420|      0|        return RNP_ERROR_BAD_STATE;
 1421|       |        /* LCOV_EXCL_END */
 1422|  12.0k|    }
 1423|  12.0k|    return RNP_SUCCESS;
 1424|  12.0k|}
 1425|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_import_keys:
 1889|  12.7k|try {
 1890|  12.7k|    if (!ffi || !input) {
  ------------------
  |  Branch (1890:9): [True: 0, False: 12.7k]
  |  Branch (1890:17): [True: 0, False: 12.7k]
  ------------------
 1891|      0|        return RNP_ERROR_NULL_POINTER;
 1892|      0|    }
 1893|  12.7k|    bool sec = extract_flag(flags, RNP_LOAD_SAVE_SECRET_KEYS);
  ------------------
  |  |   81|  12.7k|#define RNP_LOAD_SAVE_SECRET_KEYS (1U << 1)
  ------------------
 1894|  12.7k|    bool pub = extract_flag(flags, RNP_LOAD_SAVE_PUBLIC_KEYS);
  ------------------
  |  |   80|  12.7k|#define RNP_LOAD_SAVE_PUBLIC_KEYS (1U << 0)
  ------------------
 1895|  12.7k|    if (!pub && !sec) {
  ------------------
  |  Branch (1895:9): [True: 0, False: 12.7k]
  |  Branch (1895:17): [True: 0, False: 0]
  ------------------
 1896|      0|        FFI_LOG(ffi, "bad flags: need to specify public and/or secret keys");
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1897|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1898|      0|    }
 1899|  12.7k|    bool skipbad = extract_flag(flags, RNP_LOAD_SAVE_PERMISSIVE);
  ------------------
  |  |   82|  12.7k|#define RNP_LOAD_SAVE_PERMISSIVE (1U << 8)
  ------------------
 1900|  12.7k|    bool single = extract_flag(flags, RNP_LOAD_SAVE_SINGLE);
  ------------------
  |  |   83|  12.7k|#define RNP_LOAD_SAVE_SINGLE (1U << 9)
  ------------------
 1901|  12.7k|    bool base64 = extract_flag(flags, RNP_LOAD_SAVE_BASE64);
  ------------------
  |  |   84|  12.7k|#define RNP_LOAD_SAVE_BASE64 (1U << 10)
  ------------------
 1902|  12.7k|    if (flags) {
  ------------------
  |  Branch (1902:9): [True: 0, False: 12.7k]
  ------------------
 1903|      0|        FFI_LOG(ffi, "unexpected flags remaining: 0x%X", flags);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1904|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1905|      0|    }
 1906|       |
 1907|  12.7k|    rnp_result_t  ret = RNP_ERROR_GENERIC;
 1908|  12.7k|    rnp::KeyStore tmp_store("", ffi->context);
 1909|       |
 1910|       |    /* check whether input is base64 */
 1911|  12.7k|    if (base64 && input->src.is_base64()) {
  ------------------
  |  Branch (1911:9): [True: 0, False: 12.7k]
  |  Branch (1911:19): [True: 0, False: 0]
  ------------------
 1912|      0|        ret = rnp_input_dearmor_if_needed(input, true);
 1913|      0|        if (ret) {
  ------------------
  |  Branch (1913:13): [True: 0, False: 0]
  ------------------
 1914|      0|            return ret;
 1915|      0|        }
 1916|      0|    }
 1917|       |
 1918|       |    // load keys to temporary keystore.
 1919|  12.7k|    if (single) {
  ------------------
  |  Branch (1919:9): [True: 0, False: 12.7k]
  ------------------
 1920|       |        /* we need to init and handle dearmor on this layer since it may be used for the next
 1921|       |         * keys import */
 1922|      0|        ret = rnp_input_dearmor_if_needed(input);
 1923|      0|        if (ret == RNP_ERROR_EOF) {
  ------------------
  |  Branch (1923:13): [True: 0, False: 0]
  ------------------
 1924|      0|            return ret;
 1925|      0|        }
 1926|      0|        if (ret) {
  ------------------
  |  Branch (1926:13): [True: 0, False: 0]
  ------------------
 1927|      0|            FFI_LOG(ffi, "Failed to init/check dearmor.");
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1928|      0|            return ret;
 1929|      0|        }
 1930|      0|        ret = tmp_store.load_pgp_key(input->src, skipbad);
 1931|      0|        if (ret) {
  ------------------
  |  Branch (1931:13): [True: 0, False: 0]
  ------------------
 1932|      0|            return ret;
 1933|      0|        }
 1934|  12.7k|    } else {
 1935|  12.7k|        ret = tmp_store.load_pgp(input->src, skipbad);
 1936|  12.7k|        if (ret) {
  ------------------
  |  Branch (1936:13): [True: 7.14k, False: 5.60k]
  ------------------
 1937|  7.14k|            return ret;
 1938|  7.14k|        }
 1939|  12.7k|    }
 1940|       |
 1941|  5.60k|    nlohmann::ordered_json jsores = nlohmann::ordered_json::object();
 1942|  5.60k|    jsores["keys"] = nlohmann::ordered_json::array();
 1943|  5.60k|    nlohmann::ordered_json &jsokeys = jsores["keys"];
 1944|       |
 1945|       |    // import keys to the main keystore.
 1946|  16.4k|    for (auto &key : tmp_store.keys) {
  ------------------
  |  Branch (1946:20): [True: 16.4k, False: 5.60k]
  ------------------
 1947|  16.4k|        pgp_key_import_status_t pub_status = PGP_KEY_IMPORT_STATUS_UNKNOWN;
 1948|  16.4k|        pgp_key_import_status_t sec_status = PGP_KEY_IMPORT_STATUS_UNKNOWN;
 1949|  16.4k|        if (!pub && key.is_public()) {
  ------------------
  |  Branch (1949:13): [True: 0, False: 16.4k]
  |  Branch (1949:21): [True: 0, False: 0]
  ------------------
 1950|      0|            continue;
 1951|      0|        }
 1952|       |        // if we got here then we add public key itself or public part of the secret key
 1953|  16.4k|        if (!ffi->pubring->import_key(key, true, &pub_status)) {
  ------------------
  |  Branch (1953:13): [True: 0, False: 16.4k]
  ------------------
 1954|      0|            return RNP_ERROR_BAD_PARAMETERS;
 1955|      0|        }
 1956|       |        // import secret key part if available and requested
 1957|  16.4k|        if (sec && key.is_secret()) {
  ------------------
  |  Branch (1957:13): [True: 16.4k, False: 0]
  |  Branch (1957:20): [True: 3.88k, False: 12.5k]
  ------------------
 1958|  3.88k|            if (!ffi->secring->import_key(key, false, &sec_status)) {
  ------------------
  |  Branch (1958:17): [True: 0, False: 3.88k]
  ------------------
 1959|      0|                return RNP_ERROR_BAD_PARAMETERS;
 1960|      0|            }
 1961|       |            // add uids, certifications and other stuff from the public key if any
 1962|  3.88k|            auto *expub = ffi->pubring->get_key(key.fp());
 1963|  3.88k|            if (expub && !ffi->secring->import_key(*expub, true)) {
  ------------------
  |  Branch (1963:17): [True: 3.88k, False: 0]
  |  Branch (1963:26): [True: 0, False: 3.88k]
  ------------------
 1964|      0|                return RNP_ERROR_BAD_PARAMETERS;
 1965|      0|            }
 1966|  12.5k|        } else if (pub_status != PGP_KEY_IMPORT_STATUS_UNCHANGED) {
  ------------------
  |  Branch (1966:20): [True: 12.5k, False: 0]
  ------------------
 1967|       |            // public key was new or updated: sync into secring if a secret key exists there
 1968|  12.5k|            auto *expub = ffi->pubring->get_key(key.fp());
 1969|  12.5k|            if (expub && ffi->secring->get_key(key.fp())) {
  ------------------
  |  Branch (1969:17): [True: 12.5k, False: 0]
  |  Branch (1969:26): [True: 0, False: 12.5k]
  ------------------
 1970|      0|                if (!ffi->secring->import_key(*expub, true)) {
  ------------------
  |  Branch (1970:21): [True: 0, False: 0]
  ------------------
 1971|      0|                    return RNP_ERROR_BAD_PARAMETERS;
 1972|      0|                }
 1973|      0|            }
 1974|  12.5k|        }
 1975|       |        // now add key fingerprint to json based on statuses
 1976|  16.4k|        rnp_result_t tmpret = add_key_status(jsokeys, &key, pub_status, sec_status);
 1977|  16.4k|        if (tmpret) {
  ------------------
  |  Branch (1977:13): [True: 0, False: 16.4k]
  ------------------
 1978|      0|            return tmpret;
 1979|      0|        }
 1980|  16.4k|    }
 1981|  5.60k|    if (!results) {
  ------------------
  |  Branch (1981:9): [True: 0, False: 5.60k]
  ------------------
 1982|      0|        return RNP_SUCCESS;
 1983|      0|    }
 1984|  5.60k|    return ret_str_value(rnp::json::dump_pretty(jsores).c_str(), results);
 1985|  5.60k|}
 1986|  12.7k|FFI_GUARD
  ------------------
  |  |  619|  12.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.7k|    catch (...)                                                                     \
  |  |  |  |  615|  12.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
_ZN12rnp_input_stC2Ev:
 2240|  35.7k|rnp_input_st::rnp_input_st() : reader(NULL), closer(NULL), app_ctx(NULL)
 2241|  35.7k|{
 2242|  35.7k|    memset(&src, 0, sizeof(src));
 2243|  35.7k|}
_ZN12rnp_input_stD2Ev:
 2262|  35.7k|{
 2263|  35.7k|    bool armored = src.type == PGP_STREAM_ARMORED;
 2264|  35.7k|    src.close();
 2265|  35.7k|    if (armored) {
  ------------------
  |  Branch (2265:9): [True: 0, False: 35.7k]
  ------------------
 2266|      0|        rnp_input_t armored = (rnp_input_t) app_ctx;
 2267|      0|        delete armored;
 2268|       |        app_ctx = NULL;
 2269|      0|    }
 2270|  35.7k|}
rnp_input_from_memory:
 2319|  35.7k|try {
 2320|  35.7k|    if (!input) {
  ------------------
  |  Branch (2320:9): [True: 0, False: 35.7k]
  ------------------
 2321|      0|        return RNP_ERROR_NULL_POINTER;
 2322|      0|    }
 2323|  35.7k|    if (!buf && buf_len) {
  ------------------
  |  Branch (2323:9): [True: 0, False: 35.7k]
  |  Branch (2323:17): [True: 0, False: 0]
  ------------------
 2324|      0|        return RNP_ERROR_NULL_POINTER;
 2325|      0|    }
 2326|  35.7k|    if (!buf_len) {
  ------------------
  |  Branch (2326:9): [True: 0, False: 35.7k]
  ------------------
 2327|       |        // prevent malloc(0)
 2328|      0|        do_copy = false;
 2329|      0|    }
 2330|  35.7k|    *input = new rnp_input_st();
 2331|  35.7k|    uint8_t *data = (uint8_t *) buf;
 2332|  35.7k|    if (do_copy) {
  ------------------
  |  Branch (2332:9): [True: 0, False: 35.7k]
  ------------------
 2333|      0|        data = (uint8_t *) malloc(buf_len);
 2334|      0|        if (!data) {
  ------------------
  |  Branch (2334:13): [True: 0, False: 0]
  ------------------
 2335|       |            /* LCOV_EXCL_START */
 2336|      0|            delete *input;
 2337|      0|            *input = NULL;
 2338|      0|            return RNP_ERROR_OUT_OF_MEMORY;
 2339|       |            /* LCOV_EXCL_END */
 2340|      0|        }
 2341|      0|        memcpy(data, buf, buf_len);
 2342|      0|    }
 2343|  35.7k|    rnp_result_t ret = init_mem_src(&(*input)->src, data, buf_len, do_copy);
 2344|  35.7k|    if (ret) {
  ------------------
  |  Branch (2344:9): [True: 0, False: 35.7k]
  ------------------
 2345|       |        /* LCOV_EXCL_START */
 2346|      0|        if (do_copy) {
  ------------------
  |  Branch (2346:13): [True: 0, False: 0]
  ------------------
 2347|      0|            free(data);
 2348|      0|        }
 2349|      0|        delete *input;
 2350|      0|        *input = NULL;
 2351|       |        /* LCOV_EXCL_END */
 2352|      0|    }
 2353|  35.7k|    return ret;
 2354|  35.7k|}
 2355|  35.7k|FFI_GUARD
  ------------------
  |  |  619|  35.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  35.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  35.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  35.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  35.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  35.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  35.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  35.7k|    catch (...)                                                                     \
  |  |  |  |  615|  35.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_input_destroy:
 2408|  35.7k|try {
 2409|  35.7k|    delete input;
 2410|  35.7k|    return RNP_SUCCESS;
 2411|  35.7k|}
 2412|  35.7k|FFI_GUARD
  ------------------
  |  |  619|  35.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  35.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  35.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  35.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  35.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  35.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  35.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  35.7k|    catch (...)                                                                     \
  |  |  |  |  615|  35.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_output_to_memory:
 2498|  22.9k|try {
 2499|       |    // checks
 2500|  22.9k|    if (!output) {
  ------------------
  |  Branch (2500:9): [True: 0, False: 22.9k]
  ------------------
 2501|      0|        return RNP_ERROR_NULL_POINTER;
 2502|      0|    }
 2503|       |
 2504|  22.9k|    *output = new rnp_output_st{};
 2505|  22.9k|    rnp_result_t ret = init_mem_dest(&(*output)->dst, NULL, max_alloc);
 2506|  22.9k|    if (ret) {
  ------------------
  |  Branch (2506:9): [True: 0, False: 22.9k]
  ------------------
 2507|       |        /* LCOV_EXCL_START */
 2508|      0|        delete *output;
 2509|      0|        *output = NULL;
 2510|       |        /* LCOV_EXCL_END */
 2511|      0|    }
 2512|  22.9k|    return ret;
 2513|  22.9k|}
 2514|  22.9k|FFI_GUARD
  ------------------
  |  |  619|  22.9k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  22.9k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  22.9k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  22.9k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  22.9k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  22.9k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  22.9k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  22.9k|    catch (...)                                                                     \
  |  |  |  |  615|  22.9k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_output_memory_get_buf:
 2550|  12.7k|try {
 2551|  12.7k|    if (!output || !buf || !len) {
  ------------------
  |  Branch (2551:9): [True: 0, False: 12.7k]
  |  Branch (2551:20): [True: 0, False: 12.7k]
  |  Branch (2551:28): [True: 0, False: 12.7k]
  ------------------
 2552|      0|        return RNP_ERROR_NULL_POINTER;
 2553|      0|    }
 2554|       |
 2555|  12.7k|    if (output->dst.type != PGP_STREAM_MEMORY) {
  ------------------
  |  Branch (2555:9): [True: 0, False: 12.7k]
  ------------------
 2556|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2557|      0|    }
 2558|       |
 2559|  12.7k|    *len = output->dst.writeb;
 2560|  12.7k|    *buf = (uint8_t *) mem_dest_get_memory(&output->dst);
 2561|  12.7k|    if (!*buf && *len) {
  ------------------
  |  Branch (2561:9): [True: 2.54k, False: 10.2k]
  |  Branch (2561:18): [True: 0, False: 2.54k]
  ------------------
 2562|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2563|      0|    }
 2564|  12.7k|    if (do_copy && *len) {
  ------------------
  |  Branch (2564:9): [True: 0, False: 12.7k]
  |  Branch (2564:20): [True: 0, False: 0]
  ------------------
 2565|      0|        uint8_t *tmp_buf = *buf;
 2566|      0|        *buf = (uint8_t *) malloc(*len);
 2567|      0|        if (!*buf) {
  ------------------
  |  Branch (2567:13): [True: 0, False: 0]
  ------------------
 2568|      0|            return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2569|      0|        }
 2570|      0|        memcpy(*buf, tmp_buf, *len);
 2571|      0|    }
 2572|  12.7k|    return RNP_SUCCESS;
 2573|  12.7k|}
 2574|  12.7k|FFI_GUARD
  ------------------
  |  |  619|  12.7k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.7k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.7k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.7k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.7k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.7k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.7k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.7k|    catch (...)                                                                     \
  |  |  |  |  615|  12.7k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_output_destroy:
 2679|  22.9k|try {
 2680|  22.9k|    if (output) {
  ------------------
  |  Branch (2680:9): [True: 22.9k, False: 0]
  ------------------
 2681|  22.9k|        if (output->dst.type == PGP_STREAM_ARMORED) {
  ------------------
  |  Branch (2681:13): [True: 0, False: 22.9k]
  ------------------
 2682|      0|            ((rnp_output_t) output->app_ctx)->keep = output->keep;
 2683|      0|        }
 2684|  22.9k|        dst_close(&output->dst, !output->keep);
 2685|  22.9k|        free(output->dst_directory);
 2686|  22.9k|        delete output;
 2687|  22.9k|    }
 2688|  22.9k|    return RNP_SUCCESS;
 2689|  22.9k|}
 2690|  22.9k|FFI_GUARD
  ------------------
  |  |  619|  22.9k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  22.9k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  22.9k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  22.9k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  22.9k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  22.9k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  22.9k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  22.9k|    catch (...)                                                                     \
  |  |  |  |  615|  22.9k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_create:
 2812|  12.0k|try {
 2813|       |    // checks
 2814|  12.0k|    if (!op || !ffi || !input || !output) {
  ------------------
  |  Branch (2814:9): [True: 0, False: 12.0k]
  |  Branch (2814:16): [True: 0, False: 12.0k]
  |  Branch (2814:24): [True: 0, False: 12.0k]
  |  Branch (2814:34): [True: 0, False: 12.0k]
  ------------------
 2815|      0|        return RNP_ERROR_NULL_POINTER;
 2816|      0|    }
 2817|       |
 2818|  12.0k|    *op = new rnp_op_encrypt_st(ffi, input, output);
 2819|  12.0k|    return RNP_SUCCESS;
 2820|  12.0k|}
 2821|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_add_recipient:
 2825|  3.44k|try {
 2826|       |    // checks
 2827|  3.44k|    if (!op || !handle) {
  ------------------
  |  Branch (2827:9): [True: 0, False: 3.44k]
  |  Branch (2827:16): [True: 0, False: 3.44k]
  ------------------
 2828|      0|        return RNP_ERROR_NULL_POINTER;
 2829|      0|    }
 2830|       |
 2831|  3.44k|#if defined(ENABLE_PQC)
 2832|  3.44k|    bool prefer_pqc = op->rnpctx.pref_pqc_enc_subkey;
 2833|       |#else
 2834|       |    bool prefer_pqc = false;
 2835|       |#endif
 2836|  3.44k|    auto *key = find_suitable_key(PGP_OP_ENCRYPT,
 2837|  3.44k|                                  get_key_prefer_public(handle),
 2838|  3.44k|                                  &handle->ffi->key_provider,
 2839|  3.44k|                                  false,
 2840|  3.44k|                                  prefer_pqc);
 2841|  3.44k|    if (!key) {
  ------------------
  |  Branch (2841:9): [True: 3.40k, False: 42]
  ------------------
 2842|  3.40k|        return RNP_ERROR_NO_SUITABLE_KEY;
 2843|  3.40k|    }
 2844|     42|    op->rnpctx.recipients.push_back(key);
 2845|     42|    return RNP_SUCCESS;
 2846|  3.44k|}
 2847|  3.44k|FFI_GUARD
  ------------------
  |  |  619|  3.44k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  3.44k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  3.44k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  3.44k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  3.44k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  3.44k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  3.44k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  3.44k|    catch (...)                                                                     \
  |  |  |  |  615|  3.44k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_enable_pkesk_v6:
 2852|  3.59k|try {
 2853|  3.59k|    if (!op) {
  ------------------
  |  Branch (2853:9): [True: 0, False: 3.59k]
  ------------------
 2854|      0|        return RNP_ERROR_NULL_POINTER;
 2855|      0|    }
 2856|       |
 2857|  3.59k|    op->rnpctx.enable_pkesk_v6 = true;
 2858|  3.59k|    return RNP_SUCCESS;
 2859|  3.59k|}
 2860|  3.59k|FFI_GUARD
  ------------------
  |  |  619|  3.59k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  3.59k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  3.59k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  3.59k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  3.59k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  3.59k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  3.59k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  3.59k|    catch (...)                                                                     \
  |  |  |  |  615|  3.59k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_enable_skesk_v6:
 2864|  6.18k|try {
 2865|  6.18k|    if (!op) {
  ------------------
  |  Branch (2865:9): [True: 0, False: 6.18k]
  ------------------
 2866|      0|        return RNP_ERROR_NULL_POINTER;
 2867|      0|    }
 2868|       |
 2869|  6.18k|    op->rnpctx.enable_skesk_v6 = true;
 2870|  6.18k|    return RNP_SUCCESS;
 2871|  6.18k|}
 2872|  6.18k|FFI_GUARD
  ------------------
  |  |  619|  6.18k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  6.18k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  6.18k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  6.18k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  6.18k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  6.18k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  6.18k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  6.18k|    catch (...)                                                                     \
  |  |  |  |  615|  6.18k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_prefer_pqc_enc_subkey:
 2878|  5.07k|try {
 2879|  5.07k|    if (!op) {
  ------------------
  |  Branch (2879:9): [True: 0, False: 5.07k]
  ------------------
 2880|      0|        return RNP_ERROR_NULL_POINTER;
 2881|      0|    }
 2882|       |
 2883|  5.07k|    op->rnpctx.pref_pqc_enc_subkey = true;
 2884|  5.07k|    return RNP_SUCCESS;
 2885|  5.07k|}
 2886|  5.07k|FFI_GUARD
  ------------------
  |  |  619|  5.07k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  5.07k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  5.07k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  5.07k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  5.07k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  5.07k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  5.07k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  5.07k|    catch (...)                                                                     \
  |  |  |  |  615|  5.07k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_add_signature:
 2893|    293|try {
 2894|    293|    if (!op) {
  ------------------
  |  Branch (2894:9): [True: 0, False: 293]
  ------------------
 2895|      0|        return RNP_ERROR_NULL_POINTER;
 2896|      0|    }
 2897|    293|    return rnp_op_add_signature(op->ffi, op->signatures, key, op->rnpctx, sig);
 2898|    293|}
 2899|    293|FFI_GUARD
  ------------------
  |  |  619|    293|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    293|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    293|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    293|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    293|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    293|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    293|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    293|    catch (...)                                                                     \
  |  |  |  |  615|    293|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_hash:
 2903|  12.0k|try {
 2904|  12.0k|    if (!op) {
  ------------------
  |  Branch (2904:9): [True: 0, False: 12.0k]
  ------------------
 2905|      0|        return RNP_ERROR_NULL_POINTER;
 2906|      0|    }
 2907|  12.0k|    return rnp_op_set_hash(op->ffi, op->rnpctx, hash);
 2908|  12.0k|}
 2909|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_add_password:
 2937|  9.42k|try {
 2938|       |    // checks
 2939|  9.42k|    if (!op) {
  ------------------
  |  Branch (2939:9): [True: 0, False: 9.42k]
  ------------------
 2940|      0|        return RNP_ERROR_NULL_POINTER;
 2941|      0|    }
 2942|  9.42k|    if (password && !*password) {
  ------------------
  |  Branch (2942:9): [True: 9.42k, False: 0]
  |  Branch (2942:21): [True: 820, False: 8.60k]
  ------------------
 2943|       |        // no blank passwords
 2944|    820|        FFI_LOG(op->ffi, "Blank password");
  ------------------
  |  |   68|    820|    do {                             \
  |  |   69|    820|        FILE *fp = stderr;           \
  |  |   70|    820|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 820, False: 0]
  |  |  |  Branch (70:20): [True: 820, False: 0]
  |  |  ------------------
  |  |   71|    820|            fp = ffi->errs;          \
  |  |   72|    820|        }                            \
  |  |   73|    820|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|    820|    do {                                                                                 \
  |  |  |  |   77|    820|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 820, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    820|            break;                                                                       \
  |  |  |  |   79|    820|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|    820|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 820]
  |  |  ------------------
  ------------------
 2945|    820|        return RNP_ERROR_BAD_PARAMETERS;
 2946|    820|    }
 2947|       |
 2948|       |    // set some defaults
 2949|  8.60k|    if (!s2k_hash) {
  ------------------
  |  Branch (2949:9): [True: 0, False: 8.60k]
  ------------------
 2950|      0|        s2k_hash = DEFAULT_HASH_ALG;
  ------------------
  |  | 4369|      0|#define DEFAULT_HASH_ALG RNP_ALGNAME_SHA256
  |  |  ------------------
  |  |  |  | 4352|      0|#define RNP_ALGNAME_SHA256 "SHA256"
  |  |  ------------------
  ------------------
 2951|      0|    }
 2952|  8.60k|    if (!s2k_cipher) {
  ------------------
  |  Branch (2952:9): [True: 0, False: 8.60k]
  ------------------
 2953|      0|        s2k_cipher = DEFAULT_SYMM_ALG;
  ------------------
  |  | 4372|      0|#define DEFAULT_SYMM_ALG RNP_ALGNAME_AES_256
  |  |  ------------------
  |  |  |  | 4343|      0|#define RNP_ALGNAME_AES_256 "AES256"
  |  |  ------------------
  ------------------
 2954|      0|    }
 2955|       |    // parse
 2956|  8.60k|    pgp_hash_alg_t hash_alg = PGP_HASH_UNKNOWN;
 2957|  8.60k|    if (!str_to_hash_alg(s2k_hash, &hash_alg)) {
  ------------------
  |  Branch (2957:9): [True: 177, False: 8.42k]
  ------------------
 2958|    177|        FFI_LOG(op->ffi, "Invalid hash: %s", s2k_hash);
  ------------------
  |  |   68|    177|    do {                             \
  |  |   69|    177|        FILE *fp = stderr;           \
  |  |   70|    177|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 177, False: 0]
  |  |  |  Branch (70:20): [True: 177, False: 0]
  |  |  ------------------
  |  |   71|    177|            fp = ffi->errs;          \
  |  |   72|    177|        }                            \
  |  |   73|    177|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|    177|    do {                                                                                 \
  |  |  |  |   77|    177|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 177, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    177|            break;                                                                       \
  |  |  |  |   79|    177|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|    177|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 177]
  |  |  ------------------
  ------------------
 2959|    177|        return RNP_ERROR_BAD_PARAMETERS;
 2960|    177|    }
 2961|  8.42k|    pgp_symm_alg_t symm_alg = PGP_SA_UNKNOWN;
 2962|  8.42k|    if (!str_to_cipher(s2k_cipher, &symm_alg)) {
  ------------------
  |  Branch (2962:9): [True: 0, False: 8.42k]
  ------------------
 2963|      0|        FFI_LOG(op->ffi, "Invalid cipher: %s", s2k_cipher);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 2964|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2965|      0|    }
 2966|  8.42k|    rnp::secure_vector<char> ask_pass(MAX_PASSWORD_LENGTH, '\0');
  ------------------
  |  |   51|  8.42k|#define MAX_PASSWORD_LENGTH 256
  ------------------
 2967|  8.42k|    if (!password) {
  ------------------
  |  Branch (2967:9): [True: 0, False: 8.42k]
  ------------------
 2968|      0|        pgp_password_ctx_t pswdctx(PGP_OP_ENCRYPT_SYM);
 2969|      0|        if (!pgp_request_password(
  ------------------
  |  Branch (2969:13): [True: 0, False: 0]
  ------------------
 2970|      0|              &op->ffi->pass_provider, &pswdctx, ask_pass.data(), ask_pass.size())) {
 2971|      0|            return RNP_ERROR_BAD_PASSWORD;
 2972|      0|        }
 2973|      0|        password = ask_pass.data();
 2974|      0|    }
 2975|  8.42k|    return op->rnpctx.add_encryption_password(password, hash_alg, symm_alg, iterations);
 2976|  8.42k|}
 2977|  9.42k|FFI_GUARD
  ------------------
  |  |  619|  9.42k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  9.42k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  9.42k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  9.42k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  9.42k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  9.42k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  9.42k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  9.42k|    catch (...)                                                                     \
  |  |  |  |  615|  9.42k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_armor:
 2981|  12.0k|try {
 2982|       |    // checks
 2983|  12.0k|    if (!op) {
  ------------------
  |  Branch (2983:9): [True: 0, False: 12.0k]
  ------------------
 2984|      0|        return RNP_ERROR_NULL_POINTER;
 2985|      0|    }
 2986|  12.0k|    return rnp_op_set_armor(op->rnpctx, armored);
 2987|  12.0k|}
 2988|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_cipher:
 3016|  12.0k|try {
 3017|       |    // checks
 3018|  12.0k|    if (!op || !cipher) {
  ------------------
  |  Branch (3018:9): [True: 0, False: 12.0k]
  |  Branch (3018:16): [True: 0, False: 12.0k]
  ------------------
 3019|      0|        return RNP_ERROR_NULL_POINTER;
 3020|      0|    }
 3021|  12.0k|    if (!rnp_check_old_ciphers(op->ffi, cipher)) {
  ------------------
  |  Branch (3021:9): [True: 4.05k, False: 7.97k]
  ------------------
 3022|  4.05k|        FFI_LOG(op->ffi, "Deprecated cipher: %s", cipher);
  ------------------
  |  |   68|  4.05k|    do {                             \
  |  |   69|  4.05k|        FILE *fp = stderr;           \
  |  |   70|  4.05k|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 4.05k, False: 0]
  |  |  |  Branch (70:20): [True: 4.05k, False: 0]
  |  |  ------------------
  |  |   71|  4.05k|            fp = ffi->errs;          \
  |  |   72|  4.05k|        }                            \
  |  |   73|  4.05k|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|  4.05k|    do {                                                                                 \
  |  |  |  |   77|  4.05k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.05k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.05k|            break;                                                                       \
  |  |  |  |   79|  4.05k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|  4.05k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 4.05k]
  |  |  ------------------
  ------------------
 3023|  4.05k|        return RNP_ERROR_BAD_PARAMETERS;
 3024|  4.05k|    }
 3025|  7.97k|    if (!str_to_cipher(cipher, &op->rnpctx.ealg)) {
  ------------------
  |  Branch (3025:9): [True: 0, False: 7.97k]
  ------------------
 3026|      0|        FFI_LOG(op->ffi, "Invalid cipher: %s", cipher);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3027|      0|        return RNP_ERROR_BAD_PARAMETERS;
 3028|      0|    }
 3029|  7.97k|    return RNP_SUCCESS;
 3030|  7.97k|}
 3031|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_aead:
 3035|  12.0k|try {
 3036|       |    // checks
 3037|  12.0k|    if (!op || !alg) {
  ------------------
  |  Branch (3037:9): [True: 0, False: 12.0k]
  |  Branch (3037:16): [True: 0, False: 12.0k]
  ------------------
 3038|      0|        return RNP_ERROR_NULL_POINTER;
 3039|      0|    }
 3040|  12.0k|    if (!str_to_aead_alg(alg, &op->rnpctx.aalg)) {
  ------------------
  |  Branch (3040:9): [True: 0, False: 12.0k]
  ------------------
 3041|      0|        FFI_LOG(op->ffi, "Invalid AEAD algorithm: %s", alg);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3042|      0|        return RNP_ERROR_BAD_PARAMETERS;
 3043|      0|    }
 3044|  12.0k|    if (op->rnpctx.aalg == PGP_AEAD_EAX) {
  ------------------
  |  Branch (3044:9): [True: 2.04k, False: 9.98k]
  ------------------
 3045|       |        /* LCOV_EXCL_START */
 3046|       |        /* The define below is not reported as covered however codecov reports error */
 3047|  2.04k|        FFI_LOG(op->ffi, "Warning! EAX mode is deprecated and should not be used.");
  ------------------
  |  |   68|  2.04k|    do {                             \
  |  |   69|  2.04k|        FILE *fp = stderr;           \
  |  |   70|  2.04k|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 2.04k, False: 0]
  |  |  |  Branch (70:20): [True: 2.04k, False: 0]
  |  |  ------------------
  |  |   71|  2.04k|            fp = ffi->errs;          \
  |  |   72|  2.04k|        }                            \
  |  |   73|  2.04k|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|  2.04k|    do {                                                                                 \
  |  |  |  |   77|  2.04k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.04k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.04k|            break;                                                                       \
  |  |  |  |   79|  2.04k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|  2.04k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 2.04k]
  |  |  ------------------
  ------------------
 3048|       |        /* LCOV_EXCL_END */
 3049|  2.04k|    }
 3050|  12.0k|#ifdef ENABLE_CRYPTO_REFRESH
 3051|  12.0k|    if (op->rnpctx.aalg == PGP_AEAD_NONE && op->rnpctx.enable_pkesk_v6) {
  ------------------
  |  Branch (3051:9): [True: 5.67k, False: 6.35k]
  |  Branch (3051:45): [True: 0, False: 5.67k]
  ------------------
 3052|      0|        FFI_LOG(op->ffi,
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3053|      0|                "Setting AEAD algorithm to PGP_AEAD_NONE (%s) would contradict the previously "
 3054|      0|                "enabled PKESKv6 setting",
 3055|      0|                alg);
 3056|      0|        return RNP_ERROR_BAD_PARAMETERS;
 3057|      0|    }
 3058|  12.0k|#endif
 3059|  12.0k|    return RNP_SUCCESS;
 3060|  12.0k|}
 3061|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_aead_bits:
 3065|  12.0k|try {
 3066|  12.0k|    if (!op) {
  ------------------
  |  Branch (3066:9): [True: 0, False: 12.0k]
  ------------------
 3067|      0|        return RNP_ERROR_NULL_POINTER;
 3068|      0|    }
 3069|  12.0k|    if ((bits < 0) || (bits > 16)) {
  ------------------
  |  Branch (3069:9): [True: 0, False: 12.0k]
  |  Branch (3069:23): [True: 0, False: 12.0k]
  ------------------
 3070|      0|        return RNP_ERROR_BAD_PARAMETERS;
 3071|      0|    }
 3072|  12.0k|    op->rnpctx.abits = bits;
 3073|  12.0k|    return RNP_SUCCESS;
 3074|  12.0k|}
 3075|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_compression:
 3079|  12.0k|try {
 3080|       |    // checks
 3081|  12.0k|    if (!op) {
  ------------------
  |  Branch (3081:9): [True: 0, False: 12.0k]
  ------------------
 3082|      0|        return RNP_ERROR_NULL_POINTER;
 3083|      0|    }
 3084|  12.0k|    return rnp_op_set_compression(op->ffi, op->rnpctx, compression, level);
 3085|  12.0k|}
 3086|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_flags:
 3090|  12.0k|try {
 3091|       |    // checks
 3092|  12.0k|    if (!op) {
  ------------------
  |  Branch (3092:9): [True: 0, False: 12.0k]
  ------------------
 3093|      0|        return RNP_ERROR_NULL_POINTER;
 3094|      0|    }
 3095|  12.0k|    return rnp_op_set_flags(op->ffi, op->rnpctx, flags);
 3096|  12.0k|}
 3097|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_file_name:
 3101|  12.0k|try {
 3102|  12.0k|    if (!op) {
  ------------------
  |  Branch (3102:9): [True: 0, False: 12.0k]
  ------------------
 3103|      0|        return RNP_ERROR_NULL_POINTER;
 3104|      0|    }
 3105|  12.0k|    return rnp_op_set_file_name(op->rnpctx, filename);
 3106|  12.0k|}
 3107|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_set_file_mtime:
 3111|  12.0k|try {
 3112|  12.0k|    if (!op) {
  ------------------
  |  Branch (3112:9): [True: 0, False: 12.0k]
  ------------------
 3113|      0|        return RNP_ERROR_NULL_POINTER;
 3114|      0|    }
 3115|  12.0k|    return rnp_op_set_file_mtime(op->rnpctx, mtime);
 3116|  12.0k|}
 3117|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_execute:
 3144|  12.0k|try {
 3145|       |    // checks
 3146|  12.0k|    if (!op || !op->input || !op->output) {
  ------------------
  |  Branch (3146:9): [True: 0, False: 12.0k]
  |  Branch (3146:16): [True: 0, False: 12.0k]
  |  Branch (3146:30): [True: 0, False: 12.0k]
  ------------------
 3147|      0|        return RNP_ERROR_NULL_POINTER;
 3148|      0|    }
 3149|       |
 3150|       |    // set the default hash alg if none was specified
 3151|  12.0k|    if (!op->rnpctx.halg) {
  ------------------
  |  Branch (3151:9): [True: 0, False: 12.0k]
  ------------------
 3152|      0|        op->rnpctx.halg = DEFAULT_PGP_HASH_ALG;
  ------------------
  |  |   31|      0|#define DEFAULT_PGP_HASH_ALG PGP_HASH_SHA256
  ------------------
 3153|      0|    }
 3154|       |
 3155|  12.0k|    rnp_result_t ret = RNP_ERROR_GENERIC;
 3156|  12.0k|    if (!op->signatures.empty() && (ret = rnp_op_add_signatures(op->signatures, op->rnpctx))) {
  ------------------
  |  Branch (3156:9): [True: 0, False: 12.0k]
  |  Branch (3156:36): [True: 0, False: 0]
  ------------------
 3157|      0|        return ret;
 3158|      0|    }
 3159|  12.0k|    ret = rnp_encrypt_sign_src(op->rnpctx, op->input->src, op->output->dst);
 3160|       |
 3161|  12.0k|    dst_flush(&op->output->dst);
 3162|  12.0k|    op->output->keep = ret == RNP_SUCCESS;
 3163|  12.0k|    op->input = NULL;
 3164|  12.0k|    op->output = NULL;
 3165|  12.0k|    return ret;
 3166|  12.0k|}
 3167|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_encrypt_destroy:
 3171|  12.0k|try {
 3172|  12.0k|    delete op;
 3173|  12.0k|    return RNP_SUCCESS;
 3174|  12.0k|}
 3175|  12.0k|FFI_GUARD
  ------------------
  |  |  619|  12.0k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  12.0k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  12.0k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  12.0k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  12.0k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  12.0k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  12.0k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  12.0k|    catch (...)                                                                     \
  |  |  |  |  615|  12.0k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_create:
 3179|    718|try {
 3180|       |    // checks
 3181|    718|    if (!op || !ffi || !input || !output) {
  ------------------
  |  Branch (3181:9): [True: 0, False: 718]
  |  Branch (3181:16): [True: 0, False: 718]
  |  Branch (3181:24): [True: 0, False: 718]
  |  Branch (3181:34): [True: 0, False: 718]
  ------------------
 3182|      0|        return RNP_ERROR_NULL_POINTER;
 3183|      0|    }
 3184|       |
 3185|    718|    *op = new rnp_op_sign_st(ffi, input, output);
 3186|    718|    return RNP_SUCCESS;
 3187|    718|}
 3188|    718|FFI_GUARD
  ------------------
  |  |  619|    718|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    718|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    718|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    718|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    718|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    718|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    718|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    718|    catch (...)                                                                     \
  |  |  |  |  615|    718|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_add_signature:
 3220|     78|try {
 3221|     78|    if (!op) {
  ------------------
  |  Branch (3221:9): [True: 0, False: 78]
  ------------------
 3222|      0|        return RNP_ERROR_NULL_POINTER;
 3223|      0|    }
 3224|     78|    return rnp_op_add_signature(op->ffi, op->signatures, key, op->rnpctx, sig);
 3225|     78|}
 3226|     78|FFI_GUARD
  ------------------
  |  |  619|     78|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|     78|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|     78|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|     78|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|     78|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|     78|    catch (std::exception & e)                                                      \
  |  |  |  |  611|     78|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|     78|    catch (...)                                                                     \
  |  |  |  |  615|     78|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_set_armor:
 3269|    718|try {
 3270|    718|    if (!op) {
  ------------------
  |  Branch (3270:9): [True: 0, False: 718]
  ------------------
 3271|      0|        return RNP_ERROR_NULL_POINTER;
 3272|      0|    }
 3273|    718|    return rnp_op_set_armor(op->rnpctx, armored);
 3274|    718|}
 3275|    718|FFI_GUARD
  ------------------
  |  |  619|    718|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    718|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    718|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    718|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    718|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    718|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    718|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    718|    catch (...)                                                                     \
  |  |  |  |  615|    718|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_set_hash:
 3289|    718|try {
 3290|    718|    if (!op) {
  ------------------
  |  Branch (3290:9): [True: 0, False: 718]
  ------------------
 3291|      0|        return RNP_ERROR_NULL_POINTER;
 3292|      0|    }
 3293|    718|    return rnp_op_set_hash(op->ffi, op->rnpctx, hash);
 3294|    718|}
 3295|    718|FFI_GUARD
  ------------------
  |  |  619|    718|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    718|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    718|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    718|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    718|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    718|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    718|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    718|    catch (...)                                                                     \
  |  |  |  |  615|    718|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_execute:
 3339|    718|try {
 3340|       |    // checks
 3341|    718|    if (!op || !op->input || !op->output) {
  ------------------
  |  Branch (3341:9): [True: 0, False: 718]
  |  Branch (3341:16): [True: 0, False: 718]
  |  Branch (3341:30): [True: 0, False: 718]
  ------------------
 3342|      0|        return RNP_ERROR_NULL_POINTER;
 3343|      0|    }
 3344|       |
 3345|       |    // set the default hash alg if none was specified
 3346|    718|    if (!op->rnpctx.halg) {
  ------------------
  |  Branch (3346:9): [True: 0, False: 718]
  ------------------
 3347|      0|        op->rnpctx.halg = DEFAULT_PGP_HASH_ALG;
  ------------------
  |  |   31|      0|#define DEFAULT_PGP_HASH_ALG PGP_HASH_SHA256
  ------------------
 3348|      0|    }
 3349|    718|    rnp_result_t ret = RNP_ERROR_GENERIC;
 3350|    718|    if ((ret = rnp_op_add_signatures(op->signatures, op->rnpctx))) {
  ------------------
  |  Branch (3350:9): [True: 0, False: 718]
  ------------------
 3351|      0|        return ret;
 3352|      0|    }
 3353|    718|    ret = rnp_sign_src(op->rnpctx, op->input->src, op->output->dst);
 3354|       |
 3355|    718|    dst_flush(&op->output->dst);
 3356|    718|    op->output->keep = ret == RNP_SUCCESS;
 3357|    718|    op->input = NULL;
 3358|    718|    op->output = NULL;
 3359|    718|    return ret;
 3360|    718|}
 3361|    718|FFI_GUARD
  ------------------
  |  |  619|    718|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    718|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    718|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    718|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    718|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    718|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    718|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    718|    catch (...)                                                                     \
  |  |  |  |  615|    718|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_sign_destroy:
 3365|    718|try {
 3366|    718|    delete op;
 3367|    718|    return RNP_SUCCESS;
 3368|    718|}
 3369|    718|FFI_GUARD
  ------------------
  |  |  619|    718|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|    718|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|    718|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|    718|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|    718|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|    718|    catch (std::exception & e)                                                      \
  |  |  |  |  611|    718|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|    718|    catch (...)                                                                     \
  |  |  |  |  615|    718|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_verify_create:
 3550|  10.2k|try {
 3551|  10.2k|    if (!op || !ffi || !input || !output) {
  ------------------
  |  Branch (3551:9): [True: 0, False: 10.2k]
  |  Branch (3551:16): [True: 0, False: 10.2k]
  |  Branch (3551:24): [True: 0, False: 10.2k]
  |  Branch (3551:34): [True: 0, False: 10.2k]
  ------------------
 3552|      0|        return RNP_ERROR_NULL_POINTER;
 3553|      0|    }
 3554|       |
 3555|  10.2k|    *op = new rnp_op_verify_st(ffi, input, output);
 3556|  10.2k|    return RNP_SUCCESS;
 3557|  10.2k|}
 3558|  10.2k|FFI_GUARD
  ------------------
  |  |  619|  10.2k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  10.2k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  10.2k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  10.2k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  10.2k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  10.2k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  10.2k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  10.2k|    catch (...)                                                                     \
  |  |  |  |  615|  10.2k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_verify_execute:
 3643|  10.2k|try {
 3644|  10.2k|    if (!op) {
  ------------------
  |  Branch (3644:9): [True: 0, False: 10.2k]
  ------------------
 3645|      0|        return RNP_ERROR_NULL_POINTER;
 3646|      0|    }
 3647|       |
 3648|  10.2k|    pgp_parse_handler_t handler;
 3649|       |
 3650|  10.2k|    handler.password_provider = &op->ffi->pass_provider;
 3651|       |
 3652|  10.2k|    rnp_decryption_kp_param_t kparam(op);
 3653|  10.2k|    rnp::KeyProvider          kprov(ffi_decrypt_key_provider, &kparam);
 3654|       |
 3655|  10.2k|    handler.key_provider = &kprov;
 3656|  10.2k|    handler.on_signatures = rnp_op_verify_on_signatures;
 3657|  10.2k|    handler.src_provider = rnp_verify_src_provider;
 3658|  10.2k|    handler.dest_provider = rnp_verify_dest_provider;
 3659|  10.2k|    handler.on_recipients = rnp_verify_on_recipients;
 3660|  10.2k|    handler.on_decryption_start = rnp_verify_on_decryption_start;
 3661|  10.2k|    handler.on_decryption_info = rnp_verify_on_decryption_info;
 3662|  10.2k|    handler.on_decryption_done = rnp_verify_on_decryption_done;
 3663|  10.2k|    handler.param = op;
 3664|  10.2k|    handler.ctx = &op->rnpctx;
 3665|       |
 3666|  10.2k|    rnp_result_t ret = process_pgp_source(&handler, op->input->src);
 3667|       |    /* For hidden recipients, patch used_recipient with the actual key id that was used.
 3668|       |     * kparam.last still points to the key that succeeded: the stream-parse loop breaks
 3669|       |     * immediately after a successful encrypted_try_key(), so the key provider is not
 3670|       |     * called again after that point. */
 3671|  10.2k|    if (kparam.has_hidden && kparam.last && op->used_recipient) {
  ------------------
  |  Branch (3671:9): [True: 0, False: 10.2k]
  |  Branch (3671:30): [True: 0, False: 0]
  |  Branch (3671:45): [True: 0, False: 0]
  ------------------
 3672|      0|        op->used_recipient->keyid = kparam.last->keyid();
 3673|      0|    }
 3674|       |    /* Allow to decrypt data ignoring the signatures check if requested */
 3675|  10.2k|    if (op->ignore_sigs && op->validated && (ret == RNP_ERROR_SIGNATURE_INVALID)) {
  ------------------
  |  Branch (3675:9): [True: 0, False: 10.2k]
  |  Branch (3675:28): [True: 0, False: 0]
  |  Branch (3675:45): [True: 0, False: 0]
  ------------------
 3676|      0|        ret = RNP_SUCCESS;
 3677|      0|    }
 3678|       |    /* Allow to require all signatures be valid */
 3679|  10.2k|    if (op->require_all_sigs && !ret) {
  ------------------
  |  Branch (3679:9): [True: 0, False: 10.2k]
  |  Branch (3679:33): [True: 0, False: 0]
  ------------------
 3680|      0|        for (auto &sig : op->signatures_) {
  ------------------
  |  Branch (3680:24): [True: 0, False: 0]
  ------------------
 3681|      0|            if (sig.verify_status) {
  ------------------
  |  Branch (3681:17): [True: 0, False: 0]
  ------------------
 3682|      0|                ret = RNP_ERROR_SIGNATURE_INVALID;
 3683|      0|                break;
 3684|      0|            }
 3685|      0|        }
 3686|      0|    }
 3687|  10.2k|    if (op->output) {
  ------------------
  |  Branch (3687:9): [True: 10.2k, False: 0]
  ------------------
 3688|  10.2k|        dst_flush(&op->output->dst);
 3689|  10.2k|        op->output->keep = ret == RNP_SUCCESS;
 3690|  10.2k|    }
 3691|  10.2k|    return ret;
 3692|  10.2k|}
 3693|  10.2k|FFI_GUARD
  ------------------
  |  |  619|  10.2k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  10.2k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  10.2k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  10.2k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  10.2k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  10.2k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  10.2k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  10.2k|    catch (...)                                                                     \
  |  |  |  |  615|  10.2k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_op_verify_destroy:
 3956|  10.2k|try {
 3957|  10.2k|    delete op;
 3958|  10.2k|    return RNP_SUCCESS;
 3959|  10.2k|}
 3960|  10.2k|FFI_GUARD
  ------------------
  |  |  619|  10.2k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  10.2k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  10.2k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  10.2k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  10.2k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  10.2k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  10.2k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  10.2k|    catch (...)                                                                     \
  |  |  |  |  615|  10.2k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
_ZN16rnp_op_verify_stD2Ev:
 3963|  10.2k|{
 3964|  10.2k|    delete used_recipient;
 3965|  10.2k|    delete used_symenc;
 3966|  10.2k|}
rnp_locate_key:
 4095|  7.18k|try {
 4096|       |    // checks
 4097|  7.18k|    if (!ffi || !identifier_type || !identifier || !handle) {
  ------------------
  |  Branch (4097:9): [True: 0, False: 7.18k]
  |  Branch (4097:17): [True: 0, False: 7.18k]
  |  Branch (4097:37): [True: 0, False: 7.18k]
  |  Branch (4097:52): [True: 0, False: 7.18k]
  ------------------
 4098|      0|        return RNP_ERROR_NULL_POINTER;
 4099|      0|    }
 4100|       |
 4101|       |    // figure out the identifier type
 4102|  7.18k|    auto search = rnp::KeySearch::create(identifier_type, identifier);
 4103|  7.18k|    if (!search) {
  ------------------
  |  Branch (4103:9): [True: 0, False: 7.18k]
  ------------------
 4104|      0|        return RNP_ERROR_BAD_PARAMETERS;
 4105|      0|    }
 4106|  7.18k|    return rnp_locate_key_int(ffi, *search, handle);
 4107|  7.18k|}
 4108|  7.18k|FFI_GUARD
  ------------------
  |  |  619|  7.18k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  7.18k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  7.18k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  7.18k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  7.18k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  7.18k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  7.18k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  7.18k|    catch (...)                                                                     \
  |  |  |  |  615|  7.18k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_key_handle_destroy:
 5878|  7.18k|try {
 5879|  7.18k|    delete key;
 5880|  7.18k|    return RNP_SUCCESS;
 5881|  7.18k|}
 5882|  7.18k|FFI_GUARD
  ------------------
  |  |  619|  7.18k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  7.18k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  7.18k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  7.18k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  7.18k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  7.18k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  7.18k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  7.18k|    catch (...)                                                                     \
  |  |  |  |  615|  7.18k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_buffer_destroy:
 5886|  12.7k|{
 5887|  12.7k|    free(ptr);
 5888|  12.7k|}
rnp_key_have_secret:
 8443|  3.74k|try {
 8444|  3.74k|    if (handle == NULL || result == NULL)
  ------------------
  |  Branch (8444:9): [True: 0, False: 3.74k]
  |  Branch (8444:27): [True: 0, False: 3.74k]
  ------------------
 8445|      0|        return RNP_ERROR_NULL_POINTER;
 8446|       |
 8447|  3.74k|    *result = handle->sec != NULL;
 8448|  3.74k|    return RNP_SUCCESS;
 8449|  3.74k|}
 8450|  3.74k|FFI_GUARD
  ------------------
  |  |  619|  3.74k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  3.74k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  3.74k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  3.74k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  3.74k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  3.74k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  3.74k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  3.74k|    catch (...)                                                                     \
  |  |  |  |  615|  3.74k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_identifier_iterator_create:
 9276|  15.8k|try {
 9277|       |    // checks
 9278|  15.8k|    if (!ffi || !it || !identifier_type) {
  ------------------
  |  Branch (9278:9): [True: 0, False: 15.8k]
  |  Branch (9278:17): [True: 0, False: 15.8k]
  |  Branch (9278:24): [True: 0, False: 15.8k]
  ------------------
 9279|      0|        return RNP_ERROR_NULL_POINTER;
 9280|      0|    }
 9281|       |    // create iterator
 9282|  15.8k|    auto type = rnp::KeySearch::find_type(identifier_type);
 9283|  15.8k|    if (type == rnp::KeySearch::Type::Unknown) {
  ------------------
  |  Branch (9283:9): [True: 0, False: 15.8k]
  ------------------
 9284|      0|        return RNP_ERROR_BAD_PARAMETERS;
 9285|      0|    }
 9286|  15.8k|    *it = new rnp_identifier_iterator_st(ffi, type);
 9287|       |    // move to first item (if any)
 9288|  15.8k|    key_iter_first_item(*it);
 9289|  15.8k|    return RNP_SUCCESS;
 9290|  15.8k|}
 9291|  15.8k|FFI_GUARD
  ------------------
  |  |  619|  15.8k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  15.8k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  15.8k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  15.8k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  15.8k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  15.8k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  15.8k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  15.8k|    catch (...)                                                                     \
  |  |  |  |  615|  15.8k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_identifier_iterator_next:
 9295|  44.6k|try {
 9296|       |    // checks
 9297|  44.6k|    if (!it || !identifier) {
  ------------------
  |  Branch (9297:9): [True: 0, False: 44.6k]
  |  Branch (9297:16): [True: 0, False: 44.6k]
  ------------------
 9298|      0|        return RNP_ERROR_NULL_POINTER;
 9299|      0|    }
 9300|       |    // initialize the result to NULL
 9301|  44.6k|    *identifier = NULL;
 9302|       |    // this means we reached the end of the rings
 9303|  44.6k|    if (!it->store) {
  ------------------
  |  Branch (9303:9): [True: 10.6k, False: 34.0k]
  ------------------
 9304|  10.6k|        return RNP_SUCCESS;
 9305|  10.6k|    }
 9306|       |    // get the item
 9307|  34.0k|    it->item = key_iter_get_item(it);
 9308|  34.0k|    if (it->item.empty()) {
  ------------------
  |  Branch (9308:9): [True: 0, False: 34.0k]
  ------------------
 9309|      0|        return RNP_ERROR_GENERIC;
 9310|      0|    }
 9311|  34.0k|    bool exists;
 9312|  34.0k|    bool iterator_valid = true;
 9313|  37.3k|    while ((exists = (it->tbl.find(it->item) != it->tbl.end()))) {
  ------------------
  |  Branch (9313:12): [True: 4.68k, False: 32.6k]
  ------------------
 9314|  4.68k|        if (!((iterator_valid = key_iter_next_item(it)))) {
  ------------------
  |  Branch (9314:13): [True: 1.42k, False: 3.26k]
  ------------------
 9315|  1.42k|            break;
 9316|  1.42k|        }
 9317|  3.26k|        it->item = key_iter_get_item(it);
 9318|  3.26k|        if (it->item.empty()) {
  ------------------
  |  Branch (9318:13): [True: 0, False: 3.26k]
  ------------------
 9319|      0|            return RNP_ERROR_GENERIC;
 9320|      0|        }
 9321|  3.26k|    }
 9322|       |    // see if we actually found a new entry
 9323|  34.0k|    if (!exists) {
  ------------------
  |  Branch (9323:9): [True: 32.6k, False: 1.42k]
  ------------------
 9324|  32.6k|        it->tbl.insert(it->item);
 9325|  32.6k|        *identifier = it->item.c_str();
 9326|  32.6k|    }
 9327|       |    // prepare for the next one
 9328|  34.0k|    if (iterator_valid) {
  ------------------
  |  Branch (9328:9): [True: 32.6k, False: 1.42k]
  ------------------
 9329|  32.6k|        key_iter_next_item(it);
 9330|  32.6k|    }
 9331|  34.0k|    return RNP_SUCCESS;
 9332|  34.0k|}
 9333|  44.6k|FFI_GUARD
  ------------------
  |  |  619|  44.6k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  44.6k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  44.6k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  44.6k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  44.6k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  44.6k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  44.6k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  44.6k|    catch (...)                                                                     \
  |  |  |  |  615|  44.6k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp_identifier_iterator_destroy:
 9337|  15.8k|try {
 9338|  15.8k|    if (it) {
  ------------------
  |  Branch (9338:9): [True: 15.8k, False: 0]
  ------------------
 9339|  15.8k|        delete it;
 9340|  15.8k|    }
 9341|  15.8k|    return RNP_SUCCESS;
 9342|  15.8k|}
 9343|  15.8k|FFI_GUARD
  ------------------
  |  |  619|  15.8k|#define FFI_GUARD FFI_GUARD_FP((stderr))
  |  |  ------------------
  |  |  |  |  602|  15.8k|    catch (rnp::rnp_exception & e)                                                  \
  |  |  |  |  603|  15.8k|    {                                                                               \
  |  |  |  |  604|      0|        return ffi_exception((fp), __func__, e.what(), e.code());                   \
  |  |  |  |  605|      0|    }                                                                               \
  |  |  |  |  606|  15.8k|    catch (std::bad_alloc &)                                                        \
  |  |  |  |  607|  15.8k|    {                                                                               \
  |  |  |  |  608|      0|        return ffi_exception((fp), __func__, "bad_alloc", RNP_ERROR_OUT_OF_MEMORY); \
  |  |  |  |  609|      0|    }                                                                               \
  |  |  |  |  610|  15.8k|    catch (std::exception & e)                                                      \
  |  |  |  |  611|  15.8k|    {                                                                               \
  |  |  |  |  612|      0|        return ffi_exception((fp), __func__, e.what());                             \
  |  |  |  |  613|      0|    }                                                                               \
  |  |  |  |  614|  15.8k|    catch (...)                                                                     \
  |  |  |  |  615|  15.8k|    {                                                                               \
  |  |  |  |  616|      0|        return ffi_exception((fp), __func__, "unknown exception");                  \
  |  |  |  |  617|      0|    }
  |  |  ------------------
  ------------------
rnp.cpp:_ZL16ffi_key_providerPK21pgp_key_request_ctx_tPv:
  123|  3.23k|{
  124|  3.23k|    rnp_ffi_t ffi = (rnp_ffi_t) userdata;
  125|  3.23k|    return find_key(ffi, ctx->search, ctx->secret, true);
  126|  3.23k|}
rnp.cpp:_ZL15parse_ks_formatPN3rnp9KeyFormatEPKc:
  509|  25.4k|{
  510|  25.4k|    if (!strcmp(format, RNP_KEYSTORE_GPG)) {
  ------------------
  |  | 4375|  25.4k|#define RNP_KEYSTORE_GPG ("GPG")
  ------------------
  |  Branch (510:9): [True: 25.4k, False: 0]
  ------------------
  511|  25.4k|        *key_store_format = rnp::KeyFormat::GPG;
  512|  25.4k|    } else if (!strcmp(format, RNP_KEYSTORE_KBX)) {
  ------------------
  |  | 4376|      0|#define RNP_KEYSTORE_KBX ("KBX")
  ------------------
  |  Branch (512:16): [True: 0, False: 0]
  ------------------
  513|      0|        *key_store_format = rnp::KeyFormat::KBX;
  514|      0|    } else if (!strcmp(format, RNP_KEYSTORE_G10)) {
  ------------------
  |  | 4377|      0|#define RNP_KEYSTORE_G10 ("G10")
  ------------------
  |  Branch (514:16): [True: 0, False: 0]
  ------------------
  515|      0|        *key_store_format = rnp::KeyFormat::G10;
  516|      0|    } else {
  517|      0|        return false;
  518|      0|    }
  519|  25.4k|    return true;
  520|  25.4k|}
rnp.cpp:_ZL13close_io_filePP8_IO_FILE:
  677|  12.7k|{
  678|  12.7k|    if (*fp && !is_std_file(*fp)) {
  ------------------
  |  Branch (678:9): [True: 12.7k, False: 0]
  |  Branch (678:16): [True: 0, False: 12.7k]
  ------------------
  679|      0|        fclose(*fp);
  680|      0|    }
  681|       |    *fp = NULL;
  682|  12.7k|}
rnp.cpp:_ZL11is_std_fileP8_IO_FILE:
  671|  12.7k|{
  672|  12.7k|    return fp == stdout || fp == stderr;
  ------------------
  |  Branch (672:12): [True: 0, False: 12.7k]
  |  Branch (672:28): [True: 12.7k, False: 0]
  ------------------
  673|  12.7k|}
rnp.cpp:_ZL22rnp_password_cb_bouncePK18pgp_password_ctx_tPcmPv:
  777|  8.81k|{
  778|  8.81k|    rnp_ffi_t ffi = (rnp_ffi_t) userdata_void;
  779|       |
  780|  8.81k|    if (!ffi || !ffi->getpasscb) {
  ------------------
  |  Branch (780:9): [True: 0, False: 8.81k]
  |  Branch (780:17): [True: 0, False: 8.81k]
  ------------------
  781|      0|        return false;
  782|      0|    }
  783|       |
  784|  8.81k|    rnp_key_handle_st key(ffi, nullptr, (rnp::Key *) ctx->key);
  785|  8.81k|    return ffi->getpasscb(ffi,
  786|  8.81k|                          ffi->getpasscb_ctx,
  787|  8.81k|                          ctx->key ? &key : NULL,
  ------------------
  |  Branch (787:27): [True: 0, False: 8.81k]
  ------------------
  788|  8.81k|                          operation_description(ctx->op),
  789|  8.81k|                          password,
  790|  8.81k|                          password_size);
  791|  8.81k|}
rnp.cpp:_ZL21operation_descriptionh:
  747|  8.81k|{
  748|  8.81k|    switch (op) {
  749|      0|    case PGP_OP_ADD_SUBKEY:
  ------------------
  |  Branch (749:5): [True: 0, False: 8.81k]
  ------------------
  750|      0|        return "add subkey";
  751|      0|    case PGP_OP_ADD_USERID:
  ------------------
  |  Branch (751:5): [True: 0, False: 8.81k]
  ------------------
  752|      0|        return "add userid";
  753|      0|    case PGP_OP_SIGN:
  ------------------
  |  Branch (753:5): [True: 0, False: 8.81k]
  ------------------
  754|      0|        return "sign";
  755|      0|    case PGP_OP_DECRYPT:
  ------------------
  |  Branch (755:5): [True: 0, False: 8.81k]
  ------------------
  756|      0|        return "decrypt";
  757|      0|    case PGP_OP_UNLOCK:
  ------------------
  |  Branch (757:5): [True: 0, False: 8.81k]
  ------------------
  758|      0|        return "unlock";
  759|      0|    case PGP_OP_PROTECT:
  ------------------
  |  Branch (759:5): [True: 0, False: 8.81k]
  ------------------
  760|      0|        return "protect";
  761|      0|    case PGP_OP_UNPROTECT:
  ------------------
  |  Branch (761:5): [True: 0, False: 8.81k]
  ------------------
  762|      0|        return "unprotect";
  763|  8.81k|    case PGP_OP_DECRYPT_SYM:
  ------------------
  |  Branch (763:5): [True: 8.81k, False: 0]
  ------------------
  764|  8.81k|        return "decrypt (symmetric)";
  765|      0|    case PGP_OP_ENCRYPT_SYM:
  ------------------
  |  Branch (765:5): [True: 0, False: 8.81k]
  ------------------
  766|      0|        return "encrypt (symmetric)";
  767|      0|    default:
  ------------------
  |  Branch (767:5): [True: 0, False: 8.81k]
  ------------------
  768|      0|        return "unknown";
  769|  8.81k|    }
  770|  8.81k|}
rnp.cpp:_ZL13ret_str_valuePKcPPc:
  542|  5.60k|{
  543|  5.60k|    if (!str) {
  ------------------
  |  Branch (543:9): [True: 0, False: 5.60k]
  ------------------
  544|      0|        return RNP_ERROR_BAD_PARAMETERS;
  545|      0|    }
  546|  5.60k|    char *strcp = strdup(str);
  547|  5.60k|    if (!strcp) {
  ------------------
  |  Branch (547:9): [True: 0, False: 5.60k]
  ------------------
  548|      0|        *res = NULL;                    // LCOV_EXCL_LINE
  549|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
  550|      0|    }
  551|  5.60k|    *res = strcp;
  552|  5.60k|    return RNP_SUCCESS;
  553|  5.60k|}
rnp.cpp:_ZL15str_to_hash_algPKcP14pgp_hash_alg_t:
  429|  21.3k|{
  430|  21.3k|    auto alg = id_str_pair::lookup(hash_alg_map, str, PGP_HASH_UNKNOWN);
  431|  21.3k|    if (!hash_alg_supported(alg)) {
  ------------------
  |  Branch (431:9): [True: 1.47k, False: 19.8k]
  ------------------
  432|  1.47k|        return false;
  433|  1.47k|    }
  434|  19.8k|    *hash_alg = static_cast<pgp_hash_alg_t>(alg);
  435|  19.8k|    return true;
  436|  21.3k|}
rnp.cpp:_ZL13str_to_cipherPKcP14pgp_symm_alg_t:
  418|  16.3k|{
  419|  16.3k|    auto alg = id_str_pair::lookup(symm_alg_map, str, PGP_SA_UNKNOWN);
  420|  16.3k|    if (!symm_alg_supported(alg)) {
  ------------------
  |  Branch (420:9): [True: 0, False: 16.3k]
  ------------------
  421|      0|        return false;
  422|      0|    }
  423|  16.3k|    *cipher = static_cast<pgp_symm_alg_t>(alg);
  424|  16.3k|    return true;
  425|  16.3k|}
rnp.cpp:_ZL15str_to_aead_algPKcP14pgp_aead_alg_t:
  440|  12.0k|{
  441|  12.0k|    auto alg = id_str_pair::lookup(aead_alg_map, str, PGP_AEAD_UNKNOWN);
  442|  12.0k|    if (!aead_alg_supported(alg)) {
  ------------------
  |  Branch (442:9): [True: 0, False: 12.0k]
  ------------------
  443|      0|        return false;
  444|      0|    }
  445|  12.0k|    *aead_alg = static_cast<pgp_aead_alg_t>(alg);
  446|  12.0k|    return true;
  447|  12.0k|}
rnp.cpp:_ZL22str_to_compression_algPKcP22pgp_compression_type_t:
  451|  12.0k|{
  452|  12.0k|    auto alg = id_str_pair::lookup(compress_alg_map, str, PGP_C_UNKNOWN);
  453|  12.0k|    if (!z_alg_supported(alg)) {
  ------------------
  |  Branch (453:9): [True: 0, False: 12.0k]
  ------------------
  454|      0|        return false;
  455|      0|    }
  456|  12.0k|    *zalg = static_cast<pgp_compression_type_t>(alg);
  457|  12.0k|    return true;
  458|  12.0k|}
rnp.cpp:_ZL18symm_alg_supportedi:
  289|  16.3k|{
  290|  16.3k|    return pgp_is_sa_supported(alg, true);
  291|  16.3k|}
rnp.cpp:_ZL18aead_alg_supportedi:
  319|  12.0k|{
  320|  12.0k|    switch (alg) {
  321|  5.67k|    case PGP_AEAD_NONE:
  ------------------
  |  Branch (321:5): [True: 5.67k, False: 6.35k]
  ------------------
  322|  5.67k|#if defined(ENABLE_AEAD)
  323|  5.67k|#if !defined(CRYPTO_BACKEND_OPENSSL)
  324|  7.72k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (324:5): [True: 2.04k, False: 9.98k]
  ------------------
  325|  7.72k|#endif
  326|  10.8k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (326:5): [True: 3.14k, False: 8.88k]
  ------------------
  327|  10.8k|#if defined(ENABLE_AEAD_GCM)
  328|  12.0k|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (328:5): [True: 1.16k, False: 10.8k]
  ------------------
  329|  12.0k|#endif
  330|  12.0k|#endif
  331|  12.0k|        return true;
  332|      0|    default:
  ------------------
  |  Branch (332:5): [True: 0, False: 12.0k]
  ------------------
  333|      0|        return false;
  334|  12.0k|    }
  335|  12.0k|}
rnp.cpp:_ZL18hash_alg_supportedi:
  295|  21.3k|{
  296|  21.3k|    switch (alg) {
  297|  5.97k|    case PGP_HASH_MD5:
  ------------------
  |  Branch (297:5): [True: 5.97k, False: 15.3k]
  ------------------
  298|  5.97k|    case PGP_HASH_SHA1:
  ------------------
  |  Branch (298:5): [True: 0, False: 21.3k]
  ------------------
  299|  5.97k|#if defined(ENABLE_RIPEMD160)
  300|  8.47k|    case PGP_HASH_RIPEMD:
  ------------------
  |  Branch (300:5): [True: 2.50k, False: 18.8k]
  ------------------
  301|  8.47k|#endif
  302|  11.9k|    case PGP_HASH_SHA256:
  ------------------
  |  Branch (302:5): [True: 3.46k, False: 17.8k]
  ------------------
  303|  13.1k|    case PGP_HASH_SHA384:
  ------------------
  |  Branch (303:5): [True: 1.18k, False: 20.1k]
  ------------------
  304|  15.0k|    case PGP_HASH_SHA512:
  ------------------
  |  Branch (304:5): [True: 1.89k, False: 19.4k]
  ------------------
  305|  15.0k|    case PGP_HASH_SHA224:
  ------------------
  |  Branch (305:5): [True: 0, False: 21.3k]
  ------------------
  306|  18.0k|    case PGP_HASH_SHA3_256:
  ------------------
  |  Branch (306:5): [True: 2.99k, False: 18.3k]
  ------------------
  307|  19.8k|    case PGP_HASH_SHA3_512:
  ------------------
  |  Branch (307:5): [True: 1.85k, False: 19.4k]
  ------------------
  308|  19.8k|#if defined(ENABLE_SM2)
  309|  19.8k|    case PGP_HASH_SM3:
  ------------------
  |  Branch (309:5): [True: 0, False: 21.3k]
  ------------------
  310|  19.8k|#endif
  311|  19.8k|        return true;
  312|  1.47k|    default:
  ------------------
  |  Branch (312:5): [True: 1.47k, False: 19.8k]
  ------------------
  313|  1.47k|        return false;
  314|  21.3k|    }
  315|  21.3k|}
rnp.cpp:_ZL15z_alg_supportedi:
  383|  12.0k|{
  384|  12.0k|    switch (alg) {
  385|  2.44k|    case PGP_C_NONE:
  ------------------
  |  Branch (385:5): [True: 2.44k, False: 9.58k]
  ------------------
  386|  7.27k|    case PGP_C_ZIP:
  ------------------
  |  Branch (386:5): [True: 4.83k, False: 7.19k]
  ------------------
  387|  10.2k|    case PGP_C_ZLIB:
  ------------------
  |  Branch (387:5): [True: 2.94k, False: 9.08k]
  ------------------
  388|  10.2k|        return true;
  389|      0|#ifdef HAVE_BZLIB_H
  390|  1.80k|    case PGP_C_BZIP2:
  ------------------
  |  Branch (390:5): [True: 1.80k, False: 10.2k]
  ------------------
  391|  1.80k|        return true;
  392|      0|#endif
  393|      0|    default:
  ------------------
  |  Branch (393:5): [True: 0, False: 12.0k]
  ------------------
  394|      0|        return false;
  395|  12.0k|    }
  396|  12.0k|}
rnp.cpp:_ZL21get_feature_sec_valueP10rnp_ffi_stPKcS2_RN3rnp11FeatureTypeERi:
 1227|  12.0k|{
 1228|       |    /* Resolve by name only, without the backend-availability checks used by
 1229|       |     * str_to_*_alg(): security rules must be queryable (and removable) for
 1230|       |     * algorithms the current backend cannot use at all, e.g. everything the
 1231|       |     * FIPS provider prohibits. */
 1232|       |    /* check type */
 1233|  12.0k|    if (rnp::str_case_eq(stype, RNP_FEATURE_HASH_ALG)) {
  ------------------
  |  | 4288|  12.0k|#define RNP_FEATURE_HASH_ALG "hash algorithm"
  ------------------
  |  Branch (1233:9): [True: 0, False: 12.0k]
  ------------------
 1234|      0|        type = rnp::FeatureType::Hash;
 1235|       |        /* check feature name */
 1236|      0|        pgp_hash_alg_t alg = PGP_HASH_UNKNOWN;
 1237|      0|        if (sname && (alg = static_cast<pgp_hash_alg_t>(id_str_pair::lookup(
  ------------------
  |  Branch (1237:13): [True: 0, False: 0]
  |  Branch (1237:22): [True: 0, False: 0]
  ------------------
 1238|      0|                        hash_alg_map, sname, PGP_HASH_UNKNOWN))) == PGP_HASH_UNKNOWN) {
 1239|      0|            FFI_LOG(ffi, "Unknown hash algorithm: %s", sname);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1240|      0|            return false;
 1241|      0|        }
 1242|      0|        value = alg;
 1243|      0|        return true;
 1244|      0|    }
 1245|       |
 1246|  12.0k|    if (rnp::str_case_eq(stype, RNP_FEATURE_SYMM_ALG)) {
  ------------------
  |  | 4284|  12.0k|#define RNP_FEATURE_SYMM_ALG "symmetric algorithm"
  ------------------
  |  Branch (1246:9): [True: 12.0k, False: 0]
  ------------------
 1247|  12.0k|        type = rnp::FeatureType::Cipher;
 1248|       |        /* check feature name */
 1249|  12.0k|        pgp_symm_alg_t alg = PGP_SA_UNKNOWN;
 1250|  12.0k|        if (sname && (alg = static_cast<pgp_symm_alg_t>(id_str_pair::lookup(
  ------------------
  |  Branch (1250:13): [True: 12.0k, False: 0]
  |  Branch (1250:22): [True: 0, False: 12.0k]
  ------------------
 1251|  12.0k|                        symm_alg_map, sname, PGP_SA_UNKNOWN))) == PGP_SA_UNKNOWN) {
 1252|      0|            FFI_LOG(ffi, "Unknown cipher: %s", sname);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1253|      0|            return false;
 1254|      0|        }
 1255|  12.0k|        value = alg;
 1256|  12.0k|        return true;
 1257|  12.0k|    }
 1258|       |
 1259|      0|    if (rnp::str_case_eq(stype, RNP_FEATURE_PK_ALG)) {
  ------------------
  |  | 4287|      0|#define RNP_FEATURE_PK_ALG "public key algorithm"
  ------------------
  |  Branch (1259:9): [True: 0, False: 0]
  ------------------
 1260|      0|        type = rnp::FeatureType::PublicKey;
 1261|       |        /* check feature name */
 1262|      0|        pgp_pubkey_alg_t alg = PGP_PKA_NOTHING;
 1263|      0|        if (sname && (alg = static_cast<pgp_pubkey_alg_t>(id_str_pair::lookup(
  ------------------
  |  Branch (1263:13): [True: 0, False: 0]
  |  Branch (1263:22): [True: 0, False: 0]
  ------------------
 1264|      0|                        pubkey_alg_map, sname, PGP_PKA_NOTHING))) == PGP_PKA_NOTHING) {
 1265|      0|            FFI_LOG(ffi, "Unknown public key algorithm: %s", sname);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1266|      0|            return false;
 1267|      0|        }
 1268|      0|        value = alg;
 1269|      0|        return true;
 1270|      0|    }
 1271|       |
 1272|      0|    FFI_LOG(ffi, "Unsupported feature type: %s", stype);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1273|      0|    return false;
 1274|      0|}
rnp.cpp:_ZL12extract_flagRjj:
 1298|  75.7k|{
 1299|  75.7k|    bool res = flags & flag;
 1300|  75.7k|    flags &= ~flag;
 1301|  75.7k|    return res;
 1302|  75.7k|}
rnp.cpp:_ZL19get_security_actionj:
 1354|  12.0k|{
 1355|  12.0k|    if (flags & RNP_SECURITY_VERIFY_KEY) {
  ------------------
  |  |  135|  12.0k|#define RNP_SECURITY_VERIFY_KEY (1U << 1)
  ------------------
  |  Branch (1355:9): [True: 0, False: 12.0k]
  ------------------
 1356|      0|        return rnp::SecurityAction::VerifyKey;
 1357|      0|    }
 1358|  12.0k|    if (flags & RNP_SECURITY_VERIFY_DATA) {
  ------------------
  |  |  136|  12.0k|#define RNP_SECURITY_VERIFY_DATA (1U << 2)
  ------------------
  |  Branch (1358:9): [True: 0, False: 12.0k]
  ------------------
 1359|      0|        return rnp::SecurityAction::VerifyData;
 1360|      0|    }
 1361|  12.0k|    return rnp::SecurityAction::Any;
 1362|  12.0k|}
rnp.cpp:_ZL14add_key_statusRN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapENSt3__16vectorENS3_12basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEblmdS8_NS0_14adl_serializerENS4_IhNS8_IhEEEEvEEPKN3rnp3KeyE23pgp_key_import_status_tSK_:
 1872|  16.4k|{
 1873|  16.4k|    nlohmann::ordered_json jsokey = nlohmann::ordered_json::object();
 1874|       |
 1875|  16.4k|    if (!rnp::json::add(jsokey, "public", key_status_to_str(pub)) ||
  ------------------
  |  Branch (1875:9): [True: 0, False: 16.4k]
  |  Branch (1875:9): [True: 0, False: 16.4k]
  ------------------
 1876|  16.4k|        !rnp::json::add(jsokey, "secret", key_status_to_str(sec)) ||
  ------------------
  |  Branch (1876:9): [True: 0, False: 16.4k]
  ------------------
 1877|  16.4k|        !rnp::json::add(jsokey, "fingerprint", key->fp()) ||
  ------------------
  |  Branch (1877:9): [True: 0, False: 16.4k]
  ------------------
 1878|  16.4k|        !rnp::json::array_add(keys, jsokey)) {
  ------------------
  |  Branch (1878:9): [True: 0, False: 16.4k]
  ------------------
 1879|       |        /* LCOV_EXCL_START */
 1880|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1881|       |        /* LCOV_EXCL_END */
 1882|      0|    }
 1883|       |
 1884|  16.4k|    return RNP_SUCCESS;
 1885|  16.4k|}
rnp.cpp:_ZL17key_status_to_str23pgp_key_import_status_t:
 1860|  32.9k|{
 1861|  32.9k|    if (status == PGP_KEY_IMPORT_STATUS_UNKNOWN) {
  ------------------
  |  Branch (1861:9): [True: 12.5k, False: 20.3k]
  ------------------
 1862|  12.5k|        return "none";
 1863|  12.5k|    }
 1864|  20.3k|    return id_str_pair::lookup(key_import_status_map, status, "none");
 1865|  32.9k|}
rnp.cpp:_ZL20rnp_op_add_signatureP10rnp_ffi_stRNSt3__14listI24rnp_op_sign_signature_stNS1_9allocatorIS3_EEEEP17rnp_key_handle_stR9rnp_ctx_tPPS3_:
 2698|    371|{
 2699|    371|    if (!key) {
  ------------------
  |  Branch (2699:9): [True: 0, False: 371]
  ------------------
 2700|      0|        return RNP_ERROR_NULL_POINTER;
 2701|      0|    }
 2702|       |
 2703|    371|    auto *signkey =
 2704|    371|      find_suitable_key(PGP_OP_SIGN, get_key_require_secret(key), &key->ffi->key_provider);
 2705|    371|    if (!signkey) {
  ------------------
  |  Branch (2705:9): [True: 371, False: 0]
  ------------------
 2706|    371|        return RNP_ERROR_NO_SUITABLE_KEY;
 2707|    371|    }
 2708|       |
 2709|      0|    try {
 2710|      0|        signatures.emplace_back();
 2711|      0|    } catch (const std::exception &e) {
 2712|       |        /* LCOV_EXCL_START */
 2713|      0|        FFI_LOG(ffi, "%s", e.what());
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 2714|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2715|       |        /* LCOV_EXCL_END */
 2716|      0|    }
 2717|      0|    rnp_op_sign_signature_t newsig = &signatures.back();
 2718|      0|    newsig->signer.key = signkey;
 2719|       |    /* set default create/expire times */
 2720|      0|    newsig->signer.sigcreate = ctx.sigcreate;
 2721|      0|    newsig->signer.sigexpire = ctx.sigexpire;
 2722|      0|    newsig->ffi = ffi;
 2723|       |
 2724|      0|    if (sig) {
  ------------------
  |  Branch (2724:9): [True: 0, False: 0]
  ------------------
 2725|      0|        *sig = newsig;
 2726|      0|    }
 2727|      0|    return RNP_SUCCESS;
 2728|      0|}
rnp.cpp:_ZL15rnp_op_set_hashP10rnp_ffi_stR9rnp_ctx_tPKc:
 2756|  12.7k|{
 2757|  12.7k|    if (!hash) {
  ------------------
  |  Branch (2757:9): [True: 0, False: 12.7k]
  ------------------
 2758|      0|        return RNP_ERROR_NULL_POINTER;
 2759|      0|    }
 2760|       |
 2761|  12.7k|    if (!str_to_hash_alg(hash, &ctx.halg)) {
  ------------------
  |  Branch (2761:9): [True: 1.29k, False: 11.4k]
  ------------------
 2762|  1.29k|        FFI_LOG(ffi, "Invalid hash: %s", hash);
  ------------------
  |  |   68|  1.29k|    do {                             \
  |  |   69|  1.29k|        FILE *fp = stderr;           \
  |  |   70|  1.29k|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 1.29k, False: 0]
  |  |  |  Branch (70:20): [True: 1.29k, False: 0]
  |  |  ------------------
  |  |   71|  1.29k|            fp = ffi->errs;          \
  |  |   72|  1.29k|        }                            \
  |  |   73|  1.29k|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|  1.29k|    do {                                                                                 \
  |  |  |  |   77|  1.29k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.29k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.29k|            break;                                                                       \
  |  |  |  |   79|  1.29k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|  1.29k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 1.29k]
  |  |  ------------------
  ------------------
 2763|  1.29k|        return RNP_ERROR_BAD_PARAMETERS;
 2764|  1.29k|    }
 2765|  11.4k|    return RNP_SUCCESS;
 2766|  12.7k|}
rnp.cpp:_ZL16rnp_op_set_armorR9rnp_ctx_tb:
 2732|  12.7k|{
 2733|  12.7k|    ctx.armor = armored;
 2734|  12.7k|    return RNP_SUCCESS;
 2735|  12.7k|}
rnp.cpp:_ZL21rnp_check_old_ciphersP10rnp_ffi_stPKc:
 2992|  12.0k|{
 2993|  12.0k|    uint32_t security_level = 0;
 2994|       |
 2995|  12.0k|    if (rnp_get_security_rule(ffi,
  ------------------
  |  Branch (2995:9): [True: 0, False: 12.0k]
  ------------------
 2996|  12.0k|                              RNP_FEATURE_SYMM_ALG,
  ------------------
  |  | 4284|  12.0k|#define RNP_FEATURE_SYMM_ALG "symmetric algorithm"
  ------------------
 2997|  12.0k|                              cipher,
 2998|  12.0k|                              ffi->context.time(),
 2999|  12.0k|                              NULL,
 3000|  12.0k|                              NULL,
 3001|  12.0k|                              &security_level)) {
 3002|      0|        FFI_LOG(ffi, "Failed to get security rules for cipher algorithm \'%s\'!", cipher);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3003|      0|        return false;
 3004|      0|    }
 3005|       |
 3006|  12.0k|    if (security_level < RNP_SECURITY_DEFAULT) {
  ------------------
  |  |  129|  12.0k|#define RNP_SECURITY_DEFAULT (2U)
  ------------------
  |  Branch (3006:9): [True: 4.05k, False: 7.97k]
  ------------------
 3007|  4.05k|        FFI_LOG(ffi, "Cipher algorithm \'%s\' is cryptographically weak!", cipher);
  ------------------
  |  |   68|  4.05k|    do {                             \
  |  |   69|  4.05k|        FILE *fp = stderr;           \
  |  |   70|  4.05k|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 4.05k, False: 0]
  |  |  |  Branch (70:20): [True: 4.05k, False: 0]
  |  |  ------------------
  |  |   71|  4.05k|            fp = ffi->errs;          \
  |  |   72|  4.05k|        }                            \
  |  |   73|  4.05k|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|  4.05k|    do {                                                                                 \
  |  |  |  |   77|  4.05k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.05k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.05k|            break;                                                                       \
  |  |  |  |   79|  4.05k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|  4.05k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 4.05k]
  |  |  ------------------
  ------------------
 3008|  4.05k|        return false;
 3009|  4.05k|    }
 3010|       |    /* TODO: check other weak algorithms and key sizes */
 3011|  7.97k|    return true;
 3012|  12.0k|}
rnp.cpp:_ZL22rnp_op_set_compressionP10rnp_ffi_stR9rnp_ctx_tPKci:
 2739|  12.0k|{
 2740|  12.0k|    if (!compression) {
  ------------------
  |  Branch (2740:9): [True: 0, False: 12.0k]
  ------------------
 2741|      0|        return RNP_ERROR_NULL_POINTER;
 2742|      0|    }
 2743|       |
 2744|  12.0k|    pgp_compression_type_t zalg = PGP_C_UNKNOWN;
 2745|  12.0k|    if (!str_to_compression_alg(compression, &zalg)) {
  ------------------
  |  Branch (2745:9): [True: 0, False: 12.0k]
  ------------------
 2746|      0|        FFI_LOG(ffi, "Invalid compression: %s", compression);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 2747|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2748|      0|    }
 2749|  12.0k|    ctx.zalg = (int) zalg;
 2750|  12.0k|    ctx.zlevel = level;
 2751|  12.0k|    return RNP_SUCCESS;
 2752|  12.0k|}
rnp.cpp:_ZL16rnp_op_set_flagsP10rnp_ffi_stR9rnp_ctx_tj:
 2784|  12.0k|{
 2785|  12.0k|    ctx.no_wrap = extract_flag(flags, RNP_ENCRYPT_NOWRAP);
  ------------------
  |  |  142|  12.0k|#define RNP_ENCRYPT_NOWRAP (1U << 0)
  ------------------
 2786|  12.0k|    if (flags) {
  ------------------
  |  Branch (2786:9): [True: 0, False: 12.0k]
  ------------------
 2787|      0|        FFI_LOG(ffi, "Unknown operation flags: %x", flags);
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 2788|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2789|      0|    }
 2790|  12.0k|    return RNP_SUCCESS;
 2791|  12.0k|}
rnp.cpp:_ZL20rnp_op_set_file_nameR9rnp_ctx_tPKc:
 2795|  12.0k|{
 2796|  12.0k|    ctx.filename = filename ? filename : "";
  ------------------
  |  Branch (2796:20): [True: 12.0k, False: 0]
  ------------------
 2797|  12.0k|    return RNP_SUCCESS;
 2798|  12.0k|}
rnp.cpp:_ZL21rnp_op_set_file_mtimeR9rnp_ctx_tj:
 2802|  12.0k|{
 2803|  12.0k|    ctx.filemtime = mtime;
 2804|  12.0k|    return RNP_SUCCESS;
 2805|  12.0k|}
rnp.cpp:_ZL21rnp_op_add_signaturesRNSt3__14listI24rnp_op_sign_signature_stNS_9allocatorIS1_EEEER9rnp_ctx_t:
 3121|    718|{
 3122|    718|    for (auto &sig : opsigs) {
  ------------------
  |  Branch (3122:20): [True: 0, False: 718]
  ------------------
 3123|      0|        if (!sig.signer.key) {
  ------------------
  |  Branch (3123:13): [True: 0, False: 0]
  ------------------
 3124|      0|            return RNP_ERROR_NO_SUITABLE_KEY;
 3125|      0|        }
 3126|       |
 3127|      0|        rnp_signer_info_t sinfo = sig.signer;
 3128|      0|        if (!sig.hash_set) {
  ------------------
  |  Branch (3128:13): [True: 0, False: 0]
  ------------------
 3129|      0|            sinfo.halg = ctx.halg;
 3130|      0|        }
 3131|      0|        if (!sig.expiry_set) {
  ------------------
  |  Branch (3131:13): [True: 0, False: 0]
  ------------------
 3132|      0|            sinfo.sigexpire = ctx.sigexpire;
 3133|      0|        }
 3134|      0|        if (!sig.create_set) {
  ------------------
  |  Branch (3134:13): [True: 0, False: 0]
  ------------------
 3135|      0|            sinfo.sigcreate = ctx.sigcreate;
 3136|      0|        }
 3137|      0|        ctx.signers.push_back(sinfo);
 3138|      0|    }
 3139|    718|    return RNP_SUCCESS;
 3140|    718|}
rnp.cpp:_ZL24ffi_decrypt_key_providerPK21pgp_key_request_ctx_tPv:
 3577|  2.32k|{
 3578|  2.32k|    rnp_decryption_kp_param_t *kparam = (rnp_decryption_kp_param_t *) userdata;
 3579|       |
 3580|  2.32k|    auto ffi = kparam->op->ffi;
 3581|  2.32k|    bool hidden = false;
 3582|  2.32k|    if (ctx->secret && (ctx->search.type() == rnp::KeySearch::Type::KeyID)) {
  ------------------
  |  Branch (3582:9): [True: 1.18k, False: 1.13k]
  |  Branch (3582:24): [True: 246, False: 942]
  ------------------
 3583|    246|        auto ksearch = dynamic_cast<const rnp::KeyIDSearch *>(&ctx->search);
 3584|    246|        assert(ksearch != nullptr);
 3585|    246|        hidden = ksearch && ksearch->hidden();
  ------------------
  |  Branch (3585:18): [True: 246, False: 0]
  |  Branch (3585:29): [True: 62, False: 184]
  ------------------
 3586|    246|    }
 3587|       |    /* default to the FFI key provider if not hidden keyid request */
 3588|  2.32k|    if (!hidden) {
  ------------------
  |  Branch (3588:9): [True: 2.26k, False: 62]
  ------------------
 3589|  2.26k|        return ffi->key_provider.callback(ctx, ffi->key_provider.userdata);
 3590|  2.26k|    }
 3591|     62|    if (!kparam->op->allow_hidden) {
  ------------------
  |  Branch (3591:9): [True: 62, False: 0]
  ------------------
 3592|     62|        return NULL;
 3593|     62|    }
 3594|       |    /* Iterate over the loaded secret keys, returning the next one on each call. Once the
 3595|       |     * search is exhausted NULL is returned and kparam->last is reset, so the next hidden
 3596|       |     * PKESK (a message may contain several of them, e.g. Delta Chat with anonymous v6
 3597|       |     * PKESKs) starts again from the first key instead of being skipped. */
 3598|       |    /* inform user about the hidden recipient before searching through the loaded keys */
 3599|      0|    if (!kparam->has_hidden) {
  ------------------
  |  Branch (3599:9): [True: 0, False: 0]
  ------------------
 3600|      0|        call_key_callback(ffi, ctx->search, ctx->secret);
 3601|      0|    }
 3602|      0|    kparam->has_hidden = true;
 3603|      0|    kparam->last = find_key(ffi, ctx->search, true, true, kparam->last);
 3604|      0|    return kparam->last;
 3605|     62|}
rnp.cpp:_ZL17call_key_callbackP10rnp_ffi_stRKN3rnp9KeySearchEb:
   96|  2.29k|{
   97|  2.29k|    if (!ffi->getkeycb) {
  ------------------
  |  Branch (97:9): [True: 2.29k, False: 0]
  ------------------
   98|  2.29k|        return false;
   99|  2.29k|    }
  100|      0|    ffi->getkeycb(
  101|      0|      ffi, ffi->getkeycb_ctx, search.name().c_str(), search.value().c_str(), secret);
  102|      0|    return true;
  103|  2.29k|}
rnp.cpp:_ZL27rnp_op_verify_on_signaturesRKNSt3__16vectorIN3rnp13SignatureInfoENS_9allocatorIS2_EEEEPv:
 3373|    547|{
 3374|    547|    rnp_op_verify_t op = (rnp_op_verify_t) param;
 3375|       |
 3376|    547|    try {
 3377|       |        /* in case we have multiple signed layers */
 3378|    547|        op->signatures_.resize(sigs.size());
 3379|       |
 3380|    547|        size_t i = 0;
 3381|  23.1k|        for (const auto &sinfo : sigs) {
  ------------------
  |  Branch (3381:32): [True: 23.1k, False: 547]
  ------------------
 3382|  23.1k|            auto &res = op->signatures_[i++];
 3383|       |            /* sinfo.sig may be NULL */
 3384|  23.1k|            if (sinfo.sig) {
  ------------------
  |  Branch (3384:17): [True: 1.20k, False: 21.9k]
  ------------------
 3385|  1.20k|                res.sig_pkt = *sinfo.sig;
 3386|  1.20k|            }
 3387|  23.1k|            res.validity = sinfo.validity;
 3388|  23.1k|            res.ffi = op->ffi;
 3389|       |
 3390|       |            /* signature is valid */
 3391|  23.1k|            if (res.validity.valid()) {
  ------------------
  |  Branch (3391:17): [True: 0, False: 23.1k]
  ------------------
 3392|      0|                res.verify_status = RNP_SUCCESS;
 3393|      0|                continue;
 3394|      0|            }
 3395|       |            /* failed to parse signature */
 3396|  23.1k|            if (res.validity.unknown()) {
  ------------------
  |  Branch (3396:17): [True: 21.9k, False: 1.20k]
  ------------------
 3397|  21.9k|                res.verify_status = RNP_ERROR_SIGNATURE_UNKNOWN;
 3398|  21.9k|                continue;
 3399|  21.9k|            }
 3400|       |            /* expired signature */
 3401|  1.20k|            if (res.validity.expired()) {
  ------------------
  |  Branch (3401:17): [True: 0, False: 1.20k]
  ------------------
 3402|      0|                res.verify_status = RNP_ERROR_SIGNATURE_EXPIRED;
 3403|      0|                continue;
 3404|      0|            }
 3405|       |            /* signer's key not found */
 3406|  1.20k|            if (res.validity.no_signer()) {
  ------------------
  |  Branch (3406:17): [True: 185, False: 1.01k]
  ------------------
 3407|    185|                res.verify_status = RNP_ERROR_KEY_NOT_FOUND;
 3408|    185|                continue;
 3409|    185|            }
 3410|       |            /* other reasons */
 3411|  1.01k|            res.verify_status = RNP_ERROR_SIGNATURE_INVALID;
 3412|  1.01k|        }
 3413|    547|    } catch (const std::exception &e) {
 3414|       |        FFI_LOG(op->ffi, "%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3415|      0|    }
 3416|    547|}
rnp.cpp:_ZL24rnp_verify_dest_providerP19pgp_parse_handler_tPP10pgp_dest_tPbPK17pgp_literal_hdr_t:
 3437|  3.26k|{
 3438|  3.26k|    rnp_op_verify_t op = (rnp_op_verify_t) handler->param;
 3439|  3.26k|    if (!op->output) {
  ------------------
  |  Branch (3439:9): [True: 0, False: 3.26k]
  ------------------
 3440|      0|        return false;
 3441|      0|    }
 3442|  3.26k|    *dst = &(op->output->dst);
 3443|  3.26k|    *closedst = false;
 3444|  3.26k|    op->lithdr = lithdr ? *lithdr : pgp_literal_hdr_t();
  ------------------
  |  Branch (3444:18): [True: 3.25k, False: 10]
  ------------------
 3445|  3.26k|    return true;
 3446|  3.26k|}
rnp.cpp:_ZL24rnp_verify_on_recipientsRKNSt3__16vectorI16pgp_pk_sesskey_tNS_9allocatorIS1_EEEERKNS0_I16pgp_sk_sesskey_tNS2_IS7_EEEEPv:
 3474|  8.49k|{
 3475|  8.49k|    rnp_op_verify_t op = (rnp_op_verify_t) param;
 3476|       |    /* store only top-level encrypted stream recipients info for now */
 3477|  8.49k|    if (op->encrypted_layers++) {
  ------------------
  |  Branch (3477:9): [True: 1.08k, False: 7.40k]
  ------------------
 3478|  1.08k|        return;
 3479|  1.08k|    }
 3480|  7.40k|    if (!recipients.empty()) {
  ------------------
  |  Branch (3480:9): [True: 27, False: 7.37k]
  ------------------
 3481|     27|        op->recipients.resize(recipients.size());
 3482|     54|        for (size_t i = 0; i < recipients.size(); i++) {
  ------------------
  |  Branch (3482:28): [True: 27, False: 27]
  ------------------
 3483|     27|            recipient_handle_from_pk_sesskey(op->recipients[i], recipients[i]);
 3484|     27|        }
 3485|     27|    }
 3486|  7.40k|    if (!passwords.empty()) {
  ------------------
  |  Branch (3486:9): [True: 7.38k, False: 17]
  ------------------
 3487|  7.38k|        op->symencs.resize(passwords.size());
 3488|  14.7k|        for (size_t i = 0; i < passwords.size(); i++) {
  ------------------
  |  Branch (3488:28): [True: 7.38k, False: 7.38k]
  ------------------
 3489|  7.38k|            symenc_handle_from_sk_sesskey(op->symencs[i], passwords[i]);
 3490|  7.38k|        }
 3491|  7.38k|    }
 3492|  7.40k|}
rnp.cpp:_ZL32recipient_handle_from_pk_sesskeyR23rnp_recipient_handle_stRK16pgp_pk_sesskey_t:
 3451|     27|{
 3452|     27|    handle.keyid = sesskey.key_id;
 3453|     27|    handle.palg = sesskey.alg;
 3454|     27|}
rnp.cpp:_ZL29symenc_handle_from_sk_sesskeyR20rnp_symenc_handle_stRK16pgp_sk_sesskey_t:
 3458|  14.7k|{
 3459|  14.7k|    handle.alg = sesskey.alg;
 3460|  14.7k|    handle.halg = sesskey.s2k.hash_alg;
 3461|  14.7k|    handle.s2k_type = sesskey.s2k.specifier;
 3462|  14.7k|    if (sesskey.s2k.specifier == PGP_S2KS_ITERATED_AND_SALTED) {
  ------------------
  |  Branch (3462:9): [True: 14.7k, False: 0]
  ------------------
 3463|  14.7k|        handle.iterations = pgp_s2k_decode_iterations(sesskey.s2k.iterations);
 3464|  14.7k|    } else {
 3465|      0|        handle.iterations = 1;
 3466|      0|    }
 3467|  14.7k|    handle.aalg = sesskey.aalg;
 3468|  14.7k|}
rnp.cpp:_ZL30rnp_verify_on_decryption_startP16pgp_pk_sesskey_tP16pgp_sk_sesskey_tPv:
 3496|  7.85k|{
 3497|  7.85k|    rnp_op_verify_t op = (rnp_op_verify_t) param;
 3498|       |    /* store only top-level encrypted stream info */
 3499|  7.85k|    if (op->encrypted_layers > 1) {
  ------------------
  |  Branch (3499:9): [True: 470, False: 7.38k]
  ------------------
 3500|    470|        return;
 3501|    470|    }
 3502|  7.38k|    if (pubenc) {
  ------------------
  |  Branch (3502:9): [True: 0, False: 7.38k]
  ------------------
 3503|      0|        op->used_recipient = new (std::nothrow) rnp_recipient_handle_st();
 3504|      0|        if (!op->used_recipient) {
  ------------------
  |  Branch (3504:13): [True: 0, False: 0]
  ------------------
 3505|      0|            return;
 3506|      0|        }
 3507|      0|        recipient_handle_from_pk_sesskey(*op->used_recipient, *pubenc);
 3508|      0|        return;
 3509|      0|    }
 3510|  7.38k|    if (symenc) {
  ------------------
  |  Branch (3510:9): [True: 7.38k, False: 0]
  ------------------
 3511|  7.38k|        op->used_symenc = new (std::nothrow) rnp_symenc_handle_st();
 3512|  7.38k|        if (!op->used_symenc) {
  ------------------
  |  Branch (3512:13): [True: 0, False: 7.38k]
  ------------------
 3513|      0|            return;
 3514|      0|        }
 3515|  7.38k|        symenc_handle_from_sk_sesskey(*op->used_symenc, *symenc);
 3516|  7.38k|        return;
 3517|  7.38k|    }
 3518|      0|    FFI_LOG(op->ffi, "Warning! Both pubenc and symenc are NULL.");
  ------------------
  |  |   68|      0|    do {                             \
  |  |   69|      0|        FILE *fp = stderr;           \
  |  |   70|      0|        if (ffi && ffi->errs) {      \
  |  |  ------------------
  |  |  |  Branch (70:13): [True: 0, False: 0]
  |  |  |  Branch (70:20): [True: 0, False: 0]
  |  |  ------------------
  |  |   71|      0|            fp = ffi->errs;          \
  |  |   72|      0|        }                            \
  |  |   73|      0|        RNP_LOG_FD(fp, __VA_ARGS__); \
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (74:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
 3519|      0|}
rnp.cpp:_ZL29rnp_verify_on_decryption_infob14pgp_aead_alg_t14pgp_symm_alg_tPv:
 3523|  8.49k|{
 3524|  8.49k|    rnp_op_verify_t op = (rnp_op_verify_t) param;
 3525|       |    /* store only top-level encrypted stream info for now */
 3526|  8.49k|    if (op->encrypted_layers > 1) {
  ------------------
  |  Branch (3526:9): [True: 1.08k, False: 7.40k]
  ------------------
 3527|  1.08k|        return;
 3528|  1.08k|    }
 3529|  7.40k|    op->mdc = mdc;
 3530|  7.40k|    op->aead = aead;
 3531|  7.40k|    op->salg = salg;
 3532|  7.40k|    op->encrypted = true;
 3533|  7.40k|}
rnp.cpp:_ZL29rnp_verify_on_decryption_donebPv:
 3537|  3.13k|{
 3538|  3.13k|    rnp_op_verify_t op = (rnp_op_verify_t) param;
 3539|  3.13k|    if (op->encrypted_layers > 1) {
  ------------------
  |  Branch (3539:9): [True: 0, False: 3.13k]
  ------------------
 3540|      0|        return;
 3541|      0|    }
 3542|  3.13k|    op->validated = validated;
 3543|  3.13k|}
rnp.cpp:_ZL18rnp_locate_key_intP10rnp_ffi_stRKN3rnp9KeySearchEPP17rnp_key_handle_stb:
 4071|  7.18k|{
 4072|       |    // search pubring
 4073|  7.18k|    auto *pub = ffi->pubring->search(locator);
 4074|       |    // search secring
 4075|  7.18k|    auto *sec = ffi->secring->search(locator);
 4076|       |
 4077|  7.18k|    if (require_secret && !sec) {
  ------------------
  |  Branch (4077:9): [True: 0, False: 7.18k]
  |  Branch (4077:27): [True: 0, False: 0]
  ------------------
 4078|      0|        *handle = nullptr;
 4079|      0|        return RNP_SUCCESS;
 4080|      0|    }
 4081|       |
 4082|  7.18k|    if (pub || sec) {
  ------------------
  |  Branch (4082:9): [True: 7.18k, False: 0]
  |  Branch (4082:16): [True: 0, False: 0]
  ------------------
 4083|  7.18k|        *handle = new rnp_key_handle_st(ffi, pub, sec);
 4084|  7.18k|    } else {
 4085|      0|        *handle = nullptr;
 4086|      0|    }
 4087|  7.18k|    return RNP_SUCCESS;
 4088|  7.18k|}
rnp.cpp:_ZL22get_key_require_publicP17rnp_key_handle_st:
 5900|  3.44k|{
 5901|  3.44k|    if (!handle->pub && handle->sec) {
  ------------------
  |  Branch (5901:9): [True: 0, False: 3.44k]
  |  Branch (5901:25): [True: 0, False: 0]
  ------------------
 5902|       |        // try fingerprint
 5903|      0|        rnp::KeyFingerprintSearch fpsrch(handle->sec->fp());
 5904|      0|        handle->pub = handle->ffi->key_provider.request_key(fpsrch);
 5905|      0|        if (handle->pub) {
  ------------------
  |  Branch (5905:13): [True: 0, False: 0]
  ------------------
 5906|      0|            return handle->pub;
 5907|      0|        }
 5908|       |
 5909|       |        // try keyid
 5910|      0|        rnp::KeyIDSearch idsrch(handle->sec->keyid());
 5911|      0|        handle->pub = handle->ffi->key_provider.request_key(idsrch);
 5912|      0|    }
 5913|  3.44k|    return handle->pub;
 5914|  3.44k|}
rnp.cpp:_ZL21get_key_prefer_publicP17rnp_key_handle_st:
 5918|  3.44k|{
 5919|  3.44k|    auto *pub = get_key_require_public(handle);
 5920|  3.44k|    return pub ? pub : get_key_require_secret(handle);
  ------------------
  |  Branch (5920:12): [True: 3.44k, False: 0]
  ------------------
 5921|  3.44k|}
rnp.cpp:_ZL22get_key_require_secretP17rnp_key_handle_st:
 5925|    371|{
 5926|    371|    if (!handle->sec && handle->pub) {
  ------------------
  |  Branch (5926:9): [True: 0, False: 371]
  |  Branch (5926:25): [True: 0, False: 0]
  ------------------
 5927|       |        // try fingerprint
 5928|      0|        rnp::KeyFingerprintSearch fpsrch(handle->pub->fp());
 5929|      0|        handle->sec = handle->ffi->key_provider.request_key(fpsrch, PGP_OP_UNKNOWN, true);
 5930|      0|        if (handle->sec) {
  ------------------
  |  Branch (5930:13): [True: 0, False: 0]
  ------------------
 5931|      0|            return handle->sec;
 5932|      0|        }
 5933|       |
 5934|       |        // try keyid
 5935|      0|        rnp::KeyIDSearch idsrch(handle->pub->keyid());
 5936|      0|        handle->sec = handle->ffi->key_provider.request_key(idsrch, PGP_OP_UNKNOWN, true);
 5937|      0|    }
 5938|    371|    return handle->sec;
 5939|    371|}
rnp.cpp:_ZL8find_keyP10rnp_ffi_stRKN3rnp9KeySearchEbbPNS1_3KeyE:
  111|  3.23k|{
  112|  3.23k|    auto      ks = secret ? ffi->secring : ffi->pubring;
  ------------------
  |  Branch (112:20): [True: 1.30k, False: 1.93k]
  ------------------
  113|  3.23k|    rnp::Key *key = ks->search(search, after);
  114|  3.23k|    if (!key && try_key_provider && call_key_callback(ffi, search, secret)) {
  ------------------
  |  Branch (114:9): [True: 2.29k, False: 944]
  |  Branch (114:17): [True: 2.29k, False: 0]
  |  Branch (114:37): [True: 0, False: 2.29k]
  ------------------
  115|       |        // recurse and try the store search above once more
  116|      0|        return find_key(ffi, search, secret, false, after);
  117|      0|    }
  118|  3.23k|    return key;
  119|  3.23k|}
rnp.cpp:_ZL19key_iter_first_itemP26rnp_identifier_iterator_st:
 9226|  15.8k|{
 9227|  15.8k|    switch (it->type) {
 9228|      0|    case rnp::KeySearch::Type::KeyID:
  ------------------
  |  Branch (9228:5): [True: 0, False: 15.8k]
  ------------------
 9229|  15.8k|    case rnp::KeySearch::Type::Fingerprint:
  ------------------
  |  Branch (9229:5): [True: 15.8k, False: 0]
  ------------------
 9230|  15.8k|    case rnp::KeySearch::Type::Grip:
  ------------------
  |  Branch (9230:5): [True: 0, False: 15.8k]
  ------------------
 9231|  15.8k|        return key_iter_first_key(it);
 9232|      0|    case rnp::KeySearch::Type::UserID:
  ------------------
  |  Branch (9232:5): [True: 0, False: 15.8k]
  ------------------
 9233|      0|        if (!key_iter_first_key(it)) {
  ------------------
  |  Branch (9233:13): [True: 0, False: 0]
  ------------------
 9234|      0|            return false;
 9235|      0|        }
 9236|      0|        it->uididx = 0;
 9237|      0|        while (it->uididx >= (*it->keyp)->uid_count()) {
  ------------------
  |  Branch (9237:16): [True: 0, False: 0]
  ------------------
 9238|      0|            if (!key_iter_next_key(it)) {
  ------------------
  |  Branch (9238:17): [True: 0, False: 0]
  ------------------
 9239|      0|                return false;
 9240|      0|            }
 9241|      0|        }
 9242|      0|        break;
 9243|      0|    default:
  ------------------
  |  Branch (9243:5): [True: 0, False: 15.8k]
  ------------------
 9244|      0|        assert(false);
 9245|      0|        break;
 9246|  15.8k|    }
 9247|      0|    return true;
 9248|  15.8k|}
rnp.cpp:_ZL18key_iter_first_keyP26rnp_identifier_iterator_st:
 9210|  15.8k|{
 9211|  15.8k|    if (it->ffi->pubring->key_count()) {
  ------------------
  |  Branch (9211:9): [True: 9.60k, False: 6.24k]
  ------------------
 9212|  9.60k|        it->store = it->ffi->pubring;
 9213|  9.60k|    } else if (it->ffi->secring->key_count()) {
  ------------------
  |  Branch (9213:16): [True: 0, False: 6.24k]
  ------------------
 9214|      0|        it->store = it->ffi->secring;
 9215|  6.24k|    } else {
 9216|  6.24k|        it->store = NULL;
 9217|  6.24k|        return false;
 9218|  6.24k|    }
 9219|  9.60k|    *it->keyp = it->store->keys.begin();
 9220|  9.60k|    it->uididx = 0;
 9221|  9.60k|    return true;
 9222|  15.8k|}
rnp.cpp:_ZL17key_iter_next_keyP26rnp_identifier_iterator_st:
 9164|  37.3k|{
 9165|       |    // check if we not reached the end of the ring
 9166|  37.3k|    *it->keyp = std::next(*it->keyp);
 9167|  37.3k|    if (*it->keyp != it->store->keys.end()) {
  ------------------
  |  Branch (9167:9): [True: 27.7k, False: 9.62k]
  ------------------
 9168|  27.7k|        it->uididx = 0;
 9169|  27.7k|        return true;
 9170|  27.7k|    }
 9171|       |    // if we are currently on pubring, switch to secring (if not empty)
 9172|  9.62k|    if (it->store == it->ffi->pubring && !it->ffi->secring->keys.empty()) {
  ------------------
  |  Branch (9172:9): [True: 8.20k, False: 1.42k]
  |  Branch (9172:42): [True: 2.07k, False: 6.12k]
  ------------------
 9173|  2.07k|        it->store = it->ffi->secring;
 9174|  2.07k|        *it->keyp = it->store->keys.begin();
 9175|  2.07k|        it->uididx = 0;
 9176|  2.07k|        return true;
 9177|  2.07k|    }
 9178|       |    // we've gone through both rings
 9179|  7.54k|    it->store = NULL;
 9180|  7.54k|    return false;
 9181|  9.62k|}
rnp.cpp:_ZL17key_iter_get_itemP26rnp_identifier_iterator_st:
 9252|  37.3k|{
 9253|  37.3k|    auto &key = **it->keyp;
 9254|  37.3k|    switch (it->type) {
 9255|      0|    case rnp::KeySearch::Type::KeyID:
  ------------------
  |  Branch (9255:5): [True: 0, False: 37.3k]
  ------------------
 9256|      0|        return rnp::bin_to_hex(key.keyid().data(), key.keyid().size());
 9257|  37.3k|    case rnp::KeySearch::Type::Fingerprint:
  ------------------
  |  Branch (9257:5): [True: 37.3k, False: 0]
  ------------------
 9258|  37.3k|        return rnp::bin_to_hex(key.fp().data(), key.fp().size());
 9259|      0|    case rnp::KeySearch::Type::Grip:
  ------------------
  |  Branch (9259:5): [True: 0, False: 37.3k]
  ------------------
 9260|      0|        return rnp::bin_to_hex(key.grip().data(), key.grip().size());
 9261|      0|    case rnp::KeySearch::Type::UserID:
  ------------------
  |  Branch (9261:5): [True: 0, False: 37.3k]
  ------------------
 9262|      0|        if (it->uididx >= key.uid_count()) {
  ------------------
  |  Branch (9262:13): [True: 0, False: 0]
  ------------------
 9263|      0|            return "";
 9264|      0|        }
 9265|      0|        return key.get_uid(it->uididx).str;
 9266|      0|    default:
  ------------------
  |  Branch (9266:5): [True: 0, False: 37.3k]
  ------------------
 9267|       |        assert(false);
 9268|      0|        return "";
 9269|  37.3k|    }
 9270|  37.3k|}
rnp.cpp:_ZL18key_iter_next_itemP26rnp_identifier_iterator_st:
 9186|  37.3k|{
 9187|  37.3k|    switch (it->type) {
 9188|      0|    case rnp::KeySearch::Type::KeyID:
  ------------------
  |  Branch (9188:5): [True: 0, False: 37.3k]
  ------------------
 9189|  37.3k|    case rnp::KeySearch::Type::Fingerprint:
  ------------------
  |  Branch (9189:5): [True: 37.3k, False: 0]
  ------------------
 9190|  37.3k|    case rnp::KeySearch::Type::Grip:
  ------------------
  |  Branch (9190:5): [True: 0, False: 37.3k]
  ------------------
 9191|  37.3k|        return key_iter_next_key(it);
 9192|      0|    case rnp::KeySearch::Type::UserID:
  ------------------
  |  Branch (9192:5): [True: 0, False: 37.3k]
  ------------------
 9193|      0|        it->uididx++;
 9194|      0|        while (it->uididx >= (*it->keyp)->uid_count()) {
  ------------------
  |  Branch (9194:16): [True: 0, False: 0]
  ------------------
 9195|      0|            if (!key_iter_next_key(it)) {
  ------------------
  |  Branch (9195:17): [True: 0, False: 0]
  ------------------
 9196|      0|                return false;
 9197|      0|            }
 9198|      0|            it->uididx = 0;
 9199|      0|        }
 9200|      0|        break;
 9201|      0|    default:
  ------------------
  |  Branch (9201:5): [True: 0, False: 37.3k]
  ------------------
 9202|      0|        assert(false);
 9203|      0|        break;
 9204|  37.3k|    }
 9205|      0|    return true;
 9206|  37.3k|}

_ZNK3rnp12SecurityRule7matchesENS_11FeatureTypeEimNS_14SecurityActionE:
   52|   209k|{
   53|   209k|    if ((type != ftype) || (feature != fval) || (from > ftime)) {
  ------------------
  |  Branch (53:9): [True: 105k, False: 103k]
  |  Branch (53:28): [True: 92.1k, False: 11.6k]
  |  Branch (53:49): [True: 2.74k, False: 8.87k]
  ------------------
   54|   200k|        return false;
   55|   200k|    }
   56|  8.87k|    return (action == SecurityAction::Any) || (faction == SecurityAction::Any) ||
  ------------------
  |  Branch (56:12): [True: 8.17k, False: 699]
  |  Branch (56:47): [True: 0, False: 699]
  ------------------
   57|    699|           (action == faction);
  ------------------
  |  Branch (57:12): [True: 346, False: 353]
  ------------------
   58|   209k|}
_ZN3rnp15SecurityProfile8add_ruleEONS_12SecurityRuleE:
   75|   101k|{
   76|   101k|    rules_.emplace_back(rule);
   77|   101k|    return rules_.back();
   78|   101k|}
_ZNK3rnp15SecurityProfile8has_ruleENS_11FeatureTypeEimNS_14SecurityActionE:
  123|  23.3k|{
  124|   175k|    for (auto &rule : rules_) {
  ------------------
  |  Branch (124:21): [True: 175k, False: 19.1k]
  ------------------
  125|   175k|        if (rule.matches(type, value, time, action)) {
  ------------------
  |  Branch (125:13): [True: 4.25k, False: 171k]
  ------------------
  126|  4.25k|            return true;
  127|  4.25k|        }
  128|   175k|    }
  129|  19.1k|    return false;
  130|  23.3k|}
_ZNK3rnp15SecurityProfile8get_ruleENS_11FeatureTypeEimNS_14SecurityActionE:
  137|  4.25k|{
  138|  4.25k|    const SecurityRule *res = nullptr;
  139|  34.0k|    for (auto &rule : rules_) {
  ------------------
  |  Branch (139:21): [True: 34.0k, False: 4.25k]
  ------------------
  140|  34.0k|        if (!rule.matches(type, value, time, action)) {
  ------------------
  |  Branch (140:13): [True: 29.8k, False: 4.25k]
  ------------------
  141|  29.8k|            continue;
  142|  29.8k|        }
  143|  4.25k|        if (rule.override) {
  ------------------
  |  Branch (143:13): [True: 0, False: 4.25k]
  ------------------
  144|      0|            return rule;
  145|      0|        }
  146|  4.25k|        if (!res || (res->from < rule.from)) {
  ------------------
  |  Branch (146:13): [True: 4.25k, False: 0]
  |  Branch (146:21): [True: 0, False: 0]
  ------------------
  147|  4.25k|            res = &rule;
  148|  4.25k|        }
  149|  4.25k|    }
  150|  4.25k|    if (!res) {
  ------------------
  |  Branch (150:9): [True: 0, False: 4.25k]
  ------------------
  151|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  152|      0|    }
  153|  4.25k|    return *res;
  154|  4.25k|}
_ZNK3rnp15SecurityProfile10hash_levelE14pgp_hash_alg_tmNS_14SecurityActionE:
  160|  11.3k|{
  161|  11.3k|    if (!has_rule(FeatureType::Hash, hash, time, action)) {
  ------------------
  |  Branch (161:9): [True: 11.1k, False: 203]
  ------------------
  162|  11.1k|        return def_level();
  163|  11.1k|    }
  164|       |
  165|    203|    try {
  166|    203|        return get_rule(FeatureType::Hash, hash, time, action).level;
  167|    203|    } catch (const std::exception &e) {
  168|       |        /* this should never happen however we need to satisfy noexcept specifier */
  169|      0|        return def_level();
  170|      0|    }
  171|    203|}
_ZNK3rnp15SecurityProfile9def_levelEv:
  175|  23.1k|{
  176|  23.1k|    return SecurityLevel::Default;
  177|  23.1k|};
_ZN3rnp15SecurityContextC2Ev:
  185|  12.7k|SecurityContext::SecurityContext() : time_(0), prov_state_(NULL), rng(RNG::Type::DRBG)
  186|  12.7k|{
  187|       |    /* Initialize crypto provider if needed (currently only for OpenSSL 3.0) */
  188|  12.7k|    if (!rnp::backend_init(&prov_state_)) {
  ------------------
  |  Branch (188:9): [True: 0, False: 12.7k]
  ------------------
  189|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_STATE);
  190|      0|    }
  191|       |    /* Mark SHA-1 data signature insecure since 2019-01-19, as GnuPG does */
  192|  12.7k|    profile.add_rule({FeatureType::Hash,
  193|  12.7k|                      PGP_HASH_SHA1,
  194|  12.7k|                      SecurityLevel::Insecure,
  195|  12.7k|                      1547856000,
  196|  12.7k|                      SecurityAction::VerifyData});
  197|       |    /* Mark SHA-1 key signature insecure since 2024-01-19 by default */
  198|  12.7k|    profile.add_rule({FeatureType::Hash,
  199|  12.7k|                      PGP_HASH_SHA1,
  200|  12.7k|                      SecurityLevel::Insecure,
  201|  12.7k|                      1705629600,
  202|  12.7k|                      SecurityAction::VerifyKey});
  203|       |    /* Mark MD5 insecure since 2012-01-01 */
  204|  12.7k|    profile.add_rule({FeatureType::Hash, PGP_HASH_MD5, SecurityLevel::Insecure, 1325376000});
  205|       |    /* Mark CAST5, 3DES, IDEA, BLOWFISH insecure since 2024-10-01*/
  206|  12.7k|    profile.add_rule({FeatureType::Cipher, PGP_SA_CAST5, SecurityLevel::Insecure, 1727730000});
  207|  12.7k|    profile.add_rule(
  208|  12.7k|      {FeatureType::Cipher, PGP_SA_TRIPLEDES, SecurityLevel::Insecure, 1727730000});
  209|  12.7k|    profile.add_rule({FeatureType::Cipher, PGP_SA_IDEA, SecurityLevel::Insecure, 1727730000});
  210|  12.7k|    profile.add_rule(
  211|  12.7k|      {FeatureType::Cipher, PGP_SA_BLOWFISH, SecurityLevel::Insecure, 1727730000});
  212|  12.7k|#if defined(ENABLE_CRYPTO_REFRESH)
  213|       |    /* Mark RIPEMD insecure since 2024-01-19 by default */
  214|  12.7k|    profile.add_rule(
  215|  12.7k|      {FeatureType::Hash, PGP_HASH_RIPEMD, SecurityLevel::Insecure, 1705629600});
  216|  12.7k|#endif
  217|       |#if defined(RNP_FIPS_MODE)
  218|       |    /*
  219|       |     * FIPS-compliant defaults: mark non-FIPS-approved algorithms as Disabled
  220|       |     * (not merely Insecure) so they cannot be used at all. These rules have
  221|       |     * from = 0, so they apply to objects regardless of creation time. The
  222|       |     * caller may still relax individual rules via rnp_add_security_rule() with
  223|       |     * the RNP_SECURITY_OVERRIDE flag, but the defaults are intentionally
  224|       |     * strict. See docs/security.adoc for the certification boundary.
  225|       |     *
  226|       |     * Note: this enforces rnp's policy on top of OpenSSL's validated module.
  227|       |     * It does not by itself make rnp a FIPS-validated module.
  228|       |     */
  229|       |    /* Non-FIPS symmetric algorithms */
  230|       |    profile.add_rule({FeatureType::Cipher, PGP_SA_TWOFISH, SecurityLevel::Disabled, 0});
  231|       |    profile.add_rule({FeatureType::Cipher, PGP_SA_CAST5, SecurityLevel::Disabled, 0});
  232|       |    profile.add_rule({FeatureType::Cipher, PGP_SA_IDEA, SecurityLevel::Disabled, 0});
  233|       |    profile.add_rule({FeatureType::Cipher, PGP_SA_BLOWFISH, SecurityLevel::Disabled, 0});
  234|       |    profile.add_rule({FeatureType::Cipher, PGP_SA_SM4, SecurityLevel::Disabled, 0});
  235|       |    /* Non-FIPS hash algorithms */
  236|       |    profile.add_rule({FeatureType::Hash, PGP_HASH_MD5, SecurityLevel::Disabled, 0});
  237|       |    profile.add_rule({FeatureType::Hash, PGP_HASH_SHA1, SecurityLevel::Disabled, 0});
  238|       |    profile.add_rule({FeatureType::Hash, PGP_HASH_RIPEMD, SecurityLevel::Disabled, 0});
  239|       |    /* Non-FIPS public-key algorithms. DSA is FIPS-approved but only with
  240|       |     * approved key sizes; that size gating is enforced separately during key
  241|       |     * generation/use, not via a blanket rule here. */
  242|       |    profile.add_rule({FeatureType::PublicKey, PGP_PKA_EDDSA, SecurityLevel::Disabled, 0});
  243|       |    profile.add_rule({FeatureType::PublicKey, PGP_PKA_SM2, SecurityLevel::Disabled, 0});
  244|       |    profile.add_rule({FeatureType::PublicKey, PGP_PKA_ELGAMAL, SecurityLevel::Disabled, 0});
  245|       |    profile.add_rule(
  246|       |      {FeatureType::PublicKey, PGP_PKA_ELGAMAL_ENCRYPT_OR_SIGN, SecurityLevel::Disabled, 0});
  247|       |#endif
  248|  12.7k|}
_ZN3rnp15SecurityContextD2Ev:
  251|  12.7k|{
  252|  12.7k|    rnp::backend_finish(prov_state_);
  253|  12.7k|}
_ZNK3rnp15SecurityContext4timeEv:
  273|  72.0k|{
  274|  72.0k|    return time_ ? time_ : ::time(NULL);
  ------------------
  |  Branch (274:12): [True: 0, False: 72.0k]
  ------------------
  275|  72.0k|}

_ZN3rnp12SecurityRuleC2ENS_11FeatureTypeEiNS_13SecurityLevelEmNS_14SecurityActionE:
   54|   114k|        : type(ftype), feature(fval), level(flevel), from(ffrom), override(false),
   55|   114k|          action(faction){};

_ZN3pgp11SigMaterial6createE16pgp_pubkey_alg_t14pgp_hash_alg_t:
   35|  60.2k|{
   36|  60.2k|    switch (palg) {
   37|  13.9k|    case PGP_PKA_RSA:
  ------------------
  |  Branch (37:5): [True: 13.9k, False: 46.3k]
  ------------------
   38|  18.2k|    case PGP_PKA_RSA_SIGN_ONLY:
  ------------------
  |  Branch (38:5): [True: 4.36k, False: 55.9k]
  ------------------
   39|  18.2k|        return std::unique_ptr<SigMaterial>(new RSASigMaterial(halg));
   40|  2.45k|    case PGP_PKA_DSA:
  ------------------
  |  Branch (40:5): [True: 2.45k, False: 57.8k]
  ------------------
   41|  2.45k|        return std::unique_ptr<SigMaterial>(new DSASigMaterial(halg));
   42|  14.5k|    case PGP_PKA_EDDSA:
  ------------------
  |  Branch (42:5): [True: 14.5k, False: 45.7k]
  ------------------
   43|  32.1k|    case PGP_PKA_ECDSA:
  ------------------
  |  Branch (43:5): [True: 17.5k, False: 42.6k]
  ------------------
   44|  32.1k|    case PGP_PKA_SM2:
  ------------------
  |  Branch (44:5): [True: 23, False: 60.2k]
  ------------------
   45|  32.1k|    case PGP_PKA_ECDH:
  ------------------
  |  Branch (45:5): [True: 52, False: 60.2k]
  ------------------
   46|  32.1k|        return std::unique_ptr<SigMaterial>(new ECSigMaterial(halg));
   47|  2.19k|    case PGP_PKA_ELGAMAL: /* we support reading it but will not validate */
  ------------------
  |  Branch (47:5): [True: 2.19k, False: 58.0k]
  ------------------
   48|  2.29k|    case PGP_PKA_ELGAMAL_ENCRYPT_OR_SIGN:
  ------------------
  |  Branch (48:5): [True: 103, False: 60.1k]
  ------------------
   49|  2.29k|        return std::unique_ptr<SigMaterial>(new EGSigMaterial(halg));
   50|      0|#if defined(ENABLE_CRYPTO_REFRESH)
   51|    113|    case PGP_PKA_ED25519: {
  ------------------
  |  Branch (51:5): [True: 113, False: 60.1k]
  ------------------
   52|    113|        return std::unique_ptr<SigMaterial>(new Ed25519SigMaterial(halg));
   53|  2.19k|    }
   54|    422|    case PGP_PKA_ED448: {
  ------------------
  |  Branch (54:5): [True: 422, False: 59.8k]
  ------------------
   55|    422|        return std::unique_ptr<SigMaterial>(new Ed448SigMaterial(halg));
   56|  2.19k|    }
   57|      0|#endif
   58|      0|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
   59|     76|    case PGP_PKA_DILITHIUM3_ED25519:
  ------------------
  |  Branch (59:5): [True: 76, False: 60.2k]
  ------------------
   60|     76|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     76|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   61|     87|    case PGP_PKA_DILITHIUM5_ED448:
  ------------------
  |  Branch (61:5): [True: 11, False: 60.2k]
  ------------------
   62|     87|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     87|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   63|     99|    case PGP_PKA_DILITHIUM3_P384:
  ------------------
  |  Branch (63:5): [True: 12, False: 60.2k]
  ------------------
   64|     99|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     99|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   65|    116|    case PGP_PKA_DILITHIUM5_P521:
  ------------------
  |  Branch (65:5): [True: 17, False: 60.2k]
  ------------------
   66|    116|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    116|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   67|    137|    case PGP_PKA_DILITHIUM3_BP384:
  ------------------
  |  Branch (67:5): [True: 21, False: 60.2k]
  ------------------
   68|    137|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    137|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   69|    158|    case PGP_PKA_DILITHIUM5_BP512:
  ------------------
  |  Branch (69:5): [True: 21, False: 60.2k]
  ------------------
   70|    158|        return std::unique_ptr<SigMaterial>(new DilithiumSigMaterial(palg, halg));
   71|    156|    case PGP_PKA_SPHINCSPLUS_SHAKE_128f:
  ------------------
  |  Branch (71:5): [True: 156, False: 60.1k]
  ------------------
   72|    156|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    156|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   73|    195|    case PGP_PKA_SPHINCSPLUS_SHAKE_128s:
  ------------------
  |  Branch (73:5): [True: 39, False: 60.2k]
  ------------------
   74|    195|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    195|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   75|    376|    case PGP_PKA_SPHINCSPLUS_SHAKE_256s:
  ------------------
  |  Branch (75:5): [True: 181, False: 60.0k]
  ------------------
   76|    376|        return std::unique_ptr<SigMaterial>(new SlhdsaSigMaterial(palg, halg));
   77|      0|#endif
   78|  3.98k|    default:
  ------------------
  |  Branch (78:5): [True: 3.98k, False: 56.2k]
  ------------------
   79|  3.98k|        RNP_LOG("Unknown pk algorithm : %d", (int) palg);
  ------------------
  |  |   84|  3.98k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  3.98k|    do {                                                                                 \
  |  |  |  |   77|  3.98k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3.98k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  3.98k|            break;                                                                       \
  |  |  |  |   79|  3.98k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   80|  3.98k|        return nullptr;
   81|  60.2k|    }
   82|  60.2k|}
_ZN3pgp14RSASigMaterial5parseER17pgp_packet_body_t:
   86|  18.2k|{
   87|  18.2k|    return pkt.get(sig.s);
   88|  18.2k|}
_ZN3pgp14DSASigMaterial5parseER17pgp_packet_body_t:
   98|  2.45k|{
   99|  2.45k|    return pkt.get(sig.r) && pkt.get(sig.s);
  ------------------
  |  Branch (99:12): [True: 2.40k, False: 48]
  |  Branch (99:30): [True: 2.34k, False: 63]
  ------------------
  100|  2.45k|}
_ZN3pgp13EGSigMaterial5parseER17pgp_packet_body_t:
  111|  2.29k|{
  112|  2.29k|    return pkt.get(sig.r) && pkt.get(sig.s);
  ------------------
  |  Branch (112:12): [True: 2.24k, False: 47]
  |  Branch (112:30): [True: 2.18k, False: 62]
  ------------------
  113|  2.29k|}
_ZN3pgp13ECSigMaterial5parseER17pgp_packet_body_t:
  125|  32.1k|{
  126|  32.1k|    return pkt.get(sig.r) && pkt.get(sig.s);
  ------------------
  |  Branch (126:12): [True: 31.9k, False: 273]
  |  Branch (126:30): [True: 31.2k, False: 631]
  ------------------
  127|  32.1k|}
_ZN3pgp18Ed25519SigMaterial5parseER17pgp_packet_body_t:
  139|    113|{
  140|    113|    auto ec_desc = pgp::ec::Curve::get(PGP_CURVE_25519);
  141|    113|    if (!pkt.get(sig.sig, 2 * ec_desc->bytes())) {
  ------------------
  |  Branch (141:9): [True: 21, False: 92]
  ------------------
  142|     21|        RNP_LOG("failed to parse ED25519 signature data");
  ------------------
  |  |   84|     21|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     21|    do {                                                                                 \
  |  |  |  |   77|     21|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 21, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     21|            break;                                                                       \
  |  |  |  |   79|     21|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  143|     21|        return false;
  144|     21|    }
  145|     92|    return true;
  146|    113|}
_ZN3pgp16Ed448SigMaterial5parseER17pgp_packet_body_t:
  156|    422|{
  157|    422|    auto ec_desc = pgp::ec::Curve::get(PGP_CURVE_448);
  158|    422|    if (!pkt.get(sig.sig, 2 * ec_desc->bytes())) {
  ------------------
  |  Branch (158:9): [True: 44, False: 378]
  ------------------
  159|     44|        RNP_LOG("failed to parse ED448 signature data");
  ------------------
  |  |   84|     44|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     44|    do {                                                                                 \
  |  |  |  |   77|     44|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 44, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     44|            break;                                                                       \
  |  |  |  |   79|     44|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  160|     44|        return false;
  161|     44|    }
  162|    378|    return true;
  163|    422|}
_ZN3pgp20DilithiumSigMaterial5parseER17pgp_packet_body_t:
  175|    158|{
  176|    158|    if (!pkt.get(sig.sig, pgp_dilithium_exdsa_signature_t::composite_signature_size(palg))) {
  ------------------
  |  Branch (176:9): [True: 158, False: 0]
  ------------------
  177|    158|        RNP_LOG("failed to get mldsa-ecdsa/eddsa signature");
  ------------------
  |  |   84|    158|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    158|    do {                                                                                 \
  |  |  |  |   77|    158|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 158, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    158|            break;                                                                       \
  |  |  |  |   79|    158|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  178|    158|        return false;
  179|    158|    }
  180|      0|    return true;
  181|    158|}
_ZN3pgp17SlhdsaSigMaterial5parseER17pgp_packet_body_t:
  191|    376|{
  192|    376|    auto sig_size = sphincsplus_signature_size(palg);
  193|    376|    if (!sig_size) {
  ------------------
  |  Branch (193:9): [True: 0, False: 376]
  ------------------
  194|      0|        RNP_LOG("invalid SLH-DSA algorithm value");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  195|      0|        return false;
  196|      0|    }
  197|    376|    if (!pkt.get(sig.sig, sig_size)) {
  ------------------
  |  Branch (197:9): [True: 375, False: 1]
  ------------------
  198|    375|        RNP_LOG("failed to parse SLH-DSA signature data");
  ------------------
  |  |   84|    375|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    375|    do {                                                                                 \
  |  |  |  |   77|    375|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 375, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    375|            break;                                                                       \
  |  |  |  |   79|    375|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  199|    375|        return false;
  200|    375|    }
  201|      1|    return true;
  202|    376|}

_ZN3pgp11SigMaterialC2E14pgp_hash_alg_t:
   40|  56.2k|    SigMaterial(pgp_hash_alg_t ahalg) : halg(ahalg){};
_ZN3pgp11SigMaterialD2Ev:
   41|  56.2k|    virtual ~SigMaterial(){};
_ZN3pgp14RSASigMaterialC2E14pgp_hash_alg_t:
   52|  18.2k|    RSASigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp14DSASigMaterialC2E14pgp_hash_alg_t:
   61|  2.45k|    DSASigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp13EGSigMaterialC2E14pgp_hash_alg_t:
   70|  2.29k|    EGSigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp13ECSigMaterialC2E14pgp_hash_alg_t:
   79|  32.1k|    ECSigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp18Ed25519SigMaterialC2E14pgp_hash_alg_t:
   89|    113|    Ed25519SigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp16Ed448SigMaterialC2E14pgp_hash_alg_t:
   98|    422|    Ed448SigMaterial(pgp_hash_alg_t ahalg) : SigMaterial(ahalg){};
_ZN3pgp20DilithiumSigMaterialC2E16pgp_pubkey_alg_t14pgp_hash_alg_t:
  112|    158|        : SigMaterial(ahalg), palg(apalg){};
_ZN3pgp17SlhdsaSigMaterialC2E16pgp_pubkey_alg_t14pgp_hash_alg_t:
  123|    376|        : SigMaterial(ahalg), palg(apalg){};

_ZN3pgp3pkt6sigsub3RawC2Ehbb:
   43|  10.6k|    : hashed_(hashed), raw_type_(rawtype), critical_(critical), type_(Type::Unknown)
   44|  10.6k|{
   45|  10.6k|}
_ZN3pgp3pkt6sigsub3RawC2ENS1_4TypeEbb:
   48|   209k|    : hashed_(hashed), raw_type_(static_cast<uint8_t>(type)), critical_(critical), type_(type)
   49|   209k|{
   50|   209k|}
_ZN3pgp3pkt6sigsub3RawD2Ev:
   53|  1.46M|{
   54|  1.46M|}
_ZNK3pgp3pkt6sigsub3Raw10check_sizeEm:
   58|  12.6k|{
   59|  12.6k|    return true;
   60|  12.6k|};
_ZN3pgp3pkt6sigsub3Raw10parse_dataEPKhm:
   64|  10.6k|{
   65|  10.6k|    return true;
   66|  10.6k|};
_ZN3pgp3pkt6sigsub3Raw5parseEPKhmm:
   70|   220k|{
   71|   220k|    parse_depth_ = depth;
   72|   220k|    if (!check_size(size)) {
  ------------------
  |  Branch (72:9): [True: 4.66k, False: 215k]
  ------------------
   73|  4.66k|        RNP_LOG("wrong len %zu of subpacket type %" PRIu8, size, raw_type_);
  ------------------
  |  |   84|  4.66k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  4.66k|    do {                                                                                 \
  |  |  |  |   77|  4.66k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.66k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.66k|            break;                                                                       \
  |  |  |  |   79|  4.66k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   74|  4.66k|        return false;
   75|  4.66k|    }
   76|   215k|    if (!parse_data(data, size)) {
  ------------------
  |  Branch (76:9): [True: 877, False: 214k]
  ------------------
   77|    877|        return false;
   78|    877|    }
   79|   214k|    data_.assign(data, data + size);
   80|   214k|    return true;
   81|   215k|}
_ZN3pgp3pkt6sigsub3Raw6createEhbb:
  129|   220k|{
  130|   220k|    switch (type) {
  131|  33.2k|    case (uint8_t) Type::CreationTime:
  ------------------
  |  Branch (131:5): [True: 33.2k, False: 186k]
  ------------------
  132|  33.2k|        return RawPtr(new CreationTime(hashed, critical));
  133|  5.82k|    case (uint8_t) Type::ExpirationTime:
  ------------------
  |  Branch (133:5): [True: 5.82k, False: 214k]
  ------------------
  134|  5.82k|        return RawPtr(new ExpirationTime(hashed, critical));
  135|    767|    case (uint8_t) Type::ExportableCert:
  ------------------
  |  Branch (135:5): [True: 767, False: 219k]
  ------------------
  136|    767|        return RawPtr(new ExportableCert(hashed, critical));
  137|    318|    case (uint8_t) Type::Trust:
  ------------------
  |  Branch (137:5): [True: 318, False: 219k]
  ------------------
  138|    318|        return RawPtr(new Trust(hashed, critical));
  139|    180|    case (uint8_t) Type::RegExp:
  ------------------
  |  Branch (139:5): [True: 180, False: 219k]
  ------------------
  140|    180|        return RawPtr(new RegExp(hashed, critical));
  141|    482|    case (uint8_t) Type::Revocable:
  ------------------
  |  Branch (141:5): [True: 482, False: 219k]
  ------------------
  142|    482|        return RawPtr(new Revocable(hashed, critical));
  143|  2.02k|    case (uint8_t) Type::KeyExpirationTime:
  ------------------
  |  Branch (143:5): [True: 2.02k, False: 218k]
  ------------------
  144|  2.02k|        return RawPtr(new KeyExpirationTime(hashed, critical));
  145|  11.6k|    case (uint8_t) Type::PreferredSymmetric:
  ------------------
  |  Branch (145:5): [True: 11.6k, False: 208k]
  ------------------
  146|  11.6k|        return RawPtr(new PreferredSymmetric(hashed, critical));
  147|    303|    case (uint8_t) Type::RevocationKey:
  ------------------
  |  Branch (147:5): [True: 303, False: 219k]
  ------------------
  148|    303|        return RawPtr(new RevocationKey(hashed, critical));
  149|  28.5k|    case (uint8_t) Type::IssuerKeyID:
  ------------------
  |  Branch (149:5): [True: 28.5k, False: 191k]
  ------------------
  150|  28.5k|        return RawPtr(new IssuerKeyID(hashed, critical));
  151|    527|    case (uint8_t) Type::NotationData:
  ------------------
  |  Branch (151:5): [True: 527, False: 219k]
  ------------------
  152|    527|        return RawPtr(new NotationData(hashed, critical));
  153|  11.3k|    case (uint8_t) Type::PreferredHash:
  ------------------
  |  Branch (153:5): [True: 11.3k, False: 208k]
  ------------------
  154|  11.3k|        return RawPtr(new PreferredHash(hashed, critical));
  155|  11.6k|    case (uint8_t) Type::PreferredCompress:
  ------------------
  |  Branch (155:5): [True: 11.6k, False: 208k]
  ------------------
  156|  11.6k|        return RawPtr(new PreferredCompress(hashed, critical));
  157|  9.51k|    case (uint8_t) Type::KeyserverPrefs:
  ------------------
  |  Branch (157:5): [True: 9.51k, False: 210k]
  ------------------
  158|  9.51k|        return RawPtr(new KeyserverPrefs(hashed, critical));
  159|  1.36k|    case (uint8_t) Type::PreferredKeyserver:
  ------------------
  |  Branch (159:5): [True: 1.36k, False: 218k]
  ------------------
  160|  1.36k|        return RawPtr(new PreferredKeyserver(hashed, critical));
  161|  5.43k|    case (uint8_t) Type::PrimaryUserID:
  ------------------
  |  Branch (161:5): [True: 5.43k, False: 214k]
  ------------------
  162|  5.43k|        return RawPtr(new PrimaryUserID(hashed, critical));
  163|    247|    case (uint8_t) Type::PolicyURI:
  ------------------
  |  Branch (163:5): [True: 247, False: 219k]
  ------------------
  164|    247|        return RawPtr(new PolicyURI(hashed, critical));
  165|  23.8k|    case (uint8_t) Type::KeyFlags:
  ------------------
  |  Branch (165:5): [True: 23.8k, False: 196k]
  ------------------
  166|  23.8k|        return RawPtr(new KeyFlags(hashed, critical));
  167|    248|    case (uint8_t) Type::SignersUserID:
  ------------------
  |  Branch (167:5): [True: 248, False: 219k]
  ------------------
  168|    248|        return RawPtr(new SignersUserID(hashed, critical));
  169|  11.6k|    case (uint8_t) Type::RevocationReason:
  ------------------
  |  Branch (169:5): [True: 11.6k, False: 208k]
  ------------------
  170|  11.6k|        return RawPtr(new RevocationReason(hashed, critical));
  171|  9.58k|    case (uint8_t) Type::Features:
  ------------------
  |  Branch (171:5): [True: 9.58k, False: 210k]
  ------------------
  172|  9.58k|        return RawPtr(new Features(hashed, critical));
  173|    711|    case (uint8_t) Type::EmbeddedSignature:
  ------------------
  |  Branch (173:5): [True: 711, False: 219k]
  ------------------
  174|    711|        return RawPtr(new EmbeddedSignature(hashed, critical));
  175|  31.6k|    case (uint8_t) Type::IssuerFingerprint:
  ------------------
  |  Branch (175:5): [True: 31.6k, False: 188k]
  ------------------
  176|  31.6k|        return RawPtr(new IssuerFingerprint(hashed, critical));
  177|  7.74k|    case (uint8_t) Type::PreferredAEAD:
  ------------------
  |  Branch (177:5): [True: 7.74k, False: 212k]
  ------------------
  178|  7.74k|        return RawPtr(new PreferredAEAD(hashed, critical));
  179|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  180|     40|    case (uint8_t) Type::IntendedRecipientFingerprint:
  ------------------
  |  Branch (180:5): [True: 40, False: 220k]
  ------------------
  181|     40|        return RawPtr(new IntendedRecipientFingerprint(hashed, critical));
  182|    607|    case (uint8_t) Type::PreferredAEADv6:
  ------------------
  |  Branch (182:5): [True: 607, False: 219k]
  ------------------
  183|    607|        return RawPtr(new PreferredAEADv6(hashed, critical));
  184|      0|#endif
  185|  10.6k|    default:
  ------------------
  |  Branch (185:5): [True: 10.6k, False: 209k]
  ------------------
  186|  10.6k|        report_unknown(type, critical);
  187|  10.6k|        return RawPtr(new Raw(type, hashed, critical));
  188|   220k|    }
  189|   220k|}
_ZN3pgp3pkt6sigsub3Raw6createEPKhmbm:
  199|   220k|{
  200|   220k|    if (!size) {
  ------------------
  |  Branch (200:9): [True: 0, False: 220k]
  ------------------
  201|      0|        RNP_LOG("got subpacket with 0 length");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  202|      0|        return nullptr;
  203|      0|    }
  204|   220k|    bool    critical = data[0] & 0x80;
  205|   220k|    uint8_t type = data[0] & 0x7f;
  206|   220k|    auto    sub = create(type, hashed, critical);
  207|       |    /* Unknown subpacket (including the critical one) is kept as unparsed Raw subpacket,
  208|       |     * so the signature can still be loaded. Signature with the unknown critical subpacket
  209|       |     * is marked as invalid during the validation, see RFC 9580: 5.2.3.16. */
  210|   220k|    if (!sub || !sub->parse(data + 1, size - 1, depth)) {
  ------------------
  |  Branch (210:9): [True: 0, False: 220k]
  |  Branch (210:17): [True: 5.54k, False: 214k]
  ------------------
  211|  5.54k|        return nullptr;
  212|  5.54k|    }
  213|   214k|    return sub;
  214|   220k|}
_ZNK3pgp3pkt6sigsub3Raw5cloneEv:
  218|  40.6k|{
  219|  40.6k|    return RawPtr(new Raw(*this));
  220|  40.6k|}
_ZNK3pgp3pkt6sigsub4Time10check_sizeEm:
  232|  41.1k|{
  233|  41.1k|    return size == 4;
  234|  41.1k|}
_ZN3pgp3pkt6sigsub4Time10parse_dataEPKhm:
  238|  38.5k|{
  239|  38.5k|    time_ = read_uint32(data);
  240|  38.5k|    return true;
  241|  38.5k|}
_ZNK3pgp3pkt6sigsub12CreationTime5cloneEv:
  246|   192k|{
  247|   192k|    return RawPtr(new CreationTime(*this));
  248|   192k|}
_ZNK3pgp3pkt6sigsub14ExpirationTime5cloneEv:
  253|  35.2k|{
  254|  35.2k|    return RawPtr(new ExpirationTime(*this));
  255|  35.2k|}
_ZNK3pgp3pkt6sigsub17KeyExpirationTime5cloneEv:
  260|  9.49k|{
  261|  9.49k|    return RawPtr(new KeyExpirationTime(*this));
  262|  9.49k|}
_ZNK3pgp3pkt6sigsub4Bool10check_sizeEm:
  274|  6.68k|{
  275|  6.68k|    return size == 1;
  276|  6.68k|}
_ZN3pgp3pkt6sigsub4Bool10parse_dataEPKhm:
  280|  5.87k|{
  281|  5.87k|    value_ = data[0];
  282|  5.87k|    return true;
  283|  5.87k|}
_ZNK3pgp3pkt6sigsub14ExportableCert5cloneEv:
  288|  2.42k|{
  289|  2.42k|    return RawPtr(new ExportableCert(*this));
  290|  2.42k|}
_ZNK3pgp3pkt6sigsub5Trust10check_sizeEm:
  303|    318|{
  304|    318|    return size == 2;
  305|    318|}
_ZN3pgp3pkt6sigsub5Trust10parse_dataEPKhm:
  309|     53|{
  310|     53|    level_ = data[0];
  311|     53|    amount_ = data[1];
  312|     53|    return true;
  313|     53|}
_ZNK3pgp3pkt6sigsub5Trust5cloneEv:
  317|    196|{
  318|    196|    return RawPtr(new Trust(*this));
  319|    196|}
_ZN3pgp3pkt6sigsub6String10parse_dataEPKhm:
  330|  2.03k|{
  331|  2.03k|    value_.assign(data, data + size);
  332|  2.03k|    return true;
  333|  2.03k|}
_ZNK3pgp3pkt6sigsub6RegExp5cloneEv:
  338|    306|{
  339|    306|    return RawPtr(new RegExp(*this));
  340|    306|}
_ZNK3pgp3pkt6sigsub9Revocable5cloneEv:
  345|    197|{
  346|    197|    return RawPtr(new Revocable(*this));
  347|    197|}
_ZNK3pgp3pkt6sigsub9Preferred10check_sizeEm:
  358|  43.0k|{
  359|       |    /* No reason to have more then 256 bytes */
  360|  43.0k|    return size < 256;
  361|  43.0k|}
_ZN3pgp3pkt6sigsub9Preferred10parse_dataEPKhm:
  365|  42.9k|{
  366|  42.9k|    algs_.assign(data, data + size);
  367|  42.9k|    return true;
  368|  42.9k|}
_ZNK3pgp3pkt6sigsub18PreferredSymmetric5cloneEv:
  373|  65.4k|{
  374|  65.4k|    return RawPtr(new PreferredSymmetric(*this));
  375|  65.4k|}
_ZNK3pgp3pkt6sigsub13PreferredHash5cloneEv:
  380|  66.9k|{
  381|  66.9k|    return RawPtr(new PreferredHash(*this));
  382|  66.9k|}
_ZNK3pgp3pkt6sigsub17PreferredCompress5cloneEv:
  387|  71.1k|{
  388|  71.1k|    return RawPtr(new PreferredCompress(*this));
  389|  71.1k|}
_ZNK3pgp3pkt6sigsub13PreferredAEAD5cloneEv:
  394|  43.8k|{
  395|  43.8k|    return RawPtr(new PreferredAEAD(*this));
  396|  43.8k|}
_ZNK3pgp3pkt6sigsub15PreferredAEADv610check_sizeEm:
  402|    607|{
  403|    607|    if (size % 2) {
  ------------------
  |  Branch (403:9): [True: 54, False: 553]
  ------------------
  404|     54|        RNP_LOG("v6 AEAD Ciphersuite Preferences must contain an even number of bytes");
  ------------------
  |  |   84|     54|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     54|    do {                                                                                 \
  |  |  |  |   77|     54|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 54, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     54|            break;                                                                       \
  |  |  |  |   79|     54|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  405|     54|        return false;
  406|     54|    }
  407|    553|    return Preferred::check_size(size);
  408|    607|}
_ZNK3pgp3pkt6sigsub15PreferredAEADv65cloneEv:
  412|  2.75k|{
  413|  2.75k|    return RawPtr(new PreferredAEADv6(*this));
  414|  2.75k|}
_ZNK3pgp3pkt6sigsub13RevocationKey10check_sizeEm:
  429|    303|{
  430|    303|    return (size == 2 + PGP_FINGERPRINT_V4_SIZE) || (size == 2 + PGP_FINGERPRINT_V5_SIZE);
  ------------------
  |  |   43|    303|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
                  return (size == 2 + PGP_FINGERPRINT_V4_SIZE) || (size == 2 + PGP_FINGERPRINT_V5_SIZE);
  ------------------
  |  |   44|    282|#define PGP_FINGERPRINT_V5_SIZE 32
  ------------------
  |  Branch (430:12): [True: 21, False: 282]
  |  Branch (430:53): [True: 20, False: 262]
  ------------------
  431|    303|}
_ZN3pgp3pkt6sigsub13RevocationKey10parse_dataEPKhm:
  435|     41|{
  436|     41|    rev_class_ = data[0];
  437|     41|    alg_ = static_cast<pgp_pubkey_alg_t>(data[1]);
  438|     41|    fp_ = pgp::Fingerprint(data + 2, size - 2);
  439|     41|    return true;
  440|     41|}
_ZNK3pgp3pkt6sigsub13RevocationKey5cloneEv:
  444|    132|{
  445|    132|    return RawPtr(new RevocationKey(*this));
  446|    132|}
_ZNK3pgp3pkt6sigsub11IssuerKeyID10check_sizeEm:
  457|  28.5k|{
  458|  28.5k|    return size == PGP_KEY_ID_SIZE;
  ------------------
  |  |   39|  28.5k|#define PGP_KEY_ID_SIZE 8
  ------------------
  459|  28.5k|}
_ZN3pgp3pkt6sigsub11IssuerKeyID10parse_dataEPKhm:
  463|  28.0k|{
  464|  28.0k|    memcpy(keyid_.data(), data, keyid_.size());
  465|  28.0k|    return true;
  466|  28.0k|}
_ZNK3pgp3pkt6sigsub11IssuerKeyID5cloneEv:
  470|   186k|{
  471|   186k|    return RawPtr(new IssuerKeyID(*this));
  472|   186k|}
_ZNK3pgp3pkt6sigsub12NotationData10check_sizeEm:
  492|    527|{
  493|    527|    return size >= 8;
  494|    527|}
_ZN3pgp3pkt6sigsub12NotationData10parse_dataEPKhm:
  498|    478|{
  499|    478|    size_t nlen = read_uint16(data + 4);
  500|    478|    size_t vlen = read_uint16(data + 6);
  501|    478|    if (size != nlen + vlen + 8) {
  ------------------
  |  Branch (501:9): [True: 296, False: 182]
  ------------------
  502|    296|        return false;
  503|    296|    }
  504|    182|    memcpy(flags_.data(), data, 4);
  505|    182|    name_.assign(data + 8, data + 8 + nlen);
  506|    182|    value_.assign(data + 8 + nlen, data + 8 + nlen + vlen);
  507|    182|    return true;
  508|    478|}
_ZNK3pgp3pkt6sigsub12NotationData5cloneEv:
  542|    939|{
  543|    939|    return RawPtr(new NotationData(*this));
  544|    939|}
_ZNK3pgp3pkt6sigsub5Flags10check_sizeEm:
  556|  42.9k|{
  557|  42.9k|    return size >= 1;
  558|  42.9k|}
_ZN3pgp3pkt6sigsub5Flags10parse_dataEPKhm:
  562|  42.8k|{
  563|  42.8k|    flags_ = data[0];
  564|  42.8k|    return true;
  565|  42.8k|}
_ZNK3pgp3pkt6sigsub14KeyserverPrefs5cloneEv:
  570|  59.8k|{
  571|  59.8k|    return RawPtr(new KeyserverPrefs(*this));
  572|  59.8k|}
_ZNK3pgp3pkt6sigsub18PreferredKeyserver5cloneEv:
  577|  8.11k|{
  578|  8.11k|    return RawPtr(new PreferredKeyserver(*this));
  579|  8.11k|}
_ZNK3pgp3pkt6sigsub13PrimaryUserID5cloneEv:
  584|  32.2k|{
  585|  32.2k|    return RawPtr(new PrimaryUserID(*this));
  586|  32.2k|}
_ZNK3pgp3pkt6sigsub9PolicyURI5cloneEv:
  591|    846|{
  592|    846|    return RawPtr(new PolicyURI(*this));
  593|    846|}
_ZNK3pgp3pkt6sigsub8KeyFlags5cloneEv:
  598|   138k|{
  599|   138k|    return RawPtr(new KeyFlags(*this));
  600|   138k|}
_ZNK3pgp3pkt6sigsub13SignersUserID5cloneEv:
  605|    756|{
  606|    756|    return RawPtr(new SignersUserID(*this));
  607|    756|}
_ZNK3pgp3pkt6sigsub16RevocationReason10check_sizeEm:
  620|  11.6k|{
  621|  11.6k|    return size >= 1;
  622|  11.6k|}
_ZN3pgp3pkt6sigsub16RevocationReason10parse_dataEPKhm:
  626|  11.6k|{
  627|  11.6k|    code_ = static_cast<pgp_revocation_type_t>(data[0]);
  628|  11.6k|    reason_.assign(data + 1, data + size);
  629|  11.6k|    return true;
  630|  11.6k|}
_ZNK3pgp3pkt6sigsub16RevocationReason5cloneEv:
  634|  52.9k|{
  635|  52.9k|    return RawPtr(new RevocationReason(*this));
  636|  52.9k|}
_ZNK3pgp3pkt6sigsub8Features5cloneEv:
  641|  59.0k|{
  642|  59.0k|    return RawPtr(new Features(*this));
  643|  59.0k|}
_ZN3pgp3pkt6sigsub17EmbeddedSignatureC2ERKS2_:
  646|    207|EmbeddedSignature::EmbeddedSignature(const EmbeddedSignature &src) : Raw(src)
  647|    207|{
  648|    207|    signature_ = std::unique_ptr<Signature>(new Signature(*src.signature_));
  649|    207|}
_ZN3pgp3pkt6sigsub17EmbeddedSignatureC2Ebb:
  652|    711|    : Raw(Type::EmbeddedSignature, hashed, critical)
  653|    711|{
  654|    711|}
_ZNK3pgp3pkt6sigsub17EmbeddedSignature10check_sizeEm:
  671|    711|{
  672|    711|    return size > 6;
  673|    711|}
_ZN3pgp3pkt6sigsub17EmbeddedSignature10parse_dataEPKhm:
  677|    607|{
  678|    607|    if (parse_depth_ >= MAX_EMBEDDED_SIGNATURE_DEPTH) {
  ------------------
  |  Branch (678:9): [True: 0, False: 607]
  ------------------
  679|      0|        RNP_LOG("embedded signature nesting is too deep: %zu", parse_depth_);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  680|      0|        return false;
  681|      0|    }
  682|    607|    pgp_packet_body_t pkt(data, size);
  683|    607|    Signature         sig;
  684|    607|    if (sig.parse(pkt, parse_depth_ + 1)) {
  ------------------
  |  Branch (684:9): [True: 581, False: 26]
  ------------------
  685|    581|        return false;
  686|    581|    }
  687|     26|    signature_ = std::unique_ptr<Signature>(new Signature(std::move(sig)));
  688|     26|    return true;
  689|    607|}
_ZNK3pgp3pkt6sigsub17EmbeddedSignature5cloneEv:
  712|    207|{
  713|    207|    return RawPtr(new EmbeddedSignature(*this));
  714|    207|}
_ZNK3pgp3pkt6sigsub17IssuerFingerprint10check_sizeEm:
  727|  31.6k|{
  728|  31.6k|    return (size >= 21) && (size <= PGP_MAX_FINGERPRINT_SIZE + 1);
  ------------------
  |  |   45|  31.6k|#define PGP_MAX_FINGERPRINT_SIZE 32
  ------------------
  |  Branch (728:12): [True: 31.6k, False: 60]
  |  Branch (728:28): [True: 31.6k, False: 6]
  ------------------
  729|  31.6k|}
_ZN3pgp3pkt6sigsub17IssuerFingerprint10parse_dataEPKhm:
  733|  31.6k|{
  734|  31.6k|    version_ = data[0];
  735|  31.6k|    fp_ = pgp::Fingerprint(data + 1, size - 1);
  736|  31.6k|    return true;
  737|  31.6k|}
_ZNK3pgp3pkt6sigsub17IssuerFingerprint5cloneEv:
  741|   172k|{
  742|   172k|    return RawPtr(new IssuerFingerprint(*this));
  743|   172k|}
_ZNK3pgp3pkt6sigsub28IntendedRecipientFingerprint10check_sizeEm:
  757|     40|{
  758|     40|    return (size >= 21) && (size <= PGP_MAX_FINGERPRINT_SIZE + 1);
  ------------------
  |  |   45|     33|#define PGP_MAX_FINGERPRINT_SIZE 32
  ------------------
  |  Branch (758:12): [True: 33, False: 7]
  |  Branch (758:28): [True: 22, False: 11]
  ------------------
  759|     40|}
_ZN3pgp3pkt6sigsub28IntendedRecipientFingerprint10parse_dataEPKhm:
  763|     22|{
  764|     22|    version_ = data[0];
  765|     22|    fp_ = pgp::Fingerprint(data + 1, size - 1);
  766|     22|    return true;
  767|     22|}
_ZNK3pgp3pkt6sigsub28IntendedRecipientFingerprint5cloneEv:
  771|    104|{
  772|    104|    return RawPtr(new IntendedRecipientFingerprint(*this));
  773|    104|}
_ZN3pgp3pkt6sigsub4ListC2ERKS2_:
  777|   286k|{
  778|   286k|    items.reserve(src.items.size());
  779|  1.24M|    for (auto &item : src.items) {
  ------------------
  |  Branch (779:21): [True: 1.24M, False: 286k]
  ------------------
  780|  1.24M|        items.push_back(item->clone());
  781|  1.24M|    }
  782|   286k|}
_ZN3pgp3pkt6sigsub4ListaSERKS2_:
  786|  1.20k|{
  787|  1.20k|    if (&src == this) {
  ------------------
  |  Branch (787:9): [True: 0, False: 1.20k]
  ------------------
  788|      0|        return *this;
  789|      0|    }
  790|  1.20k|    items.clear();
  791|  1.20k|    items.reserve(src.items.size());
  792|  4.27k|    for (auto &item : src.items) {
  ------------------
  |  Branch (792:21): [True: 4.27k, False: 1.20k]
  ------------------
  793|  4.27k|        items.push_back(item->clone());
  794|  4.27k|    }
  795|  1.20k|    return *this;
  796|  1.20k|}
sig_subpacket.cpp:_ZN3pgp3pkt6sigsubL14report_unknownEhb:
   94|  10.6k|{
   95|  10.6k|    switch (type) {
   96|    153|    case (uint8_t) Type::Private_100:
  ------------------
  |  Branch (96:5): [True: 153, False: 10.4k]
  ------------------
   97|    314|    case (uint8_t) Type::Private_101:
  ------------------
  |  Branch (97:5): [True: 161, False: 10.4k]
  ------------------
   98|    450|    case (uint8_t) Type::Private_102:
  ------------------
  |  Branch (98:5): [True: 136, False: 10.4k]
  ------------------
   99|    623|    case (uint8_t) Type::Private_103:
  ------------------
  |  Branch (99:5): [True: 173, False: 10.4k]
  ------------------
  100|    880|    case (uint8_t) Type::Private_104:
  ------------------
  |  Branch (100:5): [True: 257, False: 10.3k]
  ------------------
  101|  1.28k|    case (uint8_t) Type::Private_105:
  ------------------
  |  Branch (101:5): [True: 401, False: 10.2k]
  ------------------
  102|  1.39k|    case (uint8_t) Type::Private_106:
  ------------------
  |  Branch (102:5): [True: 118, False: 10.4k]
  ------------------
  103|  1.56k|    case (uint8_t) Type::Private_107:
  ------------------
  |  Branch (103:5): [True: 166, False: 10.4k]
  ------------------
  104|  1.74k|    case (uint8_t) Type::Private_108:
  ------------------
  |  Branch (104:5): [True: 179, False: 10.4k]
  ------------------
  105|  1.89k|    case (uint8_t) Type::Private_109:
  ------------------
  |  Branch (105:5): [True: 152, False: 10.4k]
  ------------------
  106|  2.05k|    case (uint8_t) Type::Private_110:
  ------------------
  |  Branch (106:5): [True: 154, False: 10.4k]
  ------------------
  107|  2.05k|        if (critical) {
  ------------------
  |  Branch (107:13): [True: 506, False: 1.54k]
  ------------------
  108|    506|            RNP_LOG("unknown critical private subpacket %" PRIu8, type);
  ------------------
  |  |   84|    506|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    506|    do {                                                                                 \
  |  |  |  |   77|    506|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 506, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    506|            break;                                                                       \
  |  |  |  |   79|    506|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  109|    506|        }
  110|  2.05k|        return;
  111|  1.23k|    case (uint8_t) Type::Reserved_1:
  ------------------
  |  Branch (111:5): [True: 1.23k, False: 9.37k]
  ------------------
  112|  2.20k|    case (uint8_t) Type::Reserved_8:
  ------------------
  |  Branch (112:5): [True: 977, False: 9.63k]
  ------------------
  113|  4.11k|    case (uint8_t) Type::Placeholder:
  ------------------
  |  Branch (113:5): [True: 1.90k, False: 8.70k]
  ------------------
  114|  4.23k|    case (uint8_t) Type::Reserved_13:
  ------------------
  |  Branch (114:5): [True: 122, False: 10.4k]
  ------------------
  115|  4.36k|    case (uint8_t) Type::Reserved_14:
  ------------------
  |  Branch (115:5): [True: 134, False: 10.4k]
  ------------------
  116|  4.56k|    case (uint8_t) Type::Reserved_15:
  ------------------
  |  Branch (116:5): [True: 200, False: 10.4k]
  ------------------
  117|  4.73k|    case (uint8_t) Type::Reserved_17:
  ------------------
  |  Branch (117:5): [True: 172, False: 10.4k]
  ------------------
  118|  4.85k|    case (uint8_t) Type::Reserved_18:
  ------------------
  |  Branch (118:5): [True: 118, False: 10.4k]
  ------------------
  119|  5.03k|    case (uint8_t) Type::Reserved_19:
  ------------------
  |  Branch (119:5): [True: 177, False: 10.4k]
  ------------------
  120|       |        /* do not report reserved/placeholder subpacket */
  121|  5.03k|        return;
  122|  3.52k|    default:
  ------------------
  |  Branch (122:5): [True: 3.52k, False: 7.08k]
  ------------------
  123|  3.52k|        RNP_LOG("unknown subpacket : %" PRIu8, type);
  ------------------
  |  |   84|  3.52k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  3.52k|    do {                                                                                 \
  |  |  |  |   77|  3.52k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3.52k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  3.52k|            break;                                                                       \
  |  |  |  |   79|  3.52k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  124|  10.6k|    }
  125|  10.6k|}

_ZNK3pgp3pkt6sigsub3Raw8raw_typeEv:
  130|  1.63M|    {
  131|  1.63M|        return raw_type_;
  132|  1.63M|    }
_ZNK3pgp3pkt6sigsub3Raw4dataEv:
  136|  85.1k|    {
  137|  85.1k|        return data_;
  138|  85.1k|    }
_ZNK3pgp3pkt6sigsub3Raw4typeEv:
  142|  58.7k|    {
  143|  58.7k|        return type_;
  144|  58.7k|    }
_ZNK3pgp3pkt6sigsub3Raw8criticalEv:
  148|  90.7k|    {
  149|  90.7k|        return critical_;
  150|  90.7k|    }
_ZNK3pgp3pkt6sigsub3Raw6hashedEv:
  160|   676k|    {
  161|   676k|        return hashed_;
  162|   676k|    }
_ZN3pgp3pkt6sigsub4TimeC2ENS1_4TypeEbb:
  188|  41.1k|    Time(Type type, bool hashed, bool critical) : Raw(type, hashed, critical), time_(0)
  189|  41.1k|    {
  190|  41.1k|    }
_ZNK3pgp3pkt6sigsub4Time4timeEv:
  194|  26.5k|    {
  195|  26.5k|        return time_;
  196|  26.5k|    }
_ZN3pgp3pkt6sigsub12CreationTimeC2Ebb:
  212|  33.2k|        : Time(Type::CreationTime, hashed, critical)
  213|  33.2k|    {
  214|  33.2k|    }
_ZN3pgp3pkt6sigsub14ExpirationTimeC2Ebb:
  223|  5.82k|        : Time(Type::ExpirationTime, hashed, critical)
  224|  5.82k|    {
  225|  5.82k|    }
_ZN3pgp3pkt6sigsub17KeyExpirationTimeC2Ebb:
  234|  2.02k|        : Time(Type::KeyExpirationTime, hashed, critical)
  235|  2.02k|    {
  236|  2.02k|    }
_ZN3pgp3pkt6sigsub4BoolC2ENS1_4TypeEbb:
  251|  6.68k|    Bool(Type type, bool hashed, bool critical) : Raw(type, hashed, critical), value_(false)
  252|  6.68k|    {
  253|  6.68k|    }
_ZN3pgp3pkt6sigsub14ExportableCertC2Ebb:
  262|    767|        : Bool(Type::ExportableCert, hashed, critical)
  263|    767|    {
  264|    767|        value_ = true;
  265|    767|    }
_ZN3pgp3pkt6sigsub5TrustC2Ebb:
  296|    318|        : Raw(Type::Trust, hashed, critical), level_(0), amount_(0)
  297|    318|    {
  298|    318|    }
_ZN3pgp3pkt6sigsub6StringC2ENS1_4TypeEbb:
  339|  2.03k|    String(Type type, bool hashed, bool critical) : Raw(type, hashed, critical)
  340|  2.03k|    {
  341|  2.03k|    }
_ZN3pgp3pkt6sigsub6RegExpC2Ebb:
  349|    180|    RegExp(bool hashed = true, bool critical = false) : String(Type::RegExp, hashed, critical)
  350|    180|    {
  351|    180|    }
_ZN3pgp3pkt6sigsub9RevocableC2Ebb:
  366|    482|        : Bool(Type::Revocable, hashed, critical)
  367|    482|    {
  368|    482|        value_ = true;
  369|    482|    }
_ZN3pgp3pkt6sigsub9PreferredC2ENS1_4TypeEbb:
  398|  43.0k|    Preferred(Type type, bool hashed, bool critical) : Raw(type, hashed, critical){};
_ZN3pgp3pkt6sigsub18PreferredSymmetricC2Ebb:
  420|  11.6k|        : Preferred(Type::PreferredSymmetric, hashed, critical){};
_ZN3pgp3pkt6sigsub13PreferredHashC2Ebb:
  429|  11.3k|        : Preferred(Type::PreferredHash, hashed, critical){};
_ZN3pgp3pkt6sigsub17PreferredCompressC2Ebb:
  438|  11.6k|        : Preferred(Type::PreferredCompress, hashed, critical){};
_ZN3pgp3pkt6sigsub13PreferredAEADC2Ebb:
  447|  7.74k|        : Preferred(Type::PreferredAEAD, hashed, critical){};
_ZN3pgp3pkt6sigsub15PreferredAEADv6C2Ebb:
  460|    607|        : Preferred(Type::PreferredAEADv6, hashed, critical){};
_ZN3pgp3pkt6sigsub13RevocationKeyC2Ebb:
  480|    303|        : Raw(Type::RevocationKey, hashed, critical), rev_class_(0),
  481|    303|          alg_(PGP_PKA_NOTHING), fp_{} {};
_ZN3pgp3pkt6sigsub11IssuerKeyIDC2Ebb:
  537|  28.5k|        : Raw(Type::IssuerKeyID, hashed, critical)
  538|  28.5k|    {
  539|  28.5k|    }
_ZNK3pgp3pkt6sigsub11IssuerKeyID5keyidEv:
  543|  12.8k|    {
  544|  12.8k|        return keyid_;
  545|  12.8k|    }
_ZN3pgp3pkt6sigsub12NotationDataC2Ebb:
  572|    527|        : Raw(Type::NotationData, hashed, critical)
  573|    527|    {
  574|    527|    }
_ZN3pgp3pkt6sigsub5FlagsC2ENS1_4TypeEbb:
  614|  42.9k|        : Raw(type, hashed, critical), flags_(0)
  615|  42.9k|    {
  616|  42.9k|    }
_ZN3pgp3pkt6sigsub14KeyserverPrefsC2Ebb:
  625|  9.51k|        : Flags(Type::KeyserverPrefs, hashed, critical)
  626|  9.51k|    {
  627|  9.51k|    }
_ZN3pgp3pkt6sigsub18PreferredKeyserverC2Ebb:
  662|  1.36k|        : String(Type::PreferredKeyserver, hashed, critical)
  663|  1.36k|    {
  664|  1.36k|    }
_ZN3pgp3pkt6sigsub13PrimaryUserIDC2Ebb:
  686|  5.43k|        : Bool(Type::PrimaryUserID, hashed, critical)
  687|  5.43k|    {
  688|  5.43k|    }
_ZN3pgp3pkt6sigsub9PolicyURIC2Ebb:
  710|    247|        : String(Type::PolicyURI, hashed, critical)
  711|    247|    {
  712|    247|    }
_ZN3pgp3pkt6sigsub8KeyFlagsC2Ebb:
  727|  23.8k|        : Flags(Type::KeyFlags, hashed, critical)
  728|  23.8k|    {
  729|  23.8k|    }
_ZNK3pgp3pkt6sigsub8KeyFlags5flagsEv:
  733|  6.37k|    {
  734|  6.37k|        return flags_;
  735|  6.37k|    }
_ZN3pgp3pkt6sigsub13SignersUserIDC2Ebb:
  751|    248|        : String(Type::SignersUserID, hashed, critical)
  752|    248|    {
  753|    248|    }
_ZN3pgp3pkt6sigsub16RevocationReasonC2Ebb:
  784|  11.6k|        : Raw(Type::RevocationReason, hashed, critical), code_(PGP_REVOCATION_NO_REASON)
  785|  11.6k|    {
  786|  11.6k|    }
_ZNK3pgp3pkt6sigsub16RevocationReason4codeEv:
  790|  8.50k|    {
  791|  8.50k|        return code_;
  792|  8.50k|    }
_ZNK3pgp3pkt6sigsub16RevocationReason6reasonEv:
  803|  8.50k|    {
  804|  8.50k|        return reason_;
  805|  8.50k|    }
_ZN3pgp3pkt6sigsub8FeaturesC2Ebb:
  821|  9.58k|        : Flags(Type::Features, hashed, critical)
  822|  9.58k|    {
  823|  9.58k|    }
_ZNK3pgp3pkt6sigsub8Features8featuresEv:
  827|      7|    {
  828|      7|        return flags_;
  829|      7|    }
_ZN3pgp3pkt6sigsub17IssuerFingerprintC2Ebb:
  877|  31.6k|        : Raw(Type::IssuerFingerprint, hashed, critical), version_(0), fp_{}
  878|  31.6k|    {
  879|  31.6k|    }
_ZNK3pgp3pkt6sigsub17IssuerFingerprint7versionEv:
  883|  94.6k|    {
  884|  94.6k|        return version_;
  885|  94.6k|    }
_ZNK3pgp3pkt6sigsub17IssuerFingerprint2fpEv:
  896|   190k|    {
  897|   190k|        return fp_;
  898|   190k|    }
_ZN3pgp3pkt6sigsub28IntendedRecipientFingerprintC2Ebb:
  924|     40|        : Raw(Type::IntendedRecipientFingerprint, hashed, critical), version_(0), fp_{}
  925|     40|    {
  926|     40|    }
_ZN3pgp3pkt6sigsub4ListC2Ev:
  963|   374k|    {
  964|   374k|    }
_ZN3pgp3pkt6sigsub4List5beginEv:
  970|  11.3k|    {
  971|  11.3k|        return items.begin();
  972|  11.3k|    }
_ZN3pgp3pkt6sigsub4List3endEv:
  976|  11.3k|    {
  977|  11.3k|        return items.end();
  978|  11.3k|    }
_ZNK3pgp3pkt6sigsub4List5beginEv:
  982|  28.7k|    {
  983|  28.7k|        return items.begin();
  984|  28.7k|    }
_ZNK3pgp3pkt6sigsub4List3endEv:
  988|  28.7k|    {
  989|  28.7k|        return items.end();
  990|  28.7k|    }
_ZNK3pgp3pkt6sigsub4List4sizeEv:
  994|  1.87M|    {
  995|  1.87M|        return items.size();
  996|  1.87M|    }
_ZNK3pgp3pkt6sigsub4ListixEm:
 1006|  2.30M|    {
 1007|  2.30M|        return items[idx];
 1008|  2.30M|    }

_ZN3rnp9SignatureC2ERKN3pgp3pkt9SignatureE:
   32|  40.8k|    : sig(sigpkt), sigid(sig.get_id()), raw(sigpkt)
   33|  40.8k|{
   34|  40.8k|}
_ZNK3rnp9Signature7is_certEv:
   38|  78.0k|{
   39|  78.0k|    switch (sig.type()) {
   40|     32|    case PGP_CERT_CASUAL:
  ------------------
  |  Branch (40:5): [True: 32, False: 78.0k]
  ------------------
   41|     76|    case PGP_CERT_GENERIC:
  ------------------
  |  Branch (41:5): [True: 44, False: 78.0k]
  ------------------
   42|     90|    case PGP_CERT_PERSONA:
  ------------------
  |  Branch (42:5): [True: 14, False: 78.0k]
  ------------------
   43|  14.6k|    case PGP_CERT_POSITIVE:
  ------------------
  |  Branch (43:5): [True: 14.5k, False: 63.5k]
  ------------------
   44|  14.6k|        return true;
   45|  63.4k|    default:
  ------------------
  |  Branch (45:5): [True: 63.4k, False: 14.6k]
  ------------------
   46|  63.4k|        return false;
   47|  78.0k|    }
   48|  78.0k|}
_ZNK3rnp9Signature13is_revocationEv:
   52|  12.9k|{
   53|  12.9k|    switch (sig.type()) {
   54|    231|    case PGP_SIG_REV_KEY:
  ------------------
  |  Branch (54:5): [True: 231, False: 12.6k]
  ------------------
   55|    260|    case PGP_SIG_REV_SUBKEY:
  ------------------
  |  Branch (55:5): [True: 29, False: 12.8k]
  ------------------
   56|  2.33k|    case PGP_SIG_REV_CERT:
  ------------------
  |  Branch (56:5): [True: 2.07k, False: 10.8k]
  ------------------
   57|  2.33k|        return true;
   58|  10.5k|    default:
  ------------------
  |  Branch (58:5): [True: 10.5k, False: 2.33k]
  ------------------
   59|  10.5k|        return false;
   60|  12.9k|    }
   61|  12.9k|}
_ZNK3rnp9Signature7expiredEm:
   65|  1.49k|{
   66|       |    /* sig expiration: absence of subpkt or 0 means it never expires */
   67|  1.49k|    uint64_t expiration = sig.expiration();
   68|  1.49k|    if (!expiration) {
  ------------------
  |  Branch (68:9): [True: 1.49k, False: 0]
  ------------------
   69|  1.49k|        return false;
   70|  1.49k|    }
   71|      0|    return expiration + sig.creation() < at;
   72|  1.49k|}
_ZN3rnp10RevocationC2ERNS_9SignatureE:
   83|  8.50k|Revocation::Revocation(Signature &sig) : uid(sig.uid), sigid(sig.sigid)
   84|  8.50k|{
   85|  8.50k|    if (!sig.sig.has_subpkt(PGP_SIG_SUBPKT_REVOCATION_REASON)) {
  ------------------
  |  Branch (85:9): [True: 0, False: 8.50k]
  ------------------
   86|      0|        RNP_LOG("Warning: no revocation reason in the revocation");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   87|      0|        code = PGP_REVOCATION_NO_REASON;
   88|  8.50k|    } else {
   89|  8.50k|        code = sig.sig.revocation_code();
   90|  8.50k|        reason = sig.sig.revocation_reason();
   91|  8.50k|    }
   92|  8.50k|    if (reason.empty()) {
  ------------------
  |  Branch (92:9): [True: 0, False: 8.50k]
  ------------------
   93|      0|        reason = id_str_pair::lookup(revocation_code_map, code);
   94|      0|    }
   95|  8.50k|}

_ZN3rnp11SigValidityC2Ev:
   41|   141k|    SigValidity() : validated_(false){};
_ZNK3rnp11SigValidity6errorsEv:
   45|  11.3k|    {
   46|  11.3k|        return errors_;
   47|  11.3k|    }
_ZN3rnp11SigValidity9add_errorEi:
   51|   105k|    {
   52|   105k|        errors_.push_back(err);
   53|   105k|    }
_ZNK3rnp11SigValidity5validEv:
   58|  2.15M|    {
   59|  2.15M|        return validated_ && errors_.empty();
  ------------------
  |  Branch (59:16): [True: 1.52M, False: 633k]
  |  Branch (59:30): [True: 133k, False: 1.39M]
  ------------------
   60|  2.15M|    }
_ZNK3rnp11SigValidity9validatedEv:
   64|   426k|    {
   65|   426k|        return validated_;
   66|   426k|    }
_ZN3rnp11SigValidity14mark_validatedEj:
   70|  25.4k|    {
   71|  25.4k|        if (err) {
  ------------------
  |  Branch (71:13): [True: 1.20k, False: 24.2k]
  ------------------
   72|  1.20k|            errors_.push_back(err);
   73|  1.20k|        }
   74|  25.4k|        validated_ = true;
   75|  25.4k|    }
_ZN3rnp11SigValidity5resetEb:
   79|  12.9k|    {
   80|  12.9k|        errors_.clear();
   81|  12.9k|        validated_ = mark_valid;
   82|  12.9k|    }
_ZNK3rnp11SigValidity7unknownEv:
   86|  23.1k|    {
   87|  23.1k|        return (errors_.size() == 1) && (errors_[0] == RNP_ERROR_SIG_PARSE_ERROR);
  ------------------
  |  Branch (87:16): [True: 22.1k, False: 1.00k]
  |  Branch (87:41): [True: 21.9k, False: 200]
  ------------------
   88|  23.1k|    }
_ZNK3rnp11SigValidity7expiredEv:
   92|  1.20k|    {
   93|  1.20k|        bool res = false;
   94|  1.20k|        for (auto &err : errors_) {
  ------------------
  |  Branch (94:24): [True: 1.20k, False: 0]
  ------------------
   95|       |            /* only these two cases were used as expired value */
   96|  1.20k|            if ((err != RNP_ERROR_SIG_FROM_FUTURE) && (err != RNP_ERROR_SIG_EXPIRED)) {
  ------------------
  |  Branch (96:17): [True: 1.20k, False: 0]
  |  Branch (96:55): [True: 1.20k, False: 0]
  ------------------
   97|  1.20k|                return false;
   98|  1.20k|            }
   99|      0|            res = true;
  100|      0|        }
  101|      0|        return res;
  102|  1.20k|    }
_ZNK3rnp11SigValidity9no_signerEv:
  106|  1.20k|    {
  107|  1.20k|        return (errors_.size() == 1) && (errors_[0] == RNP_ERROR_SIG_NO_SIGNER_KEY);
  ------------------
  |  Branch (107:16): [True: 200, False: 1.00k]
  |  Branch (107:41): [True: 185, False: 15]
  ------------------
  108|  1.20k|    }
_ZN3rnp10RevocationC2Ev:
  145|  1.38M|    Revocation() : uid(0), code(PGP_REVOCATION_NO_REASON), sigid(){};

_ZN3rnp13rnp_exceptionC2Ej:
  101|  2.15k|    rnp_exception(rnp_result_t code = RNP_ERROR_GENERIC) : code_(code){};
_ZNKSt3__14hashINS_5arrayIhLm20EEEEclERKS2_:
   85|  5.40M|    {
   86|       |        /* since signature id value is hash itself, we may use its low bytes */
   87|  5.40M|        size_t res = 0;
   88|  5.40M|        static_assert(std::tuple_size<pgp::SigID>::value >= sizeof(res),
   89|  5.40M|                      "pgp::SigID size mismatch");
   90|  5.40M|        std::memcpy(&res, sigid.data(), sizeof(res));
   91|  5.40M|        return res;
   92|  5.40M|    }
_ZNK3rnp13rnp_exception4codeEv:
  109|  1.03k|    {
  110|  1.03k|        return code_;
  111|  1.03k|    };
_ZN14pgp_aead_hdr_tC2Ev:
  192|  9.34k|    pgp_aead_hdr_t() : ealg(PGP_SA_UNKNOWN), aalg(PGP_AEAD_NONE)
  193|  9.34k|    {
  194|  9.34k|    }

_ZN3rnp6UserIDC2ERK16pgp_userid_pkt_t:
   33|   322k|UserID::UserID(const pgp_userid_pkt_t &uidpkt) : UserID()
   34|   322k|{
   35|       |    /* copy packet data */
   36|   322k|    pkt = uidpkt;
   37|   322k|    rawpkt = RawPacket(uidpkt);
   38|       |    /* populate uid string */
   39|   322k|    if (uidpkt.tag == PGP_PKT_USER_ID) {
  ------------------
  |  Branch (39:9): [True: 317k, False: 4.65k]
  ------------------
   40|   317k|        str.assign(uidpkt.uid.data(), uidpkt.uid.data() + uidpkt.uid.size());
   41|   317k|    } else {
   42|  4.65k|        str = "(photo)";
   43|  4.65k|    }
   44|   322k|}
_ZNK3rnp6UserID9sig_countEv:
   48|   350k|{
   49|   350k|    return sigs_.size();
   50|   350k|}
_ZNK3rnp6UserID7get_sigEm:
   54|  13.9k|{
   55|  13.9k|    return sigs_.at(idx);
   56|  13.9k|}
_ZN3rnp6UserID7add_sigERKNSt3__15arrayIhLm20EEEb:
   66|  23.0k|{
   67|  23.0k|    size_t idx = begin ? 0 : sigs_.size();
  ------------------
  |  Branch (67:18): [True: 0, False: 23.0k]
  ------------------
   68|  23.0k|    sigs_.insert(sigs_.begin() + idx, sig);
   69|  23.0k|}
_ZN3rnp6UserID7del_sigERKNSt3__15arrayIhLm20EEE:
   83|  1.00k|{
   84|  1.00k|    auto it = std::find(sigs_.begin(), sigs_.end(), id);
   85|  1.00k|    if (it == sigs_.end()) {
  ------------------
  |  Branch (85:9): [True: 0, False: 1.00k]
  ------------------
   86|      0|        return false;
   87|      0|    }
   88|  1.00k|    sigs_.erase(it);
   89|  1.00k|    return true;
   90|  1.00k|}

_ZN3rnp6UserIDC2Ev:
   49|   322k|    UserID() : valid(false), revoked(false){};

_ZN11id_str_pair6lookupEPKS_iPKc:
   32|  71.9k|{
   33|   292k|    while (pair && pair->str) {
  ------------------
  |  Branch (33:12): [True: 292k, False: 0]
  |  Branch (33:20): [True: 291k, False: 487]
  ------------------
   34|   291k|        if (pair->id == id) {
  ------------------
  |  Branch (34:13): [True: 71.4k, False: 220k]
  ------------------
   35|  71.4k|            return pair->str;
   36|  71.4k|        }
   37|   220k|        pair++;
   38|   220k|    }
   39|    487|    return notfound;
   40|  71.9k|}
_ZN11id_str_pair6lookupEPKS_PKci:
   44|  73.8k|{
   45|   353k|    while (pair && pair->str) {
  ------------------
  |  Branch (45:12): [True: 353k, False: 0]
  |  Branch (45:20): [True: 352k, False: 1.47k]
  ------------------
   46|   352k|        if (rnp::str_case_eq(str, pair->str)) {
  ------------------
  |  Branch (46:13): [True: 72.3k, False: 279k]
  ------------------
   47|  72.3k|            return pair->id;
   48|  72.3k|        }
   49|   279k|        pair++;
   50|   279k|    }
   51|  1.47k|    return notfound;
   52|  73.8k|}

_Z11read_uint16PKh:
   61|   246k|{
   62|   246k|    return ((uint16_t) buf[0] << 8) | buf[1];
   63|   246k|}
_Z11read_uint32PKh:
   68|   224k|{
   69|   224k|    return ((uint32_t) buf[0] << 24) | ((uint32_t) buf[1] << 16) | ((uint32_t) buf[2] << 8) |
   70|   224k|           (uint32_t) buf[3];
   71|   224k|}
_Z12write_uint16Pht:
   76|  71.9k|{
   77|  71.9k|    buf[0] = val >> 8;
   78|  71.9k|    buf[1] = val & 0xff;
   79|  71.9k|}
_Z12write_uint32Phj:
   84|  34.1k|{
   85|  34.1k|    buf[0] = (uint8_t)(val >> 24) & 0xff;
   86|  34.1k|    buf[1] = (uint8_t)(val >> 16) & 0xff;
   87|  34.1k|    buf[2] = (uint8_t)(val >> 8) & 0xff;
   88|  34.1k|    buf[3] = (uint8_t)(val >> 0) & 0xff;
   89|  34.1k|}
_Z12write_uint64Phm:
   93|   378k|{
   94|   378k|    buf[0] = (uint8_t)(val >> 56) & 0xff;
   95|   378k|    buf[1] = (uint8_t)(val >> 48) & 0xff;
   96|   378k|    buf[2] = (uint8_t)(val >> 40) & 0xff;
   97|   378k|    buf[3] = (uint8_t)(val >> 32) & 0xff;
   98|   378k|    buf[4] = (uint8_t)(val >> 24) & 0xff;
   99|   378k|    buf[5] = (uint8_t)(val >> 16) & 0xff;
  100|   378k|    buf[6] = (uint8_t)(val >> 8) & 0xff;
  101|   378k|    buf[7] = (uint8_t)(val >> 0) & 0xff;
  102|   378k|}

_ZN3rnp8KeyStore13add_ts_subkeyERK25pgp_transferable_subkey_tPNS_3KeyE:
   43|  10.5k|{
   44|  10.5k|    try {
   45|       |        /* create subkey */
   46|  10.5k|        Key skey(tskey, pkey);
   47|       |        /* add it to the storage */
   48|  10.5k|        return add_key(skey);
   49|  10.5k|    } catch (const std::exception &e) {
   50|       |        /* LCOV_EXCL_START */
   51|    203|        RNP_LOG("failed to create subkey: %s", e.what());
  ------------------
  |  |   84|    203|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    203|    do {                                                                                 \
  |  |  |  |   77|    203|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 203, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    203|            break;                                                                       \
  |  |  |  |   79|    203|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   52|    203|        RNP_LOG_KEY("primary key is %s", pkey);
  ------------------
  |  |   87|    203|    do {                                                                                \
  |  |   88|    203|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 44, False: 159]
  |  |  ------------------
  |  |   89|     44|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|     44|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|     44|    do {                                                                                 \
  |  |  |  |  |  |   77|     44|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 44, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|     44|            break;                                                                       \
  |  |  |  |  |  |   79|     44|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|     44|            break;                                                                      \
  |  |   91|     44|        }                                                                               \
  |  |   92|    203|        auto keyid = (key)->keyid();                                                    \
  |  |   93|    159|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|    159|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|    159|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|    159|    do {                                                                                 \
  |  |  |  |  |  |   77|    159|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 159, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|    159|            break;                                                                       \
  |  |  |  |  |  |   79|    159|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|    159|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 159]
  |  |  ------------------
  ------------------
   53|    203|        return false;
   54|       |        /* LCOV_EXCL_END */
   55|    203|    }
   56|  10.5k|}
_ZN3rnp8KeyStore10add_ts_keyER22pgp_transferable_key_t:
   60|  24.6k|{
   61|  24.6k|    Key *addkey = nullptr;
   62|       |
   63|       |    /* create key from transferable key */
   64|  24.6k|    try {
   65|  24.6k|        Key key(tkey);
   66|       |        /* temporary disable key validation */
   67|  24.6k|        disable_validation = true;
   68|       |        /* add key to the storage before subkeys */
   69|  24.6k|        addkey = add_key(key);
   70|  24.6k|    } catch (const std::exception &e) {
   71|    107|        disable_validation = false;
   72|    107|        RNP_LOG("failed to add key: %s", e.what());
  ------------------
  |  |   84|    107|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    107|    do {                                                                                 \
  |  |  |  |   77|    107|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 107, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    107|            break;                                                                       \
  |  |  |  |   79|    107|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   73|    107|        return false;
   74|    107|    }
   75|       |
   76|  24.5k|    if (!addkey) {
  ------------------
  |  Branch (76:9): [True: 0, False: 24.5k]
  ------------------
   77|      0|        disable_validation = false;
   78|      0|        RNP_LOG("Failed to add key to key store.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   79|      0|        return false;
   80|      0|    }
   81|       |
   82|       |    /* add subkeys */
   83|  24.5k|    for (auto &subkey : tkey.subkeys) {
  ------------------
  |  Branch (83:23): [True: 9.89k, False: 24.3k]
  ------------------
   84|  9.89k|        if (!add_ts_subkey(subkey, addkey)) {
  ------------------
  |  Branch (84:13): [True: 159, False: 9.73k]
  ------------------
   85|    159|            RNP_LOG("Failed to add subkey to key store.");
  ------------------
  |  |   84|    159|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    159|    do {                                                                                 \
  |  |  |  |   77|    159|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 159, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    159|            break;                                                                       \
  |  |  |  |   79|    159|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   86|    159|            disable_validation = false;
   87|       |            /* during key addition all fields are copied so will be cleaned below */
   88|    159|            remove_key(*addkey, false);
   89|    159|            return false;
   90|    159|        }
   91|  9.89k|    }
   92|       |
   93|       |    /* now validate/refresh the whole key with subkeys */
   94|  24.3k|    disable_validation = false;
   95|  24.3k|    addkey->revalidate(*this);
   96|  24.3k|    return true;
   97|  24.5k|}
_ZN3rnp8KeyStore8load_pgpER12pgp_source_tb:
  124|  12.7k|{
  125|       |    /* check whether we have transferable subkey in source */
  126|  12.7k|    if (is_subkey_pkt(stream_pkt_type(src))) {
  ------------------
  |  Branch (126:9): [True: 873, False: 11.8k]
  ------------------
  127|    873|        pgp_transferable_subkey_t tskey;
  128|    873|        rnp_result_t              ret = process_pgp_subkey(src, tskey, skiperrors);
  129|    873|        if (ret == RNP_ERROR_NOT_SUPPORTED) {
  ------------------
  |  Branch (129:13): [True: 1, False: 872]
  ------------------
  130|       |            /* subkey with unsupported algorithm: skip it */
  131|      1|            return RNP_SUCCESS;
  132|      1|        }
  133|    872|        if (ret) {
  ------------------
  |  Branch (133:13): [True: 210, False: 662]
  ------------------
  134|    210|            return ret;
  135|    210|        }
  136|    662|        return add_ts_subkey(tskey) ? RNP_SUCCESS : RNP_ERROR_BAD_STATE;
  ------------------
  |  Branch (136:16): [True: 618, False: 44]
  ------------------
  137|    872|    }
  138|       |
  139|       |    /* process armored or raw transferable key packets sequence(s) */
  140|  11.8k|    try {
  141|  11.8k|        pgp_key_sequence_t keys;
  142|  11.8k|        rnp_result_t       ret = process_pgp_keys(src, keys, skiperrors);
  143|  11.8k|        if (ret) {
  ------------------
  |  Branch (143:13): [True: 5.92k, False: 5.95k]
  ------------------
  144|  5.92k|            return ret;
  145|  5.92k|        }
  146|  24.6k|        for (auto &key : keys.keys) {
  ------------------
  |  Branch (146:24): [True: 24.6k, False: 5.68k]
  ------------------
  147|  24.6k|            if (!add_ts_key(key)) {
  ------------------
  |  Branch (147:17): [True: 266, False: 24.3k]
  ------------------
  148|    266|                return RNP_ERROR_BAD_STATE;
  149|    266|            }
  150|  24.6k|        }
  151|  5.68k|        return RNP_SUCCESS;
  152|  5.95k|    } catch (const std::exception &e) {
  153|       |        /* LCOV_EXCL_START */
  154|    706|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|    706|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    706|    do {                                                                                 \
  |  |  |  |   77|    706|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 706, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    706|            break;                                                                       \
  |  |  |  |   79|    706|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  155|    706|        return RNP_ERROR_BAD_PARAMETERS;
  156|       |        /* LCOV_EXCL_END */
  157|    706|    }
  158|  11.8k|}

_ZN3rnp8KeyStore5clearEv:
  209|  38.2k|{
  210|  38.2k|    keybyfp.clear();
  211|  38.2k|    keys.clear();
  212|  38.2k|    blobs.clear();
  213|  38.2k|}
_ZNK3rnp8KeyStore9key_countEv:
  217|  22.0k|{
  218|  22.0k|    return keys.size();
  219|  22.0k|}
_ZN3rnp8KeyStore20refresh_subkey_gripsERNS_3KeyE:
  223|  23.6k|{
  224|  23.6k|    if (key.is_subkey()) {
  ------------------
  |  Branch (224:9): [True: 0, False: 23.6k]
  ------------------
  225|      0|        RNP_LOG("wrong argument");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  226|      0|        return false;
  227|      0|    }
  228|       |
  229|   130k|    for (auto &skey : keys) {
  ------------------
  |  Branch (229:21): [True: 130k, False: 23.6k]
  ------------------
  230|   130k|        bool found = false;
  231|       |
  232|       |        /* if we have primary_grip then we also added to subkey_grips */
  233|   130k|        if (!skey.is_subkey() || skey.has_primary_fp()) {
  ------------------
  |  Branch (233:13): [True: 97.3k, False: 32.7k]
  |  Branch (233:34): [True: 32.7k, False: 0]
  ------------------
  234|   130k|            continue;
  235|   130k|        }
  236|       |
  237|      0|        for (size_t i = 0; i < skey.sig_count(); i++) {
  ------------------
  |  Branch (237:28): [True: 0, False: 0]
  ------------------
  238|      0|            auto &subsig = skey.get_sig(i);
  239|       |
  240|      0|            if (subsig.sig.type() != PGP_SIG_SUBKEY) {
  ------------------
  |  Branch (240:17): [True: 0, False: 0]
  ------------------
  241|      0|                continue;
  242|      0|            }
  243|      0|            if (subsig.sig.has_keyfp()) {
  ------------------
  |  Branch (243:17): [True: 0, False: 0]
  ------------------
  244|       |                /* Version mismatch: do not use this signature's key id. A matching
  245|       |                 * version with different fingerprint bytes still falls through, as before. */
  246|      0|                if (!subsig.sig.issuer_fp_version_matches()) {
  ------------------
  |  Branch (246:21): [True: 0, False: 0]
  ------------------
  247|      0|                    continue;
  248|      0|                }
  249|      0|                if (key.fp() == subsig.sig.keyfp()) {
  ------------------
  |  Branch (249:21): [True: 0, False: 0]
  ------------------
  250|      0|                    found = true;
  251|      0|                    break;
  252|      0|                }
  253|      0|            }
  254|      0|            if (subsig.sig.has_keyid() && (key.keyid() == subsig.sig.keyid())) {
  ------------------
  |  Branch (254:17): [True: 0, False: 0]
  |  Branch (254:17): [True: 0, False: 0]
  |  Branch (254:43): [True: 0, False: 0]
  ------------------
  255|      0|                found = true;
  256|      0|                break;
  257|      0|            }
  258|      0|        }
  259|       |
  260|      0|        if (found) {
  ------------------
  |  Branch (260:13): [True: 0, False: 0]
  ------------------
  261|      0|            try {
  262|      0|                key.link_subkey_fp(skey);
  263|      0|            } catch (const std::exception &e) {
  264|       |                /* LCOV_EXCL_START */
  265|      0|                RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  266|      0|                return false;
  267|       |                /* LCOV_EXCL_END */
  268|      0|            }
  269|      0|        }
  270|      0|    }
  271|       |
  272|  23.6k|    return true;
  273|  23.6k|}
_ZN3rnp8KeyStore10add_subkeyERNS_3KeyEPS1_:
  277|  19.9k|{
  278|  19.9k|    Key *primary = NULL;
  279|  19.9k|    if (oldkey) {
  ------------------
  |  Branch (279:9): [True: 6.05k, False: 13.9k]
  ------------------
  280|  6.05k|        primary = primary_key(*oldkey);
  281|  6.05k|    }
  282|  19.9k|    if (!primary) {
  ------------------
  |  Branch (282:9): [True: 14.4k, False: 5.50k]
  ------------------
  283|  14.4k|        primary = primary_key(srckey);
  284|  14.4k|    }
  285|       |
  286|  19.9k|    if (oldkey) {
  ------------------
  |  Branch (286:9): [True: 6.05k, False: 13.9k]
  ------------------
  287|       |        /* check for the weird case when same subkey has different primary keys */
  288|  6.05k|        if (srckey.has_primary_fp() && oldkey->has_primary_fp() &&
  ------------------
  |  Branch (288:13): [True: 5.88k, False: 173]
  |  Branch (288:40): [True: 5.80k, False: 81]
  ------------------
  289|  5.80k|            (srckey.primary_fp() != oldkey->primary_fp())) {
  ------------------
  |  Branch (289:13): [True: 940, False: 4.86k]
  ------------------
  290|    940|            RNP_LOG_KEY("Warning: different primary keys for subkey %s", &srckey);
  ------------------
  |  |   87|    940|    do {                                                                                \
  |  |   88|    940|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 940]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|    940|        auto keyid = (key)->keyid();                                                    \
  |  |   93|    940|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|    940|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|    940|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|    940|    do {                                                                                 \
  |  |  |  |  |  |   77|    940|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 940, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|    940|            break;                                                                       \
  |  |  |  |  |  |   79|    940|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|    940|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 940]
  |  |  ------------------
  ------------------
  291|    940|            auto *srcprim = get_key(srckey.primary_fp());
  292|    940|            if (srcprim && (srcprim != primary)) {
  ------------------
  |  Branch (292:17): [True: 940, False: 0]
  |  Branch (292:28): [True: 938, False: 2]
  ------------------
  293|    938|                srcprim->remove_subkey_fp(srckey.fp());
  294|    938|            }
  295|    940|        }
  296|       |        /* in case we already have key let's merge it in */
  297|  6.05k|        if (!oldkey->merge(srckey, primary)) {
  ------------------
  |  Branch (297:13): [True: 0, False: 6.05k]
  ------------------
  298|      0|            RNP_LOG_KEY("failed to merge subkey %s", &srckey);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  299|      0|            RNP_LOG_KEY("primary key is %s", primary);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  300|      0|            return NULL;
  301|      0|        }
  302|  13.9k|    } else {
  303|  13.9k|        try {
  304|  13.9k|            keys.emplace_back();
  305|  13.9k|            oldkey = &keys.back();
  306|  13.9k|            keybyfp[srckey.fp()] = std::prev(keys.end());
  307|  13.9k|            *oldkey = Key(srckey);
  308|  13.9k|            if (primary) {
  ------------------
  |  Branch (308:17): [True: 12.1k, False: 1.73k]
  ------------------
  309|  12.1k|                primary->link_subkey_fp(*oldkey);
  310|  12.1k|            }
  311|  13.9k|        } catch (const std::exception &e) {
  312|       |            /* LCOV_EXCL_START */
  313|      0|            RNP_LOG_KEY("key %s copying failed", &srckey);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  314|      0|            RNP_LOG_KEY("primary key is %s", primary);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  315|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  316|      0|            if (oldkey) {
  ------------------
  |  Branch (316:17): [True: 0, False: 0]
  ------------------
  317|      0|                keys.pop_back();
  318|      0|                keybyfp.erase(srckey.fp());
  319|      0|            }
  320|      0|            return nullptr;
  321|       |            /* LCOV_EXCL_END */
  322|      0|        }
  323|  13.9k|    }
  324|       |
  325|       |    /* validate all added keys if not disabled */
  326|  19.9k|    if (!disable_validation && !oldkey->validated()) {
  ------------------
  |  Branch (326:9): [True: 618, False: 19.3k]
  |  Branch (326:32): [True: 618, False: 0]
  ------------------
  327|    618|        oldkey->validate_subkey(primary, secctx);
  328|    618|    }
  329|  19.9k|    if (!oldkey->refresh_data(primary, secctx)) {
  ------------------
  |  Branch (329:9): [True: 0, False: 19.9k]
  ------------------
  330|      0|        RNP_LOG_KEY("Failed to refresh subkey %s data", &srckey);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  331|      0|        RNP_LOG_KEY("primary key is %s", primary);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  332|      0|    }
  333|  19.9k|    return oldkey;
  334|  19.9k|}
_ZN3rnp8KeyStore7add_keyERNS_3KeyE:
  339|  59.1k|{
  340|  59.1k|    assert(srckey.type() && srckey.version());
  341|  59.1k|    auto *added_key = get_key(srckey.fp());
  342|       |    /* we cannot merge G10 keys - so just return it */
  343|  59.1k|    if (added_key && (srckey.format == KeyFormat::G10)) {
  ------------------
  |  Branch (343:9): [True: 21.6k, False: 37.5k]
  |  Branch (343:22): [True: 0, False: 21.6k]
  ------------------
  344|      0|        return added_key;
  345|      0|    }
  346|       |    /* different processing for subkeys */
  347|  59.1k|    if (srckey.is_subkey()) {
  ------------------
  |  Branch (347:9): [True: 19.9k, False: 39.2k]
  ------------------
  348|  19.9k|        return add_subkey(srckey, added_key);
  349|  19.9k|    }
  350|       |
  351|  39.2k|    if (added_key) {
  ------------------
  |  Branch (351:9): [True: 15.5k, False: 23.6k]
  ------------------
  352|  15.5k|        if (!added_key->merge(srckey)) {
  ------------------
  |  Branch (352:13): [True: 0, False: 15.5k]
  ------------------
  353|      0|            RNP_LOG_KEY("failed to merge key %s", &srckey);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  354|      0|            return NULL;
  355|      0|        }
  356|  23.6k|    } else {
  357|  23.6k|        try {
  358|  23.6k|            keys.emplace_back();
  359|  23.6k|            added_key = &keys.back();
  360|  23.6k|            keybyfp[srckey.fp()] = std::prev(keys.end());
  361|  23.6k|            *added_key = Key(srckey);
  362|       |            /* primary key may be added after subkeys, so let's handle this case correctly */
  363|  23.6k|            if (!refresh_subkey_grips(*added_key)) {
  ------------------
  |  Branch (363:17): [True: 0, False: 23.6k]
  ------------------
  364|      0|                RNP_LOG_KEY("failed to refresh subkey grips for %s", added_key);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  365|      0|            }
  366|  23.6k|        } catch (const std::exception &e) {
  367|       |            /* LCOV_EXCL_START */
  368|      0|            RNP_LOG_KEY("key %s copying failed", &srckey);
  ------------------
  |  |   87|      0|    do {                                                                                \
  |  |   88|      0|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|      0|        auto keyid = (key)->keyid();                                                    \
  |  |   93|      0|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|      0|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 0]
  |  |  ------------------
  ------------------
  369|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  370|      0|            if (added_key) {
  ------------------
  |  Branch (370:17): [True: 0, False: 0]
  ------------------
  371|      0|                keys.pop_back();
  372|      0|                keybyfp.erase(srckey.fp());
  373|      0|            }
  374|      0|            return NULL;
  375|       |            /* LCOV_EXCL_END */
  376|      0|        }
  377|  23.6k|    }
  378|       |
  379|       |    /* validate all added keys if not disabled or already validated */
  380|  39.2k|    if (!disable_validation && !added_key->validated()) {
  ------------------
  |  Branch (380:9): [True: 0, False: 39.2k]
  |  Branch (380:32): [True: 0, False: 0]
  ------------------
  381|      0|        added_key->revalidate(*this);
  382|  39.2k|    } else if (!added_key->refresh_data(secctx)) {
  ------------------
  |  Branch (382:16): [True: 414, False: 38.8k]
  ------------------
  383|    414|        RNP_LOG_KEY("Failed to refresh key %s data", &srckey);
  ------------------
  |  |   87|    414|    do {                                                                                \
  |  |   88|    414|        if (!(key)) {                                                                   \
  |  |  ------------------
  |  |  |  Branch (88:13): [True: 0, False: 414]
  |  |  ------------------
  |  |   89|      0|            RNP_LOG(msg, "(null)");                                                     \
  |  |  ------------------
  |  |  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   90|      0|            break;                                                                      \
  |  |   91|      0|        }                                                                               \
  |  |   92|    414|        auto keyid = (key)->keyid();                                                    \
  |  |   93|    414|        auto idhex = bin_to_hex(keyid.data(), keyid.size(), rnp::HexFormat::Lowercase); \
  |  |   94|    414|        RNP_LOG(msg, idhex.c_str());                                                    \
  |  |  ------------------
  |  |  |  |   84|    414|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   76|    414|    do {                                                                                 \
  |  |  |  |  |  |   77|    414|        if (!rnp_log_switch())                                                           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (77:13): [True: 414, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   78|    414|            break;                                                                       \
  |  |  |  |  |  |   79|    414|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   95|    414|    } while (0)
  |  |  ------------------
  |  |  |  Branch (95:14): [Folded, False: 414]
  |  |  ------------------
  ------------------
  384|    414|    }
  385|       |    /* Revalidate non-self revocations for all keys in keyring, as added_key key could be a
  386|       |     * revoker. Should not be time-consuming as `validate_desig_revokes()` has early exit. */
  387|   215k|    for (auto &key : keys) {
  ------------------
  |  Branch (387:20): [True: 215k, False: 39.2k]
  ------------------
  388|   215k|        if (&key == added_key) {
  ------------------
  |  Branch (388:13): [True: 39.2k, False: 176k]
  ------------------
  389|  39.2k|            continue;
  390|  39.2k|        }
  391|   176k|        if (key.validate_desig_revokes(*this)) {
  ------------------
  |  Branch (391:13): [True: 0, False: 176k]
  ------------------
  392|      0|            key.revalidate(*this);
  393|      0|        }
  394|   176k|    }
  395|  39.2k|    return added_key;
  396|  39.2k|}
_ZN3rnp8KeyStore10import_keyERNS_3KeyEbP23pgp_key_import_status_t:
  444|  24.2k|{
  445|       |    /* add public key */
  446|  24.2k|    auto * exkey = get_key(srckey.fp());
  447|  24.2k|    size_t expackets = exkey ? exkey->rawpkt_count() : 0;
  ------------------
  |  Branch (447:24): [True: 3.88k, False: 20.3k]
  ------------------
  448|  24.2k|    try {
  449|  24.2k|        Key keycp(srckey, pubkey);
  450|  24.2k|        disable_validation = true;
  451|  24.2k|        exkey = add_key(keycp);
  452|  24.2k|        disable_validation = false;
  453|  24.2k|        if (!exkey) {
  ------------------
  |  Branch (453:13): [True: 0, False: 24.2k]
  ------------------
  454|      0|            RNP_LOG("failed to add key to the keyring");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  455|      0|            return nullptr;
  456|      0|        }
  457|  24.2k|        bool changed = exkey->rawpkt_count() > expackets;
  458|  24.2k|        if (changed || !exkey->validated()) {
  ------------------
  |  Branch (458:13): [True: 20.3k, False: 3.88k]
  |  Branch (458:24): [True: 3.88k, False: 0]
  ------------------
  459|       |            /* this will revalidate primary key with all of its subkeys */
  460|  24.2k|            exkey->revalidate(*this);
  461|  24.2k|        }
  462|  24.2k|        if (status) {
  ------------------
  |  Branch (462:13): [True: 20.3k, False: 3.88k]
  ------------------
  463|  20.3k|            *status = changed ? (expackets ? PGP_KEY_IMPORT_STATUS_UPDATED :
  ------------------
  |  Branch (463:23): [True: 20.3k, False: 0]
  |  Branch (463:34): [True: 0, False: 20.3k]
  ------------------
  464|  20.3k|                                             PGP_KEY_IMPORT_STATUS_NEW) :
  465|  20.3k|                                PGP_KEY_IMPORT_STATUS_UNCHANGED;
  466|  20.3k|        }
  467|  24.2k|        return exkey;
  468|  24.2k|    } catch (const std::exception &e) {
  469|       |        /* LCOV_EXCL_START */
  470|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  471|      0|        disable_validation = false;
  472|      0|        return nullptr;
  473|       |        /* LCOV_EXCL_END */
  474|      0|    }
  475|  24.2k|}
_ZN3rnp8KeyStore10remove_keyERKNS_3KeyEb:
  577|    159|{
  578|    159|    auto it = keybyfp.find(key.fp());
  579|    159|    if (it == keybyfp.end()) {
  ------------------
  |  Branch (579:9): [True: 0, False: 159]
  ------------------
  580|      0|        return false;
  581|      0|    }
  582|       |
  583|       |    /* cleanup primary_grip (or subkey)/subkey_grips */
  584|    159|    if (key.is_primary() && key.subkey_count()) {
  ------------------
  |  Branch (584:9): [True: 133, False: 26]
  |  Branch (584:29): [True: 91, False: 42]
  ------------------
  585|    335|        for (size_t i = 0; i < key.subkey_count(); i++) {
  ------------------
  |  Branch (585:28): [True: 244, False: 91]
  ------------------
  586|    244|            auto its = keybyfp.find(key.get_subkey_fp(i));
  587|    244|            if (its == keybyfp.end()) {
  ------------------
  |  Branch (587:17): [True: 0, False: 244]
  ------------------
  588|      0|                continue;
  589|      0|            }
  590|       |            /* if subkeys are deleted then no need to update grips */
  591|    244|            if (subkeys) {
  ------------------
  |  Branch (591:17): [True: 0, False: 244]
  ------------------
  592|      0|                keys.erase(its->second);
  593|      0|                keybyfp.erase(its);
  594|      0|                continue;
  595|      0|            }
  596|    244|            its->second->unset_primary_fp();
  597|    244|        }
  598|     91|    }
  599|    159|    if (key.is_subkey() && key.has_primary_fp()) {
  ------------------
  |  Branch (599:9): [True: 26, False: 133]
  |  Branch (599:28): [True: 21, False: 5]
  ------------------
  600|     21|        auto *primary = primary_key(key);
  601|     21|        if (primary) {
  ------------------
  |  Branch (601:13): [True: 20, False: 1]
  ------------------
  602|     20|            primary->remove_subkey_fp(key.fp());
  603|     20|        }
  604|     21|    }
  605|       |
  606|    159|    keys.erase(it->second);
  607|    159|    keybyfp.erase(it);
  608|    159|    return true;
  609|    159|}
_ZN3rnp8KeyStore7get_keyERKN3pgp11FingerprintE:
  623|   339k|{
  624|   339k|    auto it = keybyfp.find(fpr);
  625|   339k|    if (it == keybyfp.end()) {
  ------------------
  |  Branch (625:9): [True: 158k, False: 181k]
  ------------------
  626|   158k|        return nullptr;
  627|   158k|    }
  628|   181k|    return &*it->second;
  629|   339k|}
_ZN3rnp8KeyStore10get_subkeyERKNS_3KeyEm:
  633|  89.0k|{
  634|  89.0k|    if (idx >= key.subkey_count()) {
  ------------------
  |  Branch (634:9): [True: 0, False: 89.0k]
  ------------------
  635|      0|        return nullptr;
  636|      0|    }
  637|  89.0k|    return get_key(key.get_subkey_fp(idx));
  638|  89.0k|}
_ZN3rnp8KeyStore11primary_keyERKNS_3KeyE:
  642|  30.4k|{
  643|  30.4k|    if (!subkey.is_subkey()) {
  ------------------
  |  Branch (643:9): [True: 81, False: 30.3k]
  ------------------
  644|     81|        return nullptr;
  645|     81|    }
  646|       |
  647|  30.3k|    if (subkey.has_primary_fp()) {
  ------------------
  |  Branch (647:9): [True: 27.6k, False: 2.71k]
  ------------------
  648|  27.6k|        Key *primary = get_key(subkey.primary_fp());
  649|  27.6k|        return primary && primary->is_primary() ? primary : nullptr;
  ------------------
  |  Branch (649:16): [True: 26.1k, False: 1.52k]
  |  Branch (649:27): [True: 26.1k, False: 30]
  ------------------
  650|  27.6k|    }
  651|       |
  652|  14.4k|    for (size_t i = 0; i < subkey.sig_count(); i++) {
  ------------------
  |  Branch (652:24): [True: 11.7k, False: 2.71k]
  ------------------
  653|  11.7k|        auto &subsig = subkey.get_sig(i);
  654|  11.7k|        if (subsig.sig.type() != PGP_SIG_SUBKEY) {
  ------------------
  |  Branch (654:13): [True: 5.31k, False: 6.46k]
  ------------------
  655|  5.31k|            continue;
  656|  5.31k|        }
  657|       |
  658|  6.46k|        Key *primary = get_signer(subsig.sig);
  659|  6.46k|        if (!primary || !primary->is_primary()) {
  ------------------
  |  Branch (659:13): [True: 6.23k, False: 225]
  |  Branch (659:25): [True: 225, False: 0]
  ------------------
  660|  6.46k|            continue;
  661|  6.46k|        }
  662|       |        /* Fingerprint lookup ignores the version octet. Do not bind a subkey to a
  663|       |         * primary whose issuer fingerprint version does not match the signature. */
  664|      0|        if (subsig.sig.has_keyfp() && !subsig.sig.issuer_fp_version_matches()) {
  ------------------
  |  Branch (664:13): [True: 0, False: 0]
  |  Branch (664:39): [True: 0, False: 0]
  ------------------
  665|      0|            continue;
  666|      0|        }
  667|      0|        return primary;
  668|      0|    }
  669|  2.71k|    return nullptr;
  670|  2.71k|}
_ZN3rnp8KeyStore6searchERKNS_9KeySearchEPNS_3KeyE:
  674|  23.7k|{
  675|       |    // since keys are distinguished by fingerprint then just do map lookup
  676|  23.7k|    if (search.type() == KeySearch::Type::Fingerprint) {
  ------------------
  |  Branch (676:9): [True: 17.5k, False: 6.23k]
  ------------------
  677|  17.5k|        auto fpsearch = dynamic_cast<const KeyFingerprintSearch *>(&search);
  678|  17.5k|        assert(fpsearch != nullptr);
  679|  17.5k|        auto key = get_key(fpsearch->get_fp());
  680|  17.5k|        if (after && (after != key)) {
  ------------------
  |  Branch (680:13): [True: 0, False: 17.5k]
  |  Branch (680:22): [True: 0, False: 0]
  ------------------
  681|      0|            RNP_LOG("searching with invalid after param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  682|      0|            return nullptr;
  683|      0|        }
  684|       |        // return NULL if after is specified
  685|  17.5k|        return after ? nullptr : key;
  ------------------
  |  Branch (685:16): [True: 0, False: 17.5k]
  ------------------
  686|  17.5k|    }
  687|       |
  688|       |    // if after is provided, make sure it is a member of the appropriate list
  689|  6.23k|    auto it = std::find_if(
  690|  6.23k|      keys.begin(), keys.end(), [after](const Key &key) { return !after || (after == &key); });
  691|  6.23k|    if (after && (it == keys.end())) {
  ------------------
  |  Branch (691:9): [True: 0, False: 6.23k]
  |  Branch (691:9): [True: 0, False: 6.23k]
  |  Branch (691:18): [True: 0, False: 0]
  ------------------
  692|      0|        RNP_LOG("searching with non-keyrings after param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  693|      0|        return nullptr;
  694|      0|    }
  695|  6.23k|    if (after) {
  ------------------
  |  Branch (695:9): [True: 0, False: 6.23k]
  ------------------
  696|      0|        it = std::next(it);
  697|      0|    }
  698|  6.23k|    it =
  699|  6.23k|      std::find_if(it, keys.end(), [&search](const Key &key) { return search.matches(key); });
  700|  6.23k|    return (it == keys.end()) ? nullptr : &(*it);
  ------------------
  |  Branch (700:12): [True: 6.00k, False: 225]
  ------------------
  701|  6.23k|}
_ZN3rnp8KeyStore10get_signerERKN3pgp3pkt9SignatureEPKNS_11KeyProviderE:
  705|  6.46k|{
  706|       |    /* if we have fingerprint let's check it */
  707|  6.46k|    std::unique_ptr<KeySearch> ks;
  708|  6.46k|    if (sig.has_keyfp()) {
  ------------------
  |  Branch (708:9): [True: 275, False: 6.18k]
  ------------------
  709|    275|        ks = KeySearch::create(sig.keyfp());
  710|  6.18k|    } else if (sig.has_keyid()) {
  ------------------
  |  Branch (710:16): [True: 5.85k, False: 337]
  ------------------
  711|  5.85k|        ks = KeySearch::create(sig.keyid());
  712|  5.85k|    } else {
  713|    337|        RNP_LOG("No way to search for the signer.");
  ------------------
  |  |   84|    337|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    337|    do {                                                                                 \
  |  |  |  |   77|    337|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 337, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    337|            break;                                                                       \
  |  |  |  |   79|    337|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  714|    337|        return nullptr;
  715|    337|    }
  716|       |
  717|  6.12k|    auto key = search(*ks);
  718|  6.12k|    if (key || !prov) {
  ------------------
  |  Branch (718:9): [True: 225, False: 5.90k]
  |  Branch (718:16): [True: 5.90k, False: 0]
  ------------------
  719|  6.12k|        return key;
  720|  6.12k|    }
  721|      0|    return prov->request_key(*ks, PGP_OP_VERIFY);
  722|  6.12k|}
_ZN3rnp8KeyStoreC2ERKNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEERNS_15SecurityContextENS_9KeyFormatE:
  725|  38.2k|    : secctx(ctx)
  726|  38.2k|{
  727|  38.2k|    if (_format == KeyFormat::Unknown) {
  ------------------
  |  Branch (727:9): [True: 0, False: 38.2k]
  ------------------
  728|      0|        RNP_LOG("Invalid key store format");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  729|      0|        throw std::invalid_argument("format");
  730|      0|    }
  731|  38.2k|    format = _format;
  732|  38.2k|    path = _path;
  733|  38.2k|}
_ZN3rnp8KeyStoreD2Ev:
  736|  38.2k|{
  737|  38.2k|    clear();
  738|  38.2k|}
rnp_key_store.cpp:_ZZN3rnp8KeyStore6searchERKNS_9KeySearchEPNS_3KeyEENK3$_0clERKS4_:
  690|  2.78k|      keys.begin(), keys.end(), [after](const Key &key) { return !after || (after == &key); });
  ------------------
  |  Branch (690:66): [True: 2.78k, False: 0]
  |  Branch (690:76): [True: 0, False: 0]
  ------------------
rnp_key_store.cpp:_ZZN3rnp8KeyStore6searchERKNS_9KeySearchEPNS_3KeyEENK3$_1clERKS4_:
  699|  2.79k|      std::find_if(it, keys.end(), [&search](const Key &key) { return search.matches(key); });

_Z16init_armored_srcP12pgp_source_tS0_b:
  939|  11.3k|{
  940|  11.3k|    if (!init_src_common(src, 0)) {
  ------------------
  |  Branch (940:9): [True: 0, False: 11.3k]
  ------------------
  941|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  942|      0|    }
  943|  11.3k|    pgp_source_armored_param_t *param = new (std::nothrow) pgp_source_armored_param_t();
  944|  11.3k|    if (!param) {
  ------------------
  |  Branch (944:9): [True: 0, False: 11.3k]
  ------------------
  945|      0|        RNP_LOG("allocation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  946|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  947|      0|    }
  948|       |
  949|  11.3k|    param->readsrc = readsrc;
  950|  11.3k|    param->noheaders = noheaders;
  951|  11.3k|    src->param = param;
  952|  11.3k|    src->raw_read = armored_src_read;
  953|  11.3k|    src->raw_close = armored_src_close;
  954|  11.3k|    src->type = PGP_STREAM_ARMORED;
  955|       |
  956|       |    /* base64 data only */
  957|  11.3k|    if (noheaders) {
  ------------------
  |  Branch (957:9): [True: 0, False: 11.3k]
  ------------------
  958|      0|        return RNP_SUCCESS;
  959|      0|    }
  960|       |
  961|       |    /* initialize crc context */
  962|  11.3k|    param->crc_ctx = rnp::CRC24::create();
  963|       |    /* parsing armored header */
  964|  11.3k|    rnp_result_t errcode = RNP_ERROR_GENERIC;
  965|  11.3k|    if (!armor_parse_header(param)) {
  ------------------
  |  Branch (965:9): [True: 415, False: 10.9k]
  ------------------
  966|    415|        errcode = RNP_ERROR_BAD_FORMAT;
  967|    415|        goto finish;
  968|    415|    }
  969|       |    /* eol */
  970|  10.9k|    if (!param->readsrc->skip_eol()) {
  ------------------
  |  Branch (970:9): [True: 1.02k, False: 9.92k]
  ------------------
  971|  1.02k|        RNP_LOG("no eol after the armor header");
  ------------------
  |  |   84|  1.02k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.02k|    do {                                                                                 \
  |  |  |  |   77|  1.02k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.02k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.02k|            break;                                                                       \
  |  |  |  |   79|  1.02k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  972|  1.02k|        errcode = RNP_ERROR_BAD_FORMAT;
  973|  1.02k|        goto finish;
  974|  1.02k|    }
  975|       |    /* parsing headers */
  976|  9.92k|    if (!armor_parse_headers(param)) {
  ------------------
  |  Branch (976:9): [True: 305, False: 9.62k]
  ------------------
  977|    305|        RNP_LOG("failed to parse headers");
  ------------------
  |  |   84|    305|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    305|    do {                                                                                 \
  |  |  |  |   77|    305|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 305, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    305|            break;                                                                       \
  |  |  |  |   79|    305|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  978|    305|        errcode = RNP_ERROR_BAD_FORMAT;
  979|    305|        goto finish;
  980|    305|    }
  981|       |
  982|       |    /* now we are good to go with base64-encoded data */
  983|  9.62k|    errcode = RNP_SUCCESS;
  984|  11.3k|finish:
  985|  11.3k|    if (errcode) {
  ------------------
  |  Branch (985:9): [True: 1.74k, False: 9.62k]
  ------------------
  986|  1.74k|        src->close();
  987|  1.74k|    }
  988|  11.3k|    return errcode;
  989|  9.62k|}
_Z16init_armored_dstP10pgp_dest_tS0_17pgp_armored_msg_t:
 1230|  5.02k|{
 1231|  5.02k|    try {
 1232|  5.02k|        *dst = pgp_dest_t();
 1233|  5.02k|    } catch (const std::exception &e) {
 1234|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1235|      0|    }
 1236|  5.02k|    pgp_dest_armored_param_t *param = new (std::nothrow) pgp_dest_armored_param_t();
 1237|  5.02k|    if (!param) {
  ------------------
  |  Branch (1237:9): [True: 0, False: 5.02k]
  ------------------
 1238|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1239|      0|    }
 1240|       |
 1241|  5.02k|    dst->param = param;
 1242|  5.02k|    dst->write = armored_dst_write;
 1243|  5.02k|    dst->finish = armored_dst_finish;
 1244|  5.02k|    dst->close = armored_dst_close;
 1245|  5.02k|    dst->type = PGP_STREAM_ARMORED;
 1246|  5.02k|    dst->writeb = 0;
 1247|  5.02k|    dst->clen = 0;
 1248|       |
 1249|  5.02k|    param->writedst = writedst;
 1250|  5.02k|    param->type = msgtype;
 1251|       |    /* Base64 message */
 1252|  5.02k|    if (msgtype == PGP_ARMORED_BASE64) {
  ------------------
  |  Branch (1252:9): [True: 0, False: 5.02k]
  ------------------
 1253|       |        /* Base64 encoding will not output EOLs but we need this to not duplicate code for a
 1254|       |         * separate base64_dst_write function */
 1255|      0|        param->eol[0] = 0;
 1256|      0|        param->eol[1] = 0;
 1257|      0|        param->llen = 256;
 1258|      0|        return RNP_SUCCESS;
 1259|      0|    }
 1260|       |    /* create crc context */
 1261|  5.02k|    param->crc_ctx = rnp::CRC24::create();
 1262|  5.02k|    param->eol[0] = CH_CR;
  ------------------
  |  |   31|  5.02k|#define CH_CR ('\r')
  ------------------
 1263|  5.02k|    param->eol[1] = CH_LF;
  ------------------
  |  |   32|  5.02k|#define CH_LF ('\n')
  ------------------
 1264|  5.02k|    param->llen = 76; /* must be multiple of 4 */
 1265|       |    /* armor header */
 1266|  5.02k|    armor_write_message_header(param, false);
 1267|  5.02k|    armor_write_eol(param);
 1268|       |    /* empty line */
 1269|  5.02k|    armor_write_eol(param);
 1270|  5.02k|    return RNP_SUCCESS;
 1271|  5.02k|}
_ZN12pgp_source_t10is_armoredEv:
 1293|  66.3k|{
 1294|  66.3k|    char   buf[ARMORED_PEEK_BUF_SIZE] = {0};
 1295|  66.3k|    size_t read = 0;
 1296|       |
 1297|  66.3k|    if (!peek(buf, sizeof(buf) - 1, &read) || (read < strlen(ST_ARMOR_BEGIN) + 1)) {
  ------------------
  |  |   46|  66.3k|#define ST_ARMOR_BEGIN ("-----BEGIN PGP ")
  ------------------
  |  Branch (1297:9): [True: 0, False: 66.3k]
  |  Branch (1297:47): [True: 913, False: 65.4k]
  ------------------
 1298|    913|        return false;
 1299|    913|    }
 1300|  65.4k|    buf[read] = 0;
 1301|  65.4k|    if (!!strstr(buf, ST_CLEAR_BEGIN)) {
  ------------------
  |  |   48|  65.4k|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
  |  Branch (1301:9): [True: 543, False: 64.8k]
  ------------------
 1302|    543|        return false;
 1303|    543|    }
 1304|  64.8k|    return !!strstr(buf, ST_ARMOR_BEGIN);
  ------------------
  |  |   46|  64.8k|#define ST_ARMOR_BEGIN ("-----BEGIN PGP ")
  ------------------
 1305|  65.4k|}
_ZN12pgp_source_t12is_cleartextEv:
 1309|  8.73k|{
 1310|  8.73k|    char   buf[ARMORED_PEEK_BUF_SIZE] = {0};
 1311|  8.73k|    size_t read = 0;
 1312|       |
 1313|  8.73k|    if (!peek(buf, sizeof(buf) - 1, &read) || (read < strlen(ST_CLEAR_BEGIN))) {
  ------------------
  |  |   48|  8.73k|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
  |  Branch (1313:9): [True: 0, False: 8.73k]
  |  Branch (1313:47): [True: 2.48k, False: 6.24k]
  ------------------
 1314|  2.48k|        return false;
 1315|  2.48k|    }
 1316|  6.24k|    buf[read] = 0;
 1317|  6.24k|    return !!strstr(buf, ST_CLEAR_BEGIN);
  ------------------
  |  |   48|  6.24k|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
 1318|  8.73k|}
_ZN3rnp13ArmoredSourceC2ER12pgp_source_tj:
 1378|  62.7k|    : Source(), readsrc_(readsrc), multiple_(false)
 1379|  62.7k|{
 1380|       |    /* Do not dearmor already armored stream */
 1381|  62.7k|    bool already = readsrc_.type == PGP_STREAM_ARMORED;
 1382|       |    /* Check for base64 source: no multiple streams allowed */
 1383|  62.7k|    if (!already && (flags & AllowBase64) && (readsrc.is_base64())) {
  ------------------
  |  Branch (1383:9): [True: 61.3k, False: 1.45k]
  |  Branch (1383:21): [True: 0, False: 61.3k]
  |  Branch (1383:46): [True: 0, False: 0]
  ------------------
 1384|      0|        auto res = init_armored_src(&src_, &readsrc_, true);
 1385|      0|        if (res) {
  ------------------
  |  Branch (1385:13): [True: 0, False: 0]
  ------------------
 1386|      0|            RNP_LOG("Failed to parse base64 data.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1387|      0|            throw rnp::rnp_exception(res);
 1388|      0|        }
 1389|      0|        armored_ = true;
 1390|      0|        return;
 1391|      0|    }
 1392|       |    /* Check for armored source */
 1393|  62.7k|    if (!already && readsrc.is_armored()) {
  ------------------
  |  Branch (1393:9): [True: 61.3k, False: 1.45k]
  |  Branch (1393:21): [True: 3.18k, False: 58.1k]
  ------------------
 1394|  3.18k|        auto res = init_armored_src(&src_, &readsrc_);
 1395|  3.18k|        if (res) {
  ------------------
  |  Branch (1395:13): [True: 1.69k, False: 1.48k]
  ------------------
 1396|  1.69k|            RNP_LOG("Failed to parse armored data.");
  ------------------
  |  |   84|  1.69k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.69k|    do {                                                                                 \
  |  |  |  |   77|  1.69k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.69k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.69k|            break;                                                                       \
  |  |  |  |   79|  1.69k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1397|  1.69k|            throw rnp::rnp_exception(res);
 1398|  1.69k|        }
 1399|  1.48k|        armored_ = true;
 1400|  1.48k|        multiple_ = flags & AllowMultiple;
 1401|  1.48k|        return;
 1402|  3.18k|    }
 1403|       |    /* Use binary source if allowed */
 1404|  59.5k|    if (!(flags & AllowBinary)) {
  ------------------
  |  Branch (1404:9): [True: 0, False: 59.5k]
  ------------------
 1405|      0|        RNP_LOG("Non-armored data is not allowed here.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1406|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1407|      0|    }
 1408|  59.5k|    armored_ = false;
 1409|  59.5k|}
_ZN3rnp13ArmoredSource7restartEv:
 1413|  3.17k|{
 1414|  3.17k|    if (!armored_ || readsrc_.eof() || readsrc_.error()) {
  ------------------
  |  Branch (1414:9): [True: 0, False: 3.17k]
  |  Branch (1414:22): [True: 15, False: 3.15k]
  |  Branch (1414:40): [True: 0, False: 3.15k]
  ------------------
 1415|     15|        return;
 1416|     15|    }
 1417|  3.15k|    src_.close();
 1418|  3.15k|    auto res = init_armored_src(&src_, &readsrc_);
 1419|  3.15k|    if (res) {
  ------------------
  |  Branch (1419:9): [True: 47, False: 3.10k]
  ------------------
 1420|     47|        throw rnp::rnp_exception(res);
 1421|     47|    }
 1422|  3.15k|}
_ZN3rnp13ArmoredSource3srcEv:
 1426|  2.02M|{
 1427|  2.02M|    return armored_ ? src_ : readsrc_;
  ------------------
  |  Branch (1427:12): [True: 22.6k, False: 2.00M]
  ------------------
 1428|  2.02M|}
stream-armor.cpp:_ZL22armor_str_to_data_typeRKNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE:
  715|  11.1k|{
  716|  11.1k|    if ((str == "MESSAGE") || (str == "ARMORED FILE")) {
  ------------------
  |  Branch (716:9): [True: 5.20k, False: 5.93k]
  |  Branch (716:31): [True: 4, False: 5.92k]
  ------------------
  717|  5.21k|        return PGP_ARMORED_MESSAGE;
  718|  5.21k|    }
  719|  5.92k|    if ((str == "PUBLIC KEY BLOCK") || (str == "PUBLIC KEY")) {
  ------------------
  |  Branch (719:9): [True: 1.49k, False: 4.43k]
  |  Branch (719:40): [True: 1, False: 4.43k]
  ------------------
  720|  1.49k|        return PGP_ARMORED_PUBLIC_KEY;
  721|  1.49k|    }
  722|  4.43k|    if ((str == "SECRET KEY BLOCK") || (str == "SECRET KEY") || (str == "PRIVATE KEY BLOCK") ||
  ------------------
  |  Branch (722:9): [True: 1, False: 4.42k]
  |  Branch (722:40): [True: 2, False: 4.42k]
  |  Branch (722:65): [True: 48, False: 4.37k]
  ------------------
  723|  4.37k|        (str == "PRIVATE KEY")) {
  ------------------
  |  Branch (723:9): [True: 23, False: 4.35k]
  ------------------
  724|     74|        return PGP_ARMORED_SECRET_KEY;
  725|     74|    }
  726|  4.35k|    if (str == "SIGNATURE") {
  ------------------
  |  Branch (726:9): [True: 4.17k, False: 186]
  ------------------
  727|  4.17k|        return PGP_ARMORED_SIGNATURE;
  728|  4.17k|    }
  729|    186|    return PGP_ARMORED_UNKNOWN;
  730|  4.35k|}
stream-armor.cpp:_ZL17peek_armor_headerR12pgp_source_tPmb:
  797|  11.3k|{
  798|  11.3k|    std::string hdr(ARMORED_PEEK_BUF_SIZE, '\0');
  ------------------
  |  |   46|  11.3k|#define ARMORED_PEEK_BUF_SIZE 1024
  ------------------
  799|  11.3k|    size_t      read = 0;
  800|  11.3k|    if (skip) {
  ------------------
  |  Branch (800:9): [True: 11.3k, False: 0]
  ------------------
  801|  11.3k|        *skip = 0;
  802|  11.3k|    }
  803|  11.3k|    if (!src.peek(&hdr.front(), hdr.size(), &read) || (read < 20)) {
  ------------------
  |  Branch (803:9): [True: 0, False: 11.3k]
  |  Branch (803:55): [True: 10, False: 11.3k]
  ------------------
  804|     10|        return "";
  805|     10|    }
  806|  11.3k|    hdr.resize(read);
  807|       |
  808|  11.3k|    std::string type;
  809|  11.3k|    size_t      armhdrlen = 0;
  810|  11.3k|    size_t      pos = find_armor_header(hdr, armhdrlen, type);
  811|  11.3k|    if (pos == std::string::npos) {
  ------------------
  |  Branch (811:9): [True: 213, False: 11.1k]
  ------------------
  812|    213|        return "";
  813|    213|    }
  814|       |
  815|       |    /* if there are non-whitespaces before the armor header then issue warning */
  816|  15.0k|    for (size_t idx = 0; check && (idx < pos); idx++) {
  ------------------
  |  Branch (816:26): [True: 15.0k, False: 0]
  |  Branch (816:35): [True: 9.23k, False: 5.79k]
  ------------------
  817|  9.23k|        if (B64DEC[(uint8_t) hdr[idx]] != 0xfd) {
  ------------------
  |  Branch (817:13): [True: 5.34k, False: 3.88k]
  ------------------
  818|  5.34k|            RNP_LOG("extra data before the header line");
  ------------------
  |  |   84|  5.34k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  5.34k|    do {                                                                                 \
  |  |  |  |   77|  5.34k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5.34k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  5.34k|            break;                                                                       \
  |  |  |  |   79|  5.34k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  819|  5.34k|            break;
  820|  5.34k|        }
  821|  9.23k|    }
  822|       |
  823|  11.1k|    if (skip) {
  ------------------
  |  Branch (823:9): [True: 11.1k, False: 0]
  ------------------
  824|  11.1k|        *skip = armhdrlen;
  825|  11.1k|    }
  826|  11.1k|    return type;
  827|  11.3k|}
stream-armor.cpp:_ZL17find_armor_headerRKNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEERmRS5_:
  698|  11.3k|{
  699|  11.3k|    size_t bg_len = strlen(ST_ARMOR_BEGIN);
  ------------------
  |  |   46|  11.3k|#define ST_ARMOR_BEGIN ("-----BEGIN PGP ")
  ------------------
  700|  11.3k|    size_t pos = str.find(ST_ARMOR_BEGIN);
  ------------------
  |  |   46|  11.3k|#define ST_ARMOR_BEGIN ("-----BEGIN PGP ")
  ------------------
  701|  11.3k|    if (pos == std::string::npos) {
  ------------------
  |  Branch (701:9): [True: 30, False: 11.3k]
  ------------------
  702|     30|        return pos;
  703|     30|    }
  704|  11.3k|    size_t end = str.find(ST_DASHES, pos + bg_len);
  ------------------
  |  |   45|  11.3k|#define ST_DASHES ("-----")
  ------------------
  705|  11.3k|    if (end == std::string::npos) {
  ------------------
  |  Branch (705:9): [True: 183, False: 11.1k]
  ------------------
  706|    183|        return end;
  707|    183|    }
  708|  11.1k|    hdrlen = end + 5;
  709|  11.1k|    type.assign(str.begin() + pos + bg_len, str.begin() + end);
  710|  11.1k|    return pos;
  711|  11.3k|}
stream-armor.cpp:_ZL16armored_src_readP12pgp_source_tPvmPm:
  476|  18.1k|{
  477|  18.1k|    pgp_source_armored_param_t *param = (pgp_source_armored_param_t *) src->param;
  478|  18.1k|    uint8_t  b64buf[ARMORED_BLOCK_SIZE];     /* input base64 data with spaces and so on */
  479|  18.1k|    uint8_t  decbuf[ARMORED_BLOCK_SIZE + 4]; /* decoded 6-bit values */
  480|  18.1k|    uint8_t *bufptr = (uint8_t *) buf;       /* for better readability below */
  481|  18.1k|    uint8_t *bptr, *bend;                    /* pointer to input data in b64buf */
  482|  18.1k|    uint8_t *dptr, *dend, *pend; /* pointers to decoded data in decbuf: working pointer, last
  483|       |                                    available byte, last byte to process */
  484|  18.1k|    uint8_t  bval;
  485|  18.1k|    uint32_t b24;
  486|  18.1k|    size_t   read = 0;
  487|  18.1k|    size_t   left = len;
  488|  18.1k|    size_t   eqcount = 0; /* number of '=' at the end of base64 stream */
  489|       |
  490|  18.1k|    if (!param) {
  ------------------
  |  Branch (490:9): [True: 0, False: 18.1k]
  ------------------
  491|      0|        return false;
  492|      0|    }
  493|       |
  494|       |    /* checking whether there are some decoded bytes */
  495|  18.1k|    if (param->restpos < param->restlen) {
  ------------------
  |  Branch (495:9): [True: 1.45k, False: 16.6k]
  ------------------
  496|  1.45k|        if (param->restlen - param->restpos >= len) {
  ------------------
  |  Branch (496:13): [True: 0, False: 1.45k]
  ------------------
  497|      0|            memcpy(bufptr, &param->rest[param->restpos], len);
  498|      0|            param->restpos += len;
  499|      0|            try {
  500|      0|                param->crc_ctx->add(bufptr, len);
  501|      0|            } catch (const std::exception &e) {
  502|      0|                RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  503|      0|                return false;
  504|      0|            }
  505|      0|            *readres = len;
  506|      0|            return true;
  507|  1.45k|        } else {
  508|  1.45k|            left = len - (param->restlen - param->restpos);
  509|  1.45k|            memcpy(bufptr, &param->rest[param->restpos], len - left);
  510|  1.45k|            param->restpos = param->restlen = 0;
  511|  1.45k|            bufptr += len - left;
  512|  1.45k|        }
  513|  1.45k|    }
  514|       |
  515|  18.1k|    if (param->eofb64) {
  ------------------
  |  Branch (515:9): [True: 7.04k, False: 11.0k]
  ------------------
  516|  7.04k|        *readres = len - left;
  517|  7.04k|        return true;
  518|  7.04k|    }
  519|       |
  520|  11.0k|    memcpy(decbuf, param->brest, param->brestlen);
  521|  11.0k|    dend = decbuf + param->brestlen;
  522|       |
  523|  27.5k|    do {
  524|  27.5k|        if (!param->readsrc->peek(b64buf, sizeof(b64buf), &read)) {
  ------------------
  |  Branch (524:13): [True: 0, False: 27.5k]
  ------------------
  525|      0|            return false;
  526|      0|        }
  527|  27.5k|        if (!read) {
  ------------------
  |  Branch (527:13): [True: 2.37k, False: 25.2k]
  ------------------
  528|  2.37k|            RNP_LOG("premature end of armored input");
  ------------------
  |  |   84|  2.37k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.37k|    do {                                                                                 \
  |  |  |  |   77|  2.37k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.37k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.37k|            break;                                                                       \
  |  |  |  |   79|  2.37k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  529|  2.37k|            return false;
  530|  2.37k|        }
  531|       |
  532|  25.2k|        dptr = dend;
  533|  25.2k|        bptr = b64buf;
  534|  25.2k|        bend = b64buf + read;
  535|       |        /* checking input data, stripping away whitespaces, checking for end of the b64 data */
  536|  76.0M|        while (bptr < bend) {
  ------------------
  |  Branch (536:16): [True: 76.0M, False: 17.9k]
  ------------------
  537|  76.0M|            if ((bval = B64DEC[*(bptr++)]) < 64) {
  ------------------
  |  Branch (537:17): [True: 74.0M, False: 1.95M]
  ------------------
  538|  74.0M|                *(dptr++) = bval;
  539|  74.0M|            } else if (bval == 0xfe) {
  ------------------
  |  Branch (539:24): [True: 6.48k, False: 1.94M]
  ------------------
  540|       |                /* '=' means the base64 padding or the beginning of checksum */
  541|  6.48k|                param->eofb64 = true;
  542|  6.48k|                break;
  543|  1.94M|            } else if (bval == 0xff) {
  ------------------
  |  Branch (543:24): [True: 732, False: 1.94M]
  ------------------
  544|    732|                auto ch = *(bptr - 1);
  545|       |                /* OpenPGP message headers without the crc and without trailing = */
  546|    732|                if ((ch == CH_DASH) && !param->noheaders) {
  ------------------
  |  |   34|    732|#define CH_DASH ('-')
  ------------------
  |  Branch (546:21): [True: 585, False: 147]
  |  Branch (546:40): [True: 585, False: 0]
  ------------------
  547|    585|                    param->eofb64 = true;
  548|    585|                    break;
  549|    585|                }
  550|    147|                RNP_LOG("wrong base64 character 0x%02hhX", ch);
  ------------------
  |  |   84|    147|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    147|    do {                                                                                 \
  |  |  |  |   77|    147|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 147, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    147|            break;                                                                       \
  |  |  |  |   79|    147|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  551|    147|                return false;
  552|    732|            }
  553|  76.0M|        }
  554|       |
  555|  25.0k|        dend = dptr;
  556|  25.0k|        dptr = decbuf;
  557|       |        /* Processing full 4s which will go directly to the buf.
  558|       |           After this left < 3 or decbuf has < 4 bytes */
  559|  25.0k|        if ((size_t)(dend - dptr) / 4 * 3 < left) {
  ------------------
  |  Branch (559:13): [True: 23.5k, False: 1.52k]
  ------------------
  560|  23.5k|            pend = decbuf + (dend - dptr) / 4 * 4;
  561|  23.5k|            left -= (dend - dptr) / 4 * 3;
  562|  23.5k|        } else {
  563|  1.52k|            pend = decbuf + (left / 3) * 4;
  564|  1.52k|            left -= left / 3 * 3;
  565|  1.52k|        }
  566|       |
  567|       |        /* this one would the most performance-consuming part for large chunks */
  568|  18.0M|        while (dptr < pend) {
  ------------------
  |  Branch (568:16): [True: 18.0M, False: 25.0k]
  ------------------
  569|  18.0M|            b24 = *dptr++ << 18;
  570|  18.0M|            b24 |= *dptr++ << 12;
  571|  18.0M|            b24 |= *dptr++ << 6;
  572|  18.0M|            b24 |= *dptr++;
  573|  18.0M|            *bufptr++ = b24 >> 16;
  574|  18.0M|            *bufptr++ = b24 >> 8;
  575|  18.0M|            *bufptr++ = b24 & 0xff;
  576|  18.0M|        }
  577|       |
  578|       |        /* moving rest to the beginning of decbuf */
  579|  25.0k|        memmove(decbuf, dptr, dend - dptr);
  580|  25.0k|        dend = decbuf + (dend - dptr);
  581|       |
  582|       |        /* skip already processed data */
  583|  25.0k|        if (!param->eofb64) {
  ------------------
  |  Branch (583:13): [True: 17.9k, False: 7.06k]
  ------------------
  584|       |            /* all input is base64 data or eol/spaces, so skipping it */
  585|  17.9k|            param->readsrc->skip(read);
  586|       |            /* check for eof for base64-encoded data without headers */
  587|  17.9k|            if (param->noheaders && param->readsrc->eof()) {
  ------------------
  |  Branch (587:17): [True: 0, False: 17.9k]
  |  Branch (587:37): [True: 0, False: 0]
  ------------------
  588|      0|                param->readsrc->skip(read);
  589|      0|                param->eofb64 = true;
  590|  17.9k|            } else {
  591|  17.9k|                continue;
  592|  17.9k|            }
  593|  17.9k|        } else {
  594|       |            /* '=' reached, bptr points on it */
  595|  7.06k|            param->readsrc->skip(bptr - b64buf - 1);
  596|  7.06k|        }
  597|       |
  598|       |        /* end of base64 data */
  599|  7.06k|        if (param->noheaders) {
  ------------------
  |  Branch (599:13): [True: 0, False: 7.06k]
  ------------------
  600|      0|            if (!base64_read_padding(*param->readsrc, &eqcount)) {
  ------------------
  |  Branch (600:17): [True: 0, False: 0]
  ------------------
  601|      0|                return false;
  602|      0|            }
  603|      0|            break;
  604|      0|        }
  605|       |        /* reading b64 padding if any */
  606|  7.06k|        if (!armor_read_padding(*param->readsrc, &eqcount)) {
  ------------------
  |  Branch (606:13): [True: 27, False: 7.04k]
  ------------------
  607|     27|            RNP_LOG("wrong padding");
  ------------------
  |  |   84|     27|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     27|    do {                                                                                 \
  |  |  |  |   77|     27|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 27, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     27|            break;                                                                       \
  |  |  |  |   79|     27|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  608|     27|            return false;
  609|     27|        }
  610|       |        /* reading crc */
  611|  7.04k|        if (!armor_read_crc(param)) {
  ------------------
  |  Branch (611:13): [True: 1.48k, False: 5.55k]
  ------------------
  612|  1.48k|            RNP_LOG("Warning: missing or malformed CRC line");
  ------------------
  |  |   84|  1.48k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.48k|    do {                                                                                 \
  |  |  |  |   77|  1.48k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.48k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.48k|            break;                                                                       \
  |  |  |  |   79|  1.48k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  613|  1.48k|        }
  614|       |        /* reading armor trailing line */
  615|  7.04k|        if (!armor_read_trailer(param)) {
  ------------------
  |  Branch (615:13): [True: 1.18k, False: 5.86k]
  ------------------
  616|  1.18k|            RNP_LOG("wrong armor trailer");
  ------------------
  |  |   84|  1.18k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.18k|    do {                                                                                 \
  |  |  |  |   77|  1.18k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.18k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.18k|            break;                                                                       \
  |  |  |  |   79|  1.18k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  617|  1.18k|            return false;
  618|  1.18k|        }
  619|  5.86k|        break;
  620|  17.9k|    } while (left >= 3);
  ------------------
  |  Branch (620:14): [True: 16.5k, False: 1.46k]
  ------------------
  621|       |
  622|       |    /* process bytes left in decbuf */
  623|       |
  624|  7.32k|    dptr = decbuf;
  625|  7.32k|    pend = decbuf + (dend - decbuf) / 4 * 4;
  626|  7.32k|    bptr = param->rest;
  627|   474k|    while (dptr < pend) {
  ------------------
  |  Branch (627:12): [True: 467k, False: 7.32k]
  ------------------
  628|   467k|        b24 = *dptr++ << 18;
  629|   467k|        b24 |= *dptr++ << 12;
  630|   467k|        b24 |= *dptr++ << 6;
  631|   467k|        b24 |= *dptr++;
  632|   467k|        *bptr++ = b24 >> 16;
  633|   467k|        *bptr++ = b24 >> 8;
  634|   467k|        *bptr++ = b24 & 0xff;
  635|   467k|    }
  636|       |
  637|  7.32k|    if (!armored_update_crc(param, buf, bufptr - (uint8_t *) buf)) {
  ------------------
  |  Branch (637:9): [True: 0, False: 7.32k]
  ------------------
  638|      0|        return false;
  639|      0|    }
  640|       |
  641|  7.32k|    if (param->eofb64) {
  ------------------
  |  Branch (641:9): [True: 5.86k, False: 1.46k]
  ------------------
  642|  5.86k|        if ((dend - dptr + eqcount) % 4 != 0) {
  ------------------
  |  Branch (642:13): [True: 59, False: 5.80k]
  ------------------
  643|     59|            RNP_LOG("wrong b64 padding");
  ------------------
  |  |   84|     59|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     59|    do {                                                                                 \
  |  |  |  |   77|     59|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 59, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     59|            break;                                                                       \
  |  |  |  |   79|     59|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  644|     59|            return false;
  645|     59|        }
  646|       |
  647|  5.80k|        if (eqcount == 1) {
  ------------------
  |  Branch (647:13): [True: 1.88k, False: 3.91k]
  ------------------
  648|  1.88k|            b24 = (*dptr << 10) | (*(dptr + 1) << 4) | (*(dptr + 2) >> 2);
  649|  1.88k|            *bptr++ = b24 >> 8;
  650|  1.88k|            *bptr++ = b24 & 0xff;
  651|  3.91k|        } else if (eqcount == 2) {
  ------------------
  |  Branch (651:20): [True: 1.61k, False: 2.30k]
  ------------------
  652|  1.61k|            *bptr++ = (*dptr << 2) | (*(dptr + 1) >> 4);
  653|  1.61k|        }
  654|       |
  655|       |        /* Calculate CRC after reading whole input stream */
  656|  5.80k|        if (!armored_update_crc(param, param->rest, bptr - param->rest, true)) {
  ------------------
  |  Branch (656:13): [True: 0, False: 5.80k]
  ------------------
  657|      0|            return false;
  658|      0|        }
  659|  5.80k|    } else {
  660|       |        /* few bytes which do not fit to 4 boundary */
  661|  3.07k|        for (int i = 0; i < dend - dptr; i++) {
  ------------------
  |  Branch (661:25): [True: 1.60k, False: 1.46k]
  ------------------
  662|  1.60k|            param->brest[i] = *(dptr + i);
  663|  1.60k|        }
  664|  1.46k|        param->brestlen = dend - dptr;
  665|  1.46k|    }
  666|       |
  667|  7.26k|    param->restlen = bptr - param->rest;
  668|       |
  669|       |    /* check whether we have some bytes to add */
  670|  7.26k|    if ((left > 0) && (param->restlen > 0)) {
  ------------------
  |  Branch (670:9): [True: 6.86k, False: 406]
  |  Branch (670:23): [True: 4.56k, False: 2.30k]
  ------------------
  671|  4.56k|        read = left > param->restlen ? param->restlen : left;
  ------------------
  |  Branch (671:16): [True: 3.47k, False: 1.08k]
  ------------------
  672|  4.56k|        memcpy(bufptr, param->rest, read);
  673|  4.56k|        if (!param->eofb64 && !armored_update_crc(param, bufptr, read)) {
  ------------------
  |  Branch (673:13): [True: 1.06k, False: 3.49k]
  |  Branch (673:31): [True: 0, False: 1.06k]
  ------------------
  674|      0|            return false;
  675|      0|        }
  676|  4.56k|        left -= read;
  677|  4.56k|        param->restpos += read;
  678|  4.56k|    }
  679|       |
  680|  7.26k|    *readres = len - left;
  681|  7.26k|    return true;
  682|  7.26k|}
stream-armor.cpp:_ZL18armor_read_paddingR12pgp_source_tPm:
  340|  7.06k|{
  341|  7.06k|    char   st[64];
  342|  7.06k|    size_t stlen = 0;
  343|       |
  344|  7.06k|    if (!src.peek_line(st, 64, &stlen)) {
  ------------------
  |  Branch (344:9): [True: 7, False: 7.06k]
  ------------------
  345|      7|        return false;
  346|      7|    }
  347|       |
  348|  7.06k|    if ((stlen == 1) || (stlen == 2)) {
  ------------------
  |  Branch (348:9): [True: 2.07k, False: 4.99k]
  |  Branch (348:25): [True: 1.82k, False: 3.16k]
  ------------------
  349|  3.89k|        if ((st[0] != CH_EQ) || ((stlen == 2) && (st[1] != CH_EQ))) {
  ------------------
  |  |   33|  3.89k|#define CH_EQ ('=')
  ------------------
                      if ((st[0] != CH_EQ) || ((stlen == 2) && (st[1] != CH_EQ))) {
  ------------------
  |  |   33|  1.82k|#define CH_EQ ('=')
  ------------------
  |  Branch (349:13): [True: 4, False: 3.89k]
  |  Branch (349:34): [True: 1.82k, False: 2.06k]
  |  Branch (349:50): [True: 6, False: 1.81k]
  ------------------
  350|     10|            return false;
  351|     10|        }
  352|       |
  353|  3.88k|        *read = stlen;
  354|  3.88k|        src.skip(stlen);
  355|  3.88k|        return src.skip_eol();
  356|  3.89k|    } else if (stlen == 5) {
  ------------------
  |  Branch (356:16): [True: 2.59k, False: 568]
  ------------------
  357|  2.59k|        *read = 0;
  358|  2.59k|        return true;
  359|  2.59k|    } else if ((stlen > 5) && !memcmp(st, ST_DASHES, 5)) {
  ------------------
  |  |   45|    565|#define ST_DASHES ("-----")
  ------------------
  |  Branch (359:16): [True: 565, False: 3]
  |  Branch (359:31): [True: 558, False: 7]
  ------------------
  360|       |        /* case with absent crc and 3-byte last chunk */
  361|    558|        *read = 0;
  362|    558|        return true;
  363|    558|    }
  364|     10|    return false;
  365|  7.06k|}
stream-armor.cpp:_ZL14armor_read_crcP26pgp_source_armored_param_t:
  401|  7.04k|{
  402|  7.04k|    uint8_t dec[4] = {0};
  403|  7.04k|    char    crc[8] = {0};
  404|  7.04k|    size_t  clen = 0;
  405|       |
  406|  7.04k|    if (!param->readsrc->peek_line(crc, sizeof(crc), &clen)) {
  ------------------
  |  Branch (406:9): [True: 1.45k, False: 5.58k]
  ------------------
  407|  1.45k|        return false;
  408|  1.45k|    }
  409|       |
  410|  5.58k|    if ((clen != 5) || (crc[0] != CH_EQ)) {
  ------------------
  |  |   33|  5.58k|#define CH_EQ ('=')
  ------------------
  |  Branch (410:9): [True: 7, False: 5.58k]
  |  Branch (410:24): [True: 16, False: 5.56k]
  ------------------
  411|     23|        return false;
  412|     23|    }
  413|       |
  414|  27.8k|    for (int i = 0; i < 4; i++) {
  ------------------
  |  Branch (414:21): [True: 22.2k, False: 5.55k]
  ------------------
  415|  22.2k|        if ((dec[i] = B64DEC[(uint8_t) crc[i + 1]]) >= 64) {
  ------------------
  |  Branch (415:13): [True: 7, False: 22.2k]
  ------------------
  416|      7|            return false;
  417|      7|        }
  418|  22.2k|    }
  419|       |
  420|  5.55k|    param->readcrc[0] = (dec[0] << 2) | ((dec[1] >> 4) & 0x0F);
  421|  5.55k|    param->readcrc[1] = (dec[1] << 4) | ((dec[2] >> 2) & 0x0F);
  422|  5.55k|    param->readcrc[2] = (dec[2] << 6) | dec[3];
  423|       |
  424|  5.55k|    param->has_crc = true;
  425|       |
  426|  5.55k|    param->readsrc->skip(5);
  427|  5.55k|    return param->readsrc->skip_eol();
  428|  5.56k|}
stream-armor.cpp:_ZL18armor_read_trailerP26pgp_source_armored_param_t:
  432|  7.04k|{
  433|       |    /* Space or tab could get between armor and trailer, see issue #2199 */
  434|  7.04k|    if (!param->readsrc->skip_chars("\r\n \t")) {
  ------------------
  |  Branch (434:9): [True: 0, False: 7.04k]
  ------------------
  435|      0|        return false;
  436|      0|    }
  437|       |
  438|  7.04k|    std::string st = ST_ARMOR_END + param->armorhdr + ST_DASHES;
  ------------------
  |  |   47|  21.1k|#define ST_ARMOR_END ("-----END PGP ")
  ------------------
                  std::string st = ST_ARMOR_END + param->armorhdr + ST_DASHES;
  ------------------
  |  |   45|  7.04k|#define ST_DASHES ("-----")
  ------------------
  439|  7.04k|    std::string str(st.size(), 0);
  440|  7.04k|    if (!param->readsrc->peek_eq(&str.front(), str.size()) || (st != str)) {
  ------------------
  |  Branch (440:9): [True: 326, False: 6.71k]
  |  Branch (440:63): [True: 856, False: 5.86k]
  ------------------
  441|  1.18k|        return false;
  442|  1.18k|    }
  443|  5.86k|    param->readsrc->skip(st.size());
  444|  5.86k|    (void) param->readsrc->skip_chars("\t ");
  445|  5.86k|    (void) param->readsrc->skip_eol();
  446|  5.86k|    return true;
  447|  7.04k|}
stream-armor.cpp:_ZL18armored_update_crcP26pgp_source_armored_param_tPKvmb:
  454|  14.1k|{
  455|  14.1k|    if (param->noheaders) {
  ------------------
  |  Branch (455:9): [True: 0, False: 14.1k]
  ------------------
  456|      0|        return true;
  457|      0|    }
  458|  14.1k|    try {
  459|  14.1k|        param->crc_ctx->add(buf, len);
  460|  14.1k|        if (!finish) {
  ------------------
  |  Branch (460:13): [True: 8.38k, False: 5.80k]
  ------------------
  461|  8.38k|            return true;
  462|  8.38k|        }
  463|  5.80k|        auto crc = param->crc_ctx->finish();
  464|  5.80k|        if (param->has_crc && memcmp(param->readcrc, crc.data(), 3)) {
  ------------------
  |  Branch (464:13): [True: 4.67k, False: 1.13k]
  |  Branch (464:31): [True: 2.10k, False: 2.56k]
  ------------------
  465|  2.10k|            RNP_LOG("Warning: CRC mismatch");
  ------------------
  |  |   84|  2.10k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.10k|    do {                                                                                 \
  |  |  |  |   77|  2.10k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.10k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.10k|            break;                                                                       \
  |  |  |  |   79|  2.10k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  466|  2.10k|        }
  467|  5.80k|        return true;
  468|  14.1k|    } catch (const std::exception &e) {
  469|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  470|      0|        return false;
  471|      0|    }
  472|  14.1k|}
stream-armor.cpp:_ZL17armored_src_closeP12pgp_source_t:
  686|  13.1k|{
  687|  13.1k|    auto param = (pgp_source_armored_param_t *) src->param;
  688|  13.1k|    delete param;
  689|       |    src->param = NULL;
  690|  13.1k|}
stream-armor.cpp:_ZL18armor_parse_headerP26pgp_source_armored_param_t:
  841|  11.3k|{
  842|  11.3k|    size_t      skip = 0;
  843|  11.3k|    std::string hdr = peek_armor_header(*param->readsrc, &skip, true);
  844|  11.3k|    if (hdr.empty()) {
  ------------------
  |  Branch (844:9): [True: 229, False: 11.1k]
  ------------------
  845|    229|        RNP_LOG("no armor header");
  ------------------
  |  |   84|    229|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    229|    do {                                                                                 \
  |  |  |  |   77|    229|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 229, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    229|            break;                                                                       \
  |  |  |  |   79|    229|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  846|    229|        return false;
  847|    229|    }
  848|       |
  849|  11.1k|    param->type = armor_str_to_data_type(hdr);
  850|  11.1k|    if (param->type == PGP_ARMORED_UNKNOWN) {
  ------------------
  |  Branch (850:9): [True: 186, False: 10.9k]
  ------------------
  851|    186|        RNP_LOG("unknown armor header");
  ------------------
  |  |   84|    186|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    186|    do {                                                                                 \
  |  |  |  |   77|    186|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 186, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    186|            break;                                                                       \
  |  |  |  |   79|    186|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  852|    186|        return false;
  853|    186|    }
  854|       |
  855|  10.9k|    param->armorhdr = std::move(hdr);
  856|  10.9k|    param->readsrc->skip(skip);
  857|  10.9k|    param->readsrc->skip_chars("\t ");
  858|  10.9k|    return true;
  859|  11.1k|}
stream-armor.cpp:_ZL19armor_parse_headersP26pgp_source_armored_param_t:
  896|  9.92k|{
  897|  9.92k|    std::vector<char> header(ARMORED_PEEK_BUF_SIZE, '\0');
  ------------------
  |  |   46|  9.92k|#define ARMORED_PEEK_BUF_SIZE 1024
  ------------------
  898|       |
  899|  31.5k|    do {
  900|  31.5k|        size_t hdrlen = 0;
  901|  31.5k|        if (!param->readsrc->peek_line(header.data(), header.size(), &hdrlen)) {
  ------------------
  |  Branch (901:13): [True: 1.52k, False: 30.0k]
  ------------------
  902|       |            /* if line is too long let's cut it to the reasonable size */
  903|  1.52k|            param->readsrc->skip(hdrlen);
  904|  1.52k|            if ((hdrlen != header.size() - 1) || !armor_skip_line(*param->readsrc)) {
  ------------------
  |  Branch (904:17): [True: 286, False: 1.24k]
  |  Branch (904:50): [True: 19, False: 1.22k]
  ------------------
  905|    305|                RNP_LOG("failed to peek line: unexpected end of data");
  ------------------
  |  |   84|    305|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    305|    do {                                                                                 \
  |  |  |  |   77|    305|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 305, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    305|            break;                                                                       \
  |  |  |  |   79|    305|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  906|    305|                return false;
  907|    305|            }
  908|  1.22k|            RNP_LOG("Too long armor header - truncated.");
  ------------------
  |  |   84|  1.22k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.22k|    do {                                                                                 \
  |  |  |  |   77|  1.22k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.22k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.22k|            break;                                                                       \
  |  |  |  |   79|  1.22k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  909|  30.0k|        } else if (hdrlen) {
  ------------------
  |  Branch (909:20): [True: 21.6k, False: 8.36k]
  ------------------
  910|  21.6k|            if (is_base64_line(header.data(), hdrlen)) {
  ------------------
  |  Branch (910:17): [True: 1.25k, False: 20.3k]
  ------------------
  911|  1.25k|                RNP_LOG("Warning: no empty line after the base64 headers");
  ------------------
  |  |   84|  1.25k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.25k|    do {                                                                                 \
  |  |  |  |   77|  1.25k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.25k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.25k|            break;                                                                       \
  |  |  |  |   79|  1.25k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  912|  1.25k|                return true;
  913|  1.25k|            }
  914|  20.3k|            param->readsrc->skip(hdrlen);
  915|  20.3k|            if (rnp::is_blank_line(header.data(), hdrlen)) {
  ------------------
  |  Branch (915:17): [True: 0, False: 20.3k]
  ------------------
  916|      0|                return param->readsrc->skip_eol();
  917|      0|            }
  918|  20.3k|        } else {
  919|       |            /* empty line - end of the headers */
  920|  8.36k|            return param->readsrc->skip_eol();
  921|  8.36k|        }
  922|       |
  923|  21.6k|        std::string hdrst(header.begin(), header.begin() + hdrlen);
  924|  21.6k|        size_t      pos = hdrst.find(": ");
  925|  21.6k|        if ((pos != std::string::npos) && armor_header_known(hdrst.substr(0, pos + 2))) {
  ------------------
  |  Branch (925:13): [True: 8.22k, False: 13.3k]
  |  Branch (925:13): [True: 3.81k, False: 17.8k]
  |  Branch (925:43): [True: 3.81k, False: 4.41k]
  ------------------
  926|       |            // do nothing at the moment, just check whether header is known
  927|  17.8k|        } else {
  928|  17.8k|            RNP_LOG("unknown header '%s'", hdrst.c_str());
  ------------------
  |  |   84|  17.8k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  17.8k|    do {                                                                                 \
  |  |  |  |   77|  17.8k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 17.8k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  17.8k|            break;                                                                       \
  |  |  |  |   79|  17.8k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  929|  17.8k|        }
  930|       |
  931|  21.6k|        if (!param->readsrc->skip_eol()) {
  ------------------
  |  Branch (931:13): [True: 0, False: 21.6k]
  ------------------
  932|      0|            return false;
  933|      0|        }
  934|  21.6k|    } while (1);
  ------------------
  |  Branch (934:14): [True: 21.6k, Folded]
  ------------------
  935|  9.92k|}
stream-armor.cpp:_ZL15armor_skip_lineR12pgp_source_t:
  863|  1.24k|{
  864|  1.24k|    char header[ARMORED_PEEK_BUF_SIZE] = {0};
  865|  2.00k|    do {
  866|  2.00k|        size_t hdrlen = 0;
  867|  2.00k|        bool   res = src.peek_line(header, sizeof(header), &hdrlen);
  868|  2.00k|        if (hdrlen) {
  ------------------
  |  Branch (868:13): [True: 1.52k, False: 482]
  ------------------
  869|  1.52k|            src.skip(hdrlen);
  870|  1.52k|        }
  871|  2.00k|        if (res || (hdrlen < sizeof(header) - 1)) {
  ------------------
  |  Branch (871:13): [True: 1.22k, False: 786]
  |  Branch (871:20): [True: 19, False: 767]
  ------------------
  872|  1.24k|            return res;
  873|  1.24k|        }
  874|  2.00k|    } while (1);
  ------------------
  |  Branch (874:14): [True: 767, Folded]
  ------------------
  875|  1.24k|}
stream-armor.cpp:_ZL18armor_header_knownRKNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE:
  889|  8.22k|{
  890|  8.22k|    return (name == ST_HEADER_VERSION) || (name == ST_HEADER_COMMENT) ||
  ------------------
  |  |   50|  8.22k|#define ST_HEADER_VERSION ("Version: ")
  ------------------
                  return (name == ST_HEADER_VERSION) || (name == ST_HEADER_COMMENT) ||
  ------------------
  |  |   51|  5.41k|#define ST_HEADER_COMMENT ("Comment: ")
  ------------------
  |  Branch (890:12): [True: 2.81k, False: 5.41k]
  |  Branch (890:43): [True: 368, False: 5.04k]
  ------------------
  891|  5.04k|           (name == ST_HEADER_CHARSET) || (name == ST_HEADER_HASH);
  ------------------
  |  |   53|  5.04k|#define ST_HEADER_CHARSET ("Charset: ")
  ------------------
                         (name == ST_HEADER_CHARSET) || (name == ST_HEADER_HASH);
  ------------------
  |  |   52|  4.71k|#define ST_HEADER_HASH ("Hash: ")
  ------------------
  |  Branch (891:12): [True: 334, False: 4.71k]
  |  Branch (891:43): [True: 299, False: 4.41k]
  ------------------
  892|  8.22k|}
stream-armor.cpp:_ZL17armored_dst_writeP10pgp_dest_tPKvm:
 1067|  4.54k|{
 1068|  4.54k|    pgp_dest_armored_param_t *param = (pgp_dest_armored_param_t *) dst->param;
 1069|  4.54k|    if (!param) {
  ------------------
  |  Branch (1069:9): [True: 0, False: 4.54k]
  ------------------
 1070|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1071|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1072|      0|    }
 1073|       |
 1074|       |    /* update crc */
 1075|  4.54k|    bool base64 = param->type == PGP_ARMORED_BASE64;
 1076|  4.54k|    if (!base64) {
  ------------------
  |  Branch (1076:9): [True: 4.54k, False: 0]
  ------------------
 1077|  4.54k|        param->tracker.feed((const uint8_t *) buf, len);
 1078|  4.54k|        try {
 1079|  4.54k|            param->crc_ctx->add(buf, len);
 1080|  4.54k|        } catch (const std::exception &e) {
 1081|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1082|      0|            return RNP_ERROR_BAD_STATE;
 1083|      0|        }
 1084|  4.54k|    }
 1085|       |
 1086|  4.54k|    uint8_t  encbuf[PGP_INPUT_CACHE_SIZE / 2];
 1087|  4.54k|    uint8_t *bufptr = (uint8_t *) buf;
 1088|  4.54k|    uint8_t *bufend = bufptr + len;
 1089|  4.54k|    uint8_t *encptr = encbuf;
 1090|       |    /* processing tail if any */
 1091|  4.54k|    if (len + param->tailc < 3) {
  ------------------
  |  Branch (1091:9): [True: 0, False: 4.54k]
  ------------------
 1092|      0|        memcpy(&param->tail[param->tailc], buf, len);
 1093|      0|        param->tailc += len;
 1094|      0|        return RNP_SUCCESS;
 1095|  4.54k|    } else if (param->tailc > 0) {
  ------------------
  |  Branch (1095:16): [True: 1.27k, False: 3.26k]
  ------------------
 1096|  1.27k|        uint8_t dec3[3] = {0};
 1097|  1.27k|        memcpy(dec3, param->tail, param->tailc);
 1098|  1.27k|        memcpy(&dec3[param->tailc], bufptr, 3 - param->tailc);
 1099|  1.27k|        bufptr += 3 - param->tailc;
 1100|  1.27k|        param->tailc = 0;
 1101|  1.27k|        armored_encode3(encptr, dec3);
 1102|  1.27k|        encptr += 4;
 1103|  1.27k|        param->lout += 4;
 1104|  1.27k|        if (param->lout == param->llen) {
  ------------------
  |  Branch (1104:13): [True: 0, False: 1.27k]
  ------------------
 1105|      0|            armor_append_eol(param, encptr);
 1106|      0|            param->lout = 0;
 1107|      0|        }
 1108|  1.27k|    }
 1109|       |
 1110|       |    /* this version prints whole chunks, so rounding down to the closest 4 */
 1111|  4.54k|    auto adjusted_llen = param->llen & ~3;
 1112|       |    /* number of input bytes to form a whole line of output, param->llen / 4 * 3 */
 1113|  4.54k|    auto inllen = (adjusted_llen >> 2) + (adjusted_llen >> 1);
 1114|       |    /* pointer to the last full line space in encbuf */
 1115|  4.54k|    auto enclast = encbuf + sizeof(encbuf) - adjusted_llen - 2;
 1116|       |
 1117|       |    /* processing line chunks, this is the main performance-hitting cycle */
 1118|  1.11M|    while (bufptr + 3 <= bufend) {
  ------------------
  |  Branch (1118:12): [True: 1.10M, False: 4.54k]
  ------------------
 1119|       |        /* checking whether we have enough space in encbuf */
 1120|  1.10M|        if (encptr > enclast) {
  ------------------
  |  Branch (1120:13): [True: 3.72k, False: 1.10M]
  ------------------
 1121|  3.72k|            dst_write(param->writedst, encbuf, encptr - encbuf);
 1122|  3.72k|            encptr = encbuf;
 1123|  3.72k|        }
 1124|       |        /* setup length of the input to process in this iteration */
 1125|  1.10M|        uint8_t *inlend =
 1126|  1.10M|          !param->lout ? bufptr + inllen : bufptr + ((adjusted_llen - param->lout) >> 2) * 3;
  ------------------
  |  Branch (1126:11): [True: 1.10M, False: 1.76k]
  ------------------
 1127|  1.10M|        if (inlend > bufend) {
  ------------------
  |  Branch (1127:13): [True: 4.28k, False: 1.10M]
  ------------------
 1128|       |            /* no enough input for the full line */
 1129|  4.28k|            inlend = bufptr + (bufend - bufptr) / 3 * 3;
 1130|  4.28k|            param->lout += (inlend - bufptr) / 3 * 4;
 1131|  1.10M|        } else {
 1132|       |            /* we have full line of input */
 1133|  1.10M|            param->lout = 0;
 1134|  1.10M|        }
 1135|       |
 1136|       |        /* processing one line */
 1137|  22.0M|        while (bufptr < inlend) {
  ------------------
  |  Branch (1137:16): [True: 20.9M, False: 1.10M]
  ------------------
 1138|  20.9M|            uint32_t t = (bufptr[0] << 16) | (bufptr[1] << 8) | (bufptr[2]);
 1139|  20.9M|            bufptr += 3;
 1140|  20.9M|            *encptr++ = B64ENC[(t >> 18) & 0xff];
 1141|  20.9M|            *encptr++ = B64ENC[(t >> 12) & 0xff];
 1142|  20.9M|            *encptr++ = B64ENC[(t >> 6) & 0xff];
 1143|  20.9M|            *encptr++ = B64ENC[t & 0xff];
 1144|  20.9M|        }
 1145|       |
 1146|       |        /* adding line ending */
 1147|  1.10M|        if (!param->lout) {
  ------------------
  |  Branch (1147:13): [True: 1.10M, False: 4.28k]
  ------------------
 1148|  1.10M|            armor_append_eol(param, encptr);
 1149|  1.10M|        }
 1150|  1.10M|    }
 1151|       |
 1152|  4.54k|    dst_write(param->writedst, encbuf, encptr - encbuf);
 1153|       |
 1154|       |    /* saving tail */
 1155|  4.54k|    param->tailc = bufend - bufptr;
 1156|  4.54k|    memcpy(param->tail, bufptr, param->tailc);
 1157|       |
 1158|  4.54k|    return RNP_SUCCESS;
 1159|  4.54k|}
_ZN19armor_crc_tracker_t4feedEPKhm:
  170|  4.54k|    {
  171|  4.54k|        if (!tracked) {
  ------------------
  |  Branch (171:13): [True: 0, False: 4.54k]
  ------------------
  172|      0|            return;
  173|      0|        }
  174|  39.0k|        while (len > 0) {
  ------------------
  |  Branch (174:16): [True: 36.2k, False: 2.77k]
  ------------------
  175|  36.2k|            switch (st) {
  ------------------
  |  Branch (175:21): [True: 36.2k, False: 0]
  ------------------
  176|  5.55k|            case State::Ptag: {
  ------------------
  |  Branch (176:13): [True: 5.55k, False: 30.7k]
  ------------------
  177|  5.55k|                uint8_t ptag = *buf++;
  178|  5.55k|                len--;
  179|  5.55k|                if (!(ptag & PGP_PTAG_ALWAYS_SET)) {
  ------------------
  |  |   47|  5.55k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
  |  Branch (179:21): [True: 0, False: 5.55k]
  ------------------
  180|      0|                    tracked = false;
  181|      0|                    return;
  182|      0|                }
  183|  5.55k|                new_fmt = ptag & PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   56|  5.55k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  184|  5.55k|                chunk_len = false;
  185|  5.55k|                saw_b1 = false;
  186|  5.55k|                len_have = 0;
  187|  5.55k|                if (new_fmt) {
  ------------------
  |  Branch (187:21): [True: 5.55k, False: 0]
  ------------------
  188|  5.55k|                    pending_tag = ptag & PGP_PTAG_NF_CONTENT_TAG_MASK;
  ------------------
  |  |  137|  5.55k|#define PGP_PTAG_NF_CONTENT_TAG_MASK 0x3f
  ------------------
  189|  5.55k|                    st = State::Len;
  190|  5.55k|                    len_need = 1;
  191|  5.55k|                } else {
  192|      0|                    pending_tag = (ptag >> PGP_PTAG_OF_CONTENT_TAG_SHIFT) & 0x0f;
  ------------------
  |  |   74|      0|#define PGP_PTAG_OF_CONTENT_TAG_SHIFT 2
  ------------------
  193|      0|                    switch (ptag & PGP_PTAG_OF_LENGTH_TYPE_MASK) {
  ------------------
  |  |   83|      0|#define PGP_PTAG_OF_LENGTH_TYPE_MASK 0x03
  ------------------
  194|      0|                    case PGP_PTAG_OLD_LEN_1:
  ------------------
  |  Branch (194:21): [True: 0, False: 0]
  ------------------
  195|      0|                        len_need = 1;
  196|      0|                        st = State::Len;
  197|      0|                        break;
  198|      0|                    case PGP_PTAG_OLD_LEN_2:
  ------------------
  |  Branch (198:21): [True: 0, False: 0]
  ------------------
  199|      0|                        len_need = 2;
  200|      0|                        st = State::Len;
  201|      0|                        break;
  202|      0|                    case PGP_PTAG_OLD_LEN_4:
  ------------------
  |  Branch (202:21): [True: 0, False: 0]
  ------------------
  203|      0|                        len_need = 4;
  204|      0|                        st = State::Len;
  205|      0|                        break;
  206|      0|                    default:
  ------------------
  |  Branch (206:21): [True: 0, False: 0]
  ------------------
  207|       |                        /* indeterminate length */
  208|      0|                        tracked = false;
  209|      0|                        return;
  210|      0|                    }
  211|      0|                }
  212|  5.55k|                break;
  213|  5.55k|            }
  214|  14.3k|            case State::Len: {
  ------------------
  |  Branch (214:13): [True: 14.3k, False: 21.9k]
  ------------------
  215|  14.3k|                uint8_t oct = *buf++;
  216|  14.3k|                len--;
  217|  14.3k|                if (!saw_b1) {
  ------------------
  |  Branch (217:21): [True: 12.9k, False: 1.39k]
  ------------------
  218|  12.9k|                    b1 = oct;
  219|  12.9k|                    saw_b1 = true;
  220|  12.9k|                    if (new_fmt) {
  ------------------
  |  Branch (220:25): [True: 12.9k, False: 0]
  ------------------
  221|  12.9k|                        if (b1 < 192) {
  ------------------
  |  Branch (221:29): [True: 4.15k, False: 8.81k]
  ------------------
  222|  4.15k|                            finish_header(b1, false);
  223|  4.15k|                            break;
  224|  4.15k|                        }
  225|  8.81k|                        if (b1 < 224) {
  ------------------
  |  Branch (225:29): [True: 1.39k, False: 7.41k]
  ------------------
  226|  1.39k|                            len_need = 1;
  227|  1.39k|                            len_have = 0;
  228|  1.39k|                            st = State::Len;
  229|  1.39k|                            break;
  230|  1.39k|                        }
  231|  7.41k|                        if (b1 == 255) {
  ------------------
  |  Branch (231:29): [True: 0, False: 7.41k]
  ------------------
  232|      0|                            len_need = 4;
  233|      0|                            len_have = 0;
  234|      0|                            st = State::Len;
  235|      0|                            break;
  236|      0|                        }
  237|       |                        /* partial body length */
  238|  7.41k|                        finish_header((size_t) 1 << (b1 & 0x1f), true);
  239|  7.41k|                        break;
  240|  7.41k|                    }
  241|  12.9k|                }
  242|  1.39k|                len_oct[len_have++] = oct;
  243|  1.39k|                if (len_have < len_need) {
  ------------------
  |  Branch (243:21): [True: 0, False: 1.39k]
  ------------------
  244|      0|                    break;
  245|      0|                }
  246|       |                /* all length octets collected */
  247|  1.39k|                size_t blen;
  248|  1.39k|                if (new_fmt) {
  ------------------
  |  Branch (248:21): [True: 1.39k, False: 0]
  ------------------
  249|  1.39k|                    blen = ((size_t)(b1 - 192) << 8) + len_oct[0] + 192;
  250|  1.39k|                } else {
  251|      0|                    blen = 0;
  252|      0|                    for (size_t i = 0; i < len_need; i++) {
  ------------------
  |  Branch (252:40): [True: 0, False: 0]
  ------------------
  253|      0|                        blen = (blen << 8) | len_oct[i];
  254|      0|                    }
  255|      0|                }
  256|  1.39k|                finish_header(blen, false);
  257|  1.39k|                break;
  258|  1.39k|            }
  259|  16.3k|            case State::Body: {
  ------------------
  |  Branch (259:13): [True: 16.3k, False: 19.9k]
  ------------------
  260|  16.3k|                if (!ver_seen && tracked_tag(last_tag) && (body_left > 0)) {
  ------------------
  |  Branch (260:21): [True: 7.73k, False: 8.62k]
  |  Branch (260:34): [True: 1.62k, False: 6.11k]
  |  Branch (260:59): [True: 1.62k, False: 0]
  ------------------
  261|  1.62k|                    account_version(*buf++);
  262|  1.62k|                    len--;
  263|  1.62k|                    body_left--;
  264|  1.62k|                    break;
  265|  1.62k|                }
  266|  14.7k|                size_t take = std::min(len, body_left);
  267|  14.7k|                buf += take;
  268|  14.7k|                len -= take;
  269|  14.7k|                body_left -= take;
  270|  14.7k|                if (body_left > 0) {
  ------------------
  |  Branch (270:21): [True: 1.76k, False: 12.9k]
  ------------------
  271|  1.76k|                    return;
  272|  1.76k|                }
  273|  12.9k|                if (in_partial) {
  ------------------
  |  Branch (273:21): [True: 7.41k, False: 5.55k]
  ------------------
  274|       |                    /* the next chunk length follows */
  275|  7.41k|                    new_fmt = true;
  276|  7.41k|                    chunk_len = true;
  277|  7.41k|                    saw_b1 = false;
  278|  7.41k|                    len_have = 0;
  279|  7.41k|                    len_need = 1;
  280|  7.41k|                    st = State::Len;
  281|  7.41k|                    break;
  282|  7.41k|                }
  283|  5.55k|                begin_header();
  284|  5.55k|                break;
  285|  12.9k|            }
  286|  36.2k|            }
  287|  36.2k|        }
  288|  4.54k|    }
_ZN19armor_crc_tracker_t13finish_headerEmb:
  142|  12.9k|    {
  143|  12.9k|        if (chunk_len) {
  ------------------
  |  Branch (143:13): [True: 7.41k, False: 5.55k]
  ------------------
  144|       |            /* no new packet: just more octets of the same body */
  145|  7.41k|            body_left = blen;
  146|  7.41k|            in_partial = partial;
  147|  7.41k|            st = State::Body;
  148|  7.41k|            return;
  149|  7.41k|        }
  150|  5.55k|        begin_body(pending_tag, blen, partial);
  151|  5.55k|    }
_ZN19armor_crc_tracker_t10begin_bodyEimb:
  115|  5.55k|    {
  116|  5.55k|        if (first_tag < 0) {
  ------------------
  |  Branch (116:13): [True: 2.77k, False: 2.78k]
  ------------------
  117|  2.77k|            first_tag = tag;
  118|  2.77k|        }
  119|  5.55k|        if (tag != PGP_PKT_SIGNATURE) {
  ------------------
  |  Branch (119:13): [True: 5.55k, False: 0]
  ------------------
  120|  5.55k|            only_sigs = false;
  121|  5.55k|        }
  122|  5.55k|        last_tag = tag;
  123|  5.55k|        last_ver = -1;
  124|  5.55k|        ver_seen = false;
  125|  5.55k|        body_left = blen;
  126|  5.55k|        in_partial = partial;
  127|  5.55k|        st = State::Body;
  128|  5.55k|    }
_ZN19armor_crc_tracker_t11tracked_tagEi:
  109|  7.73k|    {
  110|  7.73k|        return is_key_tag(tag) || (tag == PGP_PKT_SIGNATURE) || (tag == PGP_PKT_SE_IP_DATA);
  ------------------
  |  Branch (110:16): [True: 0, False: 7.73k]
  |  Branch (110:35): [True: 0, False: 7.73k]
  |  Branch (110:65): [True: 1.62k, False: 6.11k]
  ------------------
  111|  7.73k|    }
_ZN19armor_crc_tracker_t10is_key_tagEi:
  102|  12.1k|    {
  103|  12.1k|        return (tag == PGP_PKT_SECRET_KEY) || (tag == PGP_PKT_PUBLIC_KEY) ||
  ------------------
  |  Branch (103:16): [True: 0, False: 12.1k]
  |  Branch (103:47): [True: 0, False: 12.1k]
  ------------------
  104|  12.1k|               (tag == PGP_PKT_SECRET_SUBKEY) || (tag == PGP_PKT_PUBLIC_SUBKEY);
  ------------------
  |  Branch (104:16): [True: 0, False: 12.1k]
  |  Branch (104:50): [True: 0, False: 12.1k]
  ------------------
  105|  12.1k|    }
_ZN19armor_crc_tracker_t15account_versionEh:
  155|  1.62k|    {
  156|  1.62k|        last_ver = ver;
  157|  1.62k|        ver_seen = true;
  158|  1.62k|        if (is_key_tag(last_tag)) {
  ------------------
  |  Branch (158:13): [True: 0, False: 1.62k]
  ------------------
  159|      0|            saw_key = true;
  160|       |            /* version 6; the PGP_V6 enumerator needs the crypto-refresh build */
  161|      0|            all_keys_v6 = all_keys_v6 && (ver == 6);
  ------------------
  |  Branch (161:27): [True: 0, False: 0]
  |  Branch (161:42): [True: 0, False: 0]
  ------------------
  162|      0|        }
  163|  1.62k|        if (last_tag == PGP_PKT_SIGNATURE) {
  ------------------
  |  Branch (163:13): [True: 0, False: 1.62k]
  ------------------
  164|      0|            all_sigs_v6 = all_sigs_v6 && (ver == 6);
  ------------------
  |  Branch (164:27): [True: 0, False: 0]
  |  Branch (164:42): [True: 0, False: 0]
  ------------------
  165|      0|        }
  166|  1.62k|    }
_ZN19armor_crc_tracker_t12begin_headerEv:
  132|  5.55k|    {
  133|  5.55k|        st = State::Ptag;
  134|  5.55k|        saw_b1 = false;
  135|  5.55k|        len_have = 0;
  136|  5.55k|    }
stream-armor.cpp:_ZL15armored_encode3PhS_:
 1058|  3.62k|{
 1059|  3.62k|    out[0] = B64ENC[in[0] >> 2];
 1060|  3.62k|    out[1] = B64ENC[((in[0] << 4) | (in[1] >> 4)) & 0xff];
 1061|  3.62k|    out[2] = B64ENC[((in[1] << 2) | (in[2] >> 6)) & 0xff];
 1062|  3.62k|    out[3] = B64ENC[in[2] & 0xff];
 1063|  3.62k|}
stream-armor.cpp:_ZL16armor_append_eolP24pgp_dest_armored_param_tRPh:
 1029|  1.10M|{
 1030|  1.10M|    if (param->eol[0]) {
  ------------------
  |  Branch (1030:9): [True: 1.10M, False: 0]
  ------------------
 1031|  1.10M|        *ptr++ = param->eol[0];
 1032|  1.10M|    }
 1033|  1.10M|    if (param->eol[1]) {
  ------------------
  |  Branch (1033:9): [True: 1.10M, False: 0]
  ------------------
 1034|  1.10M|        *ptr++ = param->eol[1];
 1035|  1.10M|    }
 1036|  1.10M|}
stream-armor.cpp:_ZL18armored_dst_finishP10pgp_dest_t:
 1163|  2.77k|{
 1164|  2.77k|    pgp_dest_armored_param_t *param = (pgp_dest_armored_param_t *) dst->param;
 1165|       |
 1166|       |    /* writing tail */
 1167|  2.77k|    uint8_t buf[5];
 1168|  2.77k|    if (param->tailc == 1) {
  ------------------
  |  Branch (1168:9): [True: 942, False: 1.83k]
  ------------------
 1169|    942|        buf[0] = B64ENC[param->tail[0] >> 2];
 1170|    942|        buf[1] = B64ENC[(param->tail[0] << 4) & 0xff];
 1171|    942|        buf[2] = CH_EQ;
  ------------------
  |  |   33|    942|#define CH_EQ ('=')
  ------------------
 1172|    942|        buf[3] = CH_EQ;
  ------------------
  |  |   33|    942|#define CH_EQ ('=')
  ------------------
 1173|    942|        dst_write(param->writedst, buf, 4);
 1174|  1.83k|    } else if (param->tailc == 2) {
  ------------------
  |  Branch (1174:16): [True: 915, False: 917]
  ------------------
 1175|    915|        buf[0] = B64ENC[(param->tail[0] >> 2)];
 1176|    915|        buf[1] = B64ENC[((param->tail[0] << 4) | (param->tail[1] >> 4)) & 0xff];
 1177|    915|        buf[2] = B64ENC[(param->tail[1] << 2) & 0xff];
 1178|    915|        buf[3] = CH_EQ;
  ------------------
  |  |   33|    915|#define CH_EQ ('=')
  ------------------
 1179|    915|        dst_write(param->writedst, buf, 4);
 1180|    915|    }
 1181|       |    /* Check for base64 */
 1182|  2.77k|    if (param->type == PGP_ARMORED_BASE64) {
  ------------------
  |  Branch (1182:9): [True: 0, False: 2.77k]
  ------------------
 1183|      0|        return param->writedst->werr;
 1184|      0|    }
 1185|       |
 1186|       |    /* writing EOL if needed */
 1187|  2.77k|    if ((param->tailc > 0) || (param->lout > 0)) {
  ------------------
  |  Branch (1187:9): [True: 1.85k, False: 917]
  |  Branch (1187:31): [True: 859, False: 58]
  ------------------
 1188|  2.71k|        armor_write_eol(param);
 1189|  2.71k|    }
 1190|       |
 1191|       |    /* RFC 9580, 6.1: the CRC24 footer must not be generated for the armored
 1192|       |     * version 6 keys, version 6 signature sequences, and the messages ending
 1193|       |     * with a version 2 SEIPD packet. */
 1194|  2.77k|    if (param->tracker.skip_crc()) {
  ------------------
  |  Branch (1194:9): [True: 424, False: 2.35k]
  ------------------
 1195|    424|        return param->writedst->werr;
 1196|    424|    }
 1197|       |    /* writing CRC and EOL */
 1198|       |    // At this point crc_ctx is initialized, so call can't fail
 1199|  2.35k|    buf[0] = CH_EQ;
  ------------------
  |  |   33|  2.35k|#define CH_EQ ('=')
  ------------------
 1200|  2.35k|    try {
 1201|  2.35k|        auto crc = param->crc_ctx->finish();
 1202|  2.35k|        armored_encode3(&buf[1], crc.data());
 1203|  2.35k|    } catch (const std::exception &e) {
 1204|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1205|      0|    }
 1206|  2.35k|    dst_write(param->writedst, buf, 5);
 1207|  2.35k|    armor_write_eol(param);
 1208|       |
 1209|       |    /* writing armor header */
 1210|  2.35k|    armor_write_message_header(param, true);
 1211|  2.35k|    armor_write_eol(param);
 1212|  2.35k|    return param->writedst->werr;
 1213|  2.35k|}
_ZNK19armor_crc_tracker_t8skip_crcEv:
  292|  2.77k|    {
  293|  2.77k|        if (!tracked || (first_tag < 0)) {
  ------------------
  |  Branch (293:13): [True: 0, False: 2.77k]
  |  Branch (293:25): [True: 0, False: 2.77k]
  ------------------
  294|      0|            return false;
  295|      0|        }
  296|  2.77k|        if (is_key_tag(first_tag)) {
  ------------------
  |  Branch (296:13): [True: 0, False: 2.77k]
  ------------------
  297|      0|            return saw_key && all_keys_v6;
  ------------------
  |  Branch (297:20): [True: 0, False: 0]
  |  Branch (297:31): [True: 0, False: 0]
  ------------------
  298|      0|        }
  299|  2.77k|        if (only_sigs && (first_tag == PGP_PKT_SIGNATURE)) {
  ------------------
  |  Branch (299:13): [True: 0, False: 2.77k]
  |  Branch (299:26): [True: 0, False: 0]
  ------------------
  300|      0|            return all_sigs_v6;
  301|      0|        }
  302|  2.77k|        return (last_tag == PGP_PKT_SE_IP_DATA) && (last_ver == PGP_SE_IP_DATA_V2);
  ------------------
  |  Branch (302:16): [True: 1.62k, False: 1.15k]
  |  Branch (302:52): [True: 424, False: 1.19k]
  ------------------
  303|  2.77k|    }
stream-armor.cpp:_ZL17armored_dst_closeP10pgp_dest_tb:
 1217|  5.02k|{
 1218|  5.02k|    pgp_dest_armored_param_t *param = (pgp_dest_armored_param_t *) dst->param;
 1219|       |
 1220|  5.02k|    if (!param) {
  ------------------
  |  Branch (1220:9): [True: 0, False: 5.02k]
  ------------------
 1221|      0|        return;
 1222|      0|    }
 1223|       |    /* dst_close may be called without dst_finish on error */
 1224|  5.02k|    delete param;
 1225|       |    dst->param = NULL;
 1226|  5.02k|}
stream-armor.cpp:_ZL26armor_write_message_headerP24pgp_dest_armored_param_tb:
  994|  7.37k|{
  995|  7.37k|    const char *str = finish ? ST_ARMOR_END : ST_ARMOR_BEGIN;
  ------------------
  |  |   47|  2.35k|#define ST_ARMOR_END ("-----END PGP ")
  ------------------
                  const char *str = finish ? ST_ARMOR_END : ST_ARMOR_BEGIN;
  ------------------
  |  |   46|  5.02k|#define ST_ARMOR_BEGIN ("-----BEGIN PGP ")
  ------------------
  |  Branch (995:23): [True: 2.35k, False: 5.02k]
  ------------------
  996|  7.37k|    dst_write(param->writedst, str, strlen(str));
  997|  7.37k|    switch (param->type) {
  998|      0|    case PGP_ARMORED_PUBLIC_KEY:
  ------------------
  |  Branch (998:5): [True: 0, False: 7.37k]
  ------------------
  999|      0|        str = "PUBLIC KEY BLOCK";
 1000|      0|        break;
 1001|      0|    case PGP_ARMORED_SECRET_KEY:
  ------------------
  |  Branch (1001:5): [True: 0, False: 7.37k]
  ------------------
 1002|      0|        str = "PRIVATE KEY BLOCK";
 1003|      0|        break;
 1004|      0|    case PGP_ARMORED_SIGNATURE:
  ------------------
  |  Branch (1004:5): [True: 0, False: 7.37k]
  ------------------
 1005|      0|        str = "SIGNATURE";
 1006|      0|        break;
 1007|  7.37k|    case PGP_ARMORED_MESSAGE:
  ------------------
  |  Branch (1007:5): [True: 7.37k, False: 0]
  ------------------
 1008|  7.37k|    default:
  ------------------
  |  Branch (1008:5): [True: 0, False: 7.37k]
  ------------------
 1009|  7.37k|        str = "MESSAGE";
 1010|  7.37k|        break;
 1011|  7.37k|    }
 1012|  7.37k|    dst_write(param->writedst, str, strlen(str));
 1013|  7.37k|    dst_write(param->writedst, ST_DASHES, strlen(ST_DASHES));
  ------------------
  |  |   45|  7.37k|#define ST_DASHES ("-----")
  ------------------
                  dst_write(param->writedst, ST_DASHES, strlen(ST_DASHES));
  ------------------
  |  |   45|  7.37k|#define ST_DASHES ("-----")
  ------------------
 1014|  7.37k|}
stream-armor.cpp:_ZL15armor_write_eolP24pgp_dest_armored_param_t:
 1018|  17.4k|{
 1019|  17.4k|    if (param->eol[0]) {
  ------------------
  |  Branch (1019:9): [True: 17.4k, False: 0]
  ------------------
 1020|  17.4k|        dst_write(param->writedst, &param->eol[0], 1);
 1021|  17.4k|    }
 1022|  17.4k|    if (param->eol[1]) {
  ------------------
  |  Branch (1022:9): [True: 17.4k, False: 0]
  ------------------
 1023|  17.4k|        dst_write(param->writedst, &param->eol[1], 1);
 1024|  17.4k|    }
 1025|  17.4k|}
stream-armor.cpp:_ZL14is_base64_linePKcm:
  879|  21.6k|{
  880|   119k|    for (size_t i = 0; i < len && line[i]; i++) {
  ------------------
  |  Branch (880:24): [True: 118k, False: 1.23k]
  |  Branch (880:35): [True: 118k, False: 24]
  ------------------
  881|   118k|        if (B64DEC[(uint8_t) line[i]] == 0xff)
  ------------------
  |  Branch (881:13): [True: 20.3k, False: 98.2k]
  ------------------
  882|  20.3k|            return false;
  883|   118k|    }
  884|  1.25k|    return true;
  885|  21.6k|}

_ZN3rnp13ArmoredSource8multipleEv:
  123|  8.12k|    {
  124|  8.12k|        return multiple_;
  125|  8.12k|    }

_ZN12pgp_source_t4readEPvmPm:
   57|  1.81M|{
   58|  1.81M|    size_t left = len;
   59|  1.81M|    size_t read;
   60|  1.81M|    bool   readahead = cache ? cache->readahead : false;
  ------------------
  |  Branch (60:24): [True: 1.81M, False: 0]
  ------------------
   61|       |
   62|  1.81M|    if (error_) {
  ------------------
  |  Branch (62:9): [True: 0, False: 1.81M]
  ------------------
   63|      0|        return false;
   64|      0|    }
   65|       |
   66|  1.81M|    if (eof_ || (len == 0)) {
  ------------------
  |  Branch (66:9): [True: 8.77k, False: 1.80M]
  |  Branch (66:17): [True: 0, False: 1.80M]
  ------------------
   67|  8.77k|        *readres = 0;
   68|  8.77k|        return true;
   69|  8.77k|    }
   70|       |
   71|       |    // Do not read more then available if source size is known
   72|  1.80M|    if (knownsize && (readb + len > size)) {
  ------------------
  |  Branch (72:9): [True: 1.08M, False: 715k]
  |  Branch (72:22): [True: 18.1k, False: 1.06M]
  ------------------
   73|  18.1k|        len = size - readb;
   74|  18.1k|        left = len;
   75|  18.1k|        readahead = false;
   76|  18.1k|    }
   77|       |
   78|       |    // Check whether we have cache and there is data inside
   79|  1.80M|    if (cache && (cache->len > cache->pos)) {
  ------------------
  |  Branch (79:9): [True: 1.80M, False: 0]
  |  Branch (79:18): [True: 1.77M, False: 27.5k]
  ------------------
   80|  1.77M|        read = cache->len - cache->pos;
   81|  1.77M|        if (read >= len) {
  ------------------
  |  Branch (81:13): [True: 1.71M, False: 60.9k]
  ------------------
   82|  1.71M|            memcpy(buf, &cache->buf[cache->pos], len);
   83|  1.71M|            cache->pos += len;
   84|  1.71M|            goto finish;
   85|  1.71M|        } else {
   86|  60.9k|            memcpy(buf, &cache->buf[cache->pos], read);
   87|  60.9k|            cache->pos += read;
   88|  60.9k|            buf = (uint8_t *) buf + read;
   89|  60.9k|            left = len - read;
   90|  60.9k|        }
   91|  1.77M|    }
   92|       |
   93|       |    // If we got here then we have empty cache or no cache at all
   94|  99.4k|    while (left > 0) {
  ------------------
  |  Branch (94:12): [True: 90.0k, False: 9.33k]
  ------------------
   95|  90.0k|        if (left > sizeof(cache->buf) || !readahead || !cache) {
  ------------------
  |  Branch (95:13): [True: 80, False: 89.9k]
  |  Branch (95:42): [True: 9.39k, False: 80.6k]
  |  Branch (95:56): [True: 0, False: 80.6k]
  ------------------
   96|       |            // If there is no cache or chunk is larger then read directly
   97|  9.47k|            if (!raw_read(this, buf, left, &read)) {
  ------------------
  |  Branch (97:17): [True: 0, False: 9.47k]
  ------------------
   98|      0|                error_ = 1;
   99|      0|                return false;
  100|      0|            }
  101|  9.47k|            if (!read) {
  ------------------
  |  Branch (101:17): [True: 91, False: 9.38k]
  ------------------
  102|     91|                eof_ = true;
  103|     91|                len = len - left;
  104|     91|                goto finish;
  105|     91|            }
  106|  9.38k|            left -= read;
  107|  9.38k|            buf = (uint8_t *) buf + read;
  108|  80.6k|        } else {
  109|       |            // Try to fill the cache to avoid small reads
  110|  80.6k|            if (!raw_read(this, &cache->buf[0], sizeof(cache->buf), &read)) {
  ------------------
  |  Branch (110:17): [True: 716, False: 79.8k]
  ------------------
  111|    716|                error_ = true;
  112|    716|                return false;
  113|    716|            }
  114|  79.8k|            if (!read) {
  ------------------
  |  Branch (114:17): [True: 17.6k, False: 62.2k]
  ------------------
  115|  17.6k|                eof_ = true;
  116|  17.6k|                len = len - left;
  117|  17.6k|                goto finish;
  118|  62.2k|            } else if (read < left) {
  ------------------
  |  Branch (118:24): [True: 1.55k, False: 60.7k]
  ------------------
  119|  1.55k|                memcpy(buf, &cache->buf[0], read);
  120|  1.55k|                left -= read;
  121|  1.55k|                buf = (uint8_t *) buf + read;
  122|  60.7k|            } else {
  123|  60.7k|                memcpy(buf, &cache->buf[0], left);
  124|  60.7k|                cache->pos = left;
  125|  60.7k|                cache->len = read;
  126|  60.7k|                goto finish;
  127|  60.7k|            }
  128|  79.8k|        }
  129|  90.0k|    }
  130|       |
  131|  1.80M|finish:
  132|  1.80M|    readb += len;
  133|  1.80M|    if (knownsize && (readb == size)) {
  ------------------
  |  Branch (133:9): [True: 1.08M, False: 714k]
  |  Branch (133:22): [True: 20.1k, False: 1.06M]
  ------------------
  134|  20.1k|        eof_ = true;
  135|  20.1k|    }
  136|  1.80M|    *readres = len;
  137|  1.80M|    return true;
  138|  88.4k|}
_ZN12pgp_source_t7read_eqEPvm:
  142|  1.17M|{
  143|  1.17M|    size_t res = 0;
  144|  1.17M|    return read(buf, len, &res) && (res == len);
  ------------------
  |  Branch (144:12): [True: 1.17M, False: 31]
  |  Branch (144:36): [True: 1.17M, False: 286]
  ------------------
  145|  1.17M|}
_ZN12pgp_source_t4peekEPvmPm:
  149|  18.5M|{
  150|  18.5M|    if (error_) {
  ------------------
  |  Branch (150:9): [True: 1.49k, False: 18.5M]
  ------------------
  151|  1.49k|        return false;
  152|  1.49k|    }
  153|  18.5M|    if (!cache || (len > sizeof(cache->buf))) {
  ------------------
  |  Branch (153:9): [True: 0, False: 18.5M]
  |  Branch (153:19): [True: 0, False: 18.5M]
  ------------------
  154|      0|        return false;
  155|      0|    }
  156|  18.5M|    if (eof_) {
  ------------------
  |  Branch (156:9): [True: 8.92k, False: 18.5M]
  ------------------
  157|  8.92k|        *peeked = 0;
  158|  8.92k|        return true;
  159|  8.92k|    }
  160|       |
  161|  18.5M|    size_t read = 0;
  162|  18.5M|    bool   readahead = cache->readahead;
  163|       |    // Do not read more then available if source size is known
  164|  18.5M|    if (knownsize && (readb + len > size)) {
  ------------------
  |  Branch (164:9): [True: 16.4M, False: 2.14M]
  |  Branch (164:22): [True: 52.6k, False: 16.3M]
  ------------------
  165|  52.6k|        len = size - readb;
  166|  52.6k|        readahead = false;
  167|  52.6k|    }
  168|       |
  169|  18.5M|    if (cache->len - cache->pos >= len) {
  ------------------
  |  Branch (169:9): [True: 18.5M, False: 58.8k]
  ------------------
  170|  18.5M|        if (buf) {
  ------------------
  |  Branch (170:13): [True: 18.5M, False: 0]
  ------------------
  171|  18.5M|            memcpy(buf, &cache->buf[cache->pos], len);
  172|  18.5M|        }
  173|  18.5M|        *peeked = len;
  174|  18.5M|        return true;
  175|  18.5M|    }
  176|       |
  177|  58.8k|    if (cache->pos > 0) {
  ------------------
  |  Branch (177:9): [True: 4.46k, False: 54.3k]
  ------------------
  178|  4.46k|        memmove(&cache->buf[0], &cache->buf[cache->pos], cache->len - cache->pos);
  179|  4.46k|        cache->len -= cache->pos;
  180|  4.46k|        cache->pos = 0;
  181|  4.46k|    }
  182|       |
  183|  58.8k|    while (cache->len < len) {
  ------------------
  |  Branch (183:12): [True: 58.8k, False: 0]
  ------------------
  184|  58.8k|        read = readahead ? sizeof(cache->buf) - cache->len : len - cache->len;
  ------------------
  |  Branch (184:16): [True: 58.7k, False: 53]
  ------------------
  185|  58.8k|        if (knownsize && (readb + read > size)) {
  ------------------
  |  Branch (185:13): [True: 25.3k, False: 33.5k]
  |  Branch (185:26): [True: 22.0k, False: 3.28k]
  ------------------
  186|  22.0k|            read = size - readb;
  187|  22.0k|        }
  188|  58.8k|        if (!raw_read(this, &cache->buf[cache->len], read, &read)) {
  ------------------
  |  Branch (188:13): [True: 4.26k, False: 54.5k]
  ------------------
  189|  4.26k|            error_ = true;
  190|  4.26k|            return false;
  191|  4.26k|        }
  192|  54.5k|        if (!read) {
  ------------------
  |  Branch (192:13): [True: 5.98k, False: 48.5k]
  ------------------
  193|  5.98k|            if (buf) {
  ------------------
  |  Branch (193:17): [True: 5.98k, False: 0]
  ------------------
  194|  5.98k|                memcpy(buf, &cache->buf[0], cache->len);
  195|  5.98k|            }
  196|  5.98k|            *peeked = cache->len;
  197|  5.98k|            return true;
  198|  5.98k|        }
  199|  48.5k|        cache->len += read;
  200|  48.5k|        if (cache->len >= len) {
  ------------------
  |  Branch (200:13): [True: 48.5k, False: 2]
  ------------------
  201|  48.5k|            if (buf) {
  ------------------
  |  Branch (201:17): [True: 48.5k, False: 0]
  ------------------
  202|  48.5k|                memcpy(buf, cache->buf, len);
  203|  48.5k|            }
  204|  48.5k|            *peeked = len;
  205|  48.5k|            return true;
  206|  48.5k|        }
  207|  48.5k|    }
  208|      0|    return false;
  209|  58.8k|}
_ZN12pgp_source_t7peek_eqEPvm:
  213|  13.4M|{
  214|  13.4M|    size_t res = 0;
  215|  13.4M|    return peek(buf, len, &res) && (res == len);
  ------------------
  |  Branch (215:12): [True: 13.4M, False: 4.24k]
  |  Branch (215:36): [True: 13.4M, False: 2.97k]
  ------------------
  216|  13.4M|}
_ZN12pgp_source_t4skipEm:
  220|   408k|{
  221|   408k|    if (cache && (cache->len - cache->pos >= len)) {
  ------------------
  |  Branch (221:9): [True: 408k, False: 0]
  |  Branch (221:18): [True: 408k, False: 78]
  ------------------
  222|   408k|        readb += len;
  223|   408k|        cache->pos += len;
  224|   408k|        return;
  225|   408k|    }
  226|       |
  227|     78|    size_t  res = 0;
  228|     78|    uint8_t sbuf[16];
  229|     78|    if (len < sizeof(sbuf)) {
  ------------------
  |  Branch (229:9): [True: 0, False: 78]
  ------------------
  230|      0|        (void) read(sbuf, len, &res);
  231|      0|        return;
  232|      0|    }
  233|     78|    if (eof()) {
  ------------------
  |  Branch (233:9): [True: 0, False: 78]
  ------------------
  234|      0|        return;
  235|      0|    }
  236|       |
  237|     78|    void *buf = calloc(1, std::min((size_t) PGP_INPUT_CACHE_SIZE, len));
  ------------------
  |  |   35|     78|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  238|     78|    if (!buf) {
  ------------------
  |  Branch (238:9): [True: 0, False: 78]
  ------------------
  239|      0|        error_ = true;
  240|      0|        return;
  241|      0|    }
  242|       |
  243|    156|    while (len && !eof()) {
  ------------------
  |  Branch (243:12): [True: 156, False: 0]
  |  Branch (243:19): [True: 78, False: 78]
  ------------------
  244|     78|        if (!read(buf, std::min((size_t) PGP_INPUT_CACHE_SIZE, len), &res)) {
  ------------------
  |  |   35|     78|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  |  Branch (244:13): [True: 0, False: 78]
  ------------------
  245|      0|            break;
  246|      0|        }
  247|     78|        len -= res;
  248|     78|    }
  249|     78|    free(buf);
  250|     78|}
_ZN12pgp_source_t6finishEv:
  254|  11.7k|{
  255|  11.7k|    if (raw_finish) {
  ------------------
  |  Branch (255:9): [True: 4.80k, False: 6.93k]
  ------------------
  256|  4.80k|        return raw_finish(this);
  257|  4.80k|    }
  258|  6.93k|    return RNP_SUCCESS;
  259|  11.7k|}
_ZNK12pgp_source_t5errorEv:
  263|  77.9k|{
  264|  77.9k|    return error_;
  265|  77.9k|}
_ZN12pgp_source_t3eofEv:
  269|  4.40M|{
  270|  4.40M|    if (eof_) {
  ------------------
  |  Branch (270:9): [True: 41.1k, False: 4.35M]
  ------------------
  271|  41.1k|        return true;
  272|  41.1k|    }
  273|       |    /* Error on stream read is NOT considered as eof. See error(). */
  274|  4.35M|    uint8_t check;
  275|  4.35M|    size_t  read = 0;
  276|  4.35M|    return peek(&check, 1, &read) && (read == 0);
  ------------------
  |  Branch (276:12): [True: 4.35M, False: 1.49k]
  |  Branch (276:38): [True: 3.31k, False: 4.35M]
  ------------------
  277|  4.40M|}
_ZN12pgp_source_t5closeEv:
  281|   133k|{
  282|   133k|    if (raw_close) {
  ------------------
  |  Branch (282:9): [True: 73.6k, False: 59.5k]
  ------------------
  283|  73.6k|        raw_close(this);
  284|  73.6k|    }
  285|       |
  286|   133k|    if (cache) {
  ------------------
  |  Branch (286:9): [True: 71.9k, False: 61.3k]
  ------------------
  287|  71.9k|        free(cache);
  288|       |        cache = NULL;
  289|  71.9k|    }
  290|   133k|}
_ZN12pgp_source_t8skip_eolEv:
  294|  56.2k|{
  295|  56.2k|    uint8_t eol[2];
  296|  56.2k|    size_t  read;
  297|       |
  298|  56.2k|    if (!peek(eol, 2, &read) || !read) {
  ------------------
  |  Branch (298:9): [True: 0, False: 56.2k]
  |  Branch (298:33): [True: 1, False: 56.2k]
  ------------------
  299|      1|        return false;
  300|      1|    }
  301|  56.2k|    if (eol[0] == '\n') {
  ------------------
  |  Branch (301:9): [True: 20.6k, False: 35.6k]
  ------------------
  302|  20.6k|        skip(1);
  303|  20.6k|        return true;
  304|  20.6k|    }
  305|  35.6k|    if ((read == 2) && (eol[0] == '\r') && (eol[1] == '\n')) {
  ------------------
  |  Branch (305:9): [True: 35.6k, False: 8]
  |  Branch (305:24): [True: 33.6k, False: 1.94k]
  |  Branch (305:44): [True: 33.6k, False: 13]
  ------------------
  306|  33.6k|        skip(2);
  307|  33.6k|        return true;
  308|  33.6k|    }
  309|  1.96k|    return false;
  310|  35.6k|}
_ZN12pgp_source_t10skip_charsERKNSt3__112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE:
  314|  23.8k|{
  315|  24.2k|    do {
  316|  24.2k|        char   ch = 0;
  317|  24.2k|        size_t read = 0;
  318|  24.2k|        if (!peek(&ch, 1, &read)) {
  ------------------
  |  Branch (318:13): [True: 0, False: 24.2k]
  ------------------
  319|      0|            return false;
  320|      0|        }
  321|  24.2k|        if (!read) {
  ------------------
  |  Branch (321:13): [True: 302, False: 23.9k]
  ------------------
  322|       |            /* return true only if there is no underlying read error */
  323|    302|            return true;
  324|    302|        }
  325|  23.9k|        if (chars.find(ch) == std::string::npos) {
  ------------------
  |  Branch (325:13): [True: 23.5k, False: 365]
  ------------------
  326|  23.5k|            return true;
  327|  23.5k|        }
  328|    365|        skip(1);
  329|    365|    } while (1);
  ------------------
  |  Branch (329:14): [True: 365, Folded]
  ------------------
  330|  23.8k|}
_ZN12pgp_source_t9peek_lineEPcmPm:
  334|  47.6k|{
  335|  47.6k|    size_t scan_pos = 0;
  336|  47.6k|    size_t inc = 64;
  337|  47.6k|    len = len - 1;
  338|       |
  339|  71.8k|    do {
  340|  71.8k|        size_t to_peek = scan_pos + inc;
  341|  71.8k|        to_peek = to_peek > len ? len : to_peek;
  ------------------
  |  Branch (341:19): [True: 16.2k, False: 55.6k]
  ------------------
  342|  71.8k|        inc = inc * 2;
  343|       |
  344|       |        /* inefficient, each time we again read from the beginning */
  345|  71.8k|        if (!peek(buf, to_peek, readres)) {
  ------------------
  |  Branch (345:13): [True: 0, False: 71.8k]
  ------------------
  346|      0|            return false;
  347|      0|        }
  348|       |
  349|       |        /* we continue scanning where we stopped previously */
  350|  5.05M|        for (; scan_pos < *readres; scan_pos++) {
  ------------------
  |  Branch (350:16): [True: 5.02M, False: 27.9k]
  ------------------
  351|  5.02M|            if (buf[scan_pos] == '\n') {
  ------------------
  |  Branch (351:17): [True: 43.8k, False: 4.98M]
  ------------------
  352|  43.8k|                if ((scan_pos > 0) && (buf[scan_pos - 1] == '\r')) {
  ------------------
  |  Branch (352:21): [True: 41.2k, False: 2.60k]
  |  Branch (352:39): [True: 25.3k, False: 15.9k]
  ------------------
  353|  25.3k|                    scan_pos--;
  354|  25.3k|                }
  355|  43.8k|                buf[scan_pos] = '\0';
  356|  43.8k|                *readres = scan_pos;
  357|  43.8k|                return true;
  358|  43.8k|            }
  359|  5.02M|        }
  360|  27.9k|        if (*readres < to_peek) {
  ------------------
  |  Branch (360:13): [True: 608, False: 27.3k]
  ------------------
  361|    608|            return false;
  362|    608|        }
  363|  27.9k|    } while (scan_pos < len);
  ------------------
  |  Branch (363:14): [True: 24.2k, False: 3.16k]
  ------------------
  364|  3.16k|    return false;
  365|  47.6k|}
_Z15init_src_commonP12pgp_source_tm:
  369|  71.9k|{
  370|  71.9k|    memset(src, 0, sizeof(*src));
  371|  71.9k|    src->cache = (pgp_source_cache_t *) calloc(1, sizeof(*src->cache));
  372|  71.9k|    if (!src->cache) {
  ------------------
  |  Branch (372:9): [True: 0, False: 71.9k]
  ------------------
  373|      0|        RNP_LOG("cache allocation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  374|      0|        return false;
  375|      0|    }
  376|  71.9k|    src->cache->readahead = true;
  377|  71.9k|    if (!paramsize) {
  ------------------
  |  Branch (377:9): [True: 24.4k, False: 47.5k]
  ------------------
  378|  24.4k|        return true;
  379|  24.4k|    }
  380|  47.5k|    src->param = calloc(1, paramsize);
  381|  47.5k|    if (!src->param) {
  ------------------
  |  Branch (381:9): [True: 0, False: 47.5k]
  ------------------
  382|      0|        RNP_LOG("param allocation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  383|      0|        free(src->cache);
  384|      0|        src->cache = NULL;
  385|      0|        return false;
  386|      0|    }
  387|  47.5k|    return true;
  388|  47.5k|}
_Z12init_mem_srcP12pgp_source_tPKvmb:
  546|  35.7k|{
  547|  35.7k|    if (!mem && len) {
  ------------------
  |  Branch (547:9): [True: 0, False: 35.7k]
  |  Branch (547:17): [True: 0, False: 0]
  ------------------
  548|      0|        return RNP_ERROR_NULL_POINTER;
  549|      0|    }
  550|       |    /* this is actually double buffering, but then src_peek will fail */
  551|  35.7k|    if (!init_src_common(src, sizeof(pgp_source_mem_param_t))) {
  ------------------
  |  Branch (551:9): [True: 0, False: 35.7k]
  ------------------
  552|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  553|      0|    }
  554|       |
  555|  35.7k|    pgp_source_mem_param_t *param = (pgp_source_mem_param_t *) src->param;
  556|  35.7k|    param->memory = mem;
  557|  35.7k|    param->len = len;
  558|  35.7k|    param->pos = 0;
  559|  35.7k|    param->free = free;
  560|  35.7k|    src->raw_read = mem_src_read;
  561|  35.7k|    src->raw_close = mem_src_close;
  562|  35.7k|    src->raw_finish = NULL;
  563|  35.7k|    src->size = len;
  564|  35.7k|    src->knownsize = 1;
  565|  35.7k|    src->type = PGP_STREAM_MEMORY;
  566|       |
  567|  35.7k|    return RNP_SUCCESS;
  568|  35.7k|}
_Z15init_dst_commonP10pgp_dest_tm:
  629|   464k|{
  630|   464k|    try {
  631|   464k|        *dst = pgp_dest_t();
  632|   464k|    } catch (const std::exception &e) {
  633|      0|        return false; // LCOV_EXCL_LINE
  634|      0|    }
  635|   464k|    if (!paramsize) {
  ------------------
  |  Branch (635:9): [True: 0, False: 464k]
  ------------------
  636|      0|        return true;
  637|      0|    }
  638|       |    /* allocate param */
  639|   464k|    dst->param = calloc(1, paramsize);
  640|   464k|    if (!dst->param) {
  ------------------
  |  Branch (640:9): [True: 0, False: 464k]
  ------------------
  641|       |        /* LCOV_EXCL_START */
  642|      0|        RNP_LOG("allocation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  643|      0|        return false;
  644|       |        /* LCOV_EXCL_END */
  645|      0|    }
  646|   464k|    return true;
  647|   464k|}
_Z9dst_writeP10pgp_dest_tPKvm:
  651|  1.55M|{
  652|       |    /* we call write function only if all previous calls succeeded */
  653|  1.55M|    if ((len > 0) && (dst->write) && (dst->werr == RNP_SUCCESS)) {
  ------------------
  |  Branch (653:9): [True: 1.25M, False: 303k]
  |  Branch (653:22): [True: 1.25M, False: 0]
  |  Branch (653:38): [True: 1.25M, False: 0]
  ------------------
  654|       |        /* if cache non-empty and len will overflow it then fill it and write out */
  655|  1.25M|        if ((dst->clen > 0) && (dst->clen + len > dst->cache.size())) {
  ------------------
  |  Branch (655:13): [True: 546k, False: 705k]
  |  Branch (655:32): [True: 13.0k, False: 532k]
  ------------------
  656|  13.0k|            memcpy(dst->cache.data() + dst->clen, buf, dst->cache.size() - dst->clen);
  657|  13.0k|            buf = (uint8_t *) buf + dst->cache.size() - dst->clen;
  658|  13.0k|            len -= dst->cache.size() - dst->clen;
  659|  13.0k|            dst->werr = dst->write(dst, dst->cache.data(), dst->cache.size());
  660|  13.0k|            dst->writeb += dst->cache.size();
  661|  13.0k|            dst->clen = 0;
  662|  13.0k|            if (dst->werr != RNP_SUCCESS) {
  ------------------
  |  Branch (662:17): [True: 0, False: 13.0k]
  ------------------
  663|      0|                return;
  664|      0|            }
  665|  13.0k|        }
  666|       |
  667|       |        /* here everything will fit into the cache or cache is empty */
  668|  1.25M|        if (dst->no_cache || (len > dst->cache.size())) {
  ------------------
  |  Branch (668:13): [True: 671k, False: 579k]
  |  Branch (668:30): [True: 0, False: 579k]
  ------------------
  669|   671k|            dst->werr = dst->write(dst, buf, len);
  670|   671k|            if (!dst->werr) {
  ------------------
  |  Branch (670:17): [True: 671k, False: 10]
  ------------------
  671|   671k|                dst->writeb += len;
  672|   671k|            }
  673|   671k|        } else {
  674|   579k|            memcpy(dst->cache.data() + dst->clen, buf, len);
  675|   579k|            dst->clen += len;
  676|   579k|        }
  677|  1.25M|    }
  678|  1.55M|}
_Z9dst_flushP10pgp_dest_t:
  706|  64.4k|{
  707|  64.4k|    if ((dst->clen > 0) && (dst->write) && (dst->werr == RNP_SUCCESS)) {
  ------------------
  |  Branch (707:9): [True: 31.9k, False: 32.5k]
  |  Branch (707:28): [True: 31.9k, False: 0]
  |  Branch (707:44): [True: 31.9k, False: 0]
  ------------------
  708|  31.9k|        dst->werr = dst->write(dst, dst->cache.data(), dst->clen);
  709|  31.9k|        dst->writeb += dst->clen;
  710|  31.9k|        dst->clen = 0;
  711|  31.9k|    }
  712|  64.4k|}
_Z10dst_finishP10pgp_dest_t:
  716|  41.5k|{
  717|  41.5k|    rnp_result_t res = RNP_SUCCESS;
  718|       |
  719|  41.5k|    if (!dst->finished) {
  ------------------
  |  Branch (719:9): [True: 41.5k, False: 0]
  ------------------
  720|       |        /* flush write cache in the dst */
  721|  41.5k|        dst_flush(dst);
  722|  41.5k|        res = dst->werr;
  723|       |        /* do not run the finish callback (e.g. renaming of the temporary
  724|       |         * output file over the target one) if the data was not written
  725|       |         * in full, otherwise a truncated output would replace it */
  726|  41.5k|        if (dst->finish && !res) {
  ------------------
  |  Branch (726:13): [True: 31.9k, False: 9.59k]
  |  Branch (726:28): [True: 31.9k, False: 0]
  ------------------
  727|  31.9k|            res = dst->finish(dst);
  728|  31.9k|        }
  729|  41.5k|        dst->finished = true;
  730|  41.5k|    }
  731|       |
  732|  41.5k|    return res;
  733|  41.5k|}
_Z9dst_closeP10pgp_dest_tb:
  737|   477k|{
  738|   477k|    if (!discard && !dst->finished) {
  ------------------
  |  Branch (738:9): [True: 41.5k, False: 435k]
  |  Branch (738:21): [True: 9.59k, False: 31.9k]
  ------------------
  739|  9.59k|        dst_finish(dst);
  740|  9.59k|    }
  741|       |
  742|   477k|    if (dst->close) {
  ------------------
  |  Branch (742:9): [True: 477k, False: 0]
  ------------------
  743|   477k|        dst->close(dst, discard);
  744|   477k|    }
  745|   477k|}
_Z13init_mem_destP10pgp_dest_tPvj:
 1057|   441k|{
 1058|   441k|    pgp_dest_mem_param_t *param;
 1059|       |
 1060|   441k|    if (!init_dst_common(dst, sizeof(*param))) {
  ------------------
  |  Branch (1060:9): [True: 0, False: 441k]
  ------------------
 1061|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1062|      0|    }
 1063|       |
 1064|   441k|    param = (pgp_dest_mem_param_t *) dst->param;
 1065|       |
 1066|   441k|    param->maxalloc = len;
 1067|   441k|    param->allocated = mem ? len : 0;
  ------------------
  |  Branch (1067:24): [True: 0, False: 441k]
  ------------------
 1068|   441k|    param->memory = mem;
 1069|   441k|    param->free = !mem;
 1070|   441k|    param->secure = false;
 1071|       |
 1072|   441k|    dst->write = mem_dst_write;
 1073|   441k|    dst->close = mem_dst_close;
 1074|   441k|    dst->type = PGP_STREAM_MEMORY;
 1075|   441k|    dst->werr = RNP_SUCCESS;
 1076|   441k|    dst->no_cache = true;
 1077|       |
 1078|   441k|    return RNP_SUCCESS;
 1079|   441k|}
_Z19mem_dest_get_memoryP10pgp_dest_t:
 1097|   431k|{
 1098|   431k|    if (dst->type != PGP_STREAM_MEMORY) {
  ------------------
  |  Branch (1098:9): [True: 0, False: 431k]
  ------------------
 1099|      0|        RNP_LOG("wrong function call");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1100|      0|        return NULL;
 1101|      0|    }
 1102|       |
 1103|   431k|    pgp_dest_mem_param_t *param = (pgp_dest_mem_param_t *) dst->param;
 1104|       |
 1105|   431k|    if (param) {
  ------------------
  |  Branch (1105:9): [True: 431k, False: 0]
  ------------------
 1106|   431k|        return param->memory;
 1107|   431k|    }
 1108|       |
 1109|      0|    return NULL;
 1110|   431k|}
_Z13dst_write_srcP12pgp_source_tP10pgp_dest_tm:
 1196|  1.47k|{
 1197|  1.47k|    const size_t bufsize = PGP_INPUT_CACHE_SIZE;
  ------------------
  |  |   35|  1.47k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
 1198|  1.47k|    uint8_t *    readbuf = (uint8_t *) malloc(bufsize);
 1199|  1.47k|    if (!readbuf) {
  ------------------
  |  Branch (1199:9): [True: 0, False: 1.47k]
  ------------------
 1200|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1201|      0|    }
 1202|  1.47k|    rnp_result_t res = RNP_SUCCESS;
 1203|  1.47k|    try {
 1204|  1.47k|        size_t   read;
 1205|  1.47k|        uint64_t totalread = 0;
 1206|       |
 1207|  3.14k|        while (!src->eof_) {
  ------------------
  |  Branch (1207:16): [True: 1.66k, False: 1.47k]
  ------------------
 1208|  1.66k|            if (!src->read(readbuf, bufsize, &read)) {
  ------------------
  |  Branch (1208:17): [True: 1, False: 1.66k]
  ------------------
 1209|      1|                res = RNP_ERROR_GENERIC;
 1210|      1|                break;
 1211|      1|            }
 1212|  1.66k|            if (!read) {
  ------------------
  |  Branch (1212:17): [True: 0, False: 1.66k]
  ------------------
 1213|      0|                continue;
 1214|      0|            }
 1215|  1.66k|            totalread += read;
 1216|  1.66k|            if (limit && totalread > limit) {
  ------------------
  |  Branch (1216:17): [True: 1.66k, False: 0]
  |  Branch (1216:26): [True: 0, False: 1.66k]
  ------------------
 1217|      0|                res = RNP_ERROR_GENERIC;
 1218|      0|                break;
 1219|      0|            }
 1220|  1.66k|            if (dst) {
  ------------------
  |  Branch (1220:17): [True: 0, False: 1.66k]
  ------------------
 1221|      0|                dst_write(dst, readbuf, read);
 1222|      0|                if (dst->werr) {
  ------------------
  |  Branch (1222:21): [True: 0, False: 0]
  ------------------
 1223|      0|                    RNP_LOG("failed to output data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1224|      0|                    res = RNP_ERROR_WRITE;
 1225|      0|                    break;
 1226|      0|                }
 1227|      0|            }
 1228|  1.66k|        }
 1229|  1.47k|    } catch (...) {
 1230|      0|        free(readbuf);
 1231|      0|        throw;
 1232|      0|    }
 1233|  1.47k|    free(readbuf);
 1234|  1.47k|    if (res || !dst) {
  ------------------
  |  Branch (1234:9): [True: 1, False: 1.47k]
  |  Branch (1234:16): [True: 1.47k, False: 0]
  ------------------
 1235|  1.47k|        return res;
 1236|  1.47k|    }
 1237|      0|    dst_flush(dst);
 1238|      0|    return dst->werr;
 1239|  1.47k|}
_Z19have_pkesk_checksum16pgp_pubkey_alg_t:
 1243|    123|{
 1244|    123|    switch (alg) {
 1245|      0|#if defined(ENABLE_CRYPTO_REFRESH) || defined(ENABLE_PQC)
 1246|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 1247|      0|    case PGP_PKA_X25519:
  ------------------
  |  Branch (1247:5): [True: 0, False: 123]
  ------------------
 1248|      0|    case PGP_PKA_X448:
  ------------------
  |  Branch (1248:5): [True: 0, False: 123]
  ------------------
 1249|      0|#endif
 1250|      0|#if defined(ENABLE_PQC)
 1251|      0|    case PGP_PKA_KYBER768_X25519:
  ------------------
  |  Branch (1251:5): [True: 0, False: 123]
  ------------------
 1252|      0|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
 1253|      0|    case PGP_PKA_KYBER1024_X448:
  ------------------
  |  Branch (1253:5): [True: 0, False: 123]
  ------------------
 1254|      0|    case PGP_PKA_KYBER768_P384:
  ------------------
  |  Branch (1254:5): [True: 0, False: 123]
  ------------------
 1255|      0|    case PGP_PKA_KYBER1024_P521:
  ------------------
  |  Branch (1255:5): [True: 0, False: 123]
  ------------------
 1256|      0|    case PGP_PKA_KYBER768_BP384:
  ------------------
  |  Branch (1256:5): [True: 0, False: 123]
  ------------------
 1257|      0|    case PGP_PKA_KYBER1024_BP512:
  ------------------
  |  Branch (1257:5): [True: 0, False: 123]
  ------------------
 1258|      0|#endif
 1259|      0|#endif
 1260|      0|        return false;
 1261|      0|#endif
 1262|    123|    default:
  ------------------
  |  Branch (1262:5): [True: 123, False: 0]
  ------------------
 1263|    123|        return true;
 1264|    123|    }
 1265|    123|}
_Z26do_encrypt_pkesk_v3_alg_id16pgp_pubkey_alg_t:
 1269|     41|{
 1270|       |    /* matches the same algorithms */
 1271|     41|    return have_pkesk_checksum(alg);
 1272|     41|}
_Z26check_enforce_aes_v3_pkesk16pgp_pubkey_alg_t14pgp_symm_alg_t19pgp_pkesk_version_t:
 1280|     41|{
 1281|       |    /* The same algorithms as with pkesk_checksum */
 1282|     41|    return (ver != PGP_PKSK_V3) || have_pkesk_checksum(alg) || pgp_is_sa_aes(salg);
  ------------------
  |  Branch (1282:12): [True: 0, False: 41]
  |  Branch (1282:36): [True: 41, False: 0]
  |  Branch (1282:64): [True: 0, False: 0]
  ------------------
 1283|     41|}
_Z21encrypted_sesk_set_adR11pgp_crypt_tR16pgp_sk_sesskey_t:
 1289|  7.91k|{
 1290|  7.91k|    uint8_t ad_data[4];
 1291|       |
 1292|  7.91k|    ad_data[0] = PGP_PKT_SK_SESSION_KEY | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   47|  7.91k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                  ad_data[0] = PGP_PKT_SK_SESSION_KEY | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   56|  7.91k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
 1293|  7.91k|    ad_data[1] = skey.version;
 1294|  7.91k|    ad_data[2] = skey.alg;
 1295|  7.91k|    ad_data[3] = skey.aalg;
 1296|       |
 1297|  7.91k|    return pgp_cipher_aead_set_ad(&crypt, ad_data, 4);
 1298|  7.91k|}
stream-common.cpp:_ZL12mem_src_readP12pgp_source_tPvmPm:
  516|  38.3k|{
  517|  38.3k|    pgp_source_mem_param_t *param = (pgp_source_mem_param_t *) src->param;
  518|  38.3k|    if (!param) {
  ------------------
  |  Branch (518:9): [True: 0, False: 38.3k]
  ------------------
  519|      0|        return false;
  520|      0|    }
  521|       |
  522|  38.3k|    if (len > param->len - param->pos) {
  ------------------
  |  Branch (522:9): [True: 474, False: 37.8k]
  ------------------
  523|    474|        len = param->len - param->pos;
  524|    474|    }
  525|  38.3k|    memcpy(buf, (uint8_t *) param->memory + param->pos, len);
  526|  38.3k|    param->pos += len;
  527|  38.3k|    *read = len;
  528|  38.3k|    return true;
  529|  38.3k|}
stream-common.cpp:_ZL13mem_src_closeP12pgp_source_t:
  533|  35.7k|{
  534|  35.7k|    pgp_source_mem_param_t *param = (pgp_source_mem_param_t *) src->param;
  535|  35.7k|    if (param) {
  ------------------
  |  Branch (535:9): [True: 35.7k, False: 0]
  ------------------
  536|  35.7k|        if (param->free) {
  ------------------
  |  Branch (536:13): [True: 0, False: 35.7k]
  ------------------
  537|      0|            free((void *) param->memory);
  538|      0|        }
  539|  35.7k|        free(src->param);
  540|       |        src->param = NULL;
  541|  35.7k|    }
  542|  35.7k|}
stream-common.cpp:_ZL13mem_dst_writeP10pgp_dest_tPKvm:
  994|   671k|{
  995|   671k|    pgp_dest_mem_param_t *param = (pgp_dest_mem_param_t *) dst->param;
  996|   671k|    if (!param) {
  ------------------
  |  Branch (996:9): [True: 0, False: 671k]
  ------------------
  997|      0|        return RNP_ERROR_BAD_PARAMETERS;
  998|      0|    }
  999|       |
 1000|       |    /* checking whether we need to realloc or discard extra bytes */
 1001|   671k|    if (param->discard_overflow && (dst->writeb >= param->allocated)) {
  ------------------
  |  Branch (1001:9): [True: 0, False: 671k]
  |  Branch (1001:36): [True: 0, False: 0]
  ------------------
 1002|      0|        return RNP_SUCCESS;
 1003|      0|    }
 1004|   671k|    if (param->discard_overflow && (dst->writeb + len > param->allocated)) {
  ------------------
  |  Branch (1004:9): [True: 0, False: 671k]
  |  Branch (1004:36): [True: 0, False: 0]
  ------------------
 1005|      0|        len = param->allocated - dst->writeb;
 1006|      0|    }
 1007|       |
 1008|   671k|    if (dst->writeb + len > param->allocated) {
  ------------------
  |  Branch (1008:9): [True: 435k, False: 236k]
  ------------------
 1009|   435k|        if ((param->maxalloc > 0) && (dst->writeb + len > param->maxalloc)) {
  ------------------
  |  Branch (1009:13): [True: 16.9k, False: 418k]
  |  Branch (1009:38): [True: 10, False: 16.9k]
  ------------------
 1010|     10|            RNP_LOG("attempt to alloc more then allowed");
  ------------------
  |  |   84|     10|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     10|    do {                                                                                 \
  |  |  |  |   77|     10|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     10|            break;                                                                       \
  |  |  |  |   79|     10|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1011|     10|            return RNP_ERROR_OUT_OF_MEMORY;
 1012|     10|        }
 1013|       |
 1014|       |        /* round up to the page boundary and do it exponentially */
 1015|   435k|        size_t alloc = ((dst->writeb + len) * 2 + 4095) / 4096 * 4096;
 1016|   435k|        if ((param->maxalloc > 0) && (alloc > param->maxalloc)) {
  ------------------
  |  Branch (1016:13): [True: 16.9k, False: 418k]
  |  Branch (1016:38): [True: 10, False: 16.9k]
  ------------------
 1017|     10|            alloc = param->maxalloc;
 1018|     10|        }
 1019|       |
 1020|   435k|        void *newalloc = param->secure ? calloc(1, alloc) : realloc(param->memory, alloc);
  ------------------
  |  Branch (1020:26): [True: 0, False: 435k]
  ------------------
 1021|   435k|        if (!newalloc) {
  ------------------
  |  Branch (1021:13): [True: 0, False: 435k]
  ------------------
 1022|      0|            return RNP_ERROR_OUT_OF_MEMORY;
 1023|      0|        }
 1024|   435k|        if (param->secure && param->memory) {
  ------------------
  |  Branch (1024:13): [True: 0, False: 435k]
  |  Branch (1024:30): [True: 0, False: 0]
  ------------------
 1025|      0|            memcpy(newalloc, param->memory, dst->writeb);
 1026|      0|            secure_clear(param->memory, dst->writeb);
 1027|      0|            free(param->memory);
 1028|      0|        }
 1029|   435k|        param->memory = newalloc;
 1030|   435k|        param->allocated = alloc;
 1031|   435k|    }
 1032|       |
 1033|   671k|    memcpy((uint8_t *) param->memory + dst->writeb, buf, len);
 1034|   671k|    return RNP_SUCCESS;
 1035|   671k|}
stream-common.cpp:_ZL13mem_dst_closeP10pgp_dest_tb:
 1039|   441k|{
 1040|   441k|    pgp_dest_mem_param_t *param = (pgp_dest_mem_param_t *) dst->param;
 1041|   441k|    if (!param) {
  ------------------
  |  Branch (1041:9): [True: 0, False: 441k]
  ------------------
 1042|      0|        return;
 1043|      0|    }
 1044|       |
 1045|   441k|    if (param->free) {
  ------------------
  |  Branch (1045:9): [True: 441k, False: 0]
  ------------------
 1046|   441k|        if (param->secure) {
  ------------------
  |  Branch (1046:13): [True: 0, False: 441k]
  ------------------
 1047|      0|            secure_clear(param->memory, param->allocated);
 1048|      0|        }
 1049|   441k|        free(param->memory);
 1050|   441k|    }
 1051|   441k|    free(param);
 1052|       |    dst->param = NULL;
 1053|   441k|}

_ZN10pgp_dest_tC2Ev:
  259|  1.00M|    pgp_dest_t() = default;
_ZN10pgp_dest_taSEOS_:
  262|   478k|    pgp_dest_t &operator=(pgp_dest_t &&) = default;
_ZN3rnp6SourceC2Ev:
  404|  62.7k|    Source() : src_({})
  405|  62.7k|    {
  406|  62.7k|    }
_ZN3rnp6SourceD2Ev:
  409|  62.7k|    {
  410|  62.7k|        src_.close();
  411|  62.7k|    }
_ZN3rnp6Source5readbEv:
  427|  49.8k|    {
  428|  49.8k|        return src().readb;
  429|  49.8k|    }
_ZN3rnp6Source3eofEv:
  433|   199k|    {
  434|   199k|        return src().eof();
  435|   199k|    }
_ZN3rnp6Source5errorEv:
  439|  74.2k|    {
  440|  74.2k|        return src().error();
  441|  74.2k|    }
_ZN3rnp4DestC2Ev:
  498|   418k|    Dest() : dst_(), discard_(false)
  499|   418k|    {
  500|   418k|    }
_ZN3rnp4DestD2Ev:
  503|   418k|    {
  504|   418k|        dst_close(&dst_, discard_);
  505|   418k|    }
_ZN3rnp4Dest3dstEv:
  521|   418k|    {
  522|   418k|        return dst_;
  523|   418k|    }
_ZN3rnp4Dest6writebEv:
  527|   418k|    {
  528|   418k|        return dst_.writeb;
  529|   418k|    }
_ZN3rnp10MemoryDestC2EPvm:
  543|   418k|    MemoryDest(void *mem = NULL, size_t len = 0) : Dest()
  544|   418k|    {
  545|   418k|        auto res = init_mem_dest(&dst_, mem, len);
  546|   418k|        if (res) {
  ------------------
  |  Branch (546:13): [True: 0, False: 418k]
  ------------------
  547|      0|            throw std::bad_alloc();
  548|      0|        }
  549|   418k|        discard_ = true;
  550|   418k|    }
_ZN3rnp10MemoryDest6memoryEv:
  554|   418k|    {
  555|   418k|        return mem_dest_get_memory(&dst_);
  556|   418k|    }
_ZN3rnp10MemoryDest9to_vectorEv:
  566|   418k|    {
  567|   418k|        uint8_t *mem = (uint8_t *) memory();
  568|   418k|        return std::vector<uint8_t>(mem, mem + writeb());
  569|   418k|    }

_ZN9rnp_ctx_t23add_encryption_passwordERKNSt3__112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE14pgp_hash_alg_t14pgp_symm_alg_tm:
   38|  8.42k|{
   39|  8.42k|    rnp_symmetric_pass_info_t info = {};
   40|       |
   41|  8.42k|    info.s2k.usage = PGP_S2KU_ENCRYPTED_AND_HASHED;
   42|  8.42k|    info.s2k.specifier = PGP_S2KS_ITERATED_AND_SALTED;
   43|  8.42k|    info.s2k.hash_alg = halg;
   44|  8.42k|    sec_ctx.rng.get(info.s2k.salt, info.s2k.salt_size(info.s2k.specifier));
   45|  8.42k|    if (!iterations) {
  ------------------
  |  Branch (45:9): [True: 0, False: 8.42k]
  ------------------
   46|      0|        iterations = sec_ctx.s2k_iterations(halg);
   47|      0|    }
   48|  8.42k|    if (!iterations) {
  ------------------
  |  Branch (48:9): [True: 0, False: 8.42k]
  ------------------
   49|      0|        return RNP_ERROR_BAD_PARAMETERS;
   50|      0|    }
   51|  8.42k|    info.s2k.iterations = pgp_s2k_encode_iterations(iterations);
   52|  8.42k|    info.s2k_cipher = ealg;
   53|       |    /* Note: we're relying on the fact that a longer-than-needed key length
   54|       |     * here does not change the entire derived key (it just generates unused
   55|       |     * extra bytes at the end). We derive a key of our maximum supported length,
   56|       |     * which is a bit wasteful.
   57|       |     *
   58|       |     * This is done because we do not yet know what cipher this key will actually
   59|       |     * end up being used with until later.
   60|       |     *
   61|       |     * An alternative would be to keep a list of actual passwords and s2k params,
   62|       |     * and save the key derivation for later.
   63|       |     */
   64|  8.42k|    if (!pgp_s2k_derive_key(&info.s2k, password.c_str(), info.key.data(), info.key.size())) {
  ------------------
  |  Branch (64:9): [True: 0, False: 8.42k]
  ------------------
   65|      0|        return RNP_ERROR_GENERIC;
   66|      0|    }
   67|  8.42k|    passwords.push_back(std::move(info));
   68|  8.42k|    return RNP_SUCCESS;
   69|  8.42k|}
_ZN9rnp_ctx_t15pkeskv6_capableEPN3rnp11KeyProviderE:
   78|     31|{
   79|       |    /* either the features flag is set, or the key version is >= v6 */
   80|     31|    for (auto *key : recipients) {
  ------------------
  |  Branch (80:20): [True: 31, False: 0]
  ------------------
   81|     31|        if (key->version() >= PGP_V6) {
  ------------------
  |  Branch (81:13): [True: 0, False: 31]
  ------------------
   82|      0|            continue;
   83|      0|        }
   84|       |
   85|     31|        rnp::Key *primary = NULL;
   86|     31|        if (key->is_primary()) {
  ------------------
  |  Branch (86:13): [True: 0, False: 31]
  ------------------
   87|      0|            primary = key;
   88|     31|        } else {
   89|     31|            if (key->has_primary_fp()) {
  ------------------
  |  Branch (89:17): [True: 31, False: 0]
  ------------------
   90|     31|                rnp::KeyFingerprintSearch fpsrch(key->primary_fp());
   91|     31|                primary = key_provider->request_key(fpsrch);
   92|     31|            }
   93|     31|        }
   94|       |
   95|     31|        if (!primary) {
  ------------------
  |  Branch (95:13): [True: 0, False: 31]
  ------------------
   96|       |            // can't find primary
   97|      0|            return false;
   98|      0|        }
   99|       |
  100|       |        /* get latest self sig */
  101|       |        /* if we have direct-key signature, then it has higher priority */
  102|     31|        rnp::Signature *dirsig = primary->latest_selfsig(rnp::UserID::None);
  103|     31|        if (dirsig) {
  ------------------
  |  Branch (103:13): [True: 0, False: 31]
  ------------------
  104|      0|            return dirsig->sig.key_has_features(PGP_KEY_FEATURE_SEIPDV2);
  105|      0|        }
  106|       |        /* if we have primary uid and it is more restrictive, then use it as well */
  107|     31|        rnp::Signature *prisig = primary->latest_selfsig(PGP_UID_PRIMARY);
  ------------------
  |  |   73|     31|#define PGP_UID_PRIMARY ((uint32_t) -2)
  ------------------
  108|     31|        if (prisig) {
  ------------------
  |  Branch (108:13): [True: 0, False: 31]
  ------------------
  109|      0|            return prisig->sig.key_has_features(PGP_KEY_FEATURE_SEIPDV2);
  110|      0|        }
  111|       |        /* if we don't have direct-key sig and primary uid, use the latest self-cert */
  112|     31|        rnp::Signature *latest = primary->latest_selfsig(PGP_UID_ANY);
  ------------------
  |  |   74|     31|#define PGP_UID_ANY ((uint32_t) -3)
  ------------------
  113|     31|        if (latest) {
  ------------------
  |  Branch (113:13): [True: 7, False: 24]
  ------------------
  114|      7|            return latest->sig.key_has_features(PGP_KEY_FEATURE_SEIPDV2);
  115|      7|        }
  116|       |        /* no applicable sig found */
  117|     24|        return false;
  118|     31|    }
  119|      0|    return true;
  120|     31|}

_ZN9rnp_ctx_tC2ERN3rnp15SecurityContextERNS0_11KeyProviderER23pgp_password_provider_t:
  135|  22.9k|        : halg(DEFAULT_PGP_HASH_ALG), ealg(DEFAULT_PGP_SYMM_ALG), aalg(PGP_AEAD_NONE),
  ------------------
  |  |   31|  22.9k|#define DEFAULT_PGP_HASH_ALG PGP_HASH_SHA256
  ------------------
                      : halg(DEFAULT_PGP_HASH_ALG), ealg(DEFAULT_PGP_SYMM_ALG), aalg(PGP_AEAD_NONE),
  ------------------
  |  |   34|  22.9k|#define DEFAULT_PGP_SYMM_ALG PGP_SA_AES_256
  ------------------
  136|  22.9k|          abits(DEFAULT_AEAD_CHUNK_BITS), sec_ctx(sctx), key_provider(kprov),
  ------------------
  |  |   50|  22.9k|#define DEFAULT_AEAD_CHUNK_BITS 12
  ------------------
  137|  22.9k|          pass_provider(pprov){};

_Z15error_skippablejb:
   85|  31.7k|{
   86|  31.7k|    if (ret == RNP_ERROR_NOT_SUPPORTED) {
  ------------------
  |  Branch (86:9): [True: 1.32k, False: 30.4k]
  ------------------
   87|  1.32k|        return true;
   88|  1.32k|    }
   89|  30.4k|    return skiperrors && (ret == RNP_ERROR_BAD_FORMAT);
  ------------------
  |  Branch (89:12): [True: 30.4k, False: 0]
  |  Branch (89:26): [True: 24.7k, False: 5.70k]
  ------------------
   90|  31.7k|}
_Z22skip_ignorable_packetsR12pgp_source_t:
  104|  1.38M|{
  105|  1.38M|    int pkt = stream_pkt_type(src);
  106|  1.38M|    while (pkt_is_ignorable(pkt)) {
  ------------------
  |  Branch (106:12): [True: 2.41k, False: 1.38M]
  ------------------
  107|  2.41k|        uint64_t ppos = src.readb;
  108|  2.41k|        RNP_LOG("skipping non-critical packet %d at %" PRIu64, pkt, ppos);
  ------------------
  |  |   84|  2.41k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.41k|    do {                                                                                 \
  |  |  |  |   77|  2.41k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.41k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.41k|            break;                                                                       \
  |  |  |  |   79|  2.41k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  109|  2.41k|        if (stream_skip_packet(&src)) {
  ------------------
  |  Branch (109:13): [True: 982, False: 1.42k]
  ------------------
  110|    982|            RNP_LOG("failed to skip packet at %" PRIu64, ppos);
  ------------------
  |  |   84|    982|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    982|    do {                                                                                 \
  |  |  |  |   77|    982|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 982, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    982|            break;                                                                       \
  |  |  |  |   79|    982|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  111|    982|            return false;
  112|    982|        }
  113|  1.42k|        pkt = stream_pkt_type(src);
  114|  1.42k|    }
  115|  1.38M|    return pkt >= 0;
  116|  1.38M|}
_Z18process_pgp_subkeyR12pgp_source_tR25pgp_transferable_subkey_tb:
  174|  14.8k|{
  175|  14.8k|    int ptag;
  176|  14.8k|    subkey = pgp_transferable_subkey_t();
  177|  14.8k|    uint64_t keypos = src.readb;
  178|  14.8k|    if (!skip_ignorable_packets(src) && src.error()) {
  ------------------
  |  Branch (178:9): [True: 0, False: 14.8k]
  |  Branch (178:41): [True: 0, False: 0]
  ------------------
  179|      0|        return RNP_ERROR_READ;
  180|      0|    }
  181|  14.8k|    if (!is_subkey_pkt(ptag = stream_pkt_type(src))) {
  ------------------
  |  Branch (181:9): [True: 0, False: 14.8k]
  ------------------
  182|      0|        RNP_LOG("wrong subkey ptag: %d at %" PRIu64, ptag, keypos);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  183|      0|        return RNP_ERROR_BAD_FORMAT;
  184|      0|    }
  185|       |
  186|  14.8k|    rnp_result_t ret = RNP_ERROR_BAD_FORMAT;
  187|  14.8k|    try {
  188|  14.8k|        ret = subkey.subkey.parse(src);
  189|  14.8k|    } catch (const std::exception &e) {
  190|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  191|      0|        ret = RNP_ERROR_GENERIC;
  192|      0|    }
  193|  14.8k|    if (ret) {
  ------------------
  |  Branch (193:9): [True: 2.12k, False: 12.7k]
  ------------------
  194|  2.12k|        RNP_LOG("failed to parse subkey at %" PRIu64, keypos);
  ------------------
  |  |   84|  2.12k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.12k|    do {                                                                                 \
  |  |  |  |   77|  2.12k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.12k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.12k|            break;                                                                       \
  |  |  |  |   79|  2.12k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  195|  2.12k|        subkey.subkey = {};
  196|  2.12k|        return ret;
  197|  2.12k|    }
  198|       |
  199|  12.7k|    if (!skip_pgp_packets(src, {PGP_PKT_TRUST})) {
  ------------------
  |  Branch (199:9): [True: 26, False: 12.7k]
  ------------------
  200|     26|        return RNP_ERROR_READ;
  201|     26|    }
  202|       |
  203|  12.7k|    return process_pgp_key_signatures(src, subkey.signatures, skiperrors);
  204|  12.7k|}
_Z20process_pgp_key_autoR12pgp_source_tR22pgp_transferable_key_tbb:
  211|  62.7k|{
  212|  62.7k|    key = {};
  213|  62.7k|    uint64_t srcpos = src.readb;
  214|  62.7k|    if (!skip_ignorable_packets(src) && src.error()) {
  ------------------
  |  Branch (214:9): [True: 225, False: 62.5k]
  |  Branch (214:41): [True: 0, False: 225]
  ------------------
  215|      0|        return RNP_ERROR_READ;
  216|      0|    }
  217|  62.7k|    int ptag = stream_pkt_type(src);
  218|  62.7k|    if (ptag <= 0) {
  ------------------
  |  Branch (218:9): [True: 45, False: 62.7k]
  ------------------
  219|       |        /* eof or invalid header: only ignorable packets were skipped, if any */
  220|     45|        RNP_LOG("wrong key tag: %d at pos %" PRIu64, ptag, src.readb);
  ------------------
  |  |   84|     45|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     45|    do {                                                                                 \
  |  |  |  |   77|     45|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 45, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     45|            break;                                                                       \
  |  |  |  |   79|     45|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  221|     45|        return (ptag == 0) ? RNP_ERROR_BAD_STATE : RNP_ERROR_BAD_FORMAT;
  ------------------
  |  Branch (221:16): [True: 45, False: 0]
  ------------------
  222|     45|    }
  223|  62.7k|    if (is_subkey_pkt(ptag) && allowsub) {
  ------------------
  |  Branch (223:9): [True: 19, False: 62.7k]
  |  Branch (223:32): [True: 0, False: 19]
  ------------------
  224|      0|        pgp_transferable_subkey_t subkey;
  225|      0|        rnp_result_t              ret = process_pgp_subkey(src, subkey, skiperrors);
  226|      0|        if (subkey.subkey.tag != PGP_PKT_RESERVED) {
  ------------------
  |  Branch (226:13): [True: 0, False: 0]
  ------------------
  227|      0|            try {
  228|      0|                key.subkeys.push_back(std::move(subkey));
  229|      0|            } catch (const std::exception &e) {
  230|      0|                RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  231|      0|                ret = RNP_ERROR_OUT_OF_MEMORY;
  232|      0|            }
  233|      0|        }
  234|       |        /* change error code if we didn't process anything at all */
  235|      0|        if (srcpos == src.readb) {
  ------------------
  |  Branch (235:13): [True: 0, False: 0]
  ------------------
  236|      0|            ret = RNP_ERROR_BAD_STATE;
  237|      0|        }
  238|      0|        return ret;
  239|      0|    }
  240|       |
  241|  62.7k|    rnp_result_t ret = RNP_ERROR_BAD_FORMAT;
  242|  62.7k|    if (!is_primary_key_pkt(ptag)) {
  ------------------
  |  Branch (242:9): [True: 11.8k, False: 50.8k]
  ------------------
  243|  11.8k|        RNP_LOG("wrong key tag: %d at pos %" PRIu64, ptag, src.readb);
  ------------------
  |  |   84|  11.8k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  11.8k|    do {                                                                                 \
  |  |  |  |   77|  11.8k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11.8k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  11.8k|            break;                                                                       \
  |  |  |  |   79|  11.8k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  244|  50.8k|    } else {
  245|  50.8k|        try {
  246|  50.8k|            ret = process_pgp_key(src, key, skiperrors);
  247|  50.8k|        } catch (const rnp::rnp_exception &e) {
  248|  1.03k|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|  1.03k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.03k|    do {                                                                                 \
  |  |  |  |   77|  1.03k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.03k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.03k|            break;                                                                       \
  |  |  |  |   79|  1.03k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  249|  1.03k|            ret = e.code();
  250|  1.03k|        } catch (const std::exception &e) {
  251|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  252|      0|            ret = RNP_ERROR_GENERIC;
  253|      0|        }
  254|  50.8k|    }
  255|  62.7k|    if (skiperrors && (ret == RNP_ERROR_BAD_FORMAT) &&
  ------------------
  |  Branch (255:9): [True: 62.7k, False: 0]
  |  Branch (255:9): [True: 1.11k, False: 61.6k]
  |  Branch (255:23): [True: 29.9k, False: 32.8k]
  ------------------
  256|  29.9k|        !skip_pgp_packets(src,
  ------------------
  |  Branch (256:9): [True: 1.11k, False: 28.7k]
  ------------------
  257|  29.9k|                          {PGP_PKT_TRUST,
  258|  29.9k|                           PGP_PKT_SIGNATURE,
  259|  29.9k|                           PGP_PKT_USER_ID,
  260|  29.9k|                           PGP_PKT_USER_ATTR,
  261|  29.9k|                           PGP_PKT_PUBLIC_SUBKEY,
  262|  29.9k|                           PGP_PKT_SECRET_SUBKEY})) {
  263|  1.11k|        ret = RNP_ERROR_READ;
  264|  1.11k|    }
  265|       |    /* change error code if we didn't process anything at all */
  266|  62.7k|    if (srcpos == src.readb) {
  ------------------
  |  Branch (266:9): [True: 4.06k, False: 58.6k]
  ------------------
  267|  4.06k|        ret = RNP_ERROR_BAD_STATE;
  268|  4.06k|    }
  269|  62.7k|    return ret;
  270|  62.7k|}
_Z16process_pgp_keysR12pgp_source_tR18pgp_key_sequence_tb:
  274|  11.8k|{
  275|  11.8k|    bool has_secret = false;
  276|  11.8k|    bool has_public = false;
  277|       |
  278|  11.8k|    keys.keys.clear();
  279|       |    /* create maybe-armored stream */
  280|  11.8k|    rnp::ArmoredSource armor(
  281|  11.8k|      src, rnp::ArmoredSource::AllowBinary | rnp::ArmoredSource::AllowMultiple);
  282|       |
  283|       |    /* read sequence of transferable OpenPGP keys as described in RFC 4880, 11.1 - 11.2 */
  284|  69.0k|    while (!armor.error()) {
  ------------------
  |  Branch (284:12): [True: 68.3k, False: 706]
  ------------------
  285|       |        /* Allow multiple armored messages in a single stream */
  286|  68.3k|        if (armor.eof() && armor.multiple()) {
  ------------------
  |  Branch (286:13): [True: 8.12k, False: 60.1k]
  |  Branch (286:28): [True: 3.17k, False: 4.95k]
  ------------------
  287|  3.17k|            armor.restart();
  288|  3.17k|        }
  289|  68.3k|        if (armor.eof()) {
  ------------------
  |  Branch (289:13): [True: 4.98k, False: 63.3k]
  ------------------
  290|  4.98k|            break;
  291|  4.98k|        }
  292|       |        /* RFC 9580, 4.3: ignore unknown non-critical and padding packets anywhere
  293|       |         * in the sequence */
  294|  63.3k|        if (!skip_ignorable_packets(armor.src()) && armor.error()) {
  ------------------
  |  Branch (294:13): [True: 711, False: 62.6k]
  |  Branch (294:53): [True: 219, False: 492]
  ------------------
  295|    219|            keys.keys.clear();
  296|    219|            return RNP_ERROR_READ;
  297|    219|        }
  298|  63.1k|        if (armor.eof()) {
  ------------------
  |  Branch (298:13): [True: 262, False: 62.8k]
  ------------------
  299|    262|            break;
  300|    262|        }
  301|       |        /* Attempt to read the next key */
  302|  62.8k|        pgp_transferable_key_t curkey;
  303|  62.8k|        rnp_result_t ret = process_pgp_key_auto(armor.src(), curkey, false, skiperrors);
  304|  62.8k|        if (ret && !error_skippable(ret, skiperrors)) {
  ------------------
  |  Branch (304:13): [True: 31.7k, False: 31.0k]
  |  Branch (304:20): [True: 5.70k, False: 26.0k]
  ------------------
  305|  5.70k|            keys.keys.clear();
  306|  5.70k|            return ret;
  307|  5.70k|        }
  308|       |        /* check whether we actually read any key or just skipped erroneous packets */
  309|  57.1k|        if (curkey.key.tag == PGP_PKT_RESERVED) {
  ------------------
  |  Branch (309:13): [True: 25.8k, False: 31.2k]
  ------------------
  310|  25.8k|            continue;
  311|  25.8k|        }
  312|  31.2k|        has_secret |= (curkey.key.tag == PGP_PKT_SECRET_KEY);
  313|       |        /* public primary key with secret subkey(s) is not a public key, see #1469 */
  314|  31.2k|        if (curkey.key.tag == PGP_PKT_PUBLIC_KEY) {
  ------------------
  |  Branch (314:13): [True: 22.8k, False: 8.41k]
  ------------------
  315|  22.8k|            bool sec_sub = false;
  316|  22.8k|            for (auto &subkey : curkey.subkeys) {
  ------------------
  |  Branch (316:31): [True: 6.51k, False: 22.8k]
  ------------------
  317|  6.51k|                sec_sub |= (subkey.subkey.tag == PGP_PKT_SECRET_SUBKEY);
  318|  6.51k|            }
  319|  22.8k|            has_public |= !sec_sub;
  320|  22.8k|        }
  321|       |
  322|  31.2k|        keys.keys.emplace_back(std::move(curkey));
  323|  31.2k|    }
  324|       |
  325|  5.95k|    if (has_secret && has_public) {
  ------------------
  |  Branch (325:9): [True: 1.23k, False: 4.71k]
  |  Branch (325:23): [True: 255, False: 982]
  ------------------
  326|    255|        RNP_LOG("warning! public keys are mixed together with secret ones!");
  ------------------
  |  |   84|    255|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    255|    do {                                                                                 \
  |  |  |  |   77|    255|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 255, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    255|            break;                                                                       \
  |  |  |  |   79|    255|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  327|    255|    }
  328|       |
  329|  5.95k|    if (armor.error()) {
  ------------------
  |  Branch (329:9): [True: 0, False: 5.95k]
  ------------------
  330|      0|        keys.keys.clear();
  331|      0|        return RNP_ERROR_READ;
  332|      0|    }
  333|  5.95k|    return RNP_SUCCESS;
  334|  5.95k|}
_Z15process_pgp_keyR12pgp_source_tR22pgp_transferable_key_tb:
  338|  50.8k|{
  339|  50.8k|    key = pgp_transferable_key_t();
  340|       |    /* create maybe-armored stream */
  341|  50.8k|    rnp::ArmoredSource armor(
  342|  50.8k|      src, rnp::ArmoredSource::AllowBinary | rnp::ArmoredSource::AllowMultiple);
  343|       |
  344|       |    /* main key packet */
  345|  50.8k|    uint64_t keypos = armor.readb();
  346|  50.8k|    int      ptag = stream_pkt_type(armor.src());
  347|  50.8k|    if ((ptag <= 0) || !is_primary_key_pkt(ptag)) {
  ------------------
  |  Branch (347:9): [True: 1.95k, False: 48.9k]
  |  Branch (347:24): [True: 251, False: 48.6k]
  ------------------
  348|  1.17k|        RNP_LOG("wrong key packet tag: %d at %" PRIu64, ptag, keypos);
  ------------------
  |  |   84|  1.17k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.17k|    do {                                                                                 \
  |  |  |  |   77|  1.17k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.17k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.17k|            break;                                                                       \
  |  |  |  |   79|  1.17k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  349|  1.17k|        return RNP_ERROR_BAD_FORMAT;
  350|  1.17k|    }
  351|       |
  352|  49.7k|    rnp_result_t ret = key.key.parse(armor.src());
  353|  49.7k|    if (ret == RNP_ERROR_NOT_SUPPORTED) {
  ------------------
  |  Branch (353:9): [True: 1.27k, False: 48.4k]
  ------------------
  354|       |        /* unknown or unsupported-in-this-build key algorithm: skip the rest of
  355|       |         * this transferable key (user ids, subkeys) and let the caller continue
  356|       |         * with the next one, see issue #2370 */
  357|  1.27k|        RNP_LOG("skipping key with unsupported algorithm at %" PRIu64, keypos);
  ------------------
  |  |   84|  1.27k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.27k|    do {                                                                                 \
  |  |  |  |   77|  1.27k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.27k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.27k|            break;                                                                       \
  |  |  |  |   79|  1.27k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  358|  1.27k|        key.key = {};
  359|  1.27k|        skip_pgp_packets(armor.src(),
  360|  1.27k|                         {PGP_PKT_TRUST,
  361|  1.27k|                          PGP_PKT_SIGNATURE,
  362|  1.27k|                          PGP_PKT_USER_ID,
  363|  1.27k|                          PGP_PKT_USER_ATTR,
  364|  1.27k|                          PGP_PKT_PUBLIC_SUBKEY,
  365|  1.27k|                          PGP_PKT_SECRET_SUBKEY});
  366|  1.27k|        return ret;
  367|  1.27k|    }
  368|  48.4k|    if (ret) {
  ------------------
  |  Branch (368:9): [True: 15.8k, False: 32.6k]
  ------------------
  369|  15.8k|        RNP_LOG("failed to parse key pkt at %" PRIu64, keypos);
  ------------------
  |  |   84|  15.8k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  15.8k|    do {                                                                                 \
  |  |  |  |   77|  15.8k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15.8k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  15.8k|            break;                                                                       \
  |  |  |  |   79|  15.8k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  370|  15.8k|        key.key = {};
  371|  15.8k|        return ret;
  372|  15.8k|    }
  373|       |
  374|  32.6k|    if (!skip_pgp_packets(armor.src(), {PGP_PKT_TRUST})) {
  ------------------
  |  Branch (374:9): [True: 78, False: 32.5k]
  ------------------
  375|     78|        return RNP_ERROR_READ;
  376|     78|    }
  377|       |
  378|       |    /* direct-key signatures */
  379|  32.5k|    if ((ret = process_pgp_key_signatures(armor.src(), key.signatures, skiperrors))) {
  ------------------
  |  Branch (379:9): [True: 42, False: 32.4k]
  ------------------
  380|     42|        return ret;
  381|     42|    }
  382|       |
  383|       |    /* user ids/attrs with signatures */
  384|   449k|    while (true) {
  ------------------
  |  Branch (384:12): [True: 448k, Folded]
  ------------------
  385|   448k|        if (!skip_ignorable_packets(armor.src()) && armor.src().error()) {
  ------------------
  |  Branch (385:13): [True: 26, False: 448k]
  |  Branch (385:53): [True: 0, False: 26]
  ------------------
  386|      0|            return RNP_ERROR_READ;
  387|      0|        }
  388|   448k|        if ((ptag = stream_pkt_type(armor.src())) <= 0) {
  ------------------
  |  Branch (388:13): [True: 4.10k, False: 444k]
  ------------------
  389|  4.10k|            break;
  390|  4.10k|        }
  391|   444k|        if ((ptag != PGP_PKT_USER_ID) && (ptag != PGP_PKT_USER_ATTR)) {
  ------------------
  |  Branch (391:13): [True: 32.7k, False: 411k]
  |  Branch (391:42): [True: 27.2k, False: 5.56k]
  ------------------
  392|  27.2k|            break;
  393|  27.2k|        }
  394|       |
  395|   416k|        pgp_transferable_userid_t uid;
  396|   416k|        ret = process_pgp_userid(armor.src(), uid, skiperrors);
  397|   416k|        if ((ret == RNP_ERROR_BAD_FORMAT) && skiperrors &&
  ------------------
  |  Branch (397:13): [True: 1.62k, False: 415k]
  |  Branch (397:13): [True: 1.59k, False: 415k]
  |  Branch (397:46): [True: 1.62k, False: 0]
  ------------------
  398|  1.62k|            skip_pgp_packets(armor.src(), {PGP_PKT_TRUST, PGP_PKT_SIGNATURE})) {
  ------------------
  |  Branch (398:13): [True: 1.59k, False: 30]
  ------------------
  399|       |            /* skip malformed uid */
  400|  1.59k|            continue;
  401|  1.59k|        }
  402|   415k|        if (ret) {
  ------------------
  |  Branch (402:13): [True: 156, False: 415k]
  ------------------
  403|    156|            return ret;
  404|    156|        }
  405|   415k|        key.userids.push_back(std::move(uid));
  406|   415k|    }
  407|       |
  408|       |    /* subkeys with signatures */
  409|  46.0k|    while (ptag > 0) {
  ------------------
  |  Branch (409:12): [True: 40.9k, False: 5.14k]
  ------------------
  410|  40.9k|        if (!skip_ignorable_packets(armor.src()) && armor.src().error()) {
  ------------------
  |  Branch (410:13): [True: 33, False: 40.9k]
  |  Branch (410:53): [True: 0, False: 33]
  ------------------
  411|      0|            return RNP_ERROR_READ;
  412|      0|        }
  413|  40.9k|        if (!is_subkey_pkt(ptag = stream_pkt_type(armor.src()))) {
  ------------------
  |  Branch (413:13): [True: 26.9k, False: 14.0k]
  ------------------
  414|  26.9k|            break;
  415|  26.9k|        }
  416|       |
  417|  14.0k|        pgp_transferable_subkey_t subkey;
  418|  14.0k|        ret = process_pgp_subkey(armor.src(), subkey, skiperrors);
  419|  14.0k|        if (((ret == RNP_ERROR_BAD_FORMAT) && skiperrors ||
  ------------------
  |  Branch (419:13): [True: 1.75k, False: 12.2k]
  |  Branch (419:14): [True: 1.62k, False: 12.3k]
  |  Branch (419:47): [True: 1.62k, False: 0]
  ------------------
  420|  12.3k|             (ret == RNP_ERROR_NOT_SUPPORTED)) &&
  ------------------
  |  Branch (420:14): [True: 316, False: 12.0k]
  ------------------
  421|  1.94k|            skip_pgp_packets(armor.src(), {PGP_PKT_TRUST, PGP_PKT_SIGNATURE})) {
  ------------------
  |  Branch (421:13): [True: 1.75k, False: 187]
  ------------------
  422|       |            /* skip malformed subkey or subkey with unsupported algorithm */
  423|  1.75k|            continue;
  424|  1.75k|        }
  425|  12.2k|        if (ret) {
  ------------------
  |  Branch (425:13): [True: 248, False: 12.0k]
  ------------------
  426|    248|            return ret;
  427|    248|        }
  428|  12.0k|        key.subkeys.emplace_back(std::move(subkey));
  429|  12.0k|    }
  430|  32.0k|    return ptag >= 0 ? RNP_SUCCESS : RNP_ERROR_BAD_FORMAT;
  ------------------
  |  Branch (430:12): [True: 31.0k, False: 1.04k]
  ------------------
  431|  32.3k|}
_Z18decrypt_secret_keyP13pgp_key_pkt_tPKc:
  653|    227|{
  654|    227|    if (!key) {
  ------------------
  |  Branch (654:9): [True: 0, False: 227]
  ------------------
  655|      0|        return RNP_ERROR_NULL_POINTER;
  656|      0|    }
  657|    227|    if (!is_secret_key_pkt(key->tag)) {
  ------------------
  |  Branch (657:9): [True: 0, False: 227]
  ------------------
  658|      0|        return RNP_ERROR_BAD_PARAMETERS;
  659|      0|    }
  660|       |    /* mark material as not validated as it may be valid for public part */
  661|    227|    key->material->reset_validity();
  662|       |
  663|       |    /* check whether data is not encrypted */
  664|    227|    if (!key->sec_protection.s2k.usage) {
  ------------------
  |  Branch (664:9): [True: 227, False: 0]
  ------------------
  665|    227|        return parse_secret_key_mpis(*key, key->sec_data.data(), key->sec_data.size());
  666|    227|    }
  667|       |
  668|       |    /* check whether secret key data present */
  669|      0|    if (key->sec_data.empty()) {
  ------------------
  |  Branch (669:9): [True: 0, False: 0]
  ------------------
  670|      0|        RNP_LOG("No secret key data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  671|      0|        return RNP_ERROR_BAD_PARAMETERS;
  672|      0|    }
  673|       |
  674|       |    /* data is encrypted */
  675|      0|    if (!password) {
  ------------------
  |  Branch (675:9): [True: 0, False: 0]
  ------------------
  676|      0|        return RNP_ERROR_NULL_POINTER;
  677|      0|    }
  678|       |
  679|      0|    if (key->sec_protection.cipher_mode != PGP_CIPHER_MODE_CFB) {
  ------------------
  |  Branch (679:9): [True: 0, False: 0]
  ------------------
  680|      0|        RNP_LOG("unsupported secret key encryption mode");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  681|      0|        return RNP_ERROR_BAD_PARAMETERS;
  682|      0|    }
  683|       |
  684|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  685|      0|    if ((key->sec_protection.s2k.specifier == PGP_S2KS_ARGON2) &&
  ------------------
  |  Branch (685:9): [True: 0, False: 0]
  ------------------
  686|      0|        key->sec_protection.s2k.usage != PGP_S2KU_AEAD) {
  ------------------
  |  Branch (686:9): [True: 0, False: 0]
  ------------------
  687|      0|        RNP_LOG("s2k usage must be AEAD if using Argon2");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  688|      0|        return RNP_ERROR_BAD_PARAMETERS;
  689|      0|    }
  690|      0|#endif
  691|       |
  692|      0|    rnp::secure_array<uint8_t, PGP_MAX_KEY_SIZE> keybuf;
  693|      0|    size_t keysize = pgp_key_size(key->sec_protection.symm_alg);
  694|      0|    if (!keysize ||
  ------------------
  |  Branch (694:9): [True: 0, False: 0]
  ------------------
  695|      0|        !pgp_s2k_derive_key(&key->sec_protection.s2k, password, keybuf.data(), keysize)) {
  ------------------
  |  Branch (695:9): [True: 0, False: 0]
  ------------------
  696|      0|        RNP_LOG("failed to derive key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  697|      0|        return RNP_ERROR_BAD_PARAMETERS;
  698|      0|    }
  699|       |
  700|      0|    try {
  701|      0|        rnp::secure_bytes decdata(key->sec_data.size(), 0);
  702|      0|        pgp_crypt_t       crypt;
  703|      0|        rnp_result_t      ret = RNP_ERROR_GENERIC;
  704|       |
  705|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  706|       |        /* AEAD case */
  707|      0|        if (key->sec_protection.s2k.usage == PGP_S2KU_AEAD) {
  ------------------
  |  Branch (707:13): [True: 0, False: 0]
  ------------------
  708|       |            /* HKDF input keying material is exactly the s2k-derived key */
  709|      0|            rnp::secure_vector<uint8_t> keybuf_vec(keybuf.data(), keybuf.data() + keysize);
  710|      0|            rnp::secure_vector<uint8_t> encr_vec(key->sec_data.data(),
  711|      0|                                                 key->sec_data.data() + key->sec_data.size());
  712|       |
  713|      0|            ret = crypt_secret_key_aead(key, keybuf_vec, encr_vec, decdata, true);
  714|      0|            if (ret) {
  ------------------
  |  Branch (714:17): [True: 0, False: 0]
  ------------------
  715|      0|                RNP_LOG("could not successfully decrypt key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  716|      0|                return ret;
  717|      0|            }
  718|       |
  719|       |            // subtract authentication tag length to get the encrypted data length
  720|      0|            size_t sec_len =
  721|      0|              key->sec_data.size() - pgp_cipher_aead_tag_len(key->sec_protection.aead_alg);
  722|      0|            return parse_secret_key_mpis(*key, decdata.data(), sec_len);
  723|      0|        }
  724|      0|#endif
  725|       |
  726|      0|        if (!pgp_cipher_cfb_start(
  ------------------
  |  Branch (726:13): [True: 0, False: 0]
  ------------------
  727|      0|              &crypt, key->sec_protection.symm_alg, keybuf.data(), key->sec_protection.iv)) {
  728|      0|            RNP_LOG("failed to start cfb decryption");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  729|      0|            return RNP_ERROR_DECRYPT_FAILED;
  730|      0|        }
  731|       |
  732|      0|        switch (key->version) {
  733|      0|        case PGP_V3:
  ------------------
  |  Branch (733:9): [True: 0, False: 0]
  ------------------
  734|      0|            if (!is_rsa_key_alg(key->alg)) {
  ------------------
  |  Branch (734:17): [True: 0, False: 0]
  ------------------
  735|      0|                RNP_LOG("non-RSA v3 key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  736|      0|                ret = RNP_ERROR_BAD_PARAMETERS;
  737|      0|                break;
  738|      0|            }
  739|      0|            ret = decrypt_secret_key_v3(
  740|      0|              &crypt, decdata.data(), key->sec_data.data(), key->sec_data.size());
  741|      0|            break;
  742|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  743|      0|        case PGP_V6:
  ------------------
  |  Branch (743:9): [True: 0, False: 0]
  ------------------
  744|      0|            FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|      0|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  745|      0|#endif
  746|      0|        case PGP_V4:
  ------------------
  |  Branch (746:9): [True: 0, False: 0]
  ------------------
  747|      0|        case PGP_V5:
  ------------------
  |  Branch (747:9): [True: 0, False: 0]
  ------------------
  748|      0|            pgp_cipher_cfb_decrypt(
  749|      0|              &crypt, decdata.data(), key->sec_data.data(), key->sec_data.size());
  750|      0|            ret = RNP_SUCCESS;
  751|      0|            break;
  752|      0|        default:
  ------------------
  |  Branch (752:9): [True: 0, False: 0]
  ------------------
  753|      0|            ret = RNP_ERROR_BAD_PARAMETERS;
  754|      0|        }
  755|       |
  756|      0|        pgp_cipher_cfb_finish(&crypt);
  757|      0|        if (ret) {
  ------------------
  |  Branch (757:13): [True: 0, False: 0]
  ------------------
  758|      0|            return ret;
  759|      0|        }
  760|       |
  761|      0|        return parse_secret_key_mpis(*key, decdata.data(), decdata.size());
  762|      0|    } catch (const std::exception &e) {
  763|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  764|      0|        return RNP_ERROR_GENERIC;
  765|      0|    }
  766|      0|}
_ZNK16pgp_userid_pkt_teqERKS_:
  943|  1.10M|{
  944|  1.10M|    return (tag == src.tag) && (uid == src.uid);
  ------------------
  |  Branch (944:12): [True: 1.01M, False: 85.5k]
  |  Branch (944:32): [True: 284k, False: 730k]
  ------------------
  945|  1.10M|}
_ZNK16pgp_userid_pkt_t5writeER10pgp_dest_t:
  954|   322k|{
  955|   322k|    if ((tag != PGP_PKT_USER_ID) && (tag != PGP_PKT_USER_ATTR)) {
  ------------------
  |  Branch (955:9): [True: 4.65k, False: 317k]
  |  Branch (955:37): [True: 0, False: 4.65k]
  ------------------
  956|      0|        RNP_LOG("wrong userid tag");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  957|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  958|      0|    }
  959|       |
  960|   322k|    pgp_packet_body_t pktbody(tag);
  961|   322k|    pktbody.add(uid.data(), uid.size());
  962|   322k|    pktbody.write(dst);
  963|   322k|}
_ZN16pgp_userid_pkt_t5parseER12pgp_source_t:
  967|   416k|{
  968|       |    /* check the tag */
  969|   416k|    int stag = stream_pkt_type(src);
  970|   416k|    if ((stag != PGP_PKT_USER_ID) && (stag != PGP_PKT_USER_ATTR)) {
  ------------------
  |  Branch (970:9): [True: 5.56k, False: 411k]
  |  Branch (970:38): [True: 0, False: 5.56k]
  ------------------
  971|      0|        RNP_LOG("wrong userid tag: %d", stag);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  972|      0|        return RNP_ERROR_BAD_FORMAT;
  973|      0|    }
  974|       |
  975|   416k|    pgp_packet_body_t pkt(PGP_PKT_RESERVED);
  976|   416k|    rnp_result_t      res = pkt.read(src);
  977|   416k|    if (res) {
  ------------------
  |  Branch (977:9): [True: 1.64k, False: 415k]
  ------------------
  978|  1.64k|        return res;
  979|  1.64k|    }
  980|       |
  981|       |    /* userid type, i.e. tag */
  982|   415k|    tag = (pgp_pkt_type_t) stag;
  983|   415k|    uid.resize(pkt.size());
  984|   415k|    if (pkt.size()) {
  ------------------
  |  Branch (984:9): [True: 28.9k, False: 386k]
  ------------------
  985|  28.9k|        std::memcpy(uid.data(), pkt.data(), pkt.size());
  986|  28.9k|    }
  987|   415k|    return RNP_SUCCESS;
  988|   416k|}
_ZN13pgp_key_pkt_tC2ERKS_b:
  991|   167k|{
  992|   167k|    if (pubonly && is_secret_key_pkt(src.tag)) {
  ------------------
  |  Branch (992:9): [True: 20.3k, False: 146k]
  |  Branch (992:20): [True: 3.88k, False: 16.4k]
  ------------------
  993|  3.88k|        tag = (src.tag == PGP_PKT_SECRET_KEY) ? PGP_PKT_PUBLIC_KEY : PGP_PKT_PUBLIC_SUBKEY;
  ------------------
  |  Branch (993:15): [True: 2.03k, False: 1.85k]
  ------------------
  994|   163k|    } else {
  995|   163k|        tag = src.tag;
  996|   163k|    }
  997|   167k|    version = src.version;
  998|   167k|    creation_time = src.creation_time;
  999|   167k|    alg = src.alg;
 1000|   167k|    v3_days = src.v3_days;
 1001|   167k|    v5_pub_len = src.v5_pub_len;
 1002|   167k|    pub_data = src.pub_data;
 1003|   167k|    material = src.material ? src.material->clone() : nullptr;
  ------------------
  |  Branch (1003:16): [True: 167k, False: 0]
  ------------------
 1004|   167k|    if (pubonly) {
  ------------------
  |  Branch (1004:9): [True: 20.3k, False: 146k]
  ------------------
 1005|  20.3k|        if (material) {
  ------------------
  |  Branch (1005:13): [True: 20.3k, False: 0]
  ------------------
 1006|  20.3k|            material->clear_secret();
 1007|  20.3k|        }
 1008|  20.3k|        sec_data.resize(0);
 1009|  20.3k|        v5_s2k_len = 0;
 1010|  20.3k|        v5_sec_len = 0;
 1011|  20.3k|        sec_protection = {};
 1012|  20.3k|        return;
 1013|  20.3k|    }
 1014|   146k|    sec_data = src.sec_data;
 1015|   146k|    v5_s2k_len = src.v5_s2k_len;
 1016|   146k|    v5_sec_len = src.v5_sec_len;
 1017|   146k|    sec_protection = src.sec_protection;
 1018|   146k|}
_ZN13pgp_key_pkt_taSEOS_:
 1038|   188k|{
 1039|   188k|    if (this == &src) {
  ------------------
  |  Branch (1039:9): [True: 0, False: 188k]
  ------------------
 1040|      0|        return *this;
 1041|      0|    }
 1042|   188k|    tag = src.tag;
 1043|   188k|    version = src.version;
 1044|   188k|    creation_time = src.creation_time;
 1045|   188k|    alg = src.alg;
 1046|   188k|    v3_days = src.v3_days;
 1047|   188k|    pub_data = std::move(src.pub_data);
 1048|   188k|    material = std::move(src.material);
 1049|   188k|    secure_clear(sec_data.data(), sec_data.size());
 1050|   188k|    sec_data = std::move(src.sec_data);
 1051|   188k|    sec_protection = src.sec_protection;
 1052|   188k|    return *this;
 1053|   188k|}
_ZN13pgp_key_pkt_taSERKS_:
 1057|   170k|{
 1058|   170k|    if (this == &src) {
  ------------------
  |  Branch (1058:9): [True: 0, False: 170k]
  ------------------
 1059|      0|        return *this;
 1060|      0|    }
 1061|   170k|    tag = src.tag;
 1062|   170k|    version = src.version;
 1063|   170k|    creation_time = src.creation_time;
 1064|   170k|    alg = src.alg;
 1065|   170k|    v3_days = src.v3_days;
 1066|   170k|    pub_data = src.pub_data;
 1067|   170k|    material = src.material ? src.material->clone() : nullptr;
  ------------------
  |  Branch (1067:16): [True: 41.4k, False: 128k]
  ------------------
 1068|   170k|    secure_clear(sec_data.data(), sec_data.size());
 1069|   170k|    sec_data = std::move(src.sec_data);
 1070|   170k|    sec_protection = src.sec_protection;
 1071|   170k|    return *this;
 1072|   170k|}
_ZN13pgp_key_pkt_tD2Ev:
 1075|   603k|{
 1076|   603k|    secure_clear(sec_data.data(), sec_data.size());
 1077|   603k|}
_ZN13pgp_key_pkt_t15make_s2k_paramsER17pgp_packet_body_t:
 1081|  10.6k|{
 1082|  10.6k|    switch (sec_protection.s2k.usage) {
 1083|      6|    case PGP_S2KU_NONE:
  ------------------
  |  Branch (1083:5): [True: 6, False: 10.6k]
  ------------------
 1084|      6|        break;
 1085|  6.17k|    case PGP_S2KU_ENCRYPTED_AND_HASHED:
  ------------------
  |  Branch (1085:5): [True: 6.17k, False: 4.46k]
  ------------------
 1086|  10.5k|    case PGP_S2KU_ENCRYPTED: {
  ------------------
  |  Branch (1086:5): [True: 4.42k, False: 6.21k]
  ------------------
 1087|  10.5k|        hbody.add_byte(sec_protection.symm_alg);
 1088|  10.5k|        hbody.add(sec_protection.s2k, version);
 1089|  10.5k|        if (sec_protection.s2k.specifier != PGP_S2KS_EXPERIMENTAL) {
  ------------------
  |  Branch (1089:13): [True: 6.09k, False: 4.50k]
  ------------------
 1090|  6.09k|            size_t blsize = pgp_block_size(sec_protection.symm_alg);
 1091|  6.09k|            if (!blsize) {
  ------------------
  |  Branch (1091:17): [True: 0, False: 6.09k]
  ------------------
 1092|      0|                RNP_LOG("wrong block size");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1093|      0|                throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1094|      0|            }
 1095|  6.09k|            hbody.add(sec_protection.iv, blsize);
 1096|  6.09k|        }
 1097|  10.5k|        break;
 1098|  10.5k|    }
 1099|  10.5k|#if defined(ENABLE_CRYPTO_REFRESH)
 1100|  10.5k|    case PGP_S2KU_AEAD: {
  ------------------
  |  Branch (1100:5): [True: 30, False: 10.6k]
  ------------------
 1101|     30|        hbody.add_byte(sec_protection.symm_alg);
 1102|     30|        hbody.add_byte(sec_protection.aead_alg);
 1103|     30|        hbody.add(sec_protection.s2k, version);
 1104|     30|        size_t nonce_len = pgp_cipher_aead_nonce_len(sec_protection.aead_alg);
 1105|     30|        if (!nonce_len) {
  ------------------
  |  Branch (1105:13): [True: 6, False: 24]
  ------------------
 1106|      6|            RNP_LOG("invalid nonce size");
  ------------------
  |  |   84|      6|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      6|    do {                                                                                 \
  |  |  |  |   77|      6|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 6, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      6|            break;                                                                       \
  |  |  |  |   79|      6|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1107|      6|            throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1108|      6|        }
 1109|     24|        hbody.add(sec_protection.iv, nonce_len);
 1110|     24|        break;
 1111|     30|    }
 1112|      0|#endif
 1113|      0|    default:
  ------------------
  |  Branch (1113:5): [True: 0, False: 10.6k]
  ------------------
 1114|      0|        RNP_LOG("wrong s2k usage");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1115|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1116|  10.6k|    }
 1117|  10.6k|}
_ZN13pgp_key_pkt_t5writeER10pgp_dest_t:
 1121|  55.3k|{
 1122|  55.3k|    if (!is_key_pkt(tag)) {
  ------------------
  |  Branch (1122:9): [True: 0, False: 55.3k]
  ------------------
 1123|      0|        RNP_LOG("wrong key tag");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1124|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1125|      0|    }
 1126|  55.3k|    if (pub_data.empty()) {
  ------------------
  |  Branch (1126:9): [True: 0, False: 55.3k]
  ------------------
 1127|      0|        fill_hashed_data();
 1128|      0|    }
 1129|       |
 1130|  55.3k|    pgp_packet_body_t pktbody(tag);
 1131|       |    /* all public key data is written in hashed_data */
 1132|  55.3k|    pktbody.add(pub_data);
 1133|       |    /* if we have public key then we do not need further processing */
 1134|  55.3k|    if (!is_secret_key_pkt(tag)) {
  ------------------
  |  Branch (1134:9): [True: 44.6k, False: 10.6k]
  ------------------
 1135|  44.6k|        pktbody.write(dst);
 1136|  44.6k|        return;
 1137|  44.6k|    }
 1138|       |
 1139|       |    /* secret key fields should be pre-populated in sec_data field */
 1140|  10.6k|    if ((sec_protection.s2k.specifier != PGP_S2KS_EXPERIMENTAL) && sec_data.empty()) {
  ------------------
  |  Branch (1140:9): [True: 6.12k, False: 4.51k]
  |  Branch (1140:68): [True: 4, False: 6.11k]
  ------------------
 1141|      4|        RNP_LOG("secret key data is not populated");
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1142|      4|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1143|      4|    }
 1144|  10.6k|    pktbody.add_byte(sec_protection.s2k.usage);
 1145|  10.6k|    if (version == PGP_V5) {
  ------------------
  |  Branch (1145:9): [True: 0, False: 10.6k]
  ------------------
 1146|      0|        pktbody.add_byte(v5_s2k_len);
 1147|      0|    }
 1148|       |
 1149|  10.6k|    pgp_packet_body_t s2k_params(tag);
 1150|  10.6k|    make_s2k_params(s2k_params);
 1151|  10.6k|#if defined(ENABLE_CRYPTO_REFRESH)
 1152|  10.6k|    if ((version == PGP_V6) && (sec_protection.s2k.usage != PGP_S2KU_NONE)) {
  ------------------
  |  Branch (1152:9): [True: 1.89k, False: 8.74k]
  |  Branch (1152:32): [True: 1.89k, False: 4]
  ------------------
 1153|       |        // V6 packages contain the count of the optional 1-byte parameters
 1154|  1.89k|        pktbody.add_byte(s2k_params.size());
 1155|  1.89k|    }
 1156|  10.6k|#endif
 1157|  10.6k|    pktbody.add(s2k_params.data(), s2k_params.size());
 1158|       |
 1159|  10.6k|    if (version == PGP_V5) {
  ------------------
  |  Branch (1159:9): [True: 0, False: 10.6k]
  ------------------
 1160|      0|        pktbody.add_uint32(sec_data.size());
 1161|      0|    }
 1162|       |    /* if key is stored on card, or exported via gpg --export-secret-subkeys, then
 1163|       |     * sec_data is empty */
 1164|  10.6k|    pktbody.add(sec_data);
 1165|  10.6k|    pktbody.write(dst);
 1166|  10.6k|}
_ZN13pgp_key_pkt_t5parseER12pgp_source_t:
 1170|  63.5k|{
 1171|       |    /* check the key tag */
 1172|  63.5k|    int atag = stream_pkt_type(src);
 1173|  63.5k|    if (!is_key_pkt(atag)) {
  ------------------
  |  Branch (1173:9): [True: 0, False: 63.5k]
  ------------------
 1174|      0|        RNP_LOG("wrong key packet tag: %d", atag);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1175|      0|        return RNP_ERROR_BAD_FORMAT;
 1176|      0|    }
 1177|       |
 1178|  63.5k|    pgp_packet_body_t pkt((pgp_pkt_type_t) atag);
 1179|       |    /* Read the packet into memory */
 1180|  63.5k|    rnp_result_t res = pkt.read(src);
 1181|  63.5k|    if (res) {
  ------------------
  |  Branch (1181:9): [True: 1.80k, False: 61.7k]
  ------------------
 1182|  1.80k|        return res;
 1183|  1.80k|    }
 1184|       |    /* key type, i.e. tag */
 1185|  61.7k|    tag = (pgp_pkt_type_t) atag;
 1186|       |    /* version */
 1187|  61.7k|    uint8_t ver = 0;
 1188|  61.7k|    if (!pkt.get(ver)) {
  ------------------
  |  Branch (1188:9): [True: 1.15k, False: 60.5k]
  ------------------
 1189|  1.15k|        RNP_LOG("unable to retrieve key packet version");
  ------------------
  |  |   84|  1.15k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.15k|    do {                                                                                 \
  |  |  |  |   77|  1.15k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.15k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.15k|            break;                                                                       \
  |  |  |  |   79|  1.15k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1190|  1.15k|        return RNP_ERROR_BAD_FORMAT;
 1191|  1.15k|    }
 1192|  60.5k|    switch (ver) {
 1193|  2.49k|    case PGP_V2:
  ------------------
  |  Branch (1193:5): [True: 2.49k, False: 58.1k]
  ------------------
 1194|  2.49k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  2.49k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1195|  10.6k|    case PGP_V3:
  ------------------
  |  Branch (1195:5): [True: 8.17k, False: 52.4k]
  ------------------
 1196|  10.6k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  10.6k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1197|  47.9k|    case PGP_V4:
  ------------------
  |  Branch (1197:5): [True: 37.2k, False: 23.3k]
  ------------------
 1198|  47.9k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  47.9k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1199|  50.8k|    case PGP_V5:
  ------------------
  |  Branch (1199:5): [True: 2.97k, False: 57.6k]
  ------------------
 1200|  50.8k|        break;
 1201|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 1202|  3.92k|    case PGP_V6:
  ------------------
  |  Branch (1202:5): [True: 3.92k, False: 56.6k]
  ------------------
 1203|  3.92k|        break;
 1204|      0|#endif
 1205|  5.78k|    default:
  ------------------
  |  Branch (1205:5): [True: 5.78k, False: 54.8k]
  ------------------
 1206|  5.78k|        RNP_LOG("wrong key packet version");
  ------------------
  |  |   84|  5.78k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  5.78k|    do {                                                                                 \
  |  |  |  |   77|  5.78k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5.78k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  5.78k|            break;                                                                       \
  |  |  |  |   79|  5.78k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1207|  5.78k|        return RNP_ERROR_BAD_FORMAT;
 1208|  60.5k|    }
 1209|  54.8k|    version = (pgp_version_t) ver;
 1210|       |    /* creation time */
 1211|  54.8k|    if (!pkt.get(creation_time)) {
  ------------------
  |  Branch (1211:9): [True: 89, False: 54.7k]
  ------------------
 1212|     89|        return RNP_ERROR_BAD_FORMAT;
 1213|     89|    }
 1214|       |    /* v3: validity days */
 1215|  54.7k|    if ((version < PGP_V4) && !pkt.get(v3_days)) {
  ------------------
  |  Branch (1215:9): [True: 10.6k, False: 44.0k]
  |  Branch (1215:31): [True: 19, False: 10.6k]
  ------------------
 1216|     19|        return RNP_ERROR_BAD_FORMAT;
 1217|     19|    }
 1218|       |    /* key algorithm */
 1219|  54.7k|    uint8_t analg = 0;
 1220|  54.7k|    if (!pkt.get(analg)) {
  ------------------
  |  Branch (1220:9): [True: 605, False: 54.0k]
  ------------------
 1221|    605|        return RNP_ERROR_BAD_FORMAT;
 1222|    605|    }
 1223|  54.0k|    alg = (pgp_pubkey_alg_t) analg;
 1224|  54.0k|    material = pgp::KeyMaterial::create(alg);
 1225|  54.0k|    if (!material) {
  ------------------
  |  Branch (1225:9): [True: 1.58k, False: 52.5k]
  ------------------
 1226|       |        /* Unknown or unsupported-in-this-build algorithm (for example a PQC
 1227|       |         * algorithm when the build has ENABLE_PQC off, issue #2370). The whole
 1228|       |         * packet is already framed and read, so skip the rest of it and let the
 1229|       |         * caller skip the key while continuing with the rest of the keyring. */
 1230|  1.58k|        RNP_LOG("unknown key algorithm: %d", (int) alg);
  ------------------
  |  |   84|  1.58k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.58k|    do {                                                                                 \
  |  |  |  |   77|  1.58k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.58k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.58k|            break;                                                                       \
  |  |  |  |   79|  1.58k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1231|  1.58k|        pkt.skip(pkt.left());
 1232|  1.58k|        return RNP_ERROR_NOT_SUPPORTED;
 1233|  1.58k|    }
 1234|  52.5k|    switch (version) {
 1235|  2.41k|    case PGP_V2:
  ------------------
  |  Branch (1235:5): [True: 2.41k, False: 50.0k]
  ------------------
 1236|  10.3k|    case PGP_V3:
  ------------------
  |  Branch (1236:5): [True: 7.94k, False: 44.5k]
  ------------------
 1237|       |        /* v3 keys must be RSA-only */
 1238|  10.3k|        if (!is_rsa_key_alg(alg)) {
  ------------------
  |  Branch (1238:13): [True: 812, False: 9.54k]
  ------------------
 1239|    812|            RNP_LOG("wrong v3 pk algorithm");
  ------------------
  |  |   84|    812|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    812|    do {                                                                                 \
  |  |  |  |   77|    812|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 812, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    812|            break;                                                                       \
  |  |  |  |   79|    812|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1240|    812|            return RNP_ERROR_BAD_FORMAT;
 1241|    812|        }
 1242|  9.54k|        break;
 1243|  9.54k|    case PGP_V5:
  ------------------
  |  Branch (1243:5): [True: 2.44k, False: 50.0k]
  ------------------
 1244|  2.44k|#if defined(ENABLE_CRYPTO_REFRESH)
 1245|  6.24k|    case PGP_V6:
  ------------------
  |  Branch (1245:5): [True: 3.80k, False: 48.7k]
  ------------------
 1246|  6.24k|#endif
 1247|       |        /* v5-v6 public key material length  */
 1248|  6.24k|        if (!pkt.get(v5_pub_len)) {
  ------------------
  |  Branch (1248:13): [True: 15, False: 6.23k]
  ------------------
 1249|     15|            RNP_LOG("failed to get v5 octet count field");
  ------------------
  |  |   84|     15|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     15|    do {                                                                                 \
  |  |  |  |   77|     15|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     15|            break;                                                                       \
  |  |  |  |   79|     15|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1250|     15|            return RNP_ERROR_BAD_FORMAT;
 1251|     15|        }
 1252|  6.23k|        if (is_public_key_pkt(atag) && (v5_pub_len != pkt.left())) {
  ------------------
  |  Branch (1252:13): [True: 2.33k, False: 3.89k]
  |  Branch (1252:40): [True: 2.25k, False: 84]
  ------------------
 1253|  2.25k|            RNP_LOG("v5 octet count mismatch");
  ------------------
  |  |   84|  2.25k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.25k|    do {                                                                                 \
  |  |  |  |   77|  2.25k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.25k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.25k|            break;                                                                       \
  |  |  |  |   79|  2.25k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1254|  2.25k|            return RNP_ERROR_BAD_FORMAT;
 1255|  2.25k|        }
 1256|  3.97k|        break;
 1257|  35.9k|    default:;
  ------------------
  |  Branch (1257:5): [True: 35.9k, False: 16.6k]
  ------------------
 1258|  52.5k|    }
 1259|       |
 1260|  49.4k|#if defined(ENABLE_PQC) && defined(ENABLE_CRYPTO_REFRESH)
 1261|       |    /* PQC only for v6 keys aside from MLKEM768+X25519 */
 1262|  49.4k|    if (rnp::Key::is_pqc_alg(alg) && version < PGP_V6 && alg != PGP_PKA_KYBER768_X25519) {
  ------------------
  |  Branch (1262:9): [True: 2.80k, False: 46.6k]
  |  Branch (1262:38): [True: 120, False: 2.68k]
  |  Branch (1262:58): [True: 103, False: 17]
  ------------------
 1263|    103|        RNP_LOG("Invalid algorithm for key version");
  ------------------
  |  |   84|    103|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    103|    do {                                                                                 \
  |  |  |  |   77|    103|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 103, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    103|            break;                                                                       \
  |  |  |  |   79|    103|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1264|    103|        return RNP_ERROR_BAD_FORMAT;
 1265|    103|    }
 1266|  49.3k|#endif
 1267|       |
 1268|       |    /* algorithm specific fields */
 1269|  49.3k|    if (!material->parse(pkt)) {
  ------------------
  |  Branch (1269:9): [True: 3.64k, False: 45.6k]
  ------------------
 1270|  3.64k|        return RNP_ERROR_BAD_FORMAT;
 1271|  3.64k|    }
 1272|       |
 1273|       |    /* fill hashed data used for signatures */
 1274|  45.6k|    pub_data.assign(pkt.data(), pkt.data() + pkt.size() - pkt.left());
 1275|       |
 1276|       |    /* the algorithm-specific fields must exactly fill a public key packet
 1277|       |     * body; secret key packets continue with the protection fields below */
 1278|  45.6k|    if (!is_secret_key_pkt(tag) && pkt.left()) {
  ------------------
  |  Branch (1278:9): [True: 29.2k, False: 16.4k]
  |  Branch (1278:36): [True: 62, False: 29.1k]
  ------------------
 1279|     62|        RNP_LOG("extra data at the end of the key packet");
  ------------------
  |  |   84|     62|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     62|    do {                                                                                 \
  |  |  |  |   77|     62|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 62, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     62|            break;                                                                       \
  |  |  |  |   79|     62|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1280|     62|        return RNP_ERROR_BAD_FORMAT;
 1281|     62|    }
 1282|       |
 1283|       |    /* secret key fields if any */
 1284|  45.6k|    if (is_secret_key_pkt(tag)) {
  ------------------
  |  Branch (1284:9): [True: 16.4k, False: 29.1k]
  ------------------
 1285|  16.4k|        uint8_t usage = 0;
 1286|  16.4k|        if (!pkt.get(usage)) {
  ------------------
  |  Branch (1286:13): [True: 20, False: 16.4k]
  ------------------
 1287|     20|            RNP_LOG("failed to read key protection");
  ------------------
  |  |   84|     20|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     20|    do {                                                                                 \
  |  |  |  |   77|     20|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 20, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     20|            break;                                                                       \
  |  |  |  |   79|     20|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1288|     20|            return RNP_ERROR_BAD_FORMAT;
 1289|     20|        }
 1290|  16.4k|#if defined(ENABLE_CRYPTO_REFRESH)
 1291|  16.4k|        if (version == PGP_V6 && usage == 255) {
  ------------------
  |  Branch (1291:13): [True: 2.91k, False: 13.5k]
  |  Branch (1291:34): [True: 238, False: 2.67k]
  ------------------
 1292|    238|            RNP_LOG(
  ------------------
  |  |   84|    238|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    238|    do {                                                                                 \
  |  |  |  |   77|    238|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 238, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    238|            break;                                                                       \
  |  |  |  |   79|    238|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1293|    238|              "Error when parsing S2K usage: A version 6 packet MUST NOT use the value 255.");
 1294|    238|            return RNP_ERROR_BAD_FORMAT;
 1295|    238|        }
 1296|  16.1k|#endif
 1297|  16.1k|        sec_protection.s2k.usage = (pgp_s2k_usage_t) usage;
 1298|  16.1k|        sec_protection.cipher_mode = PGP_CIPHER_MODE_CFB;
 1299|       |
 1300|       |        /* v5 s2k length, ignored for now */
 1301|  16.1k|        if (version == PGP_V5) {
  ------------------
  |  Branch (1301:13): [True: 96, False: 16.1k]
  ------------------
 1302|     96|            if (!pkt.get(v5_s2k_len)) {
  ------------------
  |  Branch (1302:17): [True: 11, False: 85]
  ------------------
 1303|     11|                RNP_LOG("failed to read v5 s2k len");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1304|     11|                return RNP_ERROR_BAD_FORMAT;
 1305|     11|            }
 1306|     96|        }
 1307|  16.1k|#if defined(ENABLE_CRYPTO_REFRESH)
 1308|  16.1k|        if (version == PGP_V6 && sec_protection.s2k.usage != PGP_S2KU_NONE) {
  ------------------
  |  Branch (1308:13): [True: 2.67k, False: 13.5k]
  |  Branch (1308:34): [True: 2.49k, False: 184]
  ------------------
 1309|       |            // v6 packets contain the count of the following parameters
 1310|       |            // ignored for now
 1311|  2.49k|            uint8_t bt;
 1312|  2.49k|            if (!pkt.get(bt)) {
  ------------------
  |  Branch (1312:17): [True: 17, False: 2.47k]
  ------------------
 1313|     17|                RNP_LOG("failed to read s2k parameter length");
  ------------------
  |  |   84|     17|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     17|    do {                                                                                 \
  |  |  |  |   77|     17|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 17, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     17|            break;                                                                       \
  |  |  |  |   79|     17|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1314|     17|                return RNP_ERROR_BAD_FORMAT;
 1315|     17|            }
 1316|  2.49k|        }
 1317|  16.1k|#endif
 1318|       |
 1319|  16.1k|        switch (sec_protection.s2k.usage) {
 1320|  1.19k|        case PGP_S2KU_NONE:
  ------------------
  |  Branch (1320:9): [True: 1.19k, False: 14.9k]
  ------------------
 1321|  1.19k|            break;
 1322|    499|        case PGP_S2KU_ENCRYPTED:
  ------------------
  |  Branch (1322:9): [True: 499, False: 15.6k]
  ------------------
 1323|  9.65k|        case PGP_S2KU_ENCRYPTED_AND_HASHED: {
  ------------------
  |  Branch (1323:9): [True: 9.16k, False: 7.01k]
  ------------------
 1324|       |            /* we have s2k */
 1325|  9.65k|            uint8_t salg = 0;
 1326|  9.65k|            if (!pkt.get(salg)) {
  ------------------
  |  Branch (1326:17): [True: 4, False: 9.65k]
  ------------------
 1327|      4|                RNP_LOG("failed to read key protection (symmetric alg)");
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1328|      4|                return RNP_ERROR_BAD_FORMAT;
 1329|      4|            }
 1330|  9.65k|#if defined(ENABLE_CRYPTO_REFRESH)
 1331|  9.65k|            if (version == PGP_V6) {
  ------------------
  |  Branch (1331:17): [True: 50, False: 9.60k]
  ------------------
 1332|       |                // V6 packages contain the length of the following field
 1333|     50|                uint8_t s2k_specifier_len;
 1334|     50|                if (!pkt.get(s2k_specifier_len)) {
  ------------------
  |  Branch (1334:21): [True: 1, False: 49]
  ------------------
 1335|      1|                    RNP_LOG("failed to read key protection (s2k specifier length)");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1336|      1|                    return RNP_ERROR_BAD_FORMAT;
 1337|      1|                }
 1338|     50|            }
 1339|  9.65k|#endif
 1340|  9.65k|            if (!pkt.get(sec_protection.s2k)) {
  ------------------
  |  Branch (1340:17): [True: 562, False: 9.09k]
  ------------------
 1341|    562|                RNP_LOG("failed to read key protection (s2k)");
  ------------------
  |  |   84|    562|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    562|    do {                                                                                 \
  |  |  |  |   77|    562|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 562, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    562|            break;                                                                       \
  |  |  |  |   79|    562|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1342|    562|                return RNP_ERROR_BAD_FORMAT;
 1343|    562|            }
 1344|  9.09k|            sec_protection.symm_alg = (pgp_symm_alg_t) salg;
 1345|  9.09k|            break;
 1346|  9.65k|        }
 1347|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 1348|     98|        case PGP_S2KU_AEAD: {
  ------------------
  |  Branch (1348:9): [True: 98, False: 16.0k]
  ------------------
 1349|     98|            uint8_t symm_alg = 0;
 1350|     98|            uint8_t aead_alg = 0;
 1351|     98|            if (!pkt.get(symm_alg)) {
  ------------------
  |  Branch (1351:17): [True: 10, False: 88]
  ------------------
 1352|     10|                RNP_LOG("failed to read key protection (symmetric alg)");
  ------------------
  |  |   84|     10|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     10|    do {                                                                                 \
  |  |  |  |   77|     10|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     10|            break;                                                                       \
  |  |  |  |   79|     10|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1353|     10|                return RNP_ERROR_BAD_FORMAT;
 1354|     10|            }
 1355|     88|            if (!pkt.get(aead_alg)) {
  ------------------
  |  Branch (1355:17): [True: 1, False: 87]
  ------------------
 1356|      1|                RNP_LOG("failed to read key protection (aead alg)");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1357|      1|                return RNP_ERROR_BAD_FORMAT;
 1358|      1|            }
 1359|     87|            if (version == PGP_V6) {
  ------------------
  |  Branch (1359:17): [True: 62, False: 25]
  ------------------
 1360|       |                // V6 packages contain the length of the following field
 1361|     62|                uint8_t s2k_specifier_len;
 1362|     62|                if (!pkt.get(s2k_specifier_len)) {
  ------------------
  |  Branch (1362:21): [True: 1, False: 61]
  ------------------
 1363|      1|                    RNP_LOG("failed to read key protection (s2k specifier length)");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1364|      1|                    return RNP_ERROR_BAD_FORMAT;
 1365|      1|                }
 1366|     62|            }
 1367|     86|            if (!pkt.get(sec_protection.s2k)) {
  ------------------
  |  Branch (1367:17): [True: 18, False: 68]
  ------------------
 1368|     18|                RNP_LOG("failed to read key protection (s2k)");
  ------------------
  |  |   84|     18|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     18|    do {                                                                                 \
  |  |  |  |   77|     18|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 18, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     18|            break;                                                                       \
  |  |  |  |   79|     18|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1369|     18|                return RNP_ERROR_BAD_FORMAT;
 1370|     18|            }
 1371|     68|            sec_protection.symm_alg = (pgp_symm_alg_t) symm_alg;
 1372|     68|            sec_protection.aead_alg = (pgp_aead_alg_t) aead_alg;
 1373|     68|            break;
 1374|     86|        }
 1375|      0|#endif
 1376|  5.21k|        default:
  ------------------
  |  Branch (1376:9): [True: 5.21k, False: 10.9k]
  ------------------
 1377|       |            /* old-style: usage is symmetric algorithm identifier */
 1378|  5.21k|            sec_protection.symm_alg = (pgp_symm_alg_t) usage;
 1379|  5.21k|            sec_protection.s2k.usage = PGP_S2KU_ENCRYPTED;
 1380|  5.21k|            sec_protection.s2k.specifier = PGP_S2KS_SIMPLE;
 1381|  5.21k|            sec_protection.s2k.hash_alg = PGP_HASH_MD5;
 1382|  5.21k|            break;
 1383|  16.1k|        }
 1384|       |
 1385|       |        /* iv */
 1386|  15.5k|        if ((sec_protection.s2k.usage != PGP_S2KU_NONE)
  ------------------
  |  Branch (1386:13): [True: 14.3k, False: 1.19k]
  ------------------
 1387|  14.3k|#if defined(ENABLE_CRYPTO_REFRESH)
 1388|  14.3k|            && (sec_protection.s2k.usage != PGP_S2KU_AEAD)
  ------------------
  |  Branch (1388:16): [True: 14.3k, False: 68]
  ------------------
 1389|  14.3k|#endif
 1390|  14.3k|            && (sec_protection.s2k.specifier != PGP_S2KS_EXPERIMENTAL)) {
  ------------------
  |  Branch (1390:16): [True: 8.25k, False: 6.05k]
  ------------------
 1391|  8.25k|            size_t bl_size = pgp_block_size(sec_protection.symm_alg);
 1392|  8.25k|            if (!bl_size || !pkt.get(sec_protection.iv, bl_size)) {
  ------------------
  |  Branch (1392:17): [True: 343, False: 7.90k]
  |  Branch (1392:29): [True: 30, False: 7.87k]
  ------------------
 1393|    373|                RNP_LOG("failed to read iv");
  ------------------
  |  |   84|    373|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    373|    do {                                                                                 \
  |  |  |  |   77|    373|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 373, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    373|            break;                                                                       \
  |  |  |  |   79|    373|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1394|    373|                return RNP_ERROR_BAD_FORMAT;
 1395|    373|            }
 1396|  8.25k|        }
 1397|  7.32k|#if defined(ENABLE_CRYPTO_REFRESH)
 1398|  7.32k|        else if ((sec_protection.s2k.usage == PGP_S2KU_AEAD) &&
  ------------------
  |  Branch (1398:18): [True: 68, False: 7.25k]
  ------------------
 1399|     68|                 (sec_protection.s2k.specifier != PGP_S2KS_EXPERIMENTAL)) {
  ------------------
  |  Branch (1399:18): [True: 50, False: 18]
  ------------------
 1400|     50|            size_t nonce_len = pgp_cipher_aead_nonce_len(sec_protection.aead_alg);
 1401|     50|            if (!nonce_len || !pkt.get(sec_protection.iv, nonce_len)) {
  ------------------
  |  Branch (1401:17): [True: 12, False: 38]
  |  Branch (1401:31): [True: 1, False: 37]
  ------------------
 1402|     13|                RNP_LOG("failed to read iv");
  ------------------
  |  |   84|     13|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     13|    do {                                                                                 \
  |  |  |  |   77|     13|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 13, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     13|            break;                                                                       \
  |  |  |  |   79|     13|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1403|     13|                return RNP_ERROR_BAD_FORMAT;
 1404|     13|            }
 1405|     50|        }
 1406|  15.1k|#endif
 1407|       |
 1408|       |        /* v5 secret key fields length */
 1409|  15.1k|        if (version == PGP_V5) {
  ------------------
  |  Branch (1409:13): [True: 66, False: 15.1k]
  ------------------
 1410|     66|            if (!pkt.get(v5_sec_len)) {
  ------------------
  |  Branch (1410:17): [True: 11, False: 55]
  ------------------
 1411|     11|                RNP_LOG("failed to read v5 secret fields length");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1412|     11|                return RNP_ERROR_BAD_FORMAT;
 1413|     11|            }
 1414|     55|            if (v5_sec_len != pkt.left()) {
  ------------------
  |  Branch (1414:17): [True: 15, False: 40]
  ------------------
 1415|     15|                RNP_LOG("v5 secret fields length mismatch");
  ------------------
  |  |   84|     15|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     15|    do {                                                                                 \
  |  |  |  |   77|     15|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     15|            break;                                                                       \
  |  |  |  |   79|     15|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1416|     15|                return RNP_ERROR_BAD_FORMAT;
 1417|     15|            }
 1418|     55|        }
 1419|       |
 1420|       |        /* encrypted/cleartext secret MPIs are left */
 1421|  15.1k|        size_t sec_len = pkt.left();
 1422|  15.1k|        sec_data.resize(sec_len);
 1423|  15.1k|        if (sec_len && !pkt.get(sec_data.data(), sec_len)) {
  ------------------
  |  Branch (1423:13): [True: 9.32k, False: 5.83k]
  |  Branch (1423:24): [True: 0, False: 9.32k]
  ------------------
 1424|      0|            return RNP_ERROR_BAD_STATE;
 1425|      0|        }
 1426|  15.1k|    }
 1427|       |
 1428|  44.3k|    if (pkt.left()) {
  ------------------
  |  Branch (1428:9): [True: 0, False: 44.3k]
  ------------------
 1429|      0|        RNP_LOG("extra %zu bytes in key packet", pkt.left());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1430|      0|        return RNP_ERROR_BAD_FORMAT;
 1431|      0|    }
 1432|  44.3k|    return RNP_SUCCESS;
 1433|  44.3k|}
_ZN25pgp_transferable_subkey_tC2ERKS_b:
 1470|  41.7k|{
 1471|  41.7k|    subkey = pgp_key_pkt_t(src.subkey, pubonly);
 1472|  41.7k|    signatures = src.signatures;
 1473|  41.7k|}
_ZN22pgp_transferable_key_tC2ERKS_b:
 1476|  69.7k|{
 1477|  69.7k|    key = pgp_key_pkt_t(src.key, pubonly);
 1478|  69.7k|    userids = src.userids;
 1479|  69.7k|    subkeys = src.subkeys;
 1480|  69.7k|    signatures = src.signatures;
 1481|  69.7k|}
stream-key.cpp:_ZL16pkt_is_ignorablei:
   98|  1.38M|{
   99|  1.38M|    return ((ptag >= 40) && (ptag <= 63)) || (ptag == PGP_PKT_PADDING);
  ------------------
  |  Branch (99:13): [True: 2.39k, False: 1.38M]
  |  Branch (99:29): [True: 2.39k, False: 0]
  |  Branch (99:46): [True: 14, False: 1.38M]
  ------------------
  100|  1.38M|}
stream-key.cpp:_ZL16skip_pgp_packetsR12pgp_source_tRKNSt3__13setI14pgp_pkt_type_tNS1_4lessIS3_EENS1_9allocatorIS3_EEEE:
   61|   791k|{
   62|   883k|    do {
   63|   883k|        int pkt = stream_pkt_type(src);
   64|   883k|        if (!pkt) {
  ------------------
  |  Branch (64:13): [True: 8.30k, False: 875k]
  ------------------
   65|  8.30k|            break;
   66|  8.30k|        }
   67|   875k|        if (pkt < 0) {
  ------------------
  |  Branch (67:13): [True: 1.20k, False: 874k]
  ------------------
   68|  1.20k|            return false;
   69|  1.20k|        }
   70|   874k|        if (pkts.find((pgp_pkt_type_t) pkt) == pkts.end()) {
  ------------------
  |  Branch (70:13): [True: 781k, False: 92.5k]
  ------------------
   71|   781k|            return true;
   72|   781k|        }
   73|  92.5k|        uint64_t ppos = src.readb;
   74|  92.5k|        if (stream_skip_packet(&src)) {
  ------------------
  |  Branch (74:13): [True: 511, False: 92.0k]
  ------------------
   75|    511|            RNP_LOG("failed to skip packet at %" PRIu64, ppos);
  ------------------
  |  |   84|    511|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    511|    do {                                                                                 \
  |  |  |  |   77|    511|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 511, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    511|            break;                                                                       \
  |  |  |  |   79|    511|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   76|    511|            return false;
   77|    511|        }
   78|  92.5k|    } while (1);
  ------------------
  |  Branch (78:14): [True: 92.0k, Folded]
  ------------------
   79|       |
   80|  8.30k|    return true;
   81|   791k|}
stream-key.cpp:_ZL26process_pgp_key_signaturesR12pgp_source_tRNSt3__16vectorIN3pgp3pkt9SignatureENS1_9allocatorIS5_EEEEb:
  120|   459k|{
  121|   459k|    int ptag;
  122|   756k|    while (true) {
  ------------------
  |  Branch (122:12): [True: 756k, Folded]
  ------------------
  123|   756k|        if (!skip_ignorable_packets(src) && src.error()) {
  ------------------
  |  Branch (123:13): [True: 221, False: 756k]
  |  Branch (123:45): [True: 0, False: 221]
  ------------------
  124|      0|            return RNP_ERROR_READ;
  125|      0|        }
  126|   756k|        if ((ptag = stream_pkt_type(src)) != PGP_PKT_SIGNATURE) {
  ------------------
  |  Branch (126:13): [True: 459k, False: 297k]
  ------------------
  127|   459k|            break;
  128|   459k|        }
  129|   297k|        uint64_t sigpos = src.readb;
  130|   297k|        try {
  131|   297k|            pgp::pkt::Signature sig;
  132|   297k|            rnp_result_t        ret = sig.parse(src);
  133|   297k|            if (ret) {
  ------------------
  |  Branch (133:17): [True: 259k, False: 38.5k]
  ------------------
  134|   259k|                RNP_LOG("failed to parse signature at %" PRIu64, sigpos);
  ------------------
  |  |   84|   259k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|   259k|    do {                                                                                 \
  |  |  |  |   77|   259k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 259k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|   259k|            break;                                                                       \
  |  |  |  |   79|   259k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  135|   259k|                if (!skiperrors) {
  ------------------
  |  Branch (135:21): [True: 0, False: 259k]
  ------------------
  136|      0|                    return ret;
  137|      0|                }
  138|   259k|            } else {
  139|  38.5k|                sigs.emplace_back(std::move(sig));
  140|  38.5k|            }
  141|   297k|        } catch (const std::exception &e) {
  142|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  143|      0|            return RNP_ERROR_OUT_OF_MEMORY;
  144|      0|        }
  145|   297k|        if (!skip_pgp_packets(src, {PGP_PKT_TRUST})) {
  ------------------
  |  Branch (145:13): [True: 168, False: 297k]
  ------------------
  146|    168|            return RNP_ERROR_READ;
  147|    168|        }
  148|   297k|    }
  149|   459k|    return ptag < 0 ? RNP_ERROR_BAD_FORMAT : RNP_SUCCESS;
  ------------------
  |  Branch (149:12): [True: 20, False: 459k]
  ------------------
  150|   459k|}
stream-key.cpp:_ZL18process_pgp_useridR12pgp_source_tR25pgp_transferable_userid_tb:
  154|   416k|{
  155|   416k|    rnp_result_t ret;
  156|   416k|    uint64_t     uidpos = src.readb;
  157|   416k|    try {
  158|   416k|        ret = uid.uid.parse(src);
  159|   416k|    } catch (const std::exception &e) {
  160|      0|        ret = RNP_ERROR_GENERIC;
  161|      0|    }
  162|   416k|    if (ret) {
  ------------------
  |  Branch (162:9): [True: 1.64k, False: 415k]
  ------------------
  163|  1.64k|        RNP_LOG("failed to parse userid at %" PRIu64, uidpos);
  ------------------
  |  |   84|  1.64k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.64k|    do {                                                                                 \
  |  |  |  |   77|  1.64k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.64k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.64k|            break;                                                                       \
  |  |  |  |   79|  1.64k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  164|  1.64k|        return ret;
  165|  1.64k|    }
  166|   415k|    if (!skip_pgp_packets(src, {PGP_PKT_TRUST})) {
  ------------------
  |  Branch (166:9): [True: 27, False: 415k]
  ------------------
  167|     27|        return RNP_ERROR_READ;
  168|     27|    }
  169|   415k|    return process_pgp_key_signatures(src, uid.signatures, skiperrors);
  170|   415k|}
stream-key.cpp:_ZL21parse_secret_key_mpisR13pgp_key_pkt_tPKhm:
  478|    227|{
  479|    227|    if (!mpis) {
  ------------------
  |  Branch (479:9): [True: 8, False: 219]
  ------------------
  480|      8|        return RNP_ERROR_NULL_POINTER;
  481|      8|    }
  482|       |
  483|       |    /* check the cleartext data */
  484|    219|    switch (key.sec_protection.s2k.usage) {
  485|    219|    case PGP_S2KU_NONE:
  ------------------
  |  Branch (485:5): [True: 219, False: 0]
  ------------------
  486|    219|#if defined(ENABLE_CRYPTO_REFRESH)
  487|    219|        if (key.version == PGP_V6) {
  ------------------
  |  Branch (487:13): [True: 51, False: 168]
  ------------------
  488|     51|            break; /* checksum removed for v6 and usage byte zero */
  489|     51|        }
  490|    168|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|    168|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
  491|    168|#endif
  492|    168|    case PGP_S2KU_ENCRYPTED: {
  ------------------
  |  Branch (492:5): [True: 0, False: 219]
  ------------------
  493|       |        /* calculate and check sum16 of the cleartext */
  494|    168|        if (len < 2) {
  ------------------
  |  Branch (494:13): [True: 2, False: 166]
  ------------------
  495|      2|            RNP_LOG("No space for checksum.");
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  496|      2|            return RNP_ERROR_BAD_FORMAT;
  497|      2|        }
  498|    166|        uint16_t sum = 0;
  499|    166|        len -= 2;
  500|  9.12k|        for (size_t idx = 0; idx < len; idx++) {
  ------------------
  |  Branch (500:30): [True: 8.96k, False: 166]
  ------------------
  501|  8.96k|            sum += mpis[idx];
  502|  8.96k|        }
  503|    166|        uint16_t expsum = read_uint16(mpis + len);
  504|    166|        if (sum != expsum) {
  ------------------
  |  Branch (504:13): [True: 155, False: 11]
  ------------------
  505|    155|            RNP_LOG("Wrong key checksum, got 0x%X instead of 0x%X.", (int) sum, (int) expsum);
  ------------------
  |  |   84|    155|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    155|    do {                                                                                 \
  |  |  |  |   77|    155|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 155, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    155|            break;                                                                       \
  |  |  |  |   79|    155|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  506|    155|            return RNP_ERROR_DECRYPT_FAILED;
  507|    155|        }
  508|     11|        break;
  509|    166|    }
  510|     11|    case PGP_S2KU_ENCRYPTED_AND_HASHED: {
  ------------------
  |  Branch (510:5): [True: 0, False: 219]
  ------------------
  511|      0|        if (len < PGP_SHA1_HASH_SIZE) {
  ------------------
  |  |   42|      0|#define PGP_SHA1_HASH_SIZE 20
  ------------------
  |  Branch (511:13): [True: 0, False: 0]
  ------------------
  512|      0|            RNP_LOG("No space for hash");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  513|      0|            return RNP_ERROR_BAD_FORMAT;
  514|      0|        }
  515|       |        /* calculate and check sha1 hash of the cleartext */
  516|      0|        uint8_t hval[PGP_SHA1_HASH_SIZE];
  517|      0|        try {
  518|      0|            auto hash = rnp::Hash::create(PGP_HASH_SHA1);
  519|      0|            assert(hash->size() == sizeof(hval));
  520|      0|            len -= PGP_SHA1_HASH_SIZE;
  ------------------
  |  |   42|      0|#define PGP_SHA1_HASH_SIZE 20
  ------------------
  521|      0|            hash->add(mpis, len);
  522|      0|            hash->finish(hval);
  523|      0|        } catch (const std::exception &e) {
  524|      0|            RNP_LOG("hash calculation failed: %s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  525|      0|            return RNP_ERROR_BAD_STATE;
  526|      0|        }
  527|      0|        if (memcmp(hval, mpis + len, PGP_SHA1_HASH_SIZE)) {
  ------------------
  |  |   42|      0|#define PGP_SHA1_HASH_SIZE 20
  ------------------
  |  Branch (527:13): [True: 0, False: 0]
  ------------------
  528|      0|            return RNP_ERROR_DECRYPT_FAILED;
  529|      0|        }
  530|      0|        break;
  531|      0|    }
  532|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  533|      0|    case PGP_S2KU_AEAD: {
  ------------------
  |  Branch (533:5): [True: 0, False: 219]
  ------------------
  534|      0|        break; // nothing to do here
  535|      0|    }
  536|      0|#endif
  537|      0|    default:
  ------------------
  |  Branch (537:5): [True: 0, False: 219]
  ------------------
  538|      0|        RNP_LOG("unknown s2k usage: %d", (int) key.sec_protection.s2k.usage);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  539|      0|        return RNP_ERROR_BAD_PARAMETERS;
  540|    219|    }
  541|       |
  542|     62|    try {
  543|       |        /* parse mpis depending on algorithm */
  544|     62|        pgp_packet_body_t body(mpis, len);
  545|       |
  546|     62|        if (!key.material) {
  ------------------
  |  Branch (546:13): [True: 0, False: 62]
  ------------------
  547|      0|            RNP_LOG("unknown pk alg : %d", (int) key.alg);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  548|      0|            return RNP_ERROR_BAD_PARAMETERS;
  549|      0|        }
  550|     62|        if (!key.material->parse_secret(body)) {
  ------------------
  |  Branch (550:13): [True: 38, False: 24]
  ------------------
  551|     38|            return RNP_ERROR_BAD_FORMAT;
  552|     38|        }
  553|       |
  554|     24|        if (body.left()) {
  ------------------
  |  Branch (554:13): [True: 18, False: 6]
  ------------------
  555|     18|            RNP_LOG("extra data in sec key");
  ------------------
  |  |   84|     18|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     18|    do {                                                                                 \
  |  |  |  |   77|     18|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 18, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     18|            break;                                                                       \
  |  |  |  |   79|     18|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  556|     18|            return RNP_ERROR_BAD_FORMAT;
  557|     18|        }
  558|      6|        return RNP_SUCCESS;
  559|     24|    } catch (const std::exception &e) {
  560|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  561|      0|        return RNP_ERROR_GENERIC;
  562|      0|    }
  563|     62|}

_ZN13pgp_key_pkt_tC2Ev:
   59|   436k|        : tag(PGP_PKT_RESERVED), version(PGP_VUNKNOWN), creation_time(0), alg(PGP_PKA_NOTHING),
   60|   436k|          v3_days(0), v5_pub_len(0), material(nullptr), sec_protection({}), v5_s2k_len(0),
   61|   436k|          v5_sec_len(0){};
_ZN25pgp_transferable_subkey_tC2Ev:
   90|  29.7k|    pgp_transferable_subkey_t() = default;
_ZN25pgp_transferable_subkey_taSERKS_:
   92|  14.8k|    pgp_transferable_subkey_t &operator=(const pgp_transferable_subkey_t &) = default;
_ZN22pgp_transferable_key_tC2Ev:
  102|   176k|    pgp_transferable_key_t() = default;
_ZN22pgp_transferable_key_taSERKS_:
  104|   113k|    pgp_transferable_key_t &operator=(const pgp_transferable_key_t &) = default;

_Z16write_packet_lenPhm:
   50|   469k|{
   51|   469k|    if (len < 192) {
  ------------------
  |  Branch (51:9): [True: 459k, False: 10.0k]
  ------------------
   52|   459k|        buf[0] = len;
   53|   459k|        return 1;
   54|   459k|    } else if (len < 8192 + 192) {
  ------------------
  |  Branch (54:16): [True: 10.0k, False: 36]
  ------------------
   55|  10.0k|        buf[0] = ((len - 192) >> 8) + 192;
   56|  10.0k|        buf[1] = (len - 192) & 0xff;
   57|  10.0k|        return 2;
   58|  10.0k|    } else {
   59|     36|        buf[0] = 0xff;
   60|     36|        write_uint32(&buf[1], len);
   61|     36|        return 5;
   62|     36|    }
   63|   469k|}
_Z15get_packet_typeh:
   67|  5.63M|{
   68|  5.63M|    if (!(ptag & PGP_PTAG_ALWAYS_SET)) {
  ------------------
  |  |   47|  5.63M|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
  |  Branch (68:9): [True: 6.05k, False: 5.62M]
  ------------------
   69|  6.05k|        return -1;
   70|  6.05k|    }
   71|       |
   72|  5.62M|    if (ptag & PGP_PTAG_NEW_FORMAT) {
  ------------------
  |  |   56|  5.62M|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  |  Branch (72:9): [True: 3.42M, False: 2.20M]
  ------------------
   73|  3.42M|        return (int) (ptag & PGP_PTAG_NF_CONTENT_TAG_MASK);
  ------------------
  |  |  137|  3.42M|#define PGP_PTAG_NF_CONTENT_TAG_MASK 0x3f
  ------------------
   74|  3.42M|    } else {
   75|  2.20M|        return (int) ((ptag & PGP_PTAG_OF_CONTENT_TAG_MASK) >> PGP_PTAG_OF_CONTENT_TAG_SHIFT);
  ------------------
  |  |   66|  2.20M|#define PGP_PTAG_OF_CONTENT_TAG_MASK 0x3c
  ------------------
                      return (int) ((ptag & PGP_PTAG_OF_CONTENT_TAG_MASK) >> PGP_PTAG_OF_CONTENT_TAG_SHIFT);
  ------------------
  |  |   74|  2.20M|#define PGP_PTAG_OF_CONTENT_TAG_SHIFT 2
  ------------------
   76|  2.20M|    }
   77|  5.62M|}
_Z15stream_pkt_typeR12pgp_source_t:
   81|  4.13M|{
   82|  4.13M|    if (src.eof()) {
  ------------------
  |  Branch (82:9): [True: 30.2k, False: 4.10M]
  ------------------
   83|  30.2k|        return 0;
   84|  30.2k|    }
   85|  4.10M|    size_t hdrneed = 0;
   86|  4.10M|    if (!stream_pkt_hdr_len(src, hdrneed)) {
  ------------------
  |  Branch (86:9): [True: 3.06k, False: 4.10M]
  ------------------
   87|  3.06k|        return -1;
   88|  3.06k|    }
   89|  4.10M|    uint8_t hdr[PGP_MAX_HEADER_SIZE];
   90|  4.10M|    if (!src.peek_eq(hdr, hdrneed)) {
  ------------------
  |  Branch (90:9): [True: 38, False: 4.10M]
  ------------------
   91|     38|        return -1;
   92|     38|    }
   93|  4.10M|    return get_packet_type(hdr[0]);
   94|  4.10M|}
_Z18stream_pkt_hdr_lenR12pgp_source_tRm:
   98|  6.40M|{
   99|  6.40M|    uint8_t buf[2];
  100|       |
  101|  6.40M|    if (!src.peek_eq(buf, 2) || !(buf[0] & PGP_PTAG_ALWAYS_SET)) {
  ------------------
  |  |   47|  6.40M|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
  |  Branch (101:9): [True: 1.50k, False: 6.40M]
  |  Branch (101:33): [True: 1.79k, False: 6.40M]
  ------------------
  102|  3.29k|        return false;
  103|  3.29k|    }
  104|       |
  105|  6.40M|    if (buf[0] & PGP_PTAG_NEW_FORMAT) {
  ------------------
  |  |   56|  6.40M|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  |  Branch (105:9): [True: 3.87M, False: 2.53M]
  ------------------
  106|  3.87M|        if (buf[1] < 192) {
  ------------------
  |  Branch (106:13): [True: 3.74M, False: 127k]
  ------------------
  107|  3.74M|            hdrlen = 2;
  108|  3.74M|        } else if (buf[1] < 224) {
  ------------------
  |  Branch (108:20): [True: 20.7k, False: 106k]
  ------------------
  109|  20.7k|            hdrlen = 3;
  110|   106k|        } else if (buf[1] < 255) {
  ------------------
  |  Branch (110:20): [True: 4.78k, False: 101k]
  ------------------
  111|  4.78k|            hdrlen = 2;
  112|   101k|        } else {
  113|   101k|            hdrlen = 6;
  114|   101k|        }
  115|  3.87M|        return true;
  116|  3.87M|    }
  117|       |
  118|  2.53M|    switch (buf[0] & PGP_PTAG_OF_LENGTH_TYPE_MASK) {
  ------------------
  |  |   83|  2.53M|#define PGP_PTAG_OF_LENGTH_TYPE_MASK 0x03
  ------------------
  119|   986k|    case PGP_PTAG_OLD_LEN_1:
  ------------------
  |  Branch (119:5): [True: 986k, False: 1.54M]
  ------------------
  120|   986k|        hdrlen = 2;
  121|   986k|        return true;
  122|   127k|    case PGP_PTAG_OLD_LEN_2:
  ------------------
  |  Branch (122:5): [True: 127k, False: 2.40M]
  ------------------
  123|   127k|        hdrlen = 3;
  124|   127k|        return true;
  125|   167k|    case PGP_PTAG_OLD_LEN_4:
  ------------------
  |  Branch (125:5): [True: 167k, False: 2.36M]
  ------------------
  126|   167k|        hdrlen = 5;
  127|   167k|        return true;
  128|  1.25M|    case PGP_PTAG_OLD_LEN_INDETERMINATE:
  ------------------
  |  Branch (128:5): [True: 1.25M, False: 1.28M]
  ------------------
  129|  1.25M|        hdrlen = 1;
  130|  1.25M|        return true;
  131|      0|    default:
  ------------------
  |  Branch (131:5): [True: 0, False: 2.53M]
  ------------------
  132|      0|        return false;
  133|  2.53M|    }
  134|  2.53M|}
_Z19stream_read_pkt_lenR12pgp_source_tPm:
  176|  1.14M|{
  177|  1.14M|    uint8_t buf[6] = {};
  178|  1.14M|    size_t  read = 0;
  179|       |
  180|  1.14M|    if (!stream_pkt_hdr_len(src, read)) {
  ------------------
  |  Branch (180:9): [True: 0, False: 1.14M]
  ------------------
  181|      0|        return false;
  182|      0|    }
  183|       |
  184|  1.14M|    if (!src.read_eq(buf, read)) {
  ------------------
  |  Branch (184:9): [True: 0, False: 1.14M]
  ------------------
  185|      0|        return false;
  186|      0|    }
  187|       |
  188|  1.14M|    return get_pkt_len(buf, pktlen);
  189|  1.14M|}
_Z29stream_read_partial_chunk_lenP12pgp_source_tPmPb:
  193|  37.9k|{
  194|  37.9k|    uint8_t hdr[5] = {};
  195|  37.9k|    size_t  read = 0;
  196|       |
  197|  37.9k|    if (!src->read(hdr, 1, &read)) {
  ------------------
  |  Branch (197:9): [True: 0, False: 37.9k]
  ------------------
  198|      0|        RNP_LOG("failed to read header");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  199|      0|        return false;
  200|      0|    }
  201|  37.9k|    if (read < 1) {
  ------------------
  |  Branch (201:9): [True: 8, False: 37.9k]
  ------------------
  202|      8|        RNP_LOG("wrong eof");
  ------------------
  |  |   84|      8|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      8|    do {                                                                                 \
  |  |  |  |   77|      8|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 8, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      8|            break;                                                                       \
  |  |  |  |   79|      8|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  203|      8|        return false;
  204|      8|    }
  205|       |
  206|  37.9k|    *last = true;
  207|       |    // partial length
  208|  37.9k|    if ((hdr[0] >= 224) && (hdr[0] < 255)) {
  ------------------
  |  Branch (208:9): [True: 36.2k, False: 1.69k]
  |  Branch (208:28): [True: 35.7k, False: 475]
  ------------------
  209|  35.7k|        *last = false;
  210|  35.7k|        *clen = get_partial_pkt_len(hdr[0]);
  211|  35.7k|        return true;
  212|  35.7k|    }
  213|       |    // 1-byte length
  214|  2.17k|    if (hdr[0] < 192) {
  ------------------
  |  Branch (214:9): [True: 874, False: 1.30k]
  ------------------
  215|    874|        *clen = hdr[0];
  216|    874|        return true;
  217|    874|    }
  218|       |    // 2-byte length
  219|  1.30k|    if (hdr[0] < 224) {
  ------------------
  |  Branch (219:9): [True: 825, False: 475]
  ------------------
  220|    825|        if (!src->read_eq(&hdr[1], 1)) {
  ------------------
  |  Branch (220:13): [True: 4, False: 821]
  ------------------
  221|      4|            RNP_LOG("wrong 2-byte length");
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  222|      4|            return false;
  223|      4|        }
  224|    821|        *clen = ((size_t)(hdr[0] - 192) << 8) + (size_t) hdr[1] + 192;
  225|    821|        return true;
  226|    825|    }
  227|       |    // 4-byte length
  228|    475|    if (!src->read_eq(&hdr[1], 4)) {
  ------------------
  |  Branch (228:9): [True: 7, False: 468]
  ------------------
  229|      7|        RNP_LOG("wrong 4-byte length");
  ------------------
  |  |   84|      7|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      7|    do {                                                                                 \
  |  |  |  |   77|      7|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      7|            break;                                                                       \
  |  |  |  |   79|      7|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  230|      7|        return false;
  231|      7|    }
  232|    468|    *clen = ((size_t) hdr[1] << 24) | ((size_t) hdr[2] << 16) | ((size_t) hdr[3] << 8) |
  233|    468|            (size_t) hdr[4];
  234|    468|    return true;
  235|    475|}
_Z32stream_old_indeterminate_pkt_lenP12pgp_source_t:
  239|   114k|{
  240|   114k|    uint8_t ptag = 0;
  241|   114k|    if (!src->peek_eq(&ptag, 1)) {
  ------------------
  |  Branch (241:9): [True: 0, False: 114k]
  ------------------
  242|      0|        return false;
  243|      0|    }
  244|   114k|    return !(ptag & PGP_PTAG_NEW_FORMAT) &&
  ------------------
  |  |   56|   114k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  |  Branch (244:12): [True: 17.0k, False: 97.2k]
  ------------------
  245|  17.0k|           ((ptag & PGP_PTAG_OF_LENGTH_TYPE_MASK) == PGP_PTAG_OLD_LEN_INDETERMINATE);
  ------------------
  |  |   83|  17.0k|#define PGP_PTAG_OF_LENGTH_TYPE_MASK 0x03
  ------------------
  |  Branch (245:12): [True: 1.67k, False: 15.3k]
  ------------------
  246|   114k|}
_Z22stream_partial_pkt_lenP12pgp_source_t:
  250|   114k|{
  251|   114k|    uint8_t hdr[2] = {};
  252|   114k|    if (!src->peek_eq(hdr, 2)) {
  ------------------
  |  Branch (252:9): [True: 7, False: 114k]
  ------------------
  253|      7|        return false;
  254|      7|    }
  255|   114k|    return (hdr[0] & PGP_PTAG_NEW_FORMAT) && (hdr[1] >= 224) && (hdr[1] < 255);
  ------------------
  |  |   56|   114k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  |  Branch (255:12): [True: 99.0k, False: 15.5k]
  |  Branch (255:46): [True: 3.43k, False: 95.5k]
  |  Branch (255:65): [True: 2.63k, False: 795]
  ------------------
  256|   114k|}
_Z19get_partial_pkt_lenh:
  260|  37.5k|{
  261|  37.5k|    return 1 << (blen & 0x1f);
  262|  37.5k|}
_Z22stream_peek_packet_hdrP12pgp_source_tP16pgp_packet_hdr_t:
  266|  18.8k|{
  267|  18.8k|    size_t hlen = 0;
  268|  18.8k|    memset(hdr, 0, sizeof(*hdr));
  269|  18.8k|    if (!stream_pkt_hdr_len(*src, hlen)) {
  ------------------
  |  Branch (269:9): [True: 232, False: 18.5k]
  ------------------
  270|    232|        uint8_t hdr2[2] = {0};
  271|    232|        if (!src->peek_eq(hdr2, 2)) {
  ------------------
  |  Branch (271:13): [True: 232, False: 0]
  ------------------
  272|    232|            RNP_LOG("pkt header read failed");
  ------------------
  |  |   84|    232|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    232|    do {                                                                                 \
  |  |  |  |   77|    232|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 232, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    232|            break;                                                                       \
  |  |  |  |   79|    232|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  273|    232|            return RNP_ERROR_READ;
  274|    232|        }
  275|       |
  276|      0|        RNP_LOG("bad packet header: 0x%02x%02x", hdr2[0], hdr2[1]);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  277|      0|        return RNP_ERROR_BAD_FORMAT;
  278|    232|    }
  279|       |
  280|  18.5k|    if (!src->peek_eq(hdr->hdr, hlen)) {
  ------------------
  |  Branch (280:9): [True: 3, False: 18.5k]
  ------------------
  281|      3|        RNP_LOG("failed to read pkt header");
  ------------------
  |  |   84|      3|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      3|    do {                                                                                 \
  |  |  |  |   77|      3|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      3|            break;                                                                       \
  |  |  |  |   79|      3|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  282|      3|        return RNP_ERROR_READ;
  283|      3|    }
  284|       |
  285|  18.5k|    hdr->hdr_len = hlen;
  286|  18.5k|    hdr->tag = (pgp_pkt_type_t) get_packet_type(hdr->hdr[0]);
  287|       |
  288|       |    /* RFC 4880, section 4.3: packet tag 0 is reserved and must not be used. */
  289|  18.5k|    if (hdr->tag == PGP_PKT_RESERVED) {
  ------------------
  |  Branch (289:9): [True: 0, False: 18.5k]
  ------------------
  290|      0|        RNP_LOG("bad packet tag 0 (reserved)");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  291|      0|        return RNP_ERROR_BAD_FORMAT;
  292|      0|    }
  293|       |
  294|  18.5k|    if (stream_partial_pkt_len(src)) {
  ------------------
  |  Branch (294:9): [True: 1.74k, False: 16.8k]
  ------------------
  295|  1.74k|        hdr->partial = true;
  296|  16.8k|    } else if (stream_old_indeterminate_pkt_len(src)) {
  ------------------
  |  Branch (296:16): [True: 192, False: 16.6k]
  ------------------
  297|    192|        hdr->indeterminate = true;
  298|  16.6k|    } else {
  299|  16.6k|        (void) get_pkt_len(hdr->hdr, &hdr->pkt_len);
  300|  16.6k|    }
  301|       |
  302|  18.5k|    return RNP_SUCCESS;
  303|  18.5k|}
_Z18stream_read_packetP12pgp_source_tP10pgp_dest_t:
  351|  97.4k|{
  352|  97.4k|    if (stream_old_indeterminate_pkt_len(src)) {
  ------------------
  |  Branch (352:9): [True: 1.47k, False: 95.9k]
  ------------------
  353|  1.47k|        return dst_write_src(src, dst, PGP_MAX_OLD_LEN_INDETERMINATE_PKT_SIZE);
  ------------------
  |  |   43|  1.47k|#define PGP_MAX_OLD_LEN_INDETERMINATE_PKT_SIZE 0x40000000
  ------------------
  354|  1.47k|    }
  355|       |
  356|  95.9k|    if (stream_partial_pkt_len(src)) {
  ------------------
  |  Branch (356:9): [True: 890, False: 95.0k]
  ------------------
  357|    890|        return stream_read_packet_partial(src, dst);
  358|    890|    }
  359|       |
  360|  95.0k|    try {
  361|  95.0k|        pgp_packet_body_t body(PGP_PKT_RESERVED);
  362|  95.0k|        rnp_result_t      ret = body.read(*src);
  363|  95.0k|        if (dst) {
  ------------------
  |  Branch (363:13): [True: 0, False: 95.0k]
  ------------------
  364|      0|            body.write(*dst, false);
  365|      0|        }
  366|  95.0k|        return ret;
  367|  95.0k|    } catch (const std::exception &e) {
  368|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  369|      0|        return RNP_ERROR_GENERIC;
  370|      0|    }
  371|  95.0k|}
_Z18stream_skip_packetP12pgp_source_t:
  375|  97.4k|{
  376|       |    return stream_read_packet(src, NULL);
  377|  97.4k|}
_Z19stream_parse_markerR12pgp_source_t:
  381|     83|{
  382|     83|    try {
  383|     83|        pgp_packet_body_t pkt(PGP_PKT_MARKER);
  384|     83|        rnp_result_t      res = pkt.read(src);
  385|     83|        if (res) {
  ------------------
  |  Branch (385:13): [True: 14, False: 69]
  ------------------
  386|     14|            return res;
  387|     14|        }
  388|     69|        if ((pkt.size() != PGP_MARKER_LEN) ||
  ------------------
  |  |  109|     69|#define PGP_MARKER_LEN 3
  ------------------
  |  Branch (388:13): [True: 16, False: 53]
  ------------------
  389|     53|            memcmp(pkt.data(), PGP_MARKER_CONTENTS, PGP_MARKER_LEN)) {
  ------------------
  |  |  108|     53|#define PGP_MARKER_CONTENTS "PGP"
  ------------------
                          memcmp(pkt.data(), PGP_MARKER_CONTENTS, PGP_MARKER_LEN)) {
  ------------------
  |  |  109|     53|#define PGP_MARKER_LEN 3
  ------------------
  |  Branch (389:13): [True: 23, False: 30]
  ------------------
  390|     39|            return RNP_ERROR_BAD_FORMAT;
  391|     39|        }
  392|     30|        return RNP_SUCCESS;
  393|     69|    } catch (const std::exception &e) {
  394|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  395|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  396|      0|    }
  397|     83|}
_Z10is_key_pkti:
  401|   154k|{
  402|   154k|    switch (tag) {
  403|  80.1k|    case PGP_PKT_PUBLIC_KEY:
  ------------------
  |  Branch (403:5): [True: 80.1k, False: 73.9k]
  ------------------
  404|   105k|    case PGP_PKT_PUBLIC_SUBKEY:
  ------------------
  |  Branch (404:5): [True: 25.6k, False: 128k]
  ------------------
  405|   136k|    case PGP_PKT_SECRET_KEY:
  ------------------
  |  Branch (405:5): [True: 30.3k, False: 123k]
  ------------------
  406|   154k|    case PGP_PKT_SECRET_SUBKEY:
  ------------------
  |  Branch (406:5): [True: 17.8k, False: 136k]
  ------------------
  407|   154k|        return true;
  408|      0|    default:
  ------------------
  |  Branch (408:5): [True: 0, False: 154k]
  ------------------
  409|      0|        return false;
  410|   154k|    }
  411|   154k|}
_Z13is_subkey_pkti:
  415|   556k|{
  416|   556k|    return (tag == PGP_PKT_PUBLIC_SUBKEY) || (tag == PGP_PKT_SECRET_SUBKEY);
  ------------------
  |  Branch (416:12): [True: 121k, False: 434k]
  |  Branch (416:46): [True: 60.9k, False: 373k]
  ------------------
  417|   556k|}
_Z18is_primary_key_pkti:
  421|   409k|{
  422|   409k|    return (tag == PGP_PKT_PUBLIC_KEY) || (tag == PGP_PKT_SECRET_KEY);
  ------------------
  |  Branch (422:12): [True: 288k, False: 121k]
  |  Branch (422:43): [True: 98.7k, False: 22.4k]
  ------------------
  423|   409k|}
_Z17is_public_key_pkti:
  427|  6.60k|{
  428|  6.60k|    switch (tag) {
  429|  2.33k|    case PGP_PKT_PUBLIC_KEY:
  ------------------
  |  Branch (429:5): [True: 2.33k, False: 4.27k]
  ------------------
  430|  2.33k|    case PGP_PKT_PUBLIC_SUBKEY:
  ------------------
  |  Branch (430:5): [True: 6, False: 6.59k]
  ------------------
  431|  2.33k|        return true;
  432|  4.26k|    default:
  ------------------
  |  Branch (432:5): [True: 4.26k, False: 2.33k]
  ------------------
  433|  4.26k|        return false;
  434|  6.60k|    }
  435|  6.60k|}
_Z17is_secret_key_pkti:
  439|   281k|{
  440|   281k|    switch (tag) {
  441|  52.5k|    case PGP_PKT_SECRET_KEY:
  ------------------
  |  Branch (441:5): [True: 52.5k, False: 229k]
  ------------------
  442|  93.8k|    case PGP_PKT_SECRET_SUBKEY:
  ------------------
  |  Branch (442:5): [True: 41.2k, False: 240k]
  ------------------
  443|  93.8k|        return true;
  444|   188k|    default:
  ------------------
  |  Branch (444:5): [True: 188k, False: 93.8k]
  ------------------
  445|   188k|        return false;
  446|   281k|    }
  447|   281k|}
_Z14is_rsa_key_alg16pgp_pubkey_alg_t:
  451|  16.6k|{
  452|  16.6k|    switch (alg) {
  453|    848|    case PGP_PKA_RSA:
  ------------------
  |  Branch (453:5): [True: 848, False: 15.8k]
  ------------------
  454|  14.0k|    case PGP_PKA_RSA_ENCRYPT_ONLY:
  ------------------
  |  Branch (454:5): [True: 13.2k, False: 3.45k]
  ------------------
  455|  15.8k|    case PGP_PKA_RSA_SIGN_ONLY:
  ------------------
  |  Branch (455:5): [True: 1.79k, False: 14.8k]
  ------------------
  456|  15.8k|        return true;
  457|    812|    default:
  ------------------
  |  Branch (457:5): [True: 812, False: 15.8k]
  ------------------
  458|    812|        return false;
  459|  16.6k|    }
  460|  16.6k|}
_ZN17pgp_packet_body_tC2E14pgp_pkt_type_t:
  463|  1.60M|{
  464|  1.60M|    data_.reserve(16);
  465|  1.60M|    tag_ = tag;
  466|  1.60M|}
_ZN17pgp_packet_body_tC2EPKhm:
  469|  57.5k|{
  470|  57.5k|    data_.assign(data, data + len);
  471|  57.5k|    tag_ = PGP_PKT_RESERVED;
  472|  57.5k|}
_ZN17pgp_packet_body_tC2ERKNSt3__16vectorIhNS0_9allocatorIhEEEE:
  475|  56.9k|    : pgp_packet_body_t(data.data(), data.size())
  476|  56.9k|{
  477|  56.9k|}
_ZN17pgp_packet_body_t4dataEv:
  481|   131k|{
  482|   131k|    return data_.data();
  483|   131k|}
_ZN17pgp_packet_body_t3curEv:
  487|   116k|{
  488|   116k|    return data_.data() + pos_;
  489|   116k|}
_ZNK17pgp_packet_body_t4sizeEv:
  493|  1.02M|{
  494|  1.02M|    return data_.size();
  495|  1.02M|}
_ZNK17pgp_packet_body_t4leftEv:
  499|   385k|{
  500|   385k|    return data_.size() - pos_;
  501|   385k|}
_ZN17pgp_packet_body_t4skipEm:
  505|  32.8k|{
  506|  32.8k|    pos_ += bt;
  507|  32.8k|}
_ZN17pgp_packet_body_t9skip_backEm:
  511|  41.3k|{
  512|  41.3k|    pos_ = bt > pos_ ? 0 : pos_ - bt;
  ------------------
  |  Branch (512:12): [True: 0, False: 41.3k]
  ------------------
  513|  41.3k|}
_ZN17pgp_packet_body_t3getERh:
  517|   420k|{
  518|   420k|    if (pos_ >= data_.size()) {
  ------------------
  |  Branch (518:9): [True: 13.4k, False: 406k]
  ------------------
  519|  13.4k|        return false;
  520|  13.4k|    }
  521|   406k|    val = data_[pos_++];
  522|   406k|    return true;
  523|   420k|}
_ZN17pgp_packet_body_t3getERt:
  527|   232k|{
  528|   232k|    if (pos_ + 2 > data_.size()) {
  ------------------
  |  Branch (528:9): [True: 137, False: 231k]
  ------------------
  529|    137|        return false;
  530|    137|    }
  531|   231k|    val = read_uint16(data_.data() + pos_);
  532|   231k|    pos_ += 2;
  533|   231k|    return true;
  534|   232k|}
_ZN17pgp_packet_body_t3getERj:
  538|  62.3k|{
  539|  62.3k|    if (pos_ + 4 > data_.size()) {
  ------------------
  |  Branch (539:9): [True: 189, False: 62.1k]
  ------------------
  540|    189|        return false;
  541|    189|    }
  542|  62.1k|    val = read_uint32(data_.data() + pos_);
  543|  62.1k|    pos_ += 4;
  544|  62.1k|    return true;
  545|  62.3k|}
_ZN17pgp_packet_body_t3getEPhm:
  549|   367k|{
  550|   367k|    if (!len) {
  ------------------
  |  Branch (550:9): [True: 183, False: 366k]
  ------------------
  551|       |        /* Do not memcpy with a null destination and zero length, which is
  552|       |         * undefined behavior - callers may pass data() of an empty vector. */
  553|    183|        return true;
  554|    183|    }
  555|   366k|    if (pos_ + len > data_.size()) {
  ------------------
  |  Branch (555:9): [True: 10.6k, False: 356k]
  ------------------
  556|  10.6k|        return false;
  557|  10.6k|    }
  558|   356k|    memcpy(val, data_.data() + pos_, len);
  559|   356k|    pos_ += len;
  560|   356k|    return true;
  561|   366k|}
_ZN17pgp_packet_body_t3getERNSt3__16vectorIhNS0_9allocatorIhEEEEm:
  565|  78.7k|{
  566|  78.7k|    if (pos_ + len > data_.size()) {
  ------------------
  |  Branch (566:9): [True: 761, False: 78.0k]
  ------------------
  567|    761|        return false;
  568|    761|    }
  569|  78.0k|    val.assign(data_.data() + pos_, data_.data() + pos_ + len);
  570|  78.0k|    pos_ += len;
  571|  78.0k|    return true;
  572|  78.7k|}
_ZN17pgp_packet_body_t3getERNSt3__15arrayIhLm8EEE:
  576|    528|{
  577|    528|    static_assert(std::tuple_size<pgp::KeyID>::value == PGP_KEY_ID_SIZE,
  578|    528|                  "pgp::KeyID size mismatch");
  579|    528|    return get(val.data(), val.size());
  580|    528|}
_ZN17pgp_packet_body_t3getERN3pgp3mpiE:
  584|   146k|{
  585|   146k|    uint16_t bits = 0;
  586|   146k|    if (!get(bits)) {
  ------------------
  |  Branch (586:9): [True: 71, False: 146k]
  ------------------
  587|     71|        return false;
  588|     71|    }
  589|   146k|    size_t len = (bits + 7) >> 3;
  590|   146k|    if (len > PGP_MPINT_SIZE) {
  ------------------
  |  |   36|   146k|#define PGP_MPINT_SIZE (PGP_MPINT_BITS >> 3)
  |  |  ------------------
  |  |  |  |   35|   146k|#define PGP_MPINT_BITS (16384)
  |  |  ------------------
  ------------------
  |  Branch (590:9): [True: 2.39k, False: 144k]
  ------------------
  591|  2.39k|        RNP_LOG("too large mpi");
  ------------------
  |  |   84|  2.39k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.39k|    do {                                                                                 \
  |  |  |  |   77|  2.39k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.39k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.39k|            break;                                                                       \
  |  |  |  |   79|  2.39k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  592|  2.39k|        return false;
  593|  2.39k|    }
  594|   144k|    if (!len) {
  ------------------
  |  Branch (594:9): [True: 211, False: 143k]
  ------------------
  595|    211|        RNP_LOG("0 mpi");
  ------------------
  |  |   84|    211|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    211|    do {                                                                                 \
  |  |  |  |   77|    211|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 211, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    211|            break;                                                                       \
  |  |  |  |   79|    211|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  596|    211|        return false;
  597|    211|    }
  598|   143k|    val.resize(len);
  599|   143k|    if (!get(val.data(), len)) {
  ------------------
  |  Branch (599:9): [True: 1.74k, False: 142k]
  ------------------
  600|  1.74k|        RNP_LOG("failed to read mpi body");
  ------------------
  |  |   84|  1.74k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.74k|    do {                                                                                 \
  |  |  |  |   77|  1.74k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.74k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.74k|            break;                                                                       \
  |  |  |  |   79|  1.74k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  601|  1.74k|        return false;
  602|  1.74k|    }
  603|       |    /* check the mpi bit count */
  604|   142k|    size_t mbits = val.bits();
  605|   142k|    if (mbits != bits) {
  ------------------
  |  Branch (605:9): [True: 40.3k, False: 101k]
  ------------------
  606|  40.3k|        RNP_LOG(
  ------------------
  |  |   84|  40.3k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  40.3k|    do {                                                                                 \
  |  |  |  |   77|  40.3k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 40.3k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  40.3k|            break;                                                                       \
  |  |  |  |   79|  40.3k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  607|  40.3k|          "Warning! Wrong mpi bit count: got %" PRIu16 ", but actual is %zu", bits, mbits);
  608|  40.3k|    }
  609|   142k|    return true;
  610|   143k|}
_ZN17pgp_packet_body_t3getER11pgp_curve_t:
  614|  28.8k|{
  615|  28.8k|    uint8_t oidlen = 0;
  616|  28.8k|    if (!get(oidlen)) {
  ------------------
  |  Branch (616:9): [True: 12, False: 28.8k]
  ------------------
  617|     12|        return false;
  618|     12|    }
  619|  28.8k|    if (!oidlen || (oidlen == 0xff)) {
  ------------------
  |  Branch (619:9): [True: 41, False: 28.8k]
  |  Branch (619:20): [True: 43, False: 28.7k]
  ------------------
  620|     84|        RNP_LOG("unsupported curve oid len: %" PRIu8, oidlen);
  ------------------
  |  |   84|     84|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     84|    do {                                                                                 \
  |  |  |  |   77|     84|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 84, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     84|            break;                                                                       \
  |  |  |  |   79|     84|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  621|     84|        return false;
  622|     84|    }
  623|  28.7k|    std::vector<uint8_t> oid(oidlen, 0);
  624|  28.7k|    if (!get(oid, oidlen)) {
  ------------------
  |  Branch (624:9): [True: 148, False: 28.6k]
  ------------------
  625|    148|        return false;
  626|    148|    }
  627|  28.6k|    pgp_curve_t res = pgp::ec::Curve::by_OID(oid);
  628|  28.6k|    if (res == PGP_CURVE_MAX) {
  ------------------
  |  Branch (628:9): [True: 1.34k, False: 27.2k]
  ------------------
  629|  1.34k|        RNP_LOG("unsupported curve");
  ------------------
  |  |   84|  1.34k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.34k|    do {                                                                                 \
  |  |  |  |   77|  1.34k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.34k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.34k|            break;                                                                       \
  |  |  |  |   79|  1.34k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  630|  1.34k|        return false;
  631|  1.34k|    }
  632|  27.2k|    val = res;
  633|  27.2k|    return true;
  634|  28.6k|}
_ZN17pgp_packet_body_t3getER9pgp_s2k_t:
  638|  27.0k|{
  639|  27.0k|    uint8_t spec = 0, halg = 0;
  640|  27.0k|    if (!get(spec)) {
  ------------------
  |  Branch (640:9): [True: 336, False: 26.7k]
  ------------------
  641|    336|        return false;
  642|    336|    }
  643|  26.7k|    s2k.specifier = (pgp_s2k_specifier_t) spec;
  644|       |
  645|  26.7k|#if defined(ENABLE_CRYPTO_REFRESH)
  646|  26.7k|    if (s2k.specifier != PGP_S2KS_ARGON2)
  ------------------
  |  Branch (646:9): [True: 25.7k, False: 963]
  ------------------
  647|  25.7k|#endif
  648|  25.7k|    {
  649|  25.7k|        if (!get(halg)) {
  ------------------
  |  Branch (649:13): [True: 305, False: 25.4k]
  ------------------
  650|    305|            return false;
  651|    305|        }
  652|  25.4k|        s2k.hash_alg = (pgp_hash_alg_t) halg;
  653|  25.4k|    }
  654|       |
  655|  26.4k|    switch (s2k.specifier) {
  656|  2.34k|    case PGP_S2KS_SIMPLE:
  ------------------
  |  Branch (656:5): [True: 2.34k, False: 24.0k]
  ------------------
  657|  2.34k|        return true;
  658|  1.87k|    case PGP_S2KS_SALTED:
  ------------------
  |  Branch (658:5): [True: 1.87k, False: 24.5k]
  ------------------
  659|  1.87k|        return get(s2k.salt, s2k.salt_size(s2k.specifier));
  660|  11.6k|    case PGP_S2KS_ITERATED_AND_SALTED: {
  ------------------
  |  Branch (660:5): [True: 11.6k, False: 14.8k]
  ------------------
  661|  11.6k|        uint8_t iter = 0;
  662|  11.6k|        if (!get(s2k.salt, s2k.salt_size(s2k.specifier)) || !get(iter)) {
  ------------------
  |  Branch (662:13): [True: 331, False: 11.2k]
  |  Branch (662:61): [True: 568, False: 10.7k]
  ------------------
  663|    899|            return false;
  664|    899|        }
  665|  10.7k|        s2k.iterations = iter;
  666|  10.7k|        return true;
  667|  11.6k|    }
  668|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  669|    963|    case PGP_S2KS_ARGON2:
  ------------------
  |  Branch (669:5): [True: 963, False: 25.4k]
  ------------------
  670|    963|        if (!get(s2k.salt, s2k.salt_size(s2k.specifier))) {
  ------------------
  |  Branch (670:13): [True: 391, False: 572]
  ------------------
  671|    391|            return false;
  672|    391|        }
  673|    572|        if (!get(s2k.argon2_t)) {
  ------------------
  |  Branch (673:13): [True: 18, False: 554]
  ------------------
  674|     18|            return false;
  675|     18|        }
  676|    554|        if (!get(s2k.argon2_p)) {
  ------------------
  |  Branch (676:13): [True: 35, False: 519]
  ------------------
  677|     35|            return false;
  678|     35|        }
  679|    519|        if (!get(s2k.argon2_encoded_m)) {
  ------------------
  |  Branch (679:13): [True: 36, False: 483]
  ------------------
  680|     36|            return false;
  681|     36|        }
  682|    483|        return true;
  683|      0|#endif
  684|  8.17k|    case PGP_S2KS_EXPERIMENTAL: {
  ------------------
  |  Branch (684:5): [True: 8.17k, False: 18.2k]
  ------------------
  685|  8.17k|        try {
  686|  8.17k|            s2k.experimental = {data_.begin() + pos_, data_.end()};
  687|  8.17k|        } catch (const std::exception &e) {
  688|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  689|      0|            return false;
  690|      0|        }
  691|  8.17k|        uint8_t gnu[3] = {0};
  692|  8.17k|        if (!get(gnu, 3) || memcmp(gnu, "GNU", 3)) {
  ------------------
  |  Branch (692:13): [True: 5.32k, False: 2.85k]
  |  Branch (692:29): [True: 2.42k, False: 423]
  ------------------
  693|  7.75k|            RNP_LOG("Unknown experimental s2k. Skipping.");
  ------------------
  |  |   84|  7.75k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  7.75k|    do {                                                                                 \
  |  |  |  |   77|  7.75k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7.75k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  7.75k|            break;                                                                       \
  |  |  |  |   79|  7.75k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  694|  7.75k|            pos_ = data_.size();
  695|  7.75k|            s2k.gpg_ext_num = PGP_S2K_GPG_NONE;
  696|  7.75k|            return true;
  697|  7.75k|        }
  698|    423|        uint8_t ext_num = 0;
  699|    423|        if (!get(ext_num)) {
  ------------------
  |  Branch (699:13): [True: 1, False: 422]
  ------------------
  700|      1|            return false;
  701|      1|        }
  702|    422|        if ((ext_num != PGP_S2K_GPG_NO_SECRET) && (ext_num != PGP_S2K_GPG_SMARTCARD)) {
  ------------------
  |  Branch (702:13): [True: 408, False: 14]
  |  Branch (702:51): [True: 15, False: 393]
  ------------------
  703|     15|            RNP_LOG("Unsupported gpg extension num: %" PRIu8 ", skipping", ext_num);
  ------------------
  |  |   84|     15|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     15|    do {                                                                                 \
  |  |  |  |   77|     15|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 15, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     15|            break;                                                                       \
  |  |  |  |   79|     15|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  704|     15|            pos_ = data_.size();
  705|     15|            s2k.gpg_ext_num = PGP_S2K_GPG_NONE;
  706|     15|            return true;
  707|     15|        }
  708|    407|        s2k.gpg_ext_num = (pgp_s2k_gpg_extension_t) ext_num;
  709|    407|        if (s2k.gpg_ext_num == PGP_S2K_GPG_NO_SECRET) {
  ------------------
  |  Branch (709:13): [True: 14, False: 393]
  ------------------
  710|     14|            return true;
  711|     14|        }
  712|    393|        if (!get(s2k.gpg_serial_len)) {
  ------------------
  |  Branch (712:13): [True: 6, False: 387]
  ------------------
  713|      6|            RNP_LOG("Failed to get GPG serial len");
  ------------------
  |  |   84|      6|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      6|    do {                                                                                 \
  |  |  |  |   77|      6|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 6, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      6|            break;                                                                       \
  |  |  |  |   79|      6|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  714|      6|            return false;
  715|      6|        }
  716|    387|        size_t len = s2k.gpg_serial_len;
  717|    387|        if (s2k.gpg_serial_len > 16) {
  ------------------
  |  Branch (717:13): [True: 372, False: 15]
  ------------------
  718|    372|            RNP_LOG("Warning: gpg_serial_len is %d", (int) len);
  ------------------
  |  |   84|    372|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    372|    do {                                                                                 \
  |  |  |  |   77|    372|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 372, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    372|            break;                                                                       \
  |  |  |  |   79|    372|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  719|    372|            len = 16;
  720|    372|        }
  721|    387|        if (!get(s2k.gpg_serial, len)) {
  ------------------
  |  Branch (721:13): [True: 3, False: 384]
  ------------------
  722|      3|            RNP_LOG("Failed to get GPG serial");
  ------------------
  |  |   84|      3|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      3|    do {                                                                                 \
  |  |  |  |   77|      3|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      3|            break;                                                                       \
  |  |  |  |   79|      3|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  723|      3|            return false;
  724|      3|        }
  725|    384|        return true;
  726|    387|    }
  727|  1.44k|    default:
  ------------------
  |  Branch (727:5): [True: 1.44k, False: 24.9k]
  ------------------
  728|  1.44k|        RNP_LOG("unknown s2k specifier: %d", (int) s2k.specifier);
  ------------------
  |  |   84|  1.44k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.44k|    do {                                                                                 \
  |  |  |  |   77|  1.44k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.44k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.44k|            break;                                                                       \
  |  |  |  |   79|  1.44k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  729|  1.44k|        return false;
  730|  26.4k|    }
  731|  26.4k|}
_ZN17pgp_packet_body_t3addEPKvm:
  735|   675k|{
  736|   675k|    data_.insert(data_.end(), (uint8_t *) data, (uint8_t *) data + len);
  737|   675k|}
_ZN17pgp_packet_body_t3addERKNSt3__16vectorIhNS0_9allocatorIhEEEE:
  741|   147k|{
  742|   147k|    add(data.data(), data.size());
  743|   147k|}
_ZN17pgp_packet_body_t8add_byteEh:
  747|   172k|{
  748|   172k|    data_.push_back(bt);
  749|   172k|}
_ZN17pgp_packet_body_t10add_uint16Et:
  753|  28.7k|{
  754|  28.7k|    uint8_t bytes[2];
  755|  28.7k|    write_uint16(bytes, val);
  756|  28.7k|    add(bytes, 2);
  757|  28.7k|}
_ZN17pgp_packet_body_t10add_uint32Ej:
  761|     22|{
  762|     22|    uint8_t bytes[4];
  763|     22|    write_uint32(bytes, val);
  764|     22|    add(bytes, 4);
  765|     22|}
_ZN17pgp_packet_body_t3addERKNSt3__15arrayIhLm8EEE:
  769|  12.0k|{
  770|  12.0k|    add(val.data(), val.size());
  771|  12.0k|}
_ZN17pgp_packet_body_t3addERKN3pgp3mpiE:
  775|     82|{
  776|     82|    if (!val.size()) {
  ------------------
  |  Branch (776:9): [True: 0, False: 82]
  ------------------
  777|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  778|      0|    }
  779|       |
  780|     82|    size_t idx = 0;
  781|     83|    while ((idx < val.size() - 1) && (!val[idx])) {
  ------------------
  |  Branch (781:12): [True: 83, False: 0]
  |  Branch (781:38): [True: 1, False: 82]
  ------------------
  782|      1|        idx++;
  783|      1|    }
  784|       |
  785|     82|    size_t  bits = (val.size() - idx - 1) << 3;
  786|     82|    uint8_t hibyte = val[idx];
  787|    658|    while (hibyte) {
  ------------------
  |  Branch (787:12): [True: 576, False: 82]
  ------------------
  788|    576|        bits++;
  789|    576|        hibyte = hibyte >> 1;
  790|    576|    }
  791|       |
  792|     82|    uint8_t hdr[2] = {(uint8_t)(bits >> 8), (uint8_t)(bits & 0xff)};
  793|     82|    add(hdr, 2);
  794|     82|    add(val.data() + idx, val.size() - idx);
  795|     82|}
_ZN17pgp_packet_body_t14add_subpacketsERKN3pgp3pkt9SignatureEb:
  799|  28.7k|{
  800|  28.7k|    pgp_packet_body_t spbody(PGP_PKT_RESERVED);
  801|       |
  802|   186k|    for (auto &subpkt : sig.subpkts) {
  ------------------
  |  Branch (802:23): [True: 186k, False: 28.7k]
  ------------------
  803|   186k|        if (subpkt->hashed() != hashed) {
  ------------------
  |  Branch (803:13): [True: 158k, False: 28.3k]
  ------------------
  804|   158k|            continue;
  805|   158k|        }
  806|       |
  807|  28.3k|        uint8_t splen[6];
  808|  28.3k|        size_t  lenlen = write_packet_len(splen, subpkt->data().size() + 1);
  809|  28.3k|        spbody.add(splen, lenlen);
  810|  28.3k|        spbody.add_byte(subpkt->raw_type() | (subpkt->critical() << 7));
  811|  28.3k|        spbody.add(subpkt->data().data(), subpkt->data().size());
  812|  28.3k|    }
  813|       |
  814|  28.7k|    if (spbody.data_.size() > 0xffff) {
  ------------------
  |  Branch (814:9): [True: 0, False: 28.7k]
  ------------------
  815|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  816|      0|    }
  817|  28.7k|    switch (sig.version) {
  818|  28.2k|    case PGP_V4:
  ------------------
  |  Branch (818:5): [True: 28.2k, False: 492]
  ------------------
  819|  28.7k|    case PGP_V5:
  ------------------
  |  Branch (819:5): [True: 470, False: 28.2k]
  ------------------
  820|  28.7k|        add_uint16(spbody.data_.size());
  821|  28.7k|        break;
  822|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  823|     22|    case PGP_V6:
  ------------------
  |  Branch (823:5): [True: 22, False: 28.7k]
  ------------------
  824|     22|        add_uint32(spbody.data_.size());
  825|     22|        break;
  826|      0|#endif
  827|      0|    default:
  ------------------
  |  Branch (827:5): [True: 0, False: 28.7k]
  ------------------
  828|      0|        RNP_LOG("should not reach this code");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  829|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_STATE);
  830|  28.7k|    }
  831|  28.7k|    add(spbody.data_.data(), spbody.data_.size());
  832|  28.7k|}
_ZN17pgp_packet_body_t3addERK9pgp_s2k_t13pgp_version_t:
  847|  10.6k|{
  848|  10.6k|#if defined(ENABLE_CRYPTO_REFRESH)
  849|  10.6k|    if (version == PGP_V6 && s2k.usage != PGP_S2KU_NONE) {
  ------------------
  |  Branch (849:9): [True: 1.89k, False: 8.73k]
  |  Branch (849:30): [True: 1.89k, False: 0]
  ------------------
  850|  1.89k|        add_byte(pgp_s2k_t::specifier_len(s2k.specifier));
  851|  1.89k|    }
  852|  10.6k|#endif
  853|  10.6k|    add_byte(s2k.specifier);
  854|       |
  855|  10.6k|    switch (s2k.specifier) {
  856|  4.84k|    case PGP_S2KS_SIMPLE:
  ------------------
  |  Branch (856:5): [True: 4.84k, False: 5.78k]
  ------------------
  857|  4.84k|        add_byte(s2k.hash_alg);
  858|  4.84k|        return;
  859|     22|    case PGP_S2KS_SALTED:
  ------------------
  |  Branch (859:5): [True: 22, False: 10.6k]
  ------------------
  860|     22|        add_byte(s2k.hash_alg);
  861|     22|        add(s2k.salt, s2k.salt_size(s2k.specifier));
  862|     22|        return;
  863|  1.21k|    case PGP_S2KS_ITERATED_AND_SALTED: {
  ------------------
  |  Branch (863:5): [True: 1.21k, False: 9.41k]
  ------------------
  864|  1.21k|        add_byte(s2k.hash_alg);
  865|  1.21k|        unsigned iter = s2k.iterations;
  866|  1.21k|        if (iter > 255) {
  ------------------
  |  Branch (866:13): [True: 0, False: 1.21k]
  ------------------
  867|      0|            iter = pgp_s2k_encode_iterations(iter);
  868|      0|        }
  869|  1.21k|        add(s2k.salt, s2k.salt_size(s2k.specifier));
  870|  1.21k|        add_byte(iter);
  871|  1.21k|        return;
  872|      0|    }
  873|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  874|     34|    case PGP_S2KS_ARGON2:
  ------------------
  |  Branch (874:5): [True: 34, False: 10.5k]
  ------------------
  875|     34|        add(s2k.salt, s2k.salt_size(s2k.specifier));
  876|     34|        add_byte(s2k.argon2_t);
  877|     34|        add_byte(s2k.argon2_p);
  878|     34|        add_byte(s2k.argon2_encoded_m);
  879|     34|        return;
  880|      0|#endif
  881|  4.51k|    case PGP_S2KS_EXPERIMENTAL: {
  ------------------
  |  Branch (881:5): [True: 4.51k, False: 6.11k]
  ------------------
  882|  4.51k|        add_byte(s2k.hash_alg);
  883|  4.51k|        if ((s2k.gpg_ext_num != PGP_S2K_GPG_NO_SECRET) &&
  ------------------
  |  Branch (883:13): [True: 4.50k, False: 12]
  ------------------
  884|  4.50k|            (s2k.gpg_ext_num != PGP_S2K_GPG_SMARTCARD)) {
  ------------------
  |  Branch (884:13): [True: 4.29k, False: 211]
  ------------------
  885|  4.29k|            RNP_LOG("Unknown experimental s2k.");
  ------------------
  |  |   84|  4.29k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  4.29k|    do {                                                                                 \
  |  |  |  |   77|  4.29k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.29k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.29k|            break;                                                                       \
  |  |  |  |   79|  4.29k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  886|  4.29k|            add(s2k.experimental.data(), s2k.experimental.size());
  887|  4.29k|            return;
  888|  4.29k|        }
  889|    223|        add("GNU", 3);
  890|    223|        add_byte(s2k.gpg_ext_num);
  891|    223|        if (s2k.gpg_ext_num == PGP_S2K_GPG_SMARTCARD) {
  ------------------
  |  Branch (891:13): [True: 211, False: 12]
  ------------------
  892|    211|            static_assert(sizeof(s2k.gpg_serial) == 16, "invalid gpg serial length");
  893|    211|            size_t slen = s2k.gpg_serial_len > 16 ? 16 : s2k.gpg_serial_len;
  ------------------
  |  Branch (893:27): [True: 198, False: 13]
  ------------------
  894|    211|            add_byte(s2k.gpg_serial_len);
  895|    211|            add(s2k.gpg_serial, slen);
  896|    211|        }
  897|    223|        return;
  898|  4.51k|    }
  899|      0|    default:
  ------------------
  |  Branch (899:5): [True: 0, False: 10.6k]
  ------------------
  900|      0|        RNP_LOG("unknown s2k specifier");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  901|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  902|  10.6k|    }
  903|  10.6k|}
_ZN17pgp_packet_body_t4readER12pgp_source_t:
  907|  1.14M|{
  908|       |    /* Make sure we have enough data for packet header */
  909|  1.14M|    if (!src.peek_eq(hdr_, 2)) {
  ------------------
  |  Branch (909:9): [True: 151, False: 1.14M]
  ------------------
  910|    151|        return RNP_ERROR_READ;
  911|    151|    }
  912|       |
  913|       |    /* Read the packet header and length */
  914|  1.14M|    size_t len = 0;
  915|  1.14M|    if (!stream_pkt_hdr_len(src, len)) {
  ------------------
  |  Branch (915:9): [True: 0, False: 1.14M]
  ------------------
  916|      0|        return RNP_ERROR_BAD_FORMAT;
  917|      0|    }
  918|  1.14M|    if (!src.peek_eq(hdr_, len)) {
  ------------------
  |  Branch (918:9): [True: 89, False: 1.14M]
  ------------------
  919|     89|        return RNP_ERROR_READ;
  920|     89|    }
  921|  1.14M|    hdr_len_ = len;
  922|       |
  923|  1.14M|    int ptag = get_packet_type(hdr_[0]);
  924|  1.14M|    if ((ptag < 0) || ((tag_ != PGP_PKT_RESERVED) && (tag_ != ptag))) {
  ------------------
  |  Branch (924:9): [True: 0, False: 1.14M]
  |  Branch (924:24): [True: 629k, False: 511k]
  |  Branch (924:54): [True: 0, False: 629k]
  ------------------
  925|      0|        RNP_LOG("tag mismatch: %d vs %d", (int) tag_, ptag);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  926|      0|        return RNP_ERROR_BAD_FORMAT;
  927|      0|    }
  928|  1.14M|    tag_ = (pgp_pkt_type_t) ptag;
  929|       |
  930|  1.14M|    if (!stream_read_pkt_len(src, &len)) {
  ------------------
  |  Branch (930:9): [True: 276k, False: 864k]
  ------------------
  931|   276k|        return RNP_ERROR_READ;
  932|   276k|    }
  933|       |
  934|       |    /* early exit for the empty packet */
  935|   864k|    if (!len) {
  ------------------
  |  Branch (935:9): [True: 556k, False: 307k]
  ------------------
  936|   556k|        return RNP_SUCCESS;
  937|   556k|    }
  938|       |
  939|   307k|    if (len > PGP_MAX_PKT_SIZE) {
  ------------------
  |  |   40|   307k|#define PGP_MAX_PKT_SIZE 0x100000
  ------------------
  |  Branch (939:9): [True: 94.4k, False: 213k]
  ------------------
  940|  94.4k|        RNP_LOG("too large packet");
  ------------------
  |  |   84|  94.4k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  94.4k|    do {                                                                                 \
  |  |  |  |   77|  94.4k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 94.4k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  94.4k|            break;                                                                       \
  |  |  |  |   79|  94.4k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  941|  94.4k|        return RNP_ERROR_BAD_FORMAT;
  942|  94.4k|    }
  943|       |
  944|       |    /* Read the packet contents */
  945|   213k|    try {
  946|   213k|        data_.resize(len);
  947|   213k|    } catch (const std::exception &e) {
  948|      0|        RNP_LOG("malloc of %d bytes failed, %s", (int) len, e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  949|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  950|      0|    }
  951|       |
  952|   213k|    size_t read = 0;
  953|   213k|    if (!src.read(data_.data(), len, &read) || (read != len)) {
  ------------------
  |  Branch (953:9): [True: 6, False: 213k]
  |  Branch (953:48): [True: 4.82k, False: 208k]
  ------------------
  954|  4.83k|        RNP_LOG("read %d instead of %d", (int) read, (int) len);
  ------------------
  |  |   84|  4.83k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  4.83k|    do {                                                                                 \
  |  |  |  |   77|  4.83k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.83k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.83k|            break;                                                                       \
  |  |  |  |   79|  4.83k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  955|  4.83k|        return RNP_ERROR_READ;
  956|  4.83k|    }
  957|   208k|    pos_ = 0;
  958|   208k|    return RNP_SUCCESS;
  959|   213k|}
_ZN17pgp_packet_body_t5writeER10pgp_dest_tb:
  963|   426k|{
  964|   426k|    if (hdr) {
  ------------------
  |  Branch (964:9): [True: 426k, False: 0]
  ------------------
  965|   426k|        uint8_t hdrbt[6] = {
  966|   426k|          (uint8_t)(tag_ | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT), 0, 0, 0, 0, 0};
  ------------------
  |  |   47|   426k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                        (uint8_t)(tag_ | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT), 0, 0, 0, 0, 0};
  ------------------
  |  |   56|   426k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  967|   426k|        size_t hlen = 1 + write_packet_len(&hdrbt[1], data_.size());
  968|   426k|        dst_write(&dst, hdrbt, hlen);
  969|   426k|    }
  970|   426k|    dst_write(&dst, data_.data(), data_.size());
  971|   426k|}
_ZNK16pgp_sk_sesskey_t5writeER10pgp_dest_t:
  975|  8.10k|{
  976|  8.10k|    pgp_packet_body_t pktbody(PGP_PKT_SK_SESSION_KEY);
  977|       |    /* version and algorithm fields */
  978|  8.10k|    pktbody.add_byte(version);
  979|  8.10k|#if defined(ENABLE_CRYPTO_REFRESH)
  980|  8.10k|    uint8_t s2k_len;
  981|       |    /* A one-octet scalar octet count for the 5 fields following this octet. */
  982|  8.10k|    if (version == PGP_SKSK_V6) {
  ------------------
  |  Branch (982:9): [True: 1.69k, False: 6.40k]
  ------------------
  983|  1.69k|        s2k_len = pgp_s2k_t::specifier_len(s2k.specifier);
  984|  1.69k|        pktbody.add_byte(3 + s2k_len + ivlen);
  985|  1.69k|    }
  986|  8.10k|#endif
  987|  8.10k|    pktbody.add_byte(alg);
  988|  8.10k|    if (version == PGP_SKSK_V5
  ------------------
  |  Branch (988:9): [True: 2.07k, False: 6.03k]
  ------------------
  989|  6.03k|#if defined(ENABLE_CRYPTO_REFRESH)
  990|  6.03k|        || version == PGP_SKSK_V6
  ------------------
  |  Branch (990:12): [True: 1.69k, False: 4.33k]
  ------------------
  991|  8.10k|#endif
  992|  8.10k|    ) {
  993|  3.77k|        pktbody.add_byte(aalg);
  994|  3.77k|    }
  995|       |/* S2K specifier */
  996|  8.10k|#if defined(ENABLE_CRYPTO_REFRESH)
  997|       |    /* A one-octet scalar octet count of the following field. */
  998|  8.10k|    if (version == PGP_SKSK_V6) {
  ------------------
  |  Branch (998:9): [True: 1.69k, False: 6.40k]
  ------------------
  999|  1.69k|        pktbody.add_byte(s2k_len);
 1000|  1.69k|    }
 1001|  8.10k|#endif
 1002|  8.10k|    pktbody.add_byte(s2k.specifier);
 1003|  8.10k|#if defined(ENABLE_CRYPTO_REFRESH)
 1004|  8.10k|    if (s2k.specifier != PGP_S2KS_ARGON2)
  ------------------
  |  Branch (1004:9): [True: 8.10k, False: 0]
  ------------------
 1005|  8.10k|#endif
 1006|  8.10k|    {
 1007|  8.10k|        pktbody.add_byte(s2k.hash_alg);
 1008|  8.10k|    }
 1009|       |
 1010|  8.10k|    switch (s2k.specifier) {
 1011|      0|    case PGP_S2KS_SIMPLE:
  ------------------
  |  Branch (1011:5): [True: 0, False: 8.10k]
  ------------------
 1012|      0|        break;
 1013|      0|    case PGP_S2KS_SALTED:
  ------------------
  |  Branch (1013:5): [True: 0, False: 8.10k]
  ------------------
 1014|      0|        pktbody.add(s2k.salt, s2k.salt_size(s2k.specifier));
 1015|      0|        break;
 1016|  8.10k|    case PGP_S2KS_ITERATED_AND_SALTED:
  ------------------
  |  Branch (1016:5): [True: 8.10k, False: 0]
  ------------------
 1017|  8.10k|        pktbody.add(s2k.salt, s2k.salt_size(s2k.specifier));
 1018|  8.10k|        pktbody.add_byte(s2k.iterations);
 1019|  8.10k|        break;
 1020|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 1021|      0|    case PGP_S2KS_ARGON2:
  ------------------
  |  Branch (1021:5): [True: 0, False: 8.10k]
  ------------------
 1022|      0|        pktbody.add(s2k.salt, s2k.salt_size(s2k.specifier));
 1023|      0|        pktbody.add_byte(s2k.argon2_t);
 1024|      0|        pktbody.add_byte(s2k.argon2_p);
 1025|      0|        pktbody.add_byte(s2k.argon2_encoded_m);
 1026|      0|        break;
 1027|      0|#endif
 1028|      0|    default:
  ------------------
  |  Branch (1028:5): [True: 0, False: 8.10k]
  ------------------
 1029|      0|        RNP_LOG("Unexpected s2k specifier: %d", (int) s2k.specifier);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1030|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1031|  8.10k|    }
 1032|       |    /* v5 : iv */
 1033|  8.10k|    if (version == PGP_SKSK_V5
  ------------------
  |  Branch (1033:9): [True: 2.07k, False: 6.03k]
  ------------------
 1034|  6.03k|#if defined(ENABLE_CRYPTO_REFRESH)
 1035|  6.03k|        || version == PGP_SKSK_V6
  ------------------
  |  Branch (1035:12): [True: 1.69k, False: 4.33k]
  ------------------
 1036|  8.10k|#endif
 1037|  8.10k|    ) {
 1038|  3.77k|        pktbody.add(iv, ivlen);
 1039|  3.77k|    }
 1040|       |    /* encrypted key and auth tag for v5 */
 1041|  8.10k|    if (enckeylen) {
  ------------------
  |  Branch (1041:9): [True: 3.79k, False: 4.31k]
  ------------------
 1042|  3.79k|        pktbody.add(enckey, enckeylen);
 1043|  3.79k|    }
 1044|       |    /* write packet */
 1045|  8.10k|    pktbody.write(dst);
 1046|  8.10k|}
_ZN16pgp_sk_sesskey_t8parse_v6ER17pgp_packet_body_t:
 1051|  10.7k|{
 1052|  10.7k|    uint8_t bt;
 1053|  10.7k|    uint8_t octet_count;
 1054|  10.7k|    uint8_t s2k_len;
 1055|       |
 1056|       |    /* A one-octet scalar octet count for the 5 fields following this octet. */
 1057|       |    /* TODO: do we need to check octet_count? */
 1058|  10.7k|    if (!pkt.get(octet_count)) {
  ------------------
  |  Branch (1058:9): [True: 1.13k, False: 9.65k]
  ------------------
 1059|  1.13k|        RNP_LOG("failed to get octet count of next 5 fields");
  ------------------
  |  |   84|  1.13k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.13k|    do {                                                                                 \
  |  |  |  |   77|  1.13k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.13k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.13k|            break;                                                                       \
  |  |  |  |   79|  1.13k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1060|  1.13k|        return RNP_ERROR_BAD_FORMAT;
 1061|  1.13k|    }
 1062|       |
 1063|       |    /* symmetric algorithm */
 1064|  9.65k|    if (!pkt.get(bt)) {
  ------------------
  |  Branch (1064:9): [True: 3.30k, False: 6.34k]
  ------------------
 1065|  3.30k|        RNP_LOG("failed to get symm alg");
  ------------------
  |  |   84|  3.30k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  3.30k|    do {                                                                                 \
  |  |  |  |   77|  3.30k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3.30k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  3.30k|            break;                                                                       \
  |  |  |  |   79|  3.30k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1066|  3.30k|        return RNP_ERROR_BAD_FORMAT;
 1067|  3.30k|    }
 1068|  6.34k|    alg = (pgp_symm_alg_t) bt;
 1069|       |
 1070|       |    /* aead algorithm */
 1071|  6.34k|    if (!pkt.get(bt)) {
  ------------------
  |  Branch (1071:9): [True: 87, False: 6.25k]
  ------------------
 1072|     87|        RNP_LOG("failed to get aead alg");
  ------------------
  |  |   84|     87|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     87|    do {                                                                                 \
  |  |  |  |   77|     87|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 87, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     87|            break;                                                                       \
  |  |  |  |   79|     87|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1073|     87|        return RNP_ERROR_BAD_FORMAT;
 1074|     87|    }
 1075|  6.25k|    aalg = (pgp_aead_alg_t) bt;
 1076|  6.25k|    if ((aalg != PGP_AEAD_EAX) && (aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (1076:9): [True: 1.71k, False: 4.54k]
  |  Branch (1076:35): [True: 838, False: 877]
  ------------------
 1077|    838|#if defined(ENABLE_AEAD_GCM)
 1078|    838|        && (aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (1078:12): [True: 419, False: 419]
  ------------------
 1079|  6.25k|#endif
 1080|  6.25k|    ) {
 1081|    419|        RNP_LOG("unsupported AEAD algorithm : %d", (int) aalg);
  ------------------
  |  |   84|    419|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    419|    do {                                                                                 \
  |  |  |  |   77|    419|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 419, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    419|            break;                                                                       \
  |  |  |  |   79|    419|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1082|    419|        return RNP_ERROR_BAD_PARAMETERS;
 1083|    419|    }
 1084|       |
 1085|       |    /* A one-octet scalar octet count of the following field. */
 1086|       |    /* TODO: do we need to check s2k_len? */
 1087|  5.83k|    if (!pkt.get(s2k_len)) {
  ------------------
  |  Branch (1087:9): [True: 18, False: 5.82k]
  ------------------
 1088|     18|        RNP_LOG("failed to get octet count of next 5 fields");
  ------------------
  |  |   84|     18|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     18|    do {                                                                                 \
  |  |  |  |   77|     18|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 18, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     18|            break;                                                                       \
  |  |  |  |   79|     18|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1089|     18|        return RNP_ERROR_BAD_FORMAT;
 1090|     18|    }
 1091|       |
 1092|       |    /* s2k */
 1093|  5.82k|    if (!pkt.get(s2k)) {
  ------------------
  |  Branch (1093:9): [True: 1.24k, False: 4.57k]
  ------------------
 1094|  1.24k|        RNP_LOG("failed to parse s2k");
  ------------------
  |  |   84|  1.24k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.24k|    do {                                                                                 \
  |  |  |  |   77|  1.24k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.24k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.24k|            break;                                                                       \
  |  |  |  |   79|  1.24k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1095|  1.24k|        return RNP_ERROR_BAD_FORMAT;
 1096|  1.24k|    }
 1097|       |
 1098|  4.57k|    size_t noncelen = pgp_cipher_aead_nonce_len(aalg);
 1099|  4.57k|    size_t taglen = pgp_cipher_aead_tag_len(aalg);
 1100|  4.57k|    size_t keylen = 0;
 1101|       |
 1102|  4.57k|    if (pkt.left() > noncelen + taglen + PGP_MAX_KEY_SIZE) {
  ------------------
  |  |   89|  4.57k|#define PGP_MAX_KEY_SIZE 32
  ------------------
  |  Branch (1102:9): [True: 33, False: 4.54k]
  ------------------
 1103|     33|        RNP_LOG("too long esk");
  ------------------
  |  |   84|     33|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     33|    do {                                                                                 \
  |  |  |  |   77|     33|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 33, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     33|            break;                                                                       \
  |  |  |  |   79|     33|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1104|     33|        return RNP_ERROR_BAD_FORMAT;
 1105|     33|    }
 1106|  4.54k|    if (pkt.left() < noncelen + taglen + 8) {
  ------------------
  |  Branch (1106:9): [True: 2.07k, False: 2.46k]
  ------------------
 1107|  2.07k|        RNP_LOG("too short esk");
  ------------------
  |  |   84|  2.07k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  2.07k|    do {                                                                                 \
  |  |  |  |   77|  2.07k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2.07k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  2.07k|            break;                                                                       \
  |  |  |  |   79|  2.07k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1108|  2.07k|        return RNP_ERROR_BAD_FORMAT;
 1109|  2.07k|    }
 1110|       |    /* iv */
 1111|  2.46k|    if (!pkt.get(iv, noncelen)) {
  ------------------
  |  Branch (1111:9): [True: 0, False: 2.46k]
  ------------------
 1112|      0|        RNP_LOG("failed to get iv");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1113|      0|        return RNP_ERROR_BAD_FORMAT;
 1114|      0|    }
 1115|  2.46k|    ivlen = noncelen;
 1116|       |
 1117|       |    /* key */
 1118|  2.46k|    keylen = pkt.left();
 1119|  2.46k|    if (!pkt.get(enckey, keylen)) {
  ------------------
  |  Branch (1119:9): [True: 0, False: 2.46k]
  ------------------
 1120|      0|        RNP_LOG("failed to get key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1121|      0|        return RNP_ERROR_BAD_FORMAT;
 1122|      0|    }
 1123|  2.46k|    enckeylen = keylen;
 1124|  2.46k|    return RNP_SUCCESS;
 1125|  2.46k|}
_ZN16pgp_sk_sesskey_t5parseER12pgp_source_t:
 1130|  69.5k|{
 1131|  69.5k|    pgp_packet_body_t pkt(PGP_PKT_SK_SESSION_KEY);
 1132|  69.5k|    rnp_result_t      res = pkt.read(src);
 1133|  69.5k|    if (res) {
  ------------------
  |  Branch (1133:9): [True: 46.1k, False: 23.3k]
  ------------------
 1134|  46.1k|        return res;
 1135|  46.1k|    }
 1136|       |
 1137|       |    /* version */
 1138|  23.3k|    uint8_t bt;
 1139|  23.3k|    if (!pkt.get(bt) || ((bt != PGP_SKSK_V4) && (bt != PGP_SKSK_V5))) {
  ------------------
  |  Branch (1139:9): [True: 1.13k, False: 22.2k]
  |  Branch (1139:26): [True: 14.0k, False: 8.18k]
  |  Branch (1139:49): [True: 10.3k, False: 3.68k]
  ------------------
 1140|  11.4k|#if defined(ENABLE_CRYPTO_REFRESH)
 1141|  11.4k|        if (bt == PGP_SKSK_V6) {
  ------------------
  |  Branch (1141:13): [True: 10.7k, False: 702]
  ------------------
 1142|  10.7k|            version = bt;
 1143|  10.7k|            return parse_v6(pkt);
 1144|  10.7k|        }
 1145|    702|#endif
 1146|    702|        RNP_LOG("wrong packet version");
  ------------------
  |  |   84|    702|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    702|    do {                                                                                 \
  |  |  |  |   77|    702|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 702, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    702|            break;                                                                       \
  |  |  |  |   79|    702|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1147|    702|        return RNP_ERROR_BAD_FORMAT;
 1148|  11.4k|    }
 1149|  11.8k|    version = bt;
 1150|       |    /* symmetric algorithm */
 1151|  11.8k|    if (!pkt.get(bt)) {
  ------------------
  |  Branch (1151:9): [True: 105, False: 11.7k]
  ------------------
 1152|    105|        RNP_LOG("failed to get symm alg");
  ------------------
  |  |   84|    105|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    105|    do {                                                                                 \
  |  |  |  |   77|    105|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 105, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    105|            break;                                                                       \
  |  |  |  |   79|    105|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1153|    105|        return RNP_ERROR_BAD_FORMAT;
 1154|    105|    }
 1155|  11.7k|    alg = (pgp_symm_alg_t) bt;
 1156|       |
 1157|  11.7k|    if (version == PGP_SKSK_V5) {
  ------------------
  |  Branch (1157:9): [True: 3.68k, False: 8.08k]
  ------------------
 1158|       |        /* aead algorithm */
 1159|  3.68k|        if (!pkt.get(bt)) {
  ------------------
  |  Branch (1159:13): [True: 10, False: 3.67k]
  ------------------
 1160|     10|            RNP_LOG("failed to get aead alg");
  ------------------
  |  |   84|     10|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     10|    do {                                                                                 \
  |  |  |  |   77|     10|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     10|            break;                                                                       \
  |  |  |  |   79|     10|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1161|     10|            return RNP_ERROR_BAD_FORMAT;
 1162|     10|        }
 1163|  3.67k|        aalg = (pgp_aead_alg_t) bt;
 1164|  3.67k|        if ((aalg != PGP_AEAD_EAX) && (aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (1164:13): [True: 2.93k, False: 740]
  |  Branch (1164:39): [True: 992, False: 1.94k]
  ------------------
 1165|    992|#if defined(ENABLE_AEAD_GCM)
 1166|    992|            && (aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (1166:16): [True: 266, False: 726]
  ------------------
 1167|  3.67k|#endif
 1168|  3.67k|        ) {
 1169|    266|            RNP_LOG("unsupported AEAD algorithm : %d", (int) aalg);
  ------------------
  |  |   84|    266|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    266|    do {                                                                                 \
  |  |  |  |   77|    266|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 266, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    266|            break;                                                                       \
  |  |  |  |   79|    266|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1170|    266|            return RNP_ERROR_BAD_PARAMETERS;
 1171|    266|        }
 1172|  3.67k|    }
 1173|       |
 1174|       |    /* s2k */
 1175|  11.4k|    if (!pkt.get(s2k)) {
  ------------------
  |  Branch (1175:9): [True: 1.99k, False: 9.49k]
  ------------------
 1176|  1.99k|        RNP_LOG("failed to parse s2k");
  ------------------
  |  |   84|  1.99k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.99k|    do {                                                                                 \
  |  |  |  |   77|  1.99k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.99k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.99k|            break;                                                                       \
  |  |  |  |   79|  1.99k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1177|  1.99k|        return RNP_ERROR_BAD_FORMAT;
 1178|  1.99k|    }
 1179|       |
 1180|       |    /* v4 key */
 1181|  9.49k|    if (version == PGP_SKSK_V4) {
  ------------------
  |  Branch (1181:9): [True: 7.05k, False: 2.44k]
  ------------------
 1182|       |        /* encrypted session key if present */
 1183|  7.05k|        size_t keylen = pkt.left();
 1184|  7.05k|        if (keylen) {
  ------------------
  |  Branch (1184:13): [True: 2.80k, False: 4.24k]
  ------------------
 1185|  2.80k|            if (keylen > PGP_MAX_KEY_SIZE + 1) {
  ------------------
  |  |   89|  2.80k|#define PGP_MAX_KEY_SIZE 32
  ------------------
  |  Branch (1185:17): [True: 31, False: 2.77k]
  ------------------
 1186|     31|                RNP_LOG("too long esk");
  ------------------
  |  |   84|     31|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     31|    do {                                                                                 \
  |  |  |  |   77|     31|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 31, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     31|            break;                                                                       \
  |  |  |  |   79|     31|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1187|     31|                return RNP_ERROR_BAD_FORMAT;
 1188|     31|            }
 1189|  2.77k|            if (!pkt.get(enckey, keylen)) {
  ------------------
  |  Branch (1189:17): [True: 0, False: 2.77k]
  ------------------
 1190|      0|                RNP_LOG("failed to get key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1191|      0|                return RNP_ERROR_BAD_FORMAT;
 1192|      0|            }
 1193|  2.77k|        }
 1194|  7.02k|        enckeylen = keylen;
 1195|  7.02k|        return RNP_SUCCESS;
 1196|  7.05k|    }
 1197|       |
 1198|       |    /* v5: iv + esk + tag. For both EAX and OCB ivlen and taglen are 16 octets */
 1199|  2.44k|    size_t noncelen = pgp_cipher_aead_nonce_len(aalg);
 1200|  2.44k|    size_t taglen = pgp_cipher_aead_tag_len(aalg);
 1201|  2.44k|    size_t keylen = 0;
 1202|       |
 1203|  2.44k|    if (pkt.left() > noncelen + taglen + PGP_MAX_KEY_SIZE) {
  ------------------
  |  |   89|  2.44k|#define PGP_MAX_KEY_SIZE 32
  ------------------
  |  Branch (1203:9): [True: 11, False: 2.43k]
  ------------------
 1204|     11|        RNP_LOG("too long esk");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1205|     11|        return RNP_ERROR_BAD_FORMAT;
 1206|     11|    }
 1207|  2.43k|    if (pkt.left() < noncelen + taglen + 8) {
  ------------------
  |  Branch (1207:9): [True: 23, False: 2.41k]
  ------------------
 1208|     23|        RNP_LOG("too short esk");
  ------------------
  |  |   84|     23|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     23|    do {                                                                                 \
  |  |  |  |   77|     23|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 23, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     23|            break;                                                                       \
  |  |  |  |   79|     23|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1209|     23|        return RNP_ERROR_BAD_FORMAT;
 1210|     23|    }
 1211|       |    /* iv */
 1212|  2.41k|    if (!pkt.get(iv, noncelen)) {
  ------------------
  |  Branch (1212:9): [True: 0, False: 2.41k]
  ------------------
 1213|      0|        RNP_LOG("failed to get iv");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1214|      0|        return RNP_ERROR_BAD_FORMAT;
 1215|      0|    }
 1216|  2.41k|    ivlen = noncelen;
 1217|       |
 1218|       |    /* key */
 1219|  2.41k|    keylen = pkt.left();
 1220|  2.41k|    if (!pkt.get(enckey, keylen)) {
  ------------------
  |  Branch (1220:9): [True: 0, False: 2.41k]
  ------------------
 1221|      0|        RNP_LOG("failed to get key");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1222|      0|        return RNP_ERROR_BAD_FORMAT;
 1223|      0|    }
 1224|  2.41k|    enckeylen = keylen;
 1225|  2.41k|    return RNP_SUCCESS;
 1226|  2.41k|}
_ZNK16pgp_pk_sesskey_t5writeER10pgp_dest_t:
 1230|     41|{
 1231|     41|    pgp_packet_body_t pktbody(PGP_PKT_PK_SESSION_KEY);
 1232|     41|    pktbody.add_byte(version);
 1233|     41|#if defined(ENABLE_CRYPTO_REFRESH)
 1234|     41|    if (version == PGP_PKSK_V3) {
  ------------------
  |  Branch (1234:9): [True: 41, False: 0]
  ------------------
 1235|     41|#endif
 1236|     41|        pktbody.add(key_id);
 1237|     41|#if defined(ENABLE_CRYPTO_REFRESH)
 1238|     41|    } else { // PGP_PKSK_V6
 1239|       |        /* RFC 9580 §5.1.2: a zero size omits the key version and the
 1240|       |         * fingerprint (anonymous recipient). A non-zero size is one octet
 1241|       |         * of version plus the fingerprint. */
 1242|      0|        if (!fp.size()) {
  ------------------
  |  Branch (1242:13): [True: 0, False: 0]
  ------------------
 1243|      0|            pktbody.add_byte(0);
 1244|      0|        } else {
 1245|      0|            pktbody.add_byte(1 + fp.size());
 1246|      0|            pktbody.add_byte((fp.size() == PGP_FINGERPRINT_V6_SIZE) ? PGP_V6 : PGP_V4);
  ------------------
  |  |   51|      0|#define PGP_FINGERPRINT_V6_SIZE 32
  ------------------
  |  Branch (1246:30): [True: 0, False: 0]
  ------------------
 1247|      0|            pktbody.add(fp.vec());
 1248|      0|        }
 1249|      0|    }
 1250|     41|#endif
 1251|     41|    pktbody.add_byte(alg);
 1252|     41|    pktbody.add(material_buf.data(), material_buf.size());
 1253|     41|    pktbody.write(dst);
 1254|     41|}
_ZN16pgp_pk_sesskey_t5parseER12pgp_source_t:
 1258|  4.36k|{
 1259|  4.36k|    pgp_packet_body_t pkt(PGP_PKT_PK_SESSION_KEY);
 1260|  4.36k|    rnp_result_t      res = pkt.read(src);
 1261|  4.36k|    if (res) {
  ------------------
  |  Branch (1261:9): [True: 119, False: 4.24k]
  ------------------
 1262|    119|        return res;
 1263|    119|    }
 1264|       |    /* version */
 1265|  4.24k|    uint8_t bt = 0;
 1266|  4.24k|    if (!pkt.get(bt)) {
  ------------------
  |  Branch (1266:9): [True: 863, False: 3.38k]
  ------------------
 1267|    863|        RNP_LOG("Error when reading packet version");
  ------------------
  |  |   84|    863|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    863|    do {                                                                                 \
  |  |  |  |   77|    863|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 863, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    863|            break;                                                                       \
  |  |  |  |   79|    863|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1268|    863|        return RNP_ERROR_BAD_FORMAT;
 1269|    863|    }
 1270|  3.38k|#if defined(ENABLE_CRYPTO_REFRESH)
 1271|  3.38k|    if ((bt != PGP_PKSK_V3) && (bt != PGP_PKSK_V6)) {
  ------------------
  |  Branch (1271:9): [True: 2.85k, False: 528]
  |  Branch (1271:32): [True: 344, False: 2.50k]
  ------------------
 1272|       |#else
 1273|       |    if ((bt != PGP_PKSK_V3)) {
 1274|       |#endif
 1275|    344|        RNP_LOG("wrong packet version");
  ------------------
  |  |   84|    344|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    344|    do {                                                                                 \
  |  |  |  |   77|    344|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 344, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    344|            break;                                                                       \
  |  |  |  |   79|    344|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1276|    344|        return RNP_ERROR_BAD_FORMAT;
 1277|    344|    }
 1278|  3.03k|    version = (pgp_pkesk_version_t) bt;
 1279|       |
 1280|  3.03k|#if defined(ENABLE_CRYPTO_REFRESH)
 1281|  3.03k|    if (version == PGP_PKSK_V3)
  ------------------
  |  Branch (1281:9): [True: 528, False: 2.50k]
  ------------------
 1282|    528|#endif
 1283|    528|    {
 1284|       |        /* key id */
 1285|    528|        if (!pkt.get(key_id)) {
  ------------------
  |  Branch (1285:13): [True: 24, False: 504]
  ------------------
 1286|     24|            RNP_LOG("failed to get key id");
  ------------------
  |  |   84|     24|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     24|    do {                                                                                 \
  |  |  |  |   77|     24|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 24, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     24|            break;                                                                       \
  |  |  |  |   79|     24|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1287|     24|            return RNP_ERROR_BAD_FORMAT;
 1288|     24|        }
 1289|    528|    }
 1290|  2.50k|#if defined(ENABLE_CRYPTO_REFRESH)
 1291|  2.50k|    else {                          // PGP_PKSK_V6
 1292|  2.50k|        uint8_t fp_and_key_ver_len; // A one-octet size of the following two fields.
 1293|  2.50k|        if (!pkt.get(fp_and_key_ver_len)) {
  ------------------
  |  Branch (1293:13): [True: 129, False: 2.38k]
  ------------------
 1294|    129|            RNP_LOG("Error when reading length of next two fields");
  ------------------
  |  |   84|    129|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    129|    do {                                                                                 \
  |  |  |  |   77|    129|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 129, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    129|            break;                                                                       \
  |  |  |  |   79|    129|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1295|    129|            return RNP_ERROR_BAD_FORMAT;
 1296|    129|        }
 1297|       |        /* RFC 9580 §5.1.2: a zero size omits the key version and the
 1298|       |         * fingerprint. That is an anonymous recipient (§5.1.8). */
 1299|  2.38k|        if (!fp_and_key_ver_len) {
  ------------------
  |  Branch (1299:13): [True: 1.86k, False: 520]
  ------------------
 1300|  1.86k|            fp = pgp::Fingerprint();
 1301|  1.86k|        } else {
 1302|    520|            if ((fp_and_key_ver_len != 1 + PGP_FINGERPRINT_V4_SIZE) &&
  ------------------
  |  |   43|    520|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
  |  Branch (1302:17): [True: 473, False: 47]
  ------------------
 1303|    473|                (fp_and_key_ver_len != 1 + PGP_FINGERPRINT_V6_SIZE)) {
  ------------------
  |  |   51|    473|#define PGP_FINGERPRINT_V6_SIZE 32
  ------------------
  |  Branch (1303:17): [True: 281, False: 192]
  ------------------
 1304|    281|                RNP_LOG("Invalid size for key version + length field");
  ------------------
  |  |   84|    281|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    281|    do {                                                                                 \
  |  |  |  |   77|    281|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 281, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    281|            break;                                                                       \
  |  |  |  |   79|    281|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1305|    281|                return RNP_ERROR_BAD_FORMAT;
 1306|    281|            }
 1307|       |
 1308|    239|            size_t  fp_len;
 1309|    239|            uint8_t fp_key_version;
 1310|    239|            if (!pkt.get(fp_key_version)) {
  ------------------
  |  Branch (1310:17): [True: 39, False: 200]
  ------------------
 1311|     39|                RNP_LOG("Error when reading key version");
  ------------------
  |  |   84|     39|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     39|    do {                                                                                 \
  |  |  |  |   77|     39|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 39, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     39|            break;                                                                       \
  |  |  |  |   79|     39|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1312|     39|                return RNP_ERROR_BAD_FORMAT;
 1313|     39|            }
 1314|    200|            switch (fp_key_version) {
 1315|     40|            case PGP_V4:
  ------------------
  |  Branch (1315:13): [True: 40, False: 160]
  ------------------
 1316|     40|                fp_len = PGP_FINGERPRINT_V4_SIZE;
  ------------------
  |  |   43|     40|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
 1317|     40|                break;
 1318|     91|            case PGP_V6:
  ------------------
  |  Branch (1318:13): [True: 91, False: 109]
  ------------------
 1319|     91|                fp_len = PGP_FINGERPRINT_V6_SIZE;
  ------------------
  |  |   51|     91|#define PGP_FINGERPRINT_V6_SIZE 32
  ------------------
 1320|     91|                break;
 1321|     69|            default:
  ------------------
  |  Branch (1321:13): [True: 69, False: 131]
  ------------------
 1322|     69|                RNP_LOG("wrong key version used with PKESK v6");
  ------------------
  |  |   84|     69|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     69|    do {                                                                                 \
  |  |  |  |   77|     69|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 69, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     69|            break;                                                                       \
  |  |  |  |   79|     69|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1323|     69|                return RNP_ERROR_BAD_FORMAT;
 1324|    200|            }
 1325|    131|            if (fp_len + 1 != fp_and_key_ver_len) {
  ------------------
  |  Branch (1325:17): [True: 41, False: 90]
  ------------------
 1326|     41|                RNP_LOG("size mismatch (fingerprint size and fp+key version length field)");
  ------------------
  |  |   84|     41|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     41|    do {                                                                                 \
  |  |  |  |   77|     41|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 41, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     41|            break;                                                                       \
  |  |  |  |   79|     41|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1327|     41|                return RNP_ERROR_BAD_FORMAT;
 1328|     41|            }
 1329|     90|            std::vector<uint8_t> vec(fp_len, 0);
 1330|     90|            if (!pkt.get(vec.data(), vec.size())) {
  ------------------
  |  Branch (1330:17): [True: 77, False: 13]
  ------------------
 1331|     77|                RNP_LOG("Error when reading fingerprint");
  ------------------
  |  |   84|     77|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     77|    do {                                                                                 \
  |  |  |  |   77|     77|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 77, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     77|            break;                                                                       \
  |  |  |  |   79|     77|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1332|     77|                return RNP_ERROR_BAD_FORMAT;
 1333|     77|            }
 1334|     13|            fp = pgp::Fingerprint(vec.data(), vec.size());
 1335|       |            /* A v6 PKESK has no Key ID field. Derive one so recipient
 1336|       |             * reporting matches the key (RFC 9580 §5.5.4): the low 64 bits
 1337|       |             * of a v4 fingerprint, the high 64 bits of a v6 fingerprint.
 1338|       |             * An anonymous packet leaves the all-zero sentinel in place. */
 1339|     13|            if (fp_key_version == PGP_V4) {
  ------------------
  |  Branch (1339:17): [True: 3, False: 10]
  ------------------
 1340|      3|                memcpy(key_id.data(), vec.data() + fp_len - PGP_KEY_ID_SIZE, key_id.size());
  ------------------
  |  |   39|      3|#define PGP_KEY_ID_SIZE 8
  ------------------
 1341|     10|            } else {
 1342|     10|                memcpy(key_id.data(), vec.data(), key_id.size());
 1343|     10|            }
 1344|     13|        }
 1345|  2.38k|    }
 1346|  2.37k|#endif
 1347|       |
 1348|       |    /* public key algorithm */
 1349|  2.37k|    if (!pkt.get(bt)) {
  ------------------
  |  Branch (1349:9): [True: 1.63k, False: 746]
  ------------------
 1350|  1.63k|        RNP_LOG("failed to get palg");
  ------------------
  |  |   84|  1.63k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.63k|    do {                                                                                 \
  |  |  |  |   77|  1.63k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.63k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.63k|            break;                                                                       \
  |  |  |  |   79|  1.63k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1351|  1.63k|        return RNP_ERROR_BAD_FORMAT;
 1352|  1.63k|    }
 1353|    746|    alg = (pgp_pubkey_alg_t) bt;
 1354|       |
 1355|       |    /* symmetric algorithm */
 1356|    746|    salg = PGP_SA_UNKNOWN;
 1357|       |
 1358|       |    /* raw encrypted material */
 1359|    746|    if (!pkt.left()) {
  ------------------
  |  Branch (1359:9): [True: 17, False: 729]
  ------------------
 1360|     17|        RNP_LOG("No encrypted material");
  ------------------
  |  |   84|     17|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     17|    do {                                                                                 \
  |  |  |  |   77|     17|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 17, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     17|            break;                                                                       \
  |  |  |  |   79|     17|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1361|     17|        return RNP_ERROR_BAD_FORMAT;
 1362|     17|    }
 1363|    729|    try {
 1364|    729|        material_buf.resize(pkt.left());
 1365|    729|    } catch (const std::exception &e) {
 1366|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1367|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1368|      0|    }
 1369|       |    /* we cannot fail here */
 1370|    729|    pkt.get(material_buf.data(), material_buf.size());
 1371|       |    /* check whether it can be parsed */
 1372|    729|    if (!parse_material()) {
  ------------------
  |  Branch (1372:9): [True: 616, False: 113]
  ------------------
 1373|    616|        return RNP_ERROR_BAD_FORMAT;
 1374|    616|    }
 1375|    113|    return RNP_SUCCESS;
 1376|    729|}
_ZNK16pgp_pk_sesskey_t14parse_materialEv:
 1380|    729|{
 1381|    729|    auto enc = pgp::EncMaterial::create(alg);
 1382|    729|    if (!enc) {
  ------------------
  |  Branch (1382:9): [True: 104, False: 625]
  ------------------
 1383|    104|        return nullptr;
 1384|    104|    }
 1385|    625|#if defined(ENABLE_CRYPTO_REFRESH)
 1386|    625|    enc->version = version;
 1387|    625|#endif
 1388|    625|    pgp_packet_body_t pkt(material_buf);
 1389|    625|    if (!enc->parse(pkt)) {
  ------------------
  |  Branch (1389:9): [True: 310, False: 315]
  ------------------
 1390|    310|        return nullptr;
 1391|    310|    }
 1392|    315|    if (pkt.left()) {
  ------------------
  |  Branch (1392:9): [True: 202, False: 113]
  ------------------
 1393|    202|        RNP_LOG("extra %zu bytes in pk packet", pkt.left());
  ------------------
  |  |   84|    202|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    202|    do {                                                                                 \
  |  |  |  |   77|    202|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 202, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    202|            break;                                                                       \
  |  |  |  |   79|    202|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1394|    202|        return nullptr;
 1395|    202|    }
 1396|    113|    return enc;
 1397|    315|}
_ZN16pgp_pk_sesskey_t14write_materialERKN3pgp11EncMaterialE:
 1401|     41|{
 1402|     41|    pgp_packet_body_t pktbody(PGP_PKT_PK_SESSION_KEY);
 1403|     41|    material.write(pktbody);
 1404|     41|    material_buf.assign(pktbody.data(), pktbody.data() + pktbody.size());
 1405|     41|}
_ZN18pgp_one_pass_sig_t5parseER12pgp_source_t:
 1435|   139k|{
 1436|   139k|    pgp_packet_body_t pkt(PGP_PKT_ONE_PASS_SIG);
 1437|       |    /* Read the packet into memory */
 1438|   139k|    rnp_result_t res = pkt.read(src);
 1439|   139k|    if (res) {
  ------------------
  |  Branch (1439:9): [True: 38.0k, False: 101k]
  ------------------
 1440|  38.0k|        return res;
 1441|  38.0k|    }
 1442|       |
 1443|       |    /* version */
 1444|   101k|    if ((pkt.size() < 1) || !pkt.get(version)) {
  ------------------
  |  Branch (1444:9): [True: 85.1k, False: 15.9k]
  |  Branch (1444:29): [True: 0, False: 15.9k]
  ------------------
 1445|  85.1k|        return RNP_ERROR_BAD_FORMAT;
 1446|  85.1k|    }
 1447|  15.9k|    switch ((pgp_ops_version_t) version) {
 1448|  3.91k|    case PGP_OPS_V3:
  ------------------
  |  Branch (1448:5): [True: 3.91k, False: 12.0k]
  ------------------
 1449|  3.91k|        return parse_v3(pkt);
 1450|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 1451|  2.00k|    case PGP_OPS_V6:
  ------------------
  |  Branch (1451:5): [True: 2.00k, False: 13.9k]
  ------------------
 1452|  2.00k|        return parse_v6(pkt);
 1453|      0|#endif
 1454|  10.0k|    default:
  ------------------
  |  Branch (1454:5): [True: 10.0k, False: 5.91k]
  ------------------
 1455|  10.0k|        RNP_LOG("wrong packet version");
  ------------------
  |  |   84|  10.0k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  10.0k|    do {                                                                                 \
  |  |  |  |   77|  10.0k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10.0k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  10.0k|            break;                                                                       \
  |  |  |  |   79|  10.0k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1456|  10.0k|        return RNP_ERROR_BAD_FORMAT;
 1457|  15.9k|    }
 1458|  15.9k|}
_ZN18pgp_one_pass_sig_t8parse_v6ER17pgp_packet_body_t:
 1463|  2.00k|{
 1464|  2.00k|    uint8_t buf[4];
 1465|  2.00k|    uint8_t salt_size;
 1466|       |
 1467|       |    /* packet can't be smaller for v6 */
 1468|  2.00k|    const size_t min_size = 54;
 1469|  2.00k|    if ((pkt.size() < min_size)) {
  ------------------
  |  Branch (1469:9): [True: 610, False: 1.39k]
  ------------------
 1470|    610|        return RNP_ERROR_BAD_FORMAT;
 1471|    610|    }
 1472|       |    /* version */
 1473|  1.39k|    version = PGP_OPS_V6;
 1474|  1.39k|    if (!pkt.get(buf, 4)) {
  ------------------
  |  Branch (1474:9): [True: 0, False: 1.39k]
  ------------------
 1475|      0|        return RNP_ERROR_BAD_FORMAT;
 1476|      0|    }
 1477|       |    /* signature type */
 1478|  1.39k|    type = (pgp_sig_type_t) buf[0];
 1479|       |    /* hash algorithm */
 1480|  1.39k|    halg = (pgp_hash_alg_t) buf[1];
 1481|       |    /* pk algorithm */
 1482|  1.39k|    palg = (pgp_pubkey_alg_t) buf[2];
 1483|       |
 1484|       |    /* salt */
 1485|  1.39k|    salt_size = buf[3];
 1486|  1.39k|    size_t expect_salt_size;
 1487|  1.39k|    if (!pgp::pkt::Signature::v6_salt_size(halg, &expect_salt_size)) {
  ------------------
  |  Branch (1487:9): [True: 38, False: 1.35k]
  ------------------
 1488|     38|        RNP_LOG("invalid halg");
  ------------------
  |  |   84|     38|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     38|    do {                                                                                 \
  |  |  |  |   77|     38|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 38, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     38|            break;                                                                       \
  |  |  |  |   79|     38|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1489|     38|        return RNP_ERROR_BAD_FORMAT;
 1490|     38|    }
 1491|  1.35k|    if (salt_size != expect_salt_size) {
  ------------------
  |  Branch (1491:9): [True: 335, False: 1.02k]
  ------------------
 1492|    335|        RNP_LOG("invalid salt size");
  ------------------
  |  |   84|    335|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    335|    do {                                                                                 \
  |  |  |  |   77|    335|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 335, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    335|            break;                                                                       \
  |  |  |  |   79|    335|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1493|    335|        return RNP_ERROR_BAD_FORMAT;
 1494|    335|    }
 1495|  1.02k|    salt.resize(salt_size);
 1496|  1.02k|    if (!pkt.get(salt.data(), salt.size())) {
  ------------------
  |  Branch (1496:9): [True: 0, False: 1.02k]
  ------------------
 1497|      0|        RNP_LOG("failed to get salt");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1498|      0|        return RNP_ERROR_BAD_FORMAT;
 1499|      0|    }
 1500|       |
 1501|       |    /* fingerprint */
 1502|  1.02k|    std::vector<uint8_t> fp_vec;
 1503|  1.02k|    fp_vec.resize(PGP_FINGERPRINT_V6_SIZE);
  ------------------
  |  |   51|  1.02k|#define PGP_FINGERPRINT_V6_SIZE 32
  ------------------
 1504|  1.02k|    if (!pkt.get(fp_vec.data(), fp_vec.size())) {
  ------------------
  |  Branch (1504:9): [True: 13, False: 1.01k]
  ------------------
 1505|     13|        RNP_LOG("failed to get fingerprint");
  ------------------
  |  |   84|     13|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     13|    do {                                                                                 \
  |  |  |  |   77|     13|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 13, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     13|            break;                                                                       \
  |  |  |  |   79|     13|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1506|     13|        return RNP_ERROR_BAD_FORMAT;
 1507|     13|    }
 1508|  1.01k|    fp = pgp::Fingerprint(fp_vec.data(), fp_vec.size());
 1509|       |
 1510|       |    /* nested flag */
 1511|  1.01k|    if (!pkt.get(buf, 1)) {
  ------------------
  |  Branch (1511:9): [True: 6, False: 1.00k]
  ------------------
 1512|      6|        RNP_LOG("failed to get nested flag");
  ------------------
  |  |   84|      6|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      6|    do {                                                                                 \
  |  |  |  |   77|      6|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 6, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      6|            break;                                                                       \
  |  |  |  |   79|      6|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1513|      6|        return RNP_ERROR_BAD_FORMAT;
 1514|      6|    }
 1515|  1.00k|    nested = buf[0];
 1516|       |
 1517|  1.00k|    if (pkt.left()) {
  ------------------
  |  Branch (1517:9): [True: 9, False: 996]
  ------------------
 1518|      9|        RNP_LOG("trailing bytes in V6 OPS packet.");
  ------------------
  |  |   84|      9|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      9|    do {                                                                                 \
  |  |  |  |   77|      9|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      9|            break;                                                                       \
  |  |  |  |   79|      9|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1519|      9|        return RNP_ERROR_BAD_FORMAT;
 1520|      9|    }
 1521|    996|    return RNP_SUCCESS;
 1522|  1.00k|}
_ZN18pgp_one_pass_sig_t8parse_v3ER17pgp_packet_body_t:
 1527|  3.91k|{
 1528|  3.91k|    uint8_t buf[12] = {0};
 1529|  3.91k|    if ((pkt.size() != 13) || !pkt.get(buf, 12)) {
  ------------------
  |  Branch (1529:9): [True: 338, False: 3.57k]
  |  Branch (1529:31): [True: 0, False: 3.57k]
  ------------------
 1530|    338|        return RNP_ERROR_BAD_FORMAT;
 1531|    338|    }
 1532|       |    /* signature type */
 1533|  3.57k|    type = (pgp_sig_type_t) buf[0];
 1534|       |    /* hash algorithm */
 1535|  3.57k|    halg = (pgp_hash_alg_t) buf[1];
 1536|       |    /* pk algorithm */
 1537|  3.57k|    palg = (pgp_pubkey_alg_t) buf[2];
 1538|       |    /* key id */
 1539|  3.57k|    static_assert(std::tuple_size<decltype(keyid)>::value == PGP_KEY_ID_SIZE,
 1540|  3.57k|                  "pgp_one_pass_sig_t.keyid size mismatch");
 1541|  3.57k|    memcpy(keyid.data(), &buf[3], PGP_KEY_ID_SIZE);
  ------------------
  |  |   39|  3.57k|#define PGP_KEY_ID_SIZE 8
  ------------------
 1542|       |    /* nested flag */
 1543|  3.57k|    nested = buf[11];
 1544|  3.57k|    return RNP_SUCCESS;
 1545|  3.91k|}
stream-packet.cpp:_ZL11get_pkt_lenPhPm:
  138|  1.15M|{
  139|  1.15M|    if (hdr[0] & PGP_PTAG_NEW_FORMAT) {
  ------------------
  |  |   56|  1.15M|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  |  Branch (139:9): [True: 674k, False: 483k]
  ------------------
  140|       |        // 1-byte length
  141|   674k|        if (hdr[1] < 192) {
  ------------------
  |  Branch (141:13): [True: 623k, False: 50.9k]
  ------------------
  142|   623k|            *pktlen = hdr[1];
  143|   623k|            return true;
  144|   623k|        }
  145|       |        // 2-byte length
  146|  50.9k|        if (hdr[1] < 224) {
  ------------------
  |  Branch (146:13): [True: 9.32k, False: 41.6k]
  ------------------
  147|  9.32k|            *pktlen = ((size_t)(hdr[1] - 192) << 8) + (size_t) hdr[2] + 192;
  148|  9.32k|            return true;
  149|  9.32k|        }
  150|       |        // partial length - we do not allow it here
  151|  41.6k|        if (hdr[1] < 255) {
  ------------------
  |  Branch (151:13): [True: 44, False: 41.6k]
  ------------------
  152|     44|            return false;
  153|     44|        }
  154|       |        // 4-byte length
  155|  41.6k|        *pktlen = read_uint32(&hdr[2]);
  156|  41.6k|        return true;
  157|  41.6k|    }
  158|       |
  159|   483k|    switch (hdr[0] & PGP_PTAG_OF_LENGTH_TYPE_MASK) {
  ------------------
  |  |   83|   483k|#define PGP_PTAG_OF_LENGTH_TYPE_MASK 0x03
  ------------------
  160|   131k|    case PGP_PTAG_OLD_LEN_1:
  ------------------
  |  Branch (160:5): [True: 131k, False: 351k]
  ------------------
  161|   131k|        *pktlen = hdr[1];
  162|   131k|        return true;
  163|  13.7k|    case PGP_PTAG_OLD_LEN_2:
  ------------------
  |  Branch (163:5): [True: 13.7k, False: 469k]
  ------------------
  164|  13.7k|        *pktlen = read_uint16(&hdr[1]);
  165|  13.7k|        return true;
  166|  60.9k|    case PGP_PTAG_OLD_LEN_4:
  ------------------
  |  Branch (166:5): [True: 60.9k, False: 422k]
  ------------------
  167|  60.9k|        *pktlen = read_uint32(&hdr[1]);
  168|  60.9k|        return true;
  169|   276k|    default:
  ------------------
  |  Branch (169:5): [True: 276k, False: 206k]
  ------------------
  170|   276k|        return false;
  171|   483k|    }
  172|   483k|}
stream-packet.cpp:_ZL26stream_read_packet_partialP12pgp_source_tP10pgp_dest_t:
  307|    890|{
  308|    890|    uint8_t hdr = 0;
  309|    890|    if (!src->read_eq(&hdr, 1)) {
  ------------------
  |  Branch (309:9): [True: 0, False: 890]
  ------------------
  310|      0|        return RNP_ERROR_READ;
  311|      0|    }
  312|       |
  313|    890|    bool   last = false;
  314|    890|    size_t partlen = 0;
  315|    890|    if (!stream_read_partial_chunk_len(src, &partlen, &last)) {
  ------------------
  |  Branch (315:9): [True: 0, False: 890]
  ------------------
  316|      0|        return RNP_ERROR_BAD_FORMAT;
  317|      0|    }
  318|       |
  319|    890|    uint8_t *buf = (uint8_t *) malloc(PGP_INPUT_CACHE_SIZE);
  ------------------
  |  |   35|    890|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  320|    890|    if (!buf) {
  ------------------
  |  Branch (320:9): [True: 0, False: 890]
  ------------------
  321|      0|        return RNP_ERROR_OUT_OF_MEMORY;
  322|      0|    }
  323|       |
  324|  2.36k|    while (partlen > 0) {
  ------------------
  |  Branch (324:12): [True: 1.95k, False: 408]
  ------------------
  325|  1.95k|        size_t read = std::min(partlen, (size_t) PGP_INPUT_CACHE_SIZE);
  ------------------
  |  |   35|  1.95k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  326|  1.95k|        if (!src->read_eq(buf, read)) {
  ------------------
  |  Branch (326:13): [True: 241, False: 1.71k]
  ------------------
  327|    241|            free(buf);
  328|    241|            return RNP_ERROR_READ;
  329|    241|        }
  330|  1.71k|        if (dst) {
  ------------------
  |  Branch (330:13): [True: 0, False: 1.71k]
  ------------------
  331|      0|            dst_write(dst, buf, read);
  332|      0|        }
  333|  1.71k|        partlen -= read;
  334|  1.71k|        if (partlen > 0) {
  ------------------
  |  Branch (334:13): [True: 412, False: 1.30k]
  ------------------
  335|    412|            continue;
  336|    412|        }
  337|  1.30k|        if (last) {
  ------------------
  |  Branch (337:13): [True: 225, False: 1.07k]
  ------------------
  338|    225|            break;
  339|    225|        }
  340|  1.07k|        if (!stream_read_partial_chunk_len(src, &partlen, &last)) {
  ------------------
  |  Branch (340:13): [True: 16, False: 1.05k]
  ------------------
  341|     16|            free(buf);
  342|     16|            return RNP_ERROR_BAD_FORMAT;
  343|     16|        }
  344|  1.07k|    }
  345|    633|    free(buf);
  346|    633|    return RNP_SUCCESS;
  347|    890|}

_ZN16pgp_userid_pkt_tC2Ev:
  248|   739k|    pgp_userid_pkt_t() : tag(PGP_PKT_RESERVED){};

_Z16init_literal_srcP12pgp_source_tS0_:
 2037|  3.29k|{
 2038|  3.29k|    rnp_result_t                ret = RNP_ERROR_GENERIC;
 2039|  3.29k|    pgp_source_literal_param_t *param;
 2040|  3.29k|    uint8_t                     format = 0;
 2041|  3.29k|    uint8_t                     nlen = 0;
 2042|  3.29k|    uint8_t                     timestamp[4];
 2043|       |
 2044|  3.29k|    if (!init_src_common(src, sizeof(*param))) {
  ------------------
  |  Branch (2044:9): [True: 0, False: 3.29k]
  ------------------
 2045|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2046|      0|    }
 2047|       |
 2048|  3.29k|    param = (pgp_source_literal_param_t *) src->param;
 2049|  3.29k|    param->pkt.readsrc = readsrc;
 2050|  3.29k|    src->raw_read = literal_src_read;
 2051|  3.29k|    src->raw_close = literal_src_close;
 2052|  3.29k|    src->type = PGP_STREAM_LITERAL;
 2053|       |
 2054|       |    /* Reading packet length/checking whether it is partial */
 2055|  3.29k|    if ((ret = init_packet_params(param->pkt))) {
  ------------------
  |  Branch (2055:9): [True: 2, False: 3.29k]
  ------------------
 2056|      2|        goto finish;
 2057|      2|    }
 2058|       |
 2059|       |    /* data format */
 2060|  3.29k|    if (!param->pkt.readsrc->read_eq(&format, 1)) {
  ------------------
  |  Branch (2060:9): [True: 13, False: 3.28k]
  ------------------
 2061|     13|        RNP_LOG("failed to read data format");
  ------------------
  |  |   84|     13|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     13|    do {                                                                                 \
  |  |  |  |   77|     13|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 13, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     13|            break;                                                                       \
  |  |  |  |   79|     13|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2062|     13|        ret = RNP_ERROR_READ;
 2063|     13|        goto finish;
 2064|     13|    }
 2065|       |
 2066|  3.28k|    switch (format) {
 2067|  2.08k|    case 'b':
  ------------------
  |  Branch (2067:5): [True: 2.08k, False: 1.19k]
  ------------------
 2068|  2.08k|    case 't':
  ------------------
  |  Branch (2068:5): [True: 1, False: 3.28k]
  ------------------
 2069|  2.09k|    case 'u':
  ------------------
  |  Branch (2069:5): [True: 8, False: 3.27k]
  ------------------
 2070|  2.09k|    case 'l':
  ------------------
  |  Branch (2070:5): [True: 1, False: 3.28k]
  ------------------
 2071|  2.09k|    case '1':
  ------------------
  |  Branch (2071:5): [True: 2, False: 3.27k]
  ------------------
 2072|  2.09k|    case 'm':
  ------------------
  |  Branch (2072:5): [True: 1, False: 3.28k]
  ------------------
 2073|  2.09k|        break;
 2074|  1.18k|    default:
  ------------------
  |  Branch (2074:5): [True: 1.18k, False: 2.09k]
  ------------------
 2075|  1.18k|        RNP_LOG("Warning: unknown data format %" PRIu8 ", ignoring.", format);
  ------------------
  |  |   84|  1.18k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.18k|    do {                                                                                 \
  |  |  |  |   77|  1.18k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.18k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.18k|            break;                                                                       \
  |  |  |  |   79|  1.18k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2076|  1.18k|        break;
 2077|  3.28k|    }
 2078|  3.28k|    param->hdr.format = format;
 2079|       |    /* file name */
 2080|  3.28k|    if (!param->pkt.readsrc->read_eq(&nlen, 1)) {
  ------------------
  |  Branch (2080:9): [True: 5, False: 3.27k]
  ------------------
 2081|      5|        RNP_LOG("failed to read file name length");
  ------------------
  |  |   84|      5|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      5|    do {                                                                                 \
  |  |  |  |   77|      5|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      5|            break;                                                                       \
  |  |  |  |   79|      5|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2082|      5|        ret = RNP_ERROR_READ;
 2083|      5|        goto finish;
 2084|      5|    }
 2085|  3.27k|    if (nlen && !param->pkt.readsrc->read_eq(param->hdr.fname, nlen)) {
  ------------------
  |  Branch (2085:9): [True: 1.33k, False: 1.94k]
  |  Branch (2085:17): [True: 13, False: 1.31k]
  ------------------
 2086|     13|        RNP_LOG("failed to read file name");
  ------------------
  |  |   84|     13|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     13|    do {                                                                                 \
  |  |  |  |   77|     13|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 13, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     13|            break;                                                                       \
  |  |  |  |   79|     13|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2087|     13|        ret = RNP_ERROR_READ;
 2088|     13|        goto finish;
 2089|     13|    }
 2090|  3.26k|    param->hdr.fname[nlen] = 0;
 2091|  3.26k|    param->hdr.fname_len = nlen;
 2092|       |    /* timestamp */
 2093|  3.26k|    if (!param->pkt.readsrc->read_eq(timestamp, 4)) {
  ------------------
  |  Branch (2093:9): [True: 4, False: 3.25k]
  ------------------
 2094|      4|        RNP_LOG("failed to read file timestamp");
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2095|      4|        ret = RNP_ERROR_READ;
 2096|      4|        goto finish;
 2097|      4|    }
 2098|  3.25k|    param->hdr.timestamp = read_uint32(timestamp);
 2099|       |
 2100|  3.25k|    if (!param->pkt.hdr.indeterminate && !param->pkt.hdr.partial) {
  ------------------
  |  Branch (2100:9): [True: 3.13k, False: 120]
  |  Branch (2100:42): [True: 2.54k, False: 598]
  ------------------
 2101|       |        /* format filename-length filename timestamp */
 2102|  2.54k|        const uint16_t nbytes = 1 + 1 + nlen + 4;
 2103|  2.54k|        if (param->pkt.hdr.pkt_len < nbytes) {
  ------------------
  |  Branch (2103:13): [True: 3, False: 2.53k]
  ------------------
 2104|      3|            ret = RNP_ERROR_BAD_FORMAT;
 2105|      3|            goto finish;
 2106|      3|        }
 2107|  2.53k|        src->size = param->pkt.hdr.pkt_len - nbytes;
 2108|  2.53k|        src->knownsize = 1;
 2109|  2.53k|    }
 2110|  3.25k|    ret = RNP_SUCCESS;
 2111|  3.29k|finish:
 2112|  3.29k|    if (ret) {
  ------------------
  |  Branch (2112:9): [True: 40, False: 3.25k]
  ------------------
 2113|     40|        src->close();
 2114|     40|    }
 2115|  3.29k|    return ret;
 2116|  3.25k|}
_Z19get_literal_src_hdrR12pgp_source_t:
 2120|  3.25k|{
 2121|  3.25k|    return (static_cast<pgp_source_literal_param_t *>(src.param))->hdr;
 2122|  3.25k|}
_Z19init_compressed_srcP12pgp_source_tS0_Pm:
 2126|  6.76k|{
 2127|  6.76k|    rnp_result_t                   errcode = RNP_ERROR_GENERIC;
 2128|  6.76k|    pgp_source_compressed_param_t *param;
 2129|  6.76k|    uint8_t                        alg;
 2130|  6.76k|    int                            zret;
 2131|       |
 2132|  6.76k|    if (!init_src_common(src, sizeof(*param))) {
  ------------------
  |  Branch (2132:9): [True: 0, False: 6.76k]
  ------------------
 2133|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2134|      0|    }
 2135|       |
 2136|  6.76k|    param = (pgp_source_compressed_param_t *) src->param;
 2137|  6.76k|    param->pkt.readsrc = readsrc;
 2138|  6.76k|    param->decomp_left = decomp_left;
 2139|  6.76k|    src->raw_read = compressed_src_read;
 2140|  6.76k|    src->raw_close = compressed_src_close;
 2141|  6.76k|    src->type = PGP_STREAM_COMPRESSED;
 2142|       |
 2143|       |    /* Reading packet length/checking whether it is partial */
 2144|  6.76k|    errcode = init_packet_params(param->pkt);
 2145|  6.76k|    if (errcode != RNP_SUCCESS) {
  ------------------
  |  Branch (2145:9): [True: 6, False: 6.76k]
  ------------------
 2146|      6|        goto finish;
 2147|      6|    }
 2148|       |
 2149|       |    /* Reading compression algorithm */
 2150|  6.76k|    if (!param->pkt.readsrc->read_eq(&alg, 1)) {
  ------------------
  |  Branch (2150:9): [True: 14, False: 6.74k]
  ------------------
 2151|     14|        RNP_LOG("failed to read compression algorithm");
  ------------------
  |  |   84|     14|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     14|    do {                                                                                 \
  |  |  |  |   77|     14|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 14, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     14|            break;                                                                       \
  |  |  |  |   79|     14|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2152|     14|        errcode = RNP_ERROR_READ;
 2153|     14|        goto finish;
 2154|     14|    }
 2155|       |
 2156|       |    /* Initializing decompression */
 2157|  6.74k|    switch (alg) {
 2158|    526|    case PGP_C_NONE:
  ------------------
  |  Branch (2158:5): [True: 526, False: 6.22k]
  ------------------
 2159|    526|        break;
 2160|  3.82k|    case PGP_C_ZIP:
  ------------------
  |  Branch (2160:5): [True: 3.82k, False: 2.92k]
  ------------------
 2161|  5.22k|    case PGP_C_ZLIB:
  ------------------
  |  Branch (2161:5): [True: 1.40k, False: 5.33k]
  ------------------
 2162|  5.22k|        (void) memset(&param->z, 0x0, sizeof(param->z));
 2163|  5.22k|        zret =
 2164|  5.22k|          alg == PGP_C_ZIP ? (int) inflateInit2(&param->z, -15) : (int) inflateInit(&param->z);
  ------------------
  |  Branch (2164:11): [True: 3.82k, False: 1.40k]
  ------------------
 2165|  5.22k|        if (zret != Z_OK) {
  ------------------
  |  Branch (2165:13): [True: 0, False: 5.22k]
  ------------------
 2166|      0|            RNP_LOG("failed to init zlib, error %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2167|      0|            errcode = RNP_ERROR_READ;
 2168|      0|            goto finish;
 2169|      0|        }
 2170|  5.22k|        break;
 2171|  5.22k|#ifdef HAVE_BZLIB_H
 2172|  5.22k|    case PGP_C_BZIP2:
  ------------------
  |  Branch (2172:5): [True: 925, False: 5.82k]
  ------------------
 2173|    925|        (void) memset(&param->bz, 0x0, sizeof(param->bz));
 2174|    925|        zret = BZ2_bzDecompressInit(&param->bz, 0, 0);
 2175|    925|        if (zret != BZ_OK) {
  ------------------
  |  Branch (2175:13): [True: 0, False: 925]
  ------------------
 2176|      0|            RNP_LOG("failed to init bz, error %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2177|      0|            errcode = RNP_ERROR_READ;
 2178|      0|            goto finish;
 2179|      0|        }
 2180|    925|        break;
 2181|    925|#endif
 2182|    925|    default:
  ------------------
  |  Branch (2182:5): [True: 67, False: 6.68k]
  ------------------
 2183|     67|        RNP_LOG("unknown compression algorithm: %d", (int) alg);
  ------------------
  |  |   84|     67|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     67|    do {                                                                                 \
  |  |  |  |   77|     67|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 67, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     67|            break;                                                                       \
  |  |  |  |   79|     67|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2184|     67|        errcode = RNP_ERROR_BAD_FORMAT;
 2185|     67|        goto finish;
 2186|  6.74k|    }
 2187|  6.68k|    param->alg = (pgp_compression_type_t) alg;
 2188|  6.68k|    param->inlen = 0;
 2189|  6.68k|    param->inpos = 0;
 2190|       |
 2191|  6.68k|    errcode = RNP_SUCCESS;
 2192|  6.76k|finish:
 2193|  6.76k|    if (errcode != RNP_SUCCESS) {
  ------------------
  |  Branch (2193:9): [True: 87, False: 6.68k]
  ------------------
 2194|     87|        src->close();
 2195|     87|    }
 2196|  6.76k|    return errcode;
 2197|  6.68k|}
_Z19get_seipdv2_src_hdrP12pgp_source_tP17pgp_seipdv2_hdr_t:
 2232|  1.34k|{
 2233|  1.34k|    uint8_t hdrbt[3 + PGP_SEIPDV2_SALT_LEN] = {0};
 2234|       |
 2235|  1.34k|    if (!src->read_eq(hdrbt, sizeof(hdrbt))) {
  ------------------
  |  Branch (2235:9): [True: 1, False: 1.34k]
  ------------------
 2236|      1|        return false;
 2237|      1|    }
 2238|       |
 2239|  1.34k|    hdr->version = PGP_SE_IP_DATA_V2;
 2240|  1.34k|    hdr->cipher_alg = (pgp_symm_alg_t) hdrbt[0];
 2241|  1.34k|    hdr->aead_alg = (pgp_aead_alg_t) hdrbt[1];
 2242|  1.34k|    hdr->chunk_size_octet = hdrbt[2];
 2243|  1.34k|    std::memcpy(hdr->salt, &hdrbt[3], PGP_SEIPDV2_SALT_LEN);
  ------------------
  |  |  101|  1.34k|#define PGP_SEIPDV2_SALT_LEN 32
  ------------------
 2244|  1.34k|    return true;
 2245|  1.34k|}
_Z16get_aead_src_hdrP12pgp_source_tP14pgp_aead_hdr_t:
 2250|  2.60k|{
 2251|  2.60k|    uint8_t hdrbt[4] = {0};
 2252|       |
 2253|  2.60k|    if (!src->read_eq(hdrbt, 4)) {
  ------------------
  |  Branch (2253:9): [True: 0, False: 2.60k]
  ------------------
 2254|      0|        return false;
 2255|      0|    }
 2256|       |
 2257|  2.60k|    hdr->version = hdrbt[0];
 2258|  2.60k|    hdr->ealg = (pgp_symm_alg_t) hdrbt[1];
 2259|  2.60k|    hdr->aalg = (pgp_aead_alg_t) hdrbt[2];
 2260|  2.60k|    hdr->csize = hdrbt[3];
 2261|       |
 2262|  2.60k|    if (!(hdr->ivlen = pgp_cipher_aead_nonce_len(hdr->aalg))) {
  ------------------
  |  Branch (2262:9): [True: 9, False: 2.59k]
  ------------------
 2263|      9|        RNP_LOG("wrong aead nonce length: alg %d", (int) hdr->aalg);
  ------------------
  |  |   84|      9|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      9|    do {                                                                                 \
  |  |  |  |   77|      9|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      9|            break;                                                                       \
  |  |  |  |   79|      9|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2264|      9|        return false;
 2265|      9|    }
 2266|       |
 2267|  2.59k|    return src->read_eq(hdr->iv, hdr->ivlen);
 2268|  2.60k|}
_ZN20pgp_processing_ctx_tD2Ev:
 2891|  10.2k|{
 2892|  25.6k|    for (auto &src : sources) {
  ------------------
  |  Branch (2892:20): [True: 25.6k, False: 10.2k]
  ------------------
 2893|  25.6k|        src.close();
 2894|  25.6k|    }
 2895|  10.2k|}
_Z18process_pgp_sourceP19pgp_parse_handler_tR12pgp_source_t:
 3057|  10.2k|{
 3058|  10.2k|    rnp_result_t         res = RNP_ERROR_BAD_FORMAT;
 3059|  10.2k|    rnp_result_t         fres;
 3060|  10.2k|    pgp_processing_ctx_t ctx = {};
 3061|  10.2k|    pgp_source_t *       decsrc = NULL;
 3062|  10.2k|    pgp_source_t         datasrc = {0};
 3063|  10.2k|    pgp_dest_t *         outdest = NULL;
 3064|  10.2k|    bool                 closeout = true;
 3065|  10.2k|    uint8_t *            readbuf = NULL;
 3066|       |
 3067|  10.2k|    ctx.handler = *handler;
 3068|       |    /* Shared decompressed-data budget across all compression layers of the message */
 3069|  10.2k|    ctx.decomp_left = (handler->ctx && handler->ctx->max_decompressed) ?
  ------------------
  |  Branch (3069:24): [True: 10.2k, False: 0]
  |  Branch (3069:40): [True: 10.2k, False: 0]
  ------------------
 3070|  10.2k|                        handler->ctx->max_decompressed :
 3071|  10.2k|                        UINT64_MAX;
 3072|       |    /* Building readers sequence. Checking whether it is binary data */
 3073|  10.2k|    if (is_pgp_source(src)) {
  ------------------
  |  Branch (3073:9): [True: 5.18k, False: 5.02k]
  ------------------
 3074|  5.18k|        res = init_packet_sequence(ctx, src);
 3075|  5.18k|    } else {
 3076|       |        /* Trying armored or cleartext data */
 3077|  5.02k|        if (src.is_cleartext()) {
  ------------------
  |  Branch (3077:13): [True: 0, False: 5.02k]
  ------------------
 3078|       |            /* Initializing cleartext message */
 3079|      0|            res = init_cleartext_sequence(ctx, src);
 3080|  5.02k|        } else if (src.is_armored()) {
  ------------------
  |  Branch (3080:20): [True: 5.02k, False: 0]
  ------------------
 3081|       |            /* Initializing armored message */
 3082|  5.02k|            res = init_armored_sequence(ctx, src);
 3083|  5.02k|        } else {
 3084|      0|            RNP_LOG("not an OpenPGP data provided");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3085|      0|            res = RNP_ERROR_BAD_FORMAT;
 3086|      0|            goto finish;
 3087|      0|        }
 3088|  5.02k|    }
 3089|       |
 3090|  10.2k|    if (res != RNP_SUCCESS) {
  ------------------
  |  Branch (3090:9): [True: 6.92k, False: 3.28k]
  ------------------
 3091|  6.92k|        goto finish;
 3092|  6.92k|    }
 3093|       |
 3094|  3.28k|    if (!(readbuf = (uint8_t *) calloc(1, PGP_INPUT_CACHE_SIZE))) {
  ------------------
  |  |   35|  3.28k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  |  Branch (3094:9): [True: 0, False: 3.28k]
  ------------------
 3095|       |        /* LCOV_EXCL_START */
 3096|      0|        RNP_LOG("allocation failure");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3097|      0|        res = RNP_ERROR_OUT_OF_MEMORY;
 3098|      0|        goto finish;
 3099|       |        /* LCOV_EXCL_END */
 3100|      0|    }
 3101|       |
 3102|  3.28k|    if (ctx.msg_type == PGP_MESSAGE_DETACHED) {
  ------------------
  |  Branch (3102:9): [True: 17, False: 3.26k]
  ------------------
 3103|       |        /* detached signature case */
 3104|     17|        if (!handler->ctx->detached) {
  ------------------
  |  Branch (3104:13): [True: 17, False: 0]
  ------------------
 3105|     17|            RNP_LOG("Unexpected detached signature input.");
  ------------------
  |  |   84|     17|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     17|    do {                                                                                 \
  |  |  |  |   77|     17|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 17, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     17|            break;                                                                       \
  |  |  |  |   79|     17|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3106|     17|            res = RNP_ERROR_BAD_STATE;
 3107|     17|            goto finish;
 3108|     17|        }
 3109|      0|        if (!handler->src_provider || !handler->src_provider(handler, &datasrc)) {
  ------------------
  |  Branch (3109:13): [True: 0, False: 0]
  |  Branch (3109:39): [True: 0, False: 0]
  ------------------
 3110|      0|            RNP_LOG("no data source for detached signature verification");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3111|      0|            res = RNP_ERROR_READ;
 3112|      0|            goto finish;
 3113|      0|        }
 3114|       |
 3115|      0|        while (!datasrc.eof_) {
  ------------------
  |  Branch (3115:16): [True: 0, False: 0]
  ------------------
 3116|      0|            size_t read = 0;
 3117|      0|            if (!datasrc.read(readbuf, PGP_INPUT_CACHE_SIZE, &read)) {
  ------------------
  |  |   35|      0|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  |  Branch (3117:17): [True: 0, False: 0]
  ------------------
 3118|      0|                res = RNP_ERROR_GENERIC;
 3119|      0|                break;
 3120|      0|            }
 3121|      0|            if (read > 0) {
  ------------------
  |  Branch (3121:17): [True: 0, False: 0]
  ------------------
 3122|      0|                signed_src_update(ctx.signed_src, readbuf, read);
 3123|      0|            }
 3124|      0|        }
 3125|      0|        datasrc.close();
 3126|  3.26k|    } else {
 3127|  3.26k|        if (handler->ctx->detached) {
  ------------------
  |  Branch (3127:13): [True: 0, False: 3.26k]
  ------------------
 3128|      0|            RNP_LOG("Attached signature expected.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3129|      0|            res = RNP_ERROR_BAD_STATE;
 3130|      0|            goto finish;
 3131|      0|        }
 3132|       |        /* file processing case */
 3133|  3.26k|        decsrc = &ctx.sources.back();
 3134|  3.26k|        const pgp_literal_hdr_t *lithdr = nullptr;
 3135|       |
 3136|  3.26k|        if (ctx.literal_src) {
  ------------------
  |  Branch (3136:13): [True: 3.25k, False: 10]
  ------------------
 3137|  3.25k|            lithdr = &get_literal_src_hdr(*ctx.literal_src);
 3138|  3.25k|            if (ctx.signed_src) {
  ------------------
  |  Branch (3138:17): [True: 1.36k, False: 1.89k]
  ------------------
 3139|  1.36k|                signed_src_set_literal_hdr(*ctx.signed_src, *lithdr);
 3140|  1.36k|            }
 3141|  3.25k|        }
 3142|       |
 3143|  3.26k|        if (!handler->dest_provider ||
  ------------------
  |  Branch (3143:13): [True: 0, False: 3.26k]
  ------------------
 3144|  3.26k|            !handler->dest_provider(handler, &outdest, &closeout, lithdr)) {
  ------------------
  |  Branch (3144:13): [True: 0, False: 3.26k]
  ------------------
 3145|      0|            res = RNP_ERROR_WRITE;
 3146|      0|            goto finish;
 3147|      0|        }
 3148|       |
 3149|       |        /* reading the input */
 3150|  18.3k|        while (!decsrc->eof_) {
  ------------------
  |  Branch (3150:16): [True: 15.2k, False: 3.13k]
  ------------------
 3151|  15.2k|            size_t read = 0;
 3152|  15.2k|            if (!decsrc->read(readbuf, PGP_INPUT_CACHE_SIZE, &read)) {
  ------------------
  |  |   35|  15.2k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  |  Branch (3152:17): [True: 119, False: 15.1k]
  ------------------
 3153|    119|                res = RNP_ERROR_GENERIC;
 3154|    119|                break;
 3155|    119|            }
 3156|  15.1k|            if (!read) {
  ------------------
  |  Branch (3156:17): [True: 17, False: 15.1k]
  ------------------
 3157|     17|                continue;
 3158|     17|            }
 3159|  15.1k|            if (ctx.signed_src) {
  ------------------
  |  Branch (3159:17): [True: 11.9k, False: 3.13k]
  ------------------
 3160|  11.9k|                signed_src_update(ctx.signed_src, readbuf, read);
 3161|  11.9k|            }
 3162|  15.1k|            dst_write(outdest, readbuf, read);
 3163|  15.1k|            if (outdest->werr != RNP_SUCCESS) {
  ------------------
  |  Branch (3163:17): [True: 10, False: 15.1k]
  ------------------
 3164|     10|                RNP_LOG("failed to output data");
  ------------------
  |  |   84|     10|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     10|    do {                                                                                 \
  |  |  |  |   77|     10|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     10|            break;                                                                       \
  |  |  |  |   79|     10|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3165|     10|                res = RNP_ERROR_WRITE;
 3166|     10|                break;
 3167|     10|            }
 3168|  15.1k|        }
 3169|  3.26k|    }
 3170|       |
 3171|       |    /* finalizing the input. Signatures are checked on this step */
 3172|  3.26k|    if (!res) {
  ------------------
  |  Branch (3172:9): [True: 3.13k, False: 129]
  ------------------
 3173|  11.7k|        for (auto &ctxsrc : ctx.sources) {
  ------------------
  |  Branch (3173:27): [True: 11.7k, False: 3.13k]
  ------------------
 3174|  11.7k|            fres = ctxsrc.finish();
 3175|  11.7k|            if (fres) {
  ------------------
  |  Branch (3175:17): [True: 1.69k, False: 10.0k]
  ------------------
 3176|  1.69k|                res = fres;
 3177|  1.69k|            }
 3178|  11.7k|        }
 3179|  3.13k|    }
 3180|       |
 3181|  3.26k|    if (closeout && (ctx.msg_type != PGP_MESSAGE_DETACHED)) {
  ------------------
  |  Branch (3181:9): [True: 0, False: 3.26k]
  |  Branch (3181:21): [True: 0, False: 0]
  ------------------
 3182|      0|        dst_close(outdest, res != RNP_SUCCESS);
 3183|      0|    }
 3184|       |
 3185|  10.2k|finish:
 3186|  10.2k|    free(readbuf);
 3187|  10.2k|    return res;
 3188|  3.26k|}
stream-parse.cpp:_ZL16literal_src_readP12pgp_source_tPvmPm:
  344|  16.8k|{
  345|  16.8k|    pgp_source_literal_param_t *param = (pgp_source_literal_param_t *) src->param;
  346|  16.8k|    if (!param) {
  ------------------
  |  Branch (346:9): [True: 0, False: 16.8k]
  ------------------
  347|      0|        return false;
  348|      0|    }
  349|  16.8k|    return param->pkt.readsrc->read(buf, len, read);
  350|  16.8k|}
stream-parse.cpp:_ZL17literal_src_closeP12pgp_source_t:
  354|  3.29k|{
  355|  3.29k|    pgp_source_literal_param_t *param = (pgp_source_literal_param_t *) src->param;
  356|  3.29k|    if (param) {
  ------------------
  |  Branch (356:9): [True: 3.29k, False: 0]
  ------------------
  357|  3.29k|        if (param->pkt.hdr.partial) {
  ------------------
  |  Branch (357:13): [True: 613, False: 2.68k]
  ------------------
  358|    613|            param->pkt.readsrc->close();
  359|    613|            free(param->pkt.readsrc);
  360|    613|            param->pkt.readsrc = NULL;
  361|    613|        }
  362|       |
  363|  3.29k|        free(src->param);
  364|       |        src->param = NULL;
  365|  3.29k|    }
  366|  3.29k|}
stream-parse.cpp:_ZL18init_packet_paramsR25pgp_source_packet_param_t:
 2007|  18.8k|{
 2008|  18.8k|    param.origsrc = NULL;
 2009|       |
 2010|       |    /* save packet header */
 2011|  18.8k|    rnp_result_t ret = stream_peek_packet_hdr(param.readsrc, &param.hdr);
 2012|  18.8k|    if (ret) {
  ------------------
  |  Branch (2012:9): [True: 235, False: 18.5k]
  ------------------
 2013|    235|        return ret;
 2014|    235|    }
 2015|  18.5k|    param.readsrc->skip(param.hdr.hdr_len);
 2016|  18.5k|    if (!param.hdr.partial) {
  ------------------
  |  Branch (2016:9): [True: 16.8k, False: 1.74k]
  ------------------
 2017|  16.8k|        return RNP_SUCCESS;
 2018|  16.8k|    }
 2019|       |
 2020|       |    /* initialize partial reader if needed */
 2021|  1.74k|    pgp_source_t *partsrc = (pgp_source_t *) calloc(1, sizeof(*partsrc));
 2022|  1.74k|    if (!partsrc) {
  ------------------
  |  Branch (2022:9): [True: 0, False: 1.74k]
  ------------------
 2023|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 2024|      0|    }
 2025|  1.74k|    rnp_result_t errcode = init_partial_pkt_src(partsrc, param.readsrc, param.hdr);
 2026|  1.74k|    if (errcode) {
  ------------------
  |  Branch (2026:9): [True: 0, False: 1.74k]
  ------------------
 2027|      0|        free(partsrc);
 2028|      0|        return errcode;
 2029|      0|    }
 2030|  1.74k|    param.origsrc = param.readsrc;
 2031|  1.74k|    param.readsrc = partsrc;
 2032|  1.74k|    return RNP_SUCCESS;
 2033|  1.74k|}
stream-parse.cpp:_ZL20init_partial_pkt_srcP12pgp_source_tS0_R16pgp_packet_hdr_t:
  314|  1.74k|{
  315|  1.74k|    pgp_source_partial_param_t *param;
  316|  1.74k|    if (!init_src_common(src, sizeof(*param))) {
  ------------------
  |  Branch (316:9): [True: 0, False: 1.74k]
  ------------------
  317|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
  318|      0|    }
  319|       |
  320|  1.74k|    assert(hdr.partial);
  321|       |    /* we are sure that header is indeterminate */
  322|  1.74k|    param = (pgp_source_partial_param_t *) src->param;
  323|  1.74k|    param->type = hdr.tag;
  324|  1.74k|    param->psize = get_partial_pkt_len(hdr.hdr[1]);
  325|  1.74k|    param->pleft = param->psize;
  326|  1.74k|    param->last = false;
  327|  1.74k|    param->readsrc = readsrc;
  328|       |
  329|  1.74k|    src->raw_read = partial_pkt_src_read;
  330|  1.74k|    src->raw_close = partial_pkt_src_close;
  331|  1.74k|    src->type = PGP_STREAM_PARLEN_PACKET;
  332|       |
  333|  1.74k|    if (param->psize < PGP_PARTIAL_PKT_FIRST_PART_MIN_SIZE) {
  ------------------
  |  |   38|  1.74k|#define PGP_PARTIAL_PKT_FIRST_PART_MIN_SIZE 512
  ------------------
  |  Branch (333:9): [True: 75, False: 1.67k]
  ------------------
  334|     75|        RNP_LOG("first part of partial length packet sequence has size %d and that's less "
  ------------------
  |  |   84|     75|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     75|    do {                                                                                 \
  |  |  |  |   77|     75|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 75, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     75|            break;                                                                       \
  |  |  |  |   79|     75|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  335|     75|                "than allowed by the protocol",
  336|     75|                (int) param->psize);
  337|     75|    }
  338|       |
  339|  1.74k|    return RNP_SUCCESS;
  340|  1.74k|}
stream-parse.cpp:_ZL20partial_pkt_src_readP12pgp_source_tPvmPm:
  249|  18.4k|{
  250|  18.4k|    if (src->eof_) {
  ------------------
  |  Branch (250:9): [True: 0, False: 18.4k]
  ------------------
  251|      0|        *readres = 0;
  252|      0|        return true;
  253|      0|    }
  254|       |
  255|  18.4k|    pgp_source_partial_param_t *param = (pgp_source_partial_param_t *) src->param;
  256|  18.4k|    if (!param) {
  ------------------
  |  Branch (256:9): [True: 0, False: 18.4k]
  ------------------
  257|      0|        return false;
  258|      0|    }
  259|       |
  260|  18.4k|    size_t read;
  261|  18.4k|    size_t write = 0;
  262|  66.8k|    while (len > 0) {
  ------------------
  |  Branch (262:12): [True: 51.3k, False: 15.5k]
  ------------------
  263|  51.3k|        if (!param->pleft && param->last) {
  ------------------
  |  Branch (263:13): [True: 38.3k, False: 13.0k]
  |  Branch (263:30): [True: 2.29k, False: 36.0k]
  ------------------
  264|       |            // we have the last chunk
  265|  2.29k|            *readres = write;
  266|  2.29k|            return true;
  267|  2.29k|        }
  268|  49.0k|        if (!param->pleft) {
  ------------------
  |  Branch (268:13): [True: 36.0k, False: 13.0k]
  ------------------
  269|       |            // reading next chunk
  270|  36.0k|            if (!stream_read_partial_chunk_len(param->readsrc, &read, &param->last)) {
  ------------------
  |  Branch (270:17): [True: 3, False: 36.0k]
  ------------------
  271|      3|                return false;
  272|      3|            }
  273|  36.0k|            param->psize = read;
  274|  36.0k|            param->pleft = read;
  275|  36.0k|        }
  276|       |
  277|  49.0k|        if (!param->pleft) {
  ------------------
  |  Branch (277:13): [True: 21, False: 48.9k]
  ------------------
  278|     21|            *readres = write;
  279|     21|            return true;
  280|     21|        }
  281|       |
  282|  48.9k|        read = param->pleft > len ? len : param->pleft;
  ------------------
  |  Branch (282:16): [True: 11.4k, False: 37.5k]
  ------------------
  283|  48.9k|        if (!param->readsrc->read(buf, read, &read)) {
  ------------------
  |  Branch (283:13): [True: 220, False: 48.7k]
  ------------------
  284|    220|            RNP_LOG("failed to read data chunk");
  ------------------
  |  |   84|    220|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    220|    do {                                                                                 \
  |  |  |  |   77|    220|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 220, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    220|            break;                                                                       \
  |  |  |  |   79|    220|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  285|    220|            return false;
  286|    220|        }
  287|  48.7k|        if (!read) {
  ------------------
  |  Branch (287:13): [True: 424, False: 48.3k]
  ------------------
  288|    424|            RNP_LOG("unexpected eof");
  ------------------
  |  |   84|    424|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    424|    do {                                                                                 \
  |  |  |  |   77|    424|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 424, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    424|            break;                                                                       \
  |  |  |  |   79|    424|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  289|    424|            *readres = write;
  290|    424|            return true;
  291|    424|        }
  292|  48.3k|        write += read;
  293|  48.3k|        len -= read;
  294|  48.3k|        buf = (uint8_t *) buf + read;
  295|  48.3k|        param->pleft -= read;
  296|  48.3k|    }
  297|       |
  298|  15.5k|    *readres = write;
  299|  15.5k|    return true;
  300|  18.4k|}
stream-parse.cpp:_ZL21partial_pkt_src_closeP12pgp_source_t:
  304|  1.74k|{
  305|  1.74k|    pgp_source_partial_param_t *param = (pgp_source_partial_param_t *) src->param;
  306|  1.74k|    if (param) {
  ------------------
  |  Branch (306:9): [True: 1.74k, False: 0]
  ------------------
  307|  1.74k|        free(src->param);
  308|       |        src->param = NULL;
  309|  1.74k|    }
  310|  1.74k|}
stream-parse.cpp:_ZL19compressed_src_readP12pgp_source_tPvmPm:
  385|  24.2k|{
  386|  24.2k|    pgp_source_compressed_param_t *param = (pgp_source_compressed_param_t *) src->param;
  387|  24.2k|    if (!param) {
  ------------------
  |  Branch (387:9): [True: 0, False: 24.2k]
  ------------------
  388|      0|        return false; // LCOV_EXCL_LINE
  389|      0|    }
  390|       |
  391|  24.2k|    if (src->eof_ || param->zend) {
  ------------------
  |  Branch (391:9): [True: 0, False: 24.2k]
  |  Branch (391:22): [True: 4.50k, False: 19.7k]
  ------------------
  392|  4.50k|        *readres = 0;
  393|  4.50k|        return true;
  394|  4.50k|    }
  395|       |
  396|  19.7k|    if (param->alg == PGP_C_NONE) {
  ------------------
  |  Branch (396:9): [True: 1.57k, False: 18.1k]
  ------------------
  397|  1.57k|        if (!param->pkt.readsrc->read(buf, len, readres)) {
  ------------------
  |  Branch (397:13): [True: 6, False: 1.56k]
  ------------------
  398|      6|            RNP_LOG("failed to read uncompressed data");
  ------------------
  |  |   84|      6|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      6|    do {                                                                                 \
  |  |  |  |   77|      6|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 6, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      6|            break;                                                                       \
  |  |  |  |   79|      6|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  399|      6|            return false;
  400|      6|        }
  401|  1.56k|        return compressed_budget_consume(param, *readres);
  402|  1.57k|    }
  403|  18.1k|    if ((param->alg == PGP_C_ZIP) || (param->alg == PGP_C_ZLIB)) {
  ------------------
  |  Branch (403:9): [True: 15.2k, False: 2.87k]
  |  Branch (403:38): [True: 1.68k, False: 1.19k]
  ------------------
  404|  16.9k|        param->z.next_out = (Bytef *) buf;
  405|  16.9k|        param->z.avail_out = len;
  406|  16.9k|        param->z.next_in = param->in + param->inpos;
  407|  16.9k|        param->z.avail_in = param->inlen - param->inpos;
  408|       |
  409|  29.6k|        while ((param->z.avail_out > 0) && (!param->zend)) {
  ------------------
  |  Branch (409:16): [True: 17.8k, False: 11.7k]
  |  Branch (409:44): [True: 17.8k, False: 0]
  ------------------
  410|  17.8k|            if (param->z.avail_in == 0) {
  ------------------
  |  Branch (410:17): [True: 6.14k, False: 11.7k]
  ------------------
  411|  6.14k|                size_t read = 0;
  412|  6.14k|                if (!param->pkt.readsrc->read(param->in, sizeof(param->in), &read)) {
  ------------------
  |  Branch (412:21): [True: 2, False: 6.13k]
  ------------------
  413|      2|                    RNP_LOG("failed to read data");
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  414|      2|                    return false;
  415|      2|                }
  416|  6.13k|                param->z.next_in = param->in;
  417|  6.13k|                param->z.avail_in = read;
  418|  6.13k|                param->inlen = read;
  419|  6.13k|                param->inpos = 0;
  420|  6.13k|            }
  421|  17.8k|            int ret = inflate(&param->z, Z_SYNC_FLUSH);
  422|  17.8k|            if (ret == Z_STREAM_END) {
  ------------------
  |  Branch (422:17): [True: 4.99k, False: 12.8k]
  ------------------
  423|  4.99k|                param->zend = true;
  424|  4.99k|                if (param->z.avail_in > 0) {
  ------------------
  |  Branch (424:21): [True: 1.72k, False: 3.27k]
  ------------------
  425|  1.72k|                    RNP_LOG("data beyond the end of z stream");
  ------------------
  |  |   84|  1.72k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.72k|    do {                                                                                 \
  |  |  |  |   77|  1.72k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.72k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.72k|            break;                                                                       \
  |  |  |  |   79|  1.72k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  426|  1.72k|                }
  427|  4.99k|                break;
  428|  4.99k|            }
  429|  12.8k|            if (ret != Z_OK) {
  ------------------
  |  Branch (429:17): [True: 52, False: 12.8k]
  ------------------
  430|     52|                RNP_LOG("inflate error %d", ret);
  ------------------
  |  |   84|     52|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     52|    do {                                                                                 \
  |  |  |  |   77|     52|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 52, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     52|            break;                                                                       \
  |  |  |  |   79|     52|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  431|     52|                return false;
  432|     52|            }
  433|  12.8k|            if (!param->z.avail_in && param->pkt.readsrc->eof()) {
  ------------------
  |  Branch (433:17): [True: 1.02k, False: 11.7k]
  |  Branch (433:39): [True: 117, False: 911]
  ------------------
  434|    117|                RNP_LOG("unexpected end of zlib stream");
  ------------------
  |  |   84|    117|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    117|    do {                                                                                 \
  |  |  |  |   77|    117|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 117, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    117|            break;                                                                       \
  |  |  |  |   79|    117|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  435|    117|                return false;
  436|    117|            }
  437|  12.8k|        }
  438|  16.7k|        param->inpos = param->z.next_in - param->in;
  439|  16.7k|        *readres = len - param->z.avail_out;
  440|  16.7k|        return compressed_budget_consume(param, *readres);
  441|  16.9k|    }
  442|  1.19k|#ifdef HAVE_BZLIB_H
  443|  1.19k|    if (param->alg == PGP_C_BZIP2) {
  ------------------
  |  Branch (443:9): [True: 1.19k, False: 0]
  ------------------
  444|  1.19k|        param->bz.next_out = (char *) buf;
  445|  1.19k|        param->bz.avail_out = len;
  446|  1.19k|        param->bz.next_in = (char *) (param->in + param->inpos);
  447|  1.19k|        param->bz.avail_in = param->inlen - param->inpos;
  448|       |
  449|  1.88k|        while ((param->bz.avail_out > 0) && (!param->zend)) {
  ------------------
  |  Branch (449:16): [True: 1.58k, False: 292]
  |  Branch (449:45): [True: 1.58k, False: 0]
  ------------------
  450|  1.58k|            if (param->bz.avail_in == 0) {
  ------------------
  |  Branch (450:17): [True: 1.31k, False: 271]
  ------------------
  451|  1.31k|                size_t read = 0;
  452|  1.31k|                if (!param->pkt.readsrc->read(param->in, sizeof(param->in), &read)) {
  ------------------
  |  Branch (452:21): [True: 1, False: 1.31k]
  ------------------
  453|      1|                    RNP_LOG("failed to read data");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  454|      1|                    return false;
  455|      1|                }
  456|  1.31k|                param->bz.next_in = (char *) param->in;
  457|  1.31k|                param->bz.avail_in = read;
  458|  1.31k|                param->inlen = read;
  459|  1.31k|                param->inpos = 0;
  460|  1.31k|            }
  461|  1.58k|            int ret = BZ2_bzDecompress(&param->bz);
  462|  1.58k|            if (ret == BZ_STREAM_END) {
  ------------------
  |  Branch (462:17): [True: 900, False: 687]
  ------------------
  463|    900|                param->zend = true;
  464|    900|                if (param->bz.avail_in > 0) {
  ------------------
  |  Branch (464:21): [True: 223, False: 677]
  ------------------
  465|    223|                    RNP_LOG("data beyond the end of z stream");
  ------------------
  |  |   84|    223|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    223|    do {                                                                                 \
  |  |  |  |   77|    223|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 223, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    223|            break;                                                                       \
  |  |  |  |   79|    223|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  466|    223|                }
  467|    900|                break;
  468|    900|            }
  469|    687|            if (ret != BZ_OK) {
  ------------------
  |  Branch (469:17): [True: 1, False: 686]
  ------------------
  470|      1|                RNP_LOG("bzdecompress error %d", ret);
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  471|      1|                return false;
  472|      1|            }
  473|    686|            if (!param->bz.avail_in && param->pkt.readsrc->eof()) {
  ------------------
  |  Branch (473:17): [True: 394, False: 292]
  |  Branch (473:40): [True: 2, False: 392]
  ------------------
  474|      2|                RNP_LOG("unexpected end of bzip stream");
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  475|      2|                return false;
  476|      2|            }
  477|    686|        }
  478|       |
  479|  1.19k|        param->inpos = (uint8_t *) param->bz.next_in - param->in;
  480|  1.19k|        *readres = len - param->bz.avail_out;
  481|  1.19k|        return compressed_budget_consume(param, *readres);
  482|  1.19k|    }
  483|      0|#endif
  484|      0|    return false;
  485|  1.19k|}
stream-parse.cpp:_ZL25compressed_budget_consumeP29pgp_source_compressed_param_tm:
  370|  19.5k|{
  371|  19.5k|    if (!param->decomp_left) {
  ------------------
  |  Branch (371:9): [True: 0, False: 19.5k]
  ------------------
  372|       |        /* no budget set: the caller bounds the data itself (dump layer) */
  373|      0|        return true;
  374|      0|    }
  375|  19.5k|    if (produced > *param->decomp_left) {
  ------------------
  |  Branch (375:9): [True: 0, False: 19.5k]
  ------------------
  376|      0|        RNP_LOG("decompressed data exceeds the allowed limit");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  377|      0|        return false;
  378|      0|    }
  379|  19.5k|    *param->decomp_left -= produced;
  380|  19.5k|    return true;
  381|  19.5k|}
stream-parse.cpp:_ZL20compressed_src_closeP12pgp_source_t:
  489|  6.76k|{
  490|  6.76k|    pgp_source_compressed_param_t *param = (pgp_source_compressed_param_t *) src->param;
  491|  6.76k|    if (!param) {
  ------------------
  |  Branch (491:9): [True: 0, False: 6.76k]
  ------------------
  492|      0|        return; // LCOV_EXCL_LINE
  493|      0|    }
  494|       |
  495|  6.76k|    if (param->pkt.hdr.partial) {
  ------------------
  |  Branch (495:9): [True: 313, False: 6.45k]
  ------------------
  496|    313|        param->pkt.readsrc->close();
  497|    313|        free(param->pkt.readsrc);
  498|    313|        param->pkt.readsrc = NULL;
  499|    313|    }
  500|       |
  501|  6.76k|#ifdef HAVE_BZLIB_H
  502|  6.76k|    if (param->alg == PGP_C_BZIP2) {
  ------------------
  |  Branch (502:9): [True: 925, False: 5.84k]
  ------------------
  503|    925|        BZ2_bzDecompressEnd(&param->bz);
  504|    925|    }
  505|  6.76k|#endif
  506|  6.76k|    if ((param->alg == PGP_C_ZIP) || (param->alg == PGP_C_ZLIB)) {
  ------------------
  |  Branch (506:9): [True: 3.82k, False: 2.94k]
  |  Branch (506:38): [True: 1.40k, False: 1.53k]
  ------------------
  507|  5.22k|        inflateEnd(&param->z);
  508|  5.22k|    }
  509|       |
  510|  6.76k|    free(src->param);
  511|       |    src->param = NULL;
  512|  6.76k|}
stream-parse.cpp:_ZL13is_pgp_sourceR12pgp_source_t:
  221|  10.2k|{
  222|  10.2k|    uint8_t buf;
  223|  10.2k|    if (!src.peek_eq(&buf, 1)) {
  ------------------
  |  Branch (223:9): [True: 0, False: 10.2k]
  ------------------
  224|      0|        return false;
  225|      0|    }
  226|       |
  227|  10.2k|    int ptype = get_packet_type(buf);
  228|  10.2k|    switch (ptype) {
  229|     16|    case PGP_PKT_PK_SESSION_KEY:
  ------------------
  |  Branch (229:5): [True: 16, False: 10.1k]
  ------------------
  230|  5.18k|    case PGP_PKT_SK_SESSION_KEY:
  ------------------
  |  Branch (230:5): [True: 5.16k, False: 5.04k]
  ------------------
  231|  5.18k|    case PGP_PKT_ONE_PASS_SIG:
  ------------------
  |  Branch (231:5): [True: 0, False: 10.2k]
  ------------------
  232|  5.18k|    case PGP_PKT_SIGNATURE:
  ------------------
  |  Branch (232:5): [True: 0, False: 10.2k]
  ------------------
  233|  5.18k|    case PGP_PKT_SE_DATA:
  ------------------
  |  Branch (233:5): [True: 0, False: 10.2k]
  ------------------
  234|  5.18k|    case PGP_PKT_SE_IP_DATA:
  ------------------
  |  Branch (234:5): [True: 0, False: 10.2k]
  ------------------
  235|  5.18k|    case PGP_PKT_COMPRESSED:
  ------------------
  |  Branch (235:5): [True: 0, False: 10.2k]
  ------------------
  236|  5.18k|    case PGP_PKT_LITDATA:
  ------------------
  |  Branch (236:5): [True: 0, False: 10.2k]
  ------------------
  237|  5.18k|    case PGP_PKT_MARKER:
  ------------------
  |  Branch (237:5): [True: 0, False: 10.2k]
  ------------------
  238|  5.18k|        return true;
  239|  5.02k|    default:
  ------------------
  |  Branch (239:5): [True: 5.02k, False: 5.18k]
  ------------------
  240|       |        /* RFC 9580, 4.3 and 5.14: a message may begin with an unknown
  241|       |         * non-critical packet (type IDs 40-63) or a padding packet, which
  242|       |         * are then skipped */
  243|  5.02k|        return ((ptype >= 40) && (ptype <= 63)) || (ptype == PGP_PKT_PADDING);
  ------------------
  |  Branch (243:17): [True: 0, False: 5.02k]
  |  Branch (243:34): [True: 0, False: 0]
  |  Branch (243:52): [True: 0, False: 5.02k]
  ------------------
  244|  10.2k|    }
  245|  10.2k|}
stream-parse.cpp:_ZL20init_packet_sequenceR20pgp_processing_ctx_tR12pgp_source_t:
 2902|  10.2k|{
 2903|  10.2k|    pgp_source_t *lsrc = &src;
 2904|  10.2k|    size_t        srcnum = ctx.sources.size();
 2905|       |
 2906|  29.8k|    while (1) {
  ------------------
  |  Branch (2906:12): [True: 29.8k, Folded]
  ------------------
 2907|  29.8k|        uint8_t ptag = 0;
 2908|  29.8k|        if (!lsrc->peek_eq(&ptag, 1)) {
  ------------------
  |  Branch (2908:13): [True: 3.12k, False: 26.7k]
  ------------------
 2909|  3.12k|            RNP_LOG("cannot read packet tag");
  ------------------
  |  |   84|  3.12k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  3.12k|    do {                                                                                 \
  |  |  |  |   77|  3.12k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3.12k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  3.12k|            break;                                                                       \
  |  |  |  |   79|  3.12k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2910|  3.12k|            return RNP_ERROR_READ;
 2911|  3.12k|        }
 2912|       |
 2913|  26.7k|        int type = get_packet_type(ptag);
 2914|  26.7k|        if (type < 0) {
  ------------------
  |  Branch (2914:13): [True: 238, False: 26.5k]
  ------------------
 2915|    238|            RNP_LOG("wrong pkt tag %d", (int) ptag);
  ------------------
  |  |   84|    238|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    238|    do {                                                                                 \
  |  |  |  |   77|    238|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 238, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    238|            break;                                                                       \
  |  |  |  |   79|    238|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2916|    238|            return RNP_ERROR_BAD_FORMAT;
 2917|    238|        }
 2918|       |
 2919|  26.5k|        if (ctx.sources.size() - srcnum == MAXIMUM_NESTING_LEVEL) {
  ------------------
  |  |   60|  26.5k|#define MAXIMUM_NESTING_LEVEL 32
  ------------------
  |  Branch (2919:13): [True: 7, False: 26.5k]
  ------------------
 2920|      7|            RNP_LOG("Too many nested OpenPGP packets");
  ------------------
  |  |   84|      7|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      7|    do {                                                                                 \
  |  |  |  |   77|      7|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      7|            break;                                                                       \
  |  |  |  |   79|      7|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2921|      7|            return RNP_ERROR_BAD_FORMAT;
 2922|      7|        }
 2923|       |
 2924|  26.5k|        pgp_source_t psrc = {};
 2925|  26.5k|        rnp_result_t ret = RNP_ERROR_BAD_FORMAT;
 2926|  26.5k|        switch (type) {
 2927|    310|        case PGP_PKT_PK_SESSION_KEY:
  ------------------
  |  Branch (2927:9): [True: 310, False: 26.2k]
  ------------------
 2928|  9.34k|        case PGP_PKT_SK_SESSION_KEY:
  ------------------
  |  Branch (2928:9): [True: 9.03k, False: 17.4k]
  ------------------
 2929|  9.34k|            ret = init_encrypted_src(&ctx.handler, &psrc, lsrc);
 2930|  9.34k|            break;
 2931|  1.88k|        case PGP_PKT_ONE_PASS_SIG:
  ------------------
  |  Branch (2931:9): [True: 1.88k, False: 24.6k]
  ------------------
 2932|  3.70k|        case PGP_PKT_SIGNATURE:
  ------------------
  |  Branch (2932:9): [True: 1.82k, False: 24.6k]
  ------------------
 2933|  3.70k|            ret = init_signed_src(&ctx.handler, &psrc, lsrc);
 2934|  3.70k|            break;
 2935|  6.76k|        case PGP_PKT_COMPRESSED:
  ------------------
  |  Branch (2935:9): [True: 6.76k, False: 19.7k]
  ------------------
 2936|  6.76k|            ret = init_compressed_src(&psrc, lsrc, &ctx.decomp_left);
 2937|  6.76k|            break;
 2938|  3.29k|        case PGP_PKT_LITDATA:
  ------------------
  |  Branch (2938:9): [True: 3.29k, False: 23.2k]
  ------------------
 2939|  3.29k|            if ((lsrc != &src) && (lsrc->type != PGP_STREAM_ENCRYPTED) &&
  ------------------
  |  Branch (2939:17): [True: 3.29k, False: 0]
  |  Branch (2939:35): [True: 2.22k, False: 1.07k]
  ------------------
 2940|  2.22k|                (lsrc->type != PGP_STREAM_SIGNED) && (lsrc->type != PGP_STREAM_COMPRESSED)) {
  ------------------
  |  Branch (2940:17): [True: 848, False: 1.37k]
  |  Branch (2940:54): [True: 0, False: 848]
  ------------------
 2941|      0|                RNP_LOG("unexpected literal pkt");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2942|      0|                ret = RNP_ERROR_BAD_FORMAT;
 2943|      0|                break;
 2944|      0|            }
 2945|  3.29k|            ret = init_literal_src(&psrc, lsrc);
 2946|  3.29k|            break;
 2947|     83|        case PGP_PKT_MARKER:
  ------------------
  |  Branch (2947:9): [True: 83, False: 26.4k]
  ------------------
 2948|     83|            if (ctx.sources.size() != srcnum) {
  ------------------
  |  Branch (2948:17): [True: 83, False: 0]
  ------------------
 2949|     83|                RNP_LOG("Warning: marker packet wrapped in pgp stream.");
  ------------------
  |  |   84|     83|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     83|    do {                                                                                 \
  |  |  |  |   77|     83|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 83, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     83|            break;                                                                       \
  |  |  |  |   79|     83|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2950|     83|            }
 2951|     83|            ret = stream_parse_marker(*lsrc);
 2952|     83|            if (ret) {
  ------------------
  |  Branch (2952:17): [True: 53, False: 30]
  ------------------
 2953|     53|                RNP_LOG("Invalid marker packet");
  ------------------
  |  |   84|     53|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     53|    do {                                                                                 \
  |  |  |  |   77|     53|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 53, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     53|            break;                                                                       \
  |  |  |  |   79|     53|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2954|     53|                return ret;
 2955|     53|            }
 2956|     30|            continue;
 2957|  3.32k|        default:
  ------------------
  |  Branch (2957:9): [True: 3.32k, False: 23.1k]
  ------------------
 2958|       |            /* RFC 9580, 4.3: packets with type IDs 40-63 are non-critical and unknown
 2959|       |             * ones must be ignored. This also covers padding packets (5.14). */
 2960|  3.32k|            if (((type >= 40) && (type <= 63)) || (type == PGP_PKT_PADDING)) {
  ------------------
  |  Branch (2960:18): [True: 2.38k, False: 934]
  |  Branch (2960:34): [True: 2.38k, False: 0]
  |  Branch (2960:51): [True: 11, False: 923]
  ------------------
 2961|  2.39k|                if (stream_skip_packet(lsrc)) {
  ------------------
  |  Branch (2961:21): [True: 69, False: 2.32k]
  ------------------
 2962|     69|                    RNP_LOG("failed to skip packet");
  ------------------
  |  |   84|     69|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     69|    do {                                                                                 \
  |  |  |  |   77|     69|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 69, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     69|            break;                                                                       \
  |  |  |  |   79|     69|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2963|     69|                    ret = RNP_ERROR_READ;
 2964|  2.32k|                } else {
 2965|  2.32k|                    if (type == PGP_PKT_PADDING) {
  ------------------
  |  Branch (2965:25): [True: 10, False: 2.31k]
  ------------------
 2966|       |                        /* RFC 9580, 5.14: the padding packet is the last
 2967|       |                         * packet of an Optionally Padded Message, so the
 2968|       |                         * packet sequence ends here */
 2969|     10|                        if (!ctx.sources.empty()) {
  ------------------
  |  Branch (2969:29): [True: 10, False: 0]
  ------------------
 2970|     10|                            return RNP_SUCCESS;
 2971|     10|                        }
 2972|     10|                    }
 2973|  2.31k|                    continue;
 2974|  2.32k|                }
 2975|     69|                break;
 2976|  2.39k|            }
 2977|    923|            RNP_LOG("unexpected pkt %d", type);
  ------------------
  |  |   84|    923|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    923|    do {                                                                                 \
  |  |  |  |   77|    923|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 923, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    923|            break;                                                                       \
  |  |  |  |   79|    923|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2978|    923|            ret = RNP_ERROR_BAD_FORMAT;
 2979|  26.5k|        }
 2980|       |
 2981|  24.1k|        if (ret) {
  ------------------
  |  Branch (2981:13): [True: 3.49k, False: 20.6k]
  ------------------
 2982|  3.49k|            return ret;
 2983|  3.49k|        }
 2984|       |
 2985|  20.6k|        try {
 2986|  20.6k|            ctx.sources.push_back(psrc);
 2987|  20.6k|            lsrc = &ctx.sources.back();
 2988|  20.6k|        } catch (const std::exception &e) {
 2989|       |            /* LCOV_EXCL_START */
 2990|      0|            psrc.close();
 2991|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2992|      0|            return RNP_ERROR_OUT_OF_MEMORY;
 2993|       |            /* LCOV_EXCL_END */
 2994|      0|        }
 2995|       |
 2996|  20.6k|        if (lsrc->type == PGP_STREAM_LITERAL) {
  ------------------
  |  Branch (2996:13): [True: 3.25k, False: 17.3k]
  ------------------
 2997|  3.25k|            ctx.literal_src = lsrc;
 2998|  3.25k|            ctx.msg_type = PGP_MESSAGE_NORMAL;
 2999|  3.25k|            return RNP_SUCCESS;
 3000|  3.25k|        }
 3001|  17.3k|        if (lsrc->type == PGP_STREAM_SIGNED) {
  ------------------
  |  Branch (3001:13): [True: 2.81k, False: 14.5k]
  ------------------
 3002|  2.81k|            ctx.signed_src = lsrc;
 3003|  2.81k|            pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) lsrc->param;
 3004|  2.81k|            if (param->detached) {
  ------------------
  |  Branch (3004:17): [True: 17, False: 2.79k]
  ------------------
 3005|     17|                ctx.msg_type = PGP_MESSAGE_DETACHED;
 3006|     17|                return RNP_SUCCESS;
 3007|     17|            }
 3008|  2.81k|        }
 3009|  17.3k|    }
 3010|  10.2k|}
stream-parse.cpp:_ZL18init_encrypted_srcP19pgp_parse_handler_tP12pgp_source_tS2_:
 2473|  9.34k|{
 2474|  9.34k|    bool pub_decrypt_tried = false;
 2475|  9.34k|    if (!init_src_common(src, 0)) {
  ------------------
  |  Branch (2475:9): [True: 0, False: 9.34k]
  ------------------
 2476|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2477|      0|    }
 2478|  9.34k|    pgp_source_encrypted_param_t *param = new (std::nothrow) pgp_source_encrypted_param_t();
 2479|  9.34k|    if (!param) {
  ------------------
  |  Branch (2479:9): [True: 0, False: 9.34k]
  ------------------
 2480|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2481|      0|    }
 2482|  9.34k|    src->param = param;
 2483|  9.34k|    param->pkt.readsrc = readsrc;
 2484|  9.34k|    param->handler = handler;
 2485|       |
 2486|  9.34k|    src->raw_close = encrypted_src_close;
 2487|  9.34k|    src->raw_finish = encrypted_src_finish;
 2488|  9.34k|    src->type = PGP_STREAM_ENCRYPTED;
 2489|       |
 2490|       |    /* Read the packet-related information */
 2491|  9.34k|    rnp_result_t errcode = encrypted_read_packet_data(param);
 2492|  9.34k|    if (errcode) {
  ------------------
  |  Branch (2492:9): [True: 852, False: 8.49k]
  ------------------
 2493|    852|        goto finish;
 2494|    852|    }
 2495|       |
 2496|  8.49k|    src->raw_read = (!param->use_cfb()
  ------------------
  |  Branch (2496:22): [True: 3.93k, False: 4.55k]
  ------------------
 2497|  4.55k|#ifdef ENABLE_CRYPTO_REFRESH
 2498|  4.55k|                     || param->is_v2_seipd()
  ------------------
  |  Branch (2498:25): [True: 0, False: 4.55k]
  ------------------
 2499|  8.49k|#endif
 2500|  8.49k|                       ) ?
 2501|  3.93k|                      encrypted_src_read_aead :
 2502|  8.49k|                      encrypted_src_read_cfb;
 2503|       |
 2504|       |    /* Obtaining the symmetric key */
 2505|  8.49k|    if (!handler->password_provider) {
  ------------------
  |  Branch (2505:9): [True: 0, False: 8.49k]
  ------------------
 2506|       |        /* LCOV_EXCL_START */
 2507|      0|        RNP_LOG("no password provider");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2508|      0|        errcode = RNP_ERROR_BAD_PARAMETERS;
 2509|      0|        goto finish;
 2510|       |        /* LCOV_EXCL_END */
 2511|      0|    }
 2512|       |
 2513|       |    /* informing handler about the available pubencs/symencs */
 2514|  8.49k|    if (handler->on_recipients) {
  ------------------
  |  Branch (2514:9): [True: 8.49k, False: 0]
  ------------------
 2515|  8.49k|        handler->on_recipients(param->pubencs, param->symencs, handler->param);
 2516|  8.49k|    }
 2517|       |
 2518|       |    /* RFC 9580, 5.7: Symmetrically Encrypted Data packet is obsolete and malleable, so it
 2519|       |     * should be rejected. Do this before any session key decryption so no data is output.
 2520|       |     * Report the container first. The cipher is not known yet, and integrity is not
 2521|       |     * validated: on_decryption_done is intentionally not called. Allowed SED still reports
 2522|       |     * once, later, after the real cipher is known. */
 2523|  8.49k|    if ((param->auth_type == rnp::AuthType::None) &&
  ------------------
  |  Branch (2523:9): [True: 4, False: 8.48k]
  ------------------
 2524|      4|        (!handler->ctx || !handler->ctx->allow_unprotected)) {
  ------------------
  |  Branch (2524:10): [True: 0, False: 4]
  |  Branch (2524:27): [True: 4, False: 0]
  ------------------
 2525|      4|        RNP_LOG("Refusing to decrypt Symmetrically Encrypted Data packet without integrity "
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2526|      4|                "protection (allow it explicitly to override).");
 2527|      4|        if (handler->on_decryption_info) {
  ------------------
  |  Branch (2527:13): [True: 4, False: 0]
  ------------------
 2528|      4|            handler->on_decryption_info(false, PGP_AEAD_NONE, PGP_SA_UNKNOWN, handler->param);
 2529|      4|        }
 2530|      4|        errcode = RNP_ERROR_DECRYPT_FAILED;
 2531|      4|        goto finish;
 2532|      4|    }
 2533|       |
 2534|  8.48k|    bool have_key;
 2535|  8.48k|    have_key = false;
 2536|       |    /* Trying public-key decryption */
 2537|  8.48k|    if (!param->pubencs.empty()) {
  ------------------
  |  Branch (2537:9): [True: 35, False: 8.45k]
  ------------------
 2538|     35|        if (!handler->key_provider) {
  ------------------
  |  Branch (2538:13): [True: 0, False: 35]
  ------------------
 2539|       |            /* LCOV_EXCL_START */
 2540|      0|            RNP_LOG("no key provider");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2541|      0|            errcode = RNP_ERROR_BAD_PARAMETERS;
 2542|      0|            goto finish;
 2543|       |            /* LCOV_EXCL_END */
 2544|      0|        }
 2545|       |
 2546|     35|        size_t pubidx = 0;
 2547|     35|        size_t hidden_tries = 0;
 2548|     35|        errcode = RNP_ERROR_NO_SUITABLE_KEY;
 2549|     87|        while (pubidx < param->pubencs.size()) {
  ------------------
  |  Branch (2549:16): [True: 52, False: 35]
  ------------------
 2550|     52|            auto &                          pubenc = param->pubencs[pubidx];
 2551|     52|            std::unique_ptr<rnp::KeySearch> search;
 2552|     52|#if defined(ENABLE_CRYPTO_REFRESH)
 2553|     52|            if (pubenc.version == PGP_PKSK_V3) {
  ------------------
  |  Branch (2553:17): [True: 44, False: 8]
  ------------------
 2554|     44|#endif
 2555|     44|                search = rnp::KeySearch::create(pubenc.key_id);
 2556|     44|#if defined(ENABLE_CRYPTO_REFRESH)
 2557|     44|            } else if (!pubenc.fp.size()) {
  ------------------
  |  Branch (2557:24): [True: 8, False: 0]
  ------------------
 2558|       |                /* Anonymous v6 PKESK (RFC 9580 §5.1.8): no fingerprint was
 2559|       |                 * stored. Reuse the wildcard Key ID search so every secret
 2560|       |                 * key is tried, under the same hidden-recipient gate as a v3
 2561|       |                 * all-zero Key ID. */
 2562|      8|                search = rnp::KeySearch::create(pgp::KeyID({}));
 2563|      8|            } else { // PGP_PKSK_V6
 2564|      0|                search = rnp::KeySearch::create(pubenc.fp);
 2565|      0|            }
 2566|     52|#endif
 2567|       |
 2568|       |            /* Get the key if any */
 2569|     52|            auto seckey = handler->key_provider->request_key(*search, PGP_OP_DECRYPT, true);
 2570|     52|            if (!seckey) {
  ------------------
  |  Branch (2570:17): [True: 52, False: 0]
  ------------------
 2571|     52|                pubidx++;
 2572|     52|                hidden_tries = 0;
 2573|     52|                continue;
 2574|     52|            }
 2575|       |            /* Check whether key fits our needs */
 2576|      0|            bool hidden;
 2577|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 2578|      0|            if (pubenc.version == PGP_PKSK_V3) {
  ------------------
  |  Branch (2578:17): [True: 0, False: 0]
  ------------------
 2579|      0|#endif
 2580|      0|                hidden = (pubenc.key_id == pgp::KeyID({}));
 2581|      0|#if defined(ENABLE_CRYPTO_REFRESH)
 2582|      0|            } else { // PGP_PKSK_V6
 2583|      0|                hidden = !pubenc.fp.size();
 2584|      0|            }
 2585|      0|#endif
 2586|      0|            if (!hidden || (++hidden_tries >= MAX_HIDDEN_TRIES)) {
  ------------------
  |  | 2465|      0|#define MAX_HIDDEN_TRIES 64
  ------------------
  |  Branch (2586:17): [True: 0, False: 0]
  |  Branch (2586:28): [True: 0, False: 0]
  ------------------
 2587|      0|                pubidx++;
 2588|      0|            }
 2589|      0|            if (!seckey->has_secret() || !seckey->can_encrypt()) {
  ------------------
  |  Branch (2589:17): [True: 0, False: 0]
  |  Branch (2589:42): [True: 0, False: 0]
  ------------------
 2590|      0|                continue;
 2591|      0|            }
 2592|       |            /* Check whether key is of required algorithm for hidden keyid */
 2593|      0|            if (hidden && seckey->alg() != pubenc.alg) {
  ------------------
  |  Branch (2593:17): [True: 0, False: 0]
  |  Branch (2593:27): [True: 0, False: 0]
  ------------------
 2594|      0|                continue;
 2595|      0|            }
 2596|       |            /* Decrypt key */
 2597|      0|            rnp::KeyLocker seclock(*seckey);
 2598|      0|            if (!seckey->unlock(*handler->password_provider, PGP_OP_DECRYPT)) {
  ------------------
  |  Branch (2598:17): [True: 0, False: 0]
  ------------------
 2599|      0|                errcode = RNP_ERROR_BAD_PASSWORD;
 2600|      0|                continue;
 2601|      0|            }
 2602|       |
 2603|       |            /* Try to initialize the decryption */
 2604|      0|            rnp::LogStop logstop(hidden);
 2605|      0|            pub_decrypt_tried = true;
 2606|      0|            if (encrypted_try_key(param, pubenc, *seckey, handler->ctx->sec_ctx)) {
  ------------------
  |  Branch (2606:17): [True: 0, False: 0]
  ------------------
 2607|      0|                have_key = true;
 2608|       |                /* inform handler that we used this pubenc */
 2609|      0|                if (handler->on_decryption_start) {
  ------------------
  |  Branch (2609:21): [True: 0, False: 0]
  ------------------
 2610|      0|                    handler->on_decryption_start(&pubenc, NULL, handler->param);
 2611|      0|                }
 2612|      0|                break;
 2613|      0|            }
 2614|      0|        }
 2615|     35|    }
 2616|       |
 2617|       |    /* Trying password-based decryption */
 2618|  8.48k|    if (!have_key && !param->symencs.empty()) {
  ------------------
  |  Branch (2618:9): [True: 8.48k, False: 0]
  |  Branch (2618:22): [True: 8.46k, False: 27]
  ------------------
 2619|  8.46k|        rnp::secure_array<char, MAX_PASSWORD_LENGTH> password;
 2620|  8.46k|        pgp_password_ctx_t                           pass_ctx(PGP_OP_DECRYPT_SYM);
 2621|  8.46k|        int                                          attempts = RNP_PASSWORD_MAX_ATTEMPTS;
  ------------------
  |  | 2469|  8.46k|#define RNP_PASSWORD_MAX_ATTEMPTS 3
  ------------------
 2622|       |
 2623|  8.99k|        while (attempts--) {
  ------------------
  |  Branch (2623:16): [True: 8.81k, False: 177]
  ------------------
 2624|  8.81k|            if (!pgp_request_password(
  ------------------
  |  Branch (2624:17): [True: 0, False: 8.81k]
  ------------------
 2625|  8.81k|                  handler->password_provider, &pass_ctx, password.data(), password.size())) {
 2626|      0|                errcode = RNP_ERROR_BAD_PASSWORD;
 2627|      0|                goto finish;
 2628|      0|            }
 2629|       |
 2630|  8.81k|            int intres = encrypted_try_password(param, password.data());
 2631|  8.81k|            if (intres > 0) {
  ------------------
  |  Branch (2631:17): [True: 7.85k, False: 959]
  ------------------
 2632|  7.85k|                have_key = true;
 2633|  7.85k|                break;
 2634|  7.85k|            } else if (intres < 0) {
  ------------------
  |  Branch (2634:24): [True: 428, False: 531]
  ------------------
 2635|    428|                errcode = RNP_ERROR_NOT_SUPPORTED;
 2636|    428|                break;
 2637|    531|            } else {
 2638|    531|                errcode = RNP_ERROR_BAD_PASSWORD;
 2639|    531|            }
 2640|  8.81k|        }
 2641|  8.46k|    }
 2642|       |
 2643|       |    /* report decryption start to the handler */
 2644|  8.48k|    if (handler->on_decryption_info) {
  ------------------
  |  Branch (2644:9): [True: 8.48k, False: 0]
  ------------------
 2645|  8.48k|        handler->on_decryption_info(param->auth_type == rnp::AuthType::MDC,
 2646|  8.48k|                                    param->aead_hdr.aalg,
 2647|  8.48k|                                    param->salg,
 2648|  8.48k|                                    handler->param);
 2649|  8.48k|    }
 2650|       |
 2651|  8.48k|    if (!have_key) {
  ------------------
  |  Branch (2651:9): [True: 632, False: 7.85k]
  ------------------
 2652|    632|        RNP_LOG("failed to obtain decrypting key or password");
  ------------------
  |  |   84|    632|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    632|    do {                                                                                 \
  |  |  |  |   77|    632|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 632, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    632|            break;                                                                       \
  |  |  |  |   79|    632|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2653|    632|        if (pub_decrypt_tried && (errcode == RNP_ERROR_NO_SUITABLE_KEY)) {
  ------------------
  |  Branch (2653:13): [True: 0, False: 632]
  |  Branch (2653:34): [True: 0, False: 0]
  ------------------
 2654|       |            /* A suitable key was found but its session-key decryption failed: report that
 2655|       |             * instead of the misleading "no suitable key" (issue #2465). */
 2656|      0|            errcode = RNP_ERROR_DECRYPT_FAILED;
 2657|      0|        }
 2658|    632|        if (!errcode) {
  ------------------
  |  Branch (2658:13): [True: 6, False: 626]
  ------------------
 2659|      6|            errcode = RNP_ERROR_NO_SUITABLE_KEY;
 2660|      6|        }
 2661|    632|        goto finish;
 2662|    632|    }
 2663|  7.85k|    errcode = RNP_SUCCESS;
 2664|  9.34k|finish:
 2665|  9.34k|    if (errcode != RNP_SUCCESS) {
  ------------------
  |  Branch (2665:9): [True: 1.48k, False: 7.85k]
  ------------------
 2666|  1.48k|        src->close();
 2667|  1.48k|    }
 2668|  9.34k|    return errcode;
 2669|  7.85k|}
_ZN28pgp_source_encrypted_param_tC2Ev:
  121|  9.34k|    pgp_source_encrypted_param_t() : auth_type(rnp::AuthType::None), salg(PGP_SA_UNKNOWN)
  122|  9.34k|    {
  123|  9.34k|    }
stream-parse.cpp:_ZL19encrypted_src_closeP12pgp_source_t:
  983|  9.34k|{
  984|  9.34k|    pgp_source_encrypted_param_t *param = (pgp_source_encrypted_param_t *) src->param;
  985|  9.34k|    if (!param) {
  ------------------
  |  Branch (985:9): [True: 0, False: 9.34k]
  ------------------
  986|      0|        return;
  987|      0|    }
  988|  9.34k|    if (param->pkt.hdr.partial) {
  ------------------
  |  Branch (988:9): [True: 822, False: 8.52k]
  ------------------
  989|    822|        param->pkt.readsrc->close();
  990|    822|        free(param->pkt.readsrc);
  991|    822|        param->pkt.readsrc = NULL;
  992|    822|    }
  993|       |
  994|  9.34k|    if (!param->use_cfb()) {
  ------------------
  |  Branch (994:9): [True: 3.95k, False: 5.38k]
  ------------------
  995|  3.95k|#if defined(ENABLE_AEAD)
  996|  3.95k|        pgp_cipher_aead_destroy(&param->decrypt);
  997|  3.95k|#endif
  998|  5.38k|    } else {
  999|  5.38k|        pgp_cipher_cfb_finish(&param->decrypt);
 1000|  5.38k|    }
 1001|       |
 1002|  9.34k|    delete param;
 1003|       |    src->param = NULL;
 1004|  9.34k|}
stream-parse.cpp:_ZL20encrypted_src_finishP12pgp_source_t:
  938|  3.13k|{
  939|  3.13k|    pgp_source_encrypted_param_t *param = (pgp_source_encrypted_param_t *) src->param;
  940|       |
  941|       |    /* report to the handler that decryption is finished */
  942|  3.13k|    if (param->handler->on_decryption_done) {
  ------------------
  |  Branch (942:9): [True: 3.13k, False: 0]
  ------------------
  943|  3.13k|        bool validated = (param->auth_type != rnp::AuthType::None) && param->auth_validated;
  ------------------
  |  Branch (943:26): [True: 3.13k, False: 0]
  |  Branch (943:71): [True: 3.07k, False: 58]
  ------------------
  944|  3.13k|        param->handler->on_decryption_done(validated, param->handler->param);
  945|  3.13k|    }
  946|       |
  947|  3.13k|#if defined(ENABLE_AEAD)
  948|  3.13k|    if (!param->auth_validated && (param->auth_type == rnp::AuthType::AEADv1
  ------------------
  |  Branch (948:9): [True: 58, False: 3.07k]
  |  Branch (948:36): [True: 3, False: 55]
  ------------------
  949|     55|#if defined(ENABLE_CRYPTO_REFRESH)
  950|     55|                                   || param->auth_type == rnp::AuthType::AEADv2
  ------------------
  |  Branch (950:39): [True: 53, False: 2]
  ------------------
  951|     58|#endif
  952|     58|                                   )) {
  953|       |        /* The message may end with a Padding packet, which ends the
  954|       |         * Optionally Padded Message: no reader then pulls the final AEAD
  955|       |         * chunk and its summary tag, leaving the auth unvalidated even for
  956|       |         * an intact message. Drain the remaining framing here. */
  957|  45.3k|        while (!param->auth_validated) {
  ------------------
  |  Branch (957:16): [True: 45.2k, False: 28]
  ------------------
  958|  45.2k|            if (!encrypted_src_read_aead_part(param)) {
  ------------------
  |  Branch (958:17): [True: 28, False: 45.2k]
  ------------------
  959|     28|                break;
  960|     28|            }
  961|  45.2k|        }
  962|     56|    }
  963|  3.13k|#endif
  964|  3.13k|    if ((param->auth_type == rnp::AuthType::None) || param->auth_validated) {
  ------------------
  |  Branch (964:9): [True: 0, False: 3.13k]
  |  Branch (964:54): [True: 3.10k, False: 30]
  ------------------
  965|  3.10k|        return RNP_SUCCESS;
  966|  3.10k|    }
  967|     30|    switch (param->auth_type) {
  968|      2|    case rnp::AuthType::MDC:
  ------------------
  |  Branch (968:5): [True: 2, False: 28]
  ------------------
  969|      2|        RNP_LOG("mdc was not validated");
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  970|      2|        break;
  971|      0|    case rnp::AuthType::AEADv1:
  ------------------
  |  Branch (971:5): [True: 0, False: 30]
  ------------------
  972|      0|        RNP_LOG("aead last chunk was not validated");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  973|      0|        break;
  974|     28|    default:
  ------------------
  |  Branch (974:5): [True: 28, False: 2]
  ------------------
  975|     28|        RNP_LOG("auth was not validated");
  ------------------
  |  |   84|     28|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     28|    do {                                                                                 \
  |  |  |  |   77|     28|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 28, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     28|            break;                                                                       \
  |  |  |  |   79|     28|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  976|     28|        break;
  977|     30|    }
  978|     30|    return RNP_ERROR_BAD_STATE;
  979|     30|}
stream-parse.cpp:_ZL28encrypted_src_read_aead_partP28pgp_source_encrypted_param_t:
  617|   261k|{
  618|   261k|    param->cachepos = 0;
  619|   261k|    param->cachelen = 0;
  620|       |
  621|       |    /* Hand back the next batch of already-verified plaintext. */
  622|   261k|    if (param->chunk_verified && param->chunk_bufpos < param->chunk_buflen) {
  ------------------
  |  Branch (622:9): [True: 257k, False: 4.14k]
  |  Branch (622:34): [True: 894, False: 256k]
  ------------------
  623|    894|        size_t to_copy = param->chunk_buflen - param->chunk_bufpos;
  624|    894|        if (to_copy > sizeof(param->cache)) {
  ------------------
  |  Branch (624:13): [True: 683, False: 211]
  ------------------
  625|    683|            to_copy = sizeof(param->cache);
  626|    683|        }
  627|    894|        memcpy(param->cache, param->chunk_buf.data() + param->chunk_bufpos, to_copy);
  628|    894|        param->cachelen = to_copy;
  629|    894|        param->chunk_bufpos += to_copy;
  630|    894|        return true;
  631|    894|    }
  632|       |
  633|   260k|    if (param->auth_validated) {
  ------------------
  |  Branch (633:9): [True: 5.09k, False: 255k]
  ------------------
  634|  5.09k|        return true;
  635|  5.09k|    }
  636|       |
  637|       |    /* Previous chunk fully drained: re-arm the accumulator for the next chunk.
  638|       |     * The next chunk is not decrypted until this point, so verified plaintext
  639|       |     * is never overwritten before the reader has consumed it. */
  640|   255k|    if (param->chunk_verified) {
  ------------------
  |  Branch (640:9): [True: 251k, False: 3.80k]
  ------------------
  641|   251k|        param->chunk_verified = false;
  642|   251k|        param->chunk_buflen = 0;
  643|   251k|        param->chunk_bufpos = 0;
  644|   251k|    }
  645|       |
  646|       |    /* Un-decrypted remainder from the previous call is kept at the front of
  647|       |     * cache (the intermediate path compacts it), so no shift is needed here. */
  648|       |
  649|       |    /* it is always 16 for defined EAX and OCB, however this may change in future */
  650|   255k|    size_t taglen = pgp_cipher_aead_tag_len(param->aead_hdr.aalg);
  651|       |
  652|       |    /* Withheld plaintext must not surface as a zero-length read: the caller
  653|       |     * (src_read_aead) treats a successful part-read with cachelen == 0 as end
  654|       |     * of data. Keep consuming input until a whole chunk is verified and can
  655|       |     * be released (or the stream ends). */
  656|   257k|    for (;;) {
  657|   257k|        size_t read = sizeof(param->cache) - 2 * PGP_AEAD_MAX_TAG_LEN - param->rawbytes;
  ------------------
  |  |   86|   257k|#define PGP_AEAD_MAX_TAG_LEN 16
  ------------------
  658|   257k|        bool   chunkend = false;
  659|       |
  660|   257k|        if (read >= param->chunklen - param->chunkin) {
  ------------------
  |  Branch (660:13): [True: 253k, False: 3.47k]
  ------------------
  661|       |            /* param->rawbytes is smaller then param->chunklen - param->chunkin due to the
  662|       |             * previous call */
  663|   253k|            read = param->chunklen - param->chunkin - param->rawbytes;
  664|   253k|            chunkend = true;
  665|   253k|        } else {
  666|  3.47k|            read =
  667|  3.47k|              read - (read + param->rawbytes) % pgp_cipher_aead_granularity(&param->decrypt);
  668|  3.47k|        }
  669|       |
  670|   257k|        if (!param->pkt.readsrc->read(param->cache + param->rawbytes, read, &read)) {
  ------------------
  |  Branch (670:13): [True: 68, False: 257k]
  ------------------
  671|     68|            return false;
  672|     68|        }
  673|       |
  674|       |        /* checking whether we have enough input for the final tags */
  675|   257k|        size_t tagread = 0;
  676|   257k|        if (!param->pkt.readsrc->peek(
  ------------------
  |  Branch (676:13): [True: 12, False: 257k]
  ------------------
  677|   257k|              param->cache + param->rawbytes + read, taglen * 2, &tagread)) {
  678|     12|            return false;
  679|     12|        }
  680|       |
  681|   257k|        bool   lastchunk = false;
  682|   257k|        size_t avail = param->rawbytes + read + tagread;
  683|   257k|        if (tagread < taglen * 2) {
  ------------------
  |  Branch (683:13): [True: 3.56k, False: 253k]
  ------------------
  684|       |            /* this would mean the end of the stream */
  685|  3.56k|            if ((param->chunkin == 0) && (avail == taglen)) {
  ------------------
  |  Branch (685:17): [True: 3.39k, False: 172]
  |  Branch (685:42): [True: 538, False: 2.85k]
  ------------------
  686|       |                /* we have empty chunk and final tag */
  687|    538|                chunkend = false;
  688|    538|                lastchunk = true;
  689|  3.03k|            } else if (avail >= 2 * taglen) {
  ------------------
  |  Branch (689:24): [True: 3.02k, False: 7]
  ------------------
  690|       |                /* we have end of chunk and final tag */
  691|  3.02k|                chunkend = true;
  692|  3.02k|                lastchunk = true;
  693|  3.02k|            } else {
  694|      7|                RNP_LOG("unexpected end of data");
  ------------------
  |  |   84|      7|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      7|    do {                                                                                 \
  |  |  |  |   77|      7|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      7|            break;                                                                       \
  |  |  |  |   79|      7|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  695|      7|                return false;
  696|      7|            }
  697|   253k|        } else if (chunkend && (tagread == taglen * 2)) {
  ------------------
  |  Branch (697:20): [True: 251k, False: 1.85k]
  |  Branch (697:32): [True: 251k, False: 0]
  ------------------
  698|       |            /* A chunk boundary with exactly two tags ahead is ambiguous: it
  699|       |             * may be the end of the stream - the plaintext can end exactly at
  700|       |             * the chunk boundary, e.g. when a Padding packet fills the length
  701|       |             * bucket - or a following chunk with exactly taglen bytes of data
  702|       |             * peeked. Probe one byte beyond the tags: the stream end has
  703|       |             * nothing there, a following chunk always has data. Without this
  704|       |             * the final chunk would be treated as non-final and the summary
  705|       |             * tag validation left to a reader which stops at the Padding
  706|       |             * packet. */
  707|   251k|            uint8_t probeb = 0;
  708|   251k|            size_t  more = 0;
  709|   251k|            if (!param->pkt.readsrc->peek(&probeb, 1, &more)) {
  ------------------
  |  Branch (709:17): [True: 0, False: 251k]
  ------------------
  710|      0|                return false;
  711|      0|            }
  712|   251k|            lastchunk = (more == 0);
  713|   251k|        }
  714|       |
  715|   257k|        if (!chunkend && !lastchunk) {
  ------------------
  |  Branch (715:13): [True: 2.39k, False: 254k]
  |  Branch (715:26): [True: 1.85k, False: 538]
  ------------------
  716|  1.85k|            size_t used = 0;
  717|  1.85k|            bool   res = pgp_cipher_aead_update(
  718|  1.85k|              param->decrypt, param->cache, param->cache, param->rawbytes + read, used);
  719|       |
  720|  1.85k|            param->chunkin += used;
  721|  1.85k|            if (res) {
  ------------------
  |  Branch (721:17): [True: 1.85k, False: 0]
  ------------------
  722|       |                /* Withhold plaintext until the chunk tag is verified: accumulate
  723|       |                 * it in chunk_buf instead of exposing it via cachelen. */
  724|  1.85k|                encrypted_chunk_buf_append(param, param->cache, used);
  725|  1.85k|                param->rawbytes = param->rawbytes + read - used;
  726|       |                /* Compact the un-decrypted remainder to the front of cache. */
  727|  1.85k|                if (used > 0 && param->rawbytes > 0) {
  ------------------
  |  Branch (727:21): [True: 1.85k, False: 0]
  |  Branch (727:33): [True: 0, False: 1.85k]
  ------------------
  728|      0|                    memmove(param->cache, param->cache + used, param->rawbytes);
  729|      0|                }
  730|  1.85k|            }
  731|  1.85k|            if (!res) {
  ------------------
  |  Branch (731:17): [True: 0, False: 1.85k]
  ------------------
  732|      0|                return false;
  733|      0|            }
  734|       |            /* Plaintext withheld until the chunk completes: read more input. */
  735|  1.85k|            continue;
  736|  1.85k|        }
  737|       |
  738|       |        /* Processing end of chunk */
  739|   255k|        if (chunkend) {
  ------------------
  |  Branch (739:13): [True: 254k, False: 538]
  ------------------
  740|   254k|            if (tagread > taglen) {
  ------------------
  |  Branch (740:17): [True: 251k, False: 2.94k]
  ------------------
  741|   251k|                param->pkt.readsrc->skip(tagread - taglen);
  742|   251k|            }
  743|       |
  744|   254k|            size_t finlen = param->rawbytes + read + tagread - taglen;
  745|   254k|            if (!pgp_cipher_aead_finish(&param->decrypt, param->cache, param->cache, finlen)) {
  ------------------
  |  Branch (745:17): [True: 422, False: 254k]
  ------------------
  746|    422|                RNP_LOG("failed to finalize aead chunk");
  ------------------
  |  |   84|    422|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    422|    do {                                                                                 \
  |  |  |  |   77|    422|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 422, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    422|            break;                                                                       \
  |  |  |  |   79|    422|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  747|       |                /* Zero unverified plaintext — tag verification failed. */
  748|    422|                if (!param->chunk_buf.empty() && param->chunk_buflen > 0) {
  ------------------
  |  Branch (748:21): [True: 86, False: 336]
  |  Branch (748:50): [True: 86, False: 0]
  ------------------
  749|     86|                    secure_clear(param->chunk_buf.data(), param->chunk_buflen);
  750|     86|                }
  751|    422|                param->chunk_buflen = 0;
  752|    422|                param->chunk_verified = false;
  753|    422|                return false;
  754|    422|            }
  755|       |            /* Chunk tag verified: the whole chunk's plaintext is authenticated.
  756|       |             * Append the final piece (now in cache[0..final_used]) to whatever the
  757|       |             * intermediate reads accumulated. Do NOT copy chunk_buf back into cache
  758|       |             * here: the last-chunk finish() below still needs the summary tag that
  759|       |             * sits right after this piece in cache. */
  760|   254k|            size_t final_used = finlen - taglen;
  761|   254k|            param->chunkin += final_used;
  762|   254k|            encrypted_chunk_buf_append(param, param->cache, final_used);
  763|   254k|            param->rawbytes = 0;
  764|   254k|            param->chunk_verified = true;
  765|   254k|            param->chunk_bufpos = 0;
  766|   254k|        }
  767|       |
  768|       |        /* Starting a new chunk (cipher only; its plaintext is held back until the
  769|       |         * reader drains the current chunk_buf). */
  770|   254k|        size_t chunkidx = param->chunkidx;
  771|   254k|        if (chunkend && param->chunkin) {
  ------------------
  |  Branch (771:13): [True: 254k, False: 538]
  |  Branch (771:25): [True: 254k, False: 0]
  ------------------
  772|   254k|            chunkidx++;
  773|   254k|        }
  774|       |
  775|   254k|        if (!encrypted_start_aead_chunk(param, chunkidx, lastchunk)) {
  ------------------
  |  Branch (775:13): [True: 0, False: 254k]
  ------------------
  776|      0|            RNP_LOG("failed to start aead chunk");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  777|      0|            return false;
  778|      0|        }
  779|       |
  780|   254k|        if (lastchunk) {
  ------------------
  |  Branch (780:13): [True: 3.18k, False: 251k]
  ------------------
  781|       |            /* Verify the summary tag. It sits at offset (avail - taglen) in cache
  782|       |             * in both the chunkend and empty-final-chunk cases, because the chunk
  783|       |             * finish() above left the peeked tag region untouched. */
  784|  3.18k|            if (tagread > 0) {
  ------------------
  |  Branch (784:17): [True: 165, False: 3.01k]
  ------------------
  785|    165|                param->pkt.readsrc->skip(tagread);
  786|    165|            }
  787|  3.18k|            size_t off = avail - taglen;
  788|  3.18k|            if (!pgp_cipher_aead_finish(
  ------------------
  |  Branch (788:17): [True: 9, False: 3.17k]
  ------------------
  789|  3.18k|                  &param->decrypt, param->cache + off, param->cache + off, taglen)) {
  790|      9|                RNP_LOG("wrong last chunk");
  ------------------
  |  |   84|      9|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      9|    do {                                                                                 \
  |  |  |  |   77|      9|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      9|            break;                                                                       \
  |  |  |  |   79|      9|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  791|      9|                if (!param->chunk_buf.empty() && param->chunk_buflen > 0) {
  ------------------
  |  Branch (791:21): [True: 0, False: 9]
  |  Branch (791:50): [True: 0, False: 0]
  ------------------
  792|      0|                    secure_clear(param->chunk_buf.data(), param->chunk_buflen);
  793|      0|                }
  794|      9|                param->chunk_buflen = 0;
  795|      9|                param->chunk_verified = false;
  796|      9|                return false;
  797|      9|            }
  798|  3.17k|            param->auth_validated = true;
  799|  3.17k|        }
  800|       |
  801|   254k|        break;
  802|   254k|    } /* for (;;) */
  803|       |
  804|       |    /* Release the first batch of verified plaintext. Subsequent calls drain the
  805|       |     * rest from chunk_buf before any new chunk is decrypted. */
  806|   254k|    if (param->chunk_verified && param->chunk_buflen > 0) {
  ------------------
  |  Branch (806:9): [True: 254k, False: 529]
  |  Branch (806:34): [True: 254k, False: 0]
  ------------------
  807|   254k|        size_t to_copy = param->chunk_buflen;
  808|   254k|        if (to_copy > sizeof(param->cache)) {
  ------------------
  |  Branch (808:13): [True: 235, False: 254k]
  ------------------
  809|    235|            to_copy = sizeof(param->cache);
  810|    235|        }
  811|   254k|        memcpy(param->cache, param->chunk_buf.data(), to_copy);
  812|   254k|        param->cachelen = to_copy;
  813|   254k|        param->chunk_bufpos = to_copy;
  814|   254k|    }
  815|   254k|    param->rawbytes = 0;
  816|   254k|    return true;
  817|   255k|}
stream-parse.cpp:_ZL26encrypted_chunk_buf_appendP28pgp_source_encrypted_param_tPKhm:
  596|   256k|{
  597|   256k|    if (!len) {
  ------------------
  |  Branch (597:9): [True: 38, False: 256k]
  ------------------
  598|     38|        return;
  599|     38|    }
  600|   256k|    size_t need = param->chunk_buflen + len;
  601|   256k|    if (param->chunk_buf.size() < need) {
  ------------------
  |  Branch (601:9): [True: 4.84k, False: 251k]
  ------------------
  602|       |        /* double the buffer, but do not go beyond the chunk size */
  603|  4.84k|        size_t alloc = 2 * param->chunk_buf.size();
  604|  4.84k|        if (alloc > param->chunklen) {
  ------------------
  |  Branch (604:13): [True: 230, False: 4.61k]
  ------------------
  605|    230|            alloc = param->chunklen;
  606|    230|        }
  607|  4.84k|        param->chunk_buf.reserve(alloc > need ? alloc : need);
  ------------------
  |  Branch (607:34): [True: 1.17k, False: 3.67k]
  ------------------
  608|  4.84k|        param->chunk_buf.resize(need);
  609|  4.84k|    }
  610|   256k|    memcpy(param->chunk_buf.data() + param->chunk_buflen, data, len);
  611|   256k|    param->chunk_buflen += len;
  612|   256k|}
stream-parse.cpp:_ZL26encrypted_start_aead_chunkP28pgp_source_encrypted_param_tmb:
  517|   258k|{
  518|   258k|    size_t default_ad_len = param->aead_adlen;
  519|       |
  520|   258k|    if (last) {
  ------------------
  |  Branch (520:9): [True: 3.18k, False: 255k]
  ------------------
  521|  3.18k|        uint64_t total = idx * param->chunklen;
  522|  3.18k|        if (idx && param->chunkin) {
  ------------------
  |  Branch (522:13): [True: 3.17k, False: 9]
  |  Branch (522:20): [True: 2.64k, False: 529]
  ------------------
  523|  2.64k|            total -= param->chunklen - param->chunkin;
  524|  2.64k|        }
  525|       |
  526|  3.18k|        if (!param->chunkin) {
  ------------------
  |  Branch (526:13): [True: 538, False: 2.64k]
  ------------------
  527|       |            /* reset the crypto in case we had empty chunk before the last one */
  528|    538|            pgp_cipher_aead_reset(&param->decrypt);
  529|    538|        }
  530|  3.18k|        write_uint64(param->aead_ad + param->aead_adlen, total);
  531|  3.18k|        param->aead_adlen += 8;
  532|  3.18k|    }
  533|       |
  534|   258k|    switch (param->auth_type) {
  ------------------
  |  Branch (534:13): [True: 258k, False: 0]
  ------------------
  535|      0|    case rnp::AuthType::MDC:
  ------------------
  |  Branch (535:5): [True: 0, False: 258k]
  ------------------
  536|      0|        break; // cannot happen
  537|      0|    case rnp::AuthType::None:
  ------------------
  |  Branch (537:5): [True: 0, False: 258k]
  ------------------
  538|      0|        break; // cannot happen
  539|  85.8k|    case rnp::AuthType::AEADv1:
  ------------------
  |  Branch (539:5): [True: 85.8k, False: 172k]
  ------------------
  540|       |        /* set chunk index for additional data */
  541|  85.8k|        write_uint64(param->aead_ad + default_ad_len - 8, idx);
  542|       |
  543|  85.8k|        if (!pgp_cipher_aead_set_ad(&param->decrypt, param->aead_ad, param->aead_adlen)) {
  ------------------
  |  Branch (543:13): [True: 0, False: 85.8k]
  ------------------
  544|      0|            RNP_LOG("failed to set ad");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  545|      0|            return false;
  546|      0|        }
  547|  85.8k|        break;
  548|       |
  549|  85.8k|#ifdef ENABLE_CRYPTO_REFRESH
  550|   172k|    case rnp::AuthType::AEADv2:
  ------------------
  |  Branch (550:5): [True: 172k, False: 85.8k]
  ------------------
  551|       |        /* set chunk index for additional data */
  552|   172k|        write_uint64(param->aead_ad + default_ad_len - 8, idx);
  553|   172k|        std::vector<uint8_t> add_data_seipd_v2 = {
  554|   172k|          static_cast<uint8_t>(PGP_PKT_SE_IP_DATA | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT),
  ------------------
  |  |   47|   172k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                        static_cast<uint8_t>(PGP_PKT_SE_IP_DATA | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT),
  ------------------
  |  |   56|   172k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  555|   172k|          static_cast<uint8_t>(param->seipdv2_hdr.version),
  556|   172k|          static_cast<uint8_t>(param->seipdv2_hdr.cipher_alg),
  557|   172k|          static_cast<uint8_t>(param->seipdv2_hdr.aead_alg),
  558|   172k|          param->seipdv2_hdr.chunk_size_octet};
  559|       |
  560|   172k|        if (param->is_v2_seipd()) {
  ------------------
  |  Branch (560:13): [True: 172k, False: 0]
  ------------------
  561|   172k|            if (last) {
  ------------------
  |  Branch (561:17): [True: 1.19k, False: 171k]
  ------------------
  562|  1.19k|                std::copy(&param->aead_ad[5],
  563|  1.19k|                          &param->aead_ad[5 + 8],
  564|  1.19k|                          std::back_inserter(add_data_seipd_v2));
  565|  1.19k|            }
  566|   172k|            if (!pgp_cipher_aead_set_ad(
  ------------------
  |  Branch (566:17): [True: 0, False: 172k]
  ------------------
  567|   172k|                  &param->decrypt, add_data_seipd_v2.data(), add_data_seipd_v2.size())) {
  568|      0|                RNP_LOG("failed to set ad");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  569|      0|                return false;
  570|      0|            }
  571|   172k|        }
  572|   172k|        break;
  573|       |
  574|   258k|#endif
  575|   258k|    }
  576|       |
  577|       |    /* setup chunk */
  578|   258k|    param->chunkidx = idx;
  579|   258k|    param->chunkin = 0;
  580|       |
  581|       |    /* set chunk index for nonce */
  582|   258k|    uint8_t nonce[PGP_AEAD_MAX_NONCE_LEN];
  583|   258k|    size_t  nlen = pgp_cipher_aead_nonce(param->aead_hdr.aalg, param->aead_hdr.iv, nonce, idx);
  584|       |
  585|       |    /* start cipher */
  586|   258k|    return pgp_cipher_aead_start(&param->decrypt, nonce, nlen);
  587|   258k|}
stream-parse.cpp:_ZL26encrypted_read_packet_dataP28pgp_source_encrypted_param_t:
 2274|  9.34k|{
 2275|  9.34k|    int ptype;
 2276|       |    /* Reading pk/sk encrypted session key(s) */
 2277|  9.34k|    try {
 2278|  9.34k|        size_t errors = 0;
 2279|  9.34k|        bool   stop = false;
 2280|  91.8k|        while (!stop) {
  ------------------
  |  Branch (2280:16): [True: 83.1k, False: 8.76k]
  ------------------
 2281|  83.1k|            if (param->pubencs.size() + param->symencs.size() + errors > MAX_RECIPIENTS) {
  ------------------
  |  | 2270|  83.1k|#define MAX_RECIPIENTS 16384
  ------------------
  |  Branch (2281:17): [True: 1, False: 83.1k]
  ------------------
 2282|      1|                RNP_LOG("Too many recipients of the encrypted message. Aborting.");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2283|      1|                return RNP_ERROR_BAD_STATE;
 2284|      1|            }
 2285|  83.1k|            uint8_t ptag;
 2286|  83.1k|            if (!param->pkt.readsrc->peek_eq(&ptag, 1)) {
  ------------------
  |  Branch (2286:17): [True: 48, False: 83.0k]
  ------------------
 2287|     48|                RNP_LOG("failed to read packet header");
  ------------------
  |  |   84|     48|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     48|    do {                                                                                 \
  |  |  |  |   77|     48|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 48, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     48|            break;                                                                       \
  |  |  |  |   79|     48|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2288|     48|                return RNP_ERROR_READ;
 2289|     48|            }
 2290|  83.0k|            ptype = get_packet_type(ptag);
 2291|  83.0k|            switch (ptype) {
 2292|  69.5k|            case PGP_PKT_SK_SESSION_KEY: {
  ------------------
  |  Branch (2292:13): [True: 69.5k, False: 13.5k]
  ------------------
 2293|  69.5k|                pgp_sk_sesskey_t skey;
 2294|  69.5k|                rnp_result_t     ret = skey.parse(*param->pkt.readsrc);
 2295|  69.5k|                if (ret == RNP_ERROR_READ) {
  ------------------
  |  Branch (2295:21): [True: 60, False: 69.4k]
  ------------------
 2296|     60|                    RNP_LOG("SKESK: Premature end of data.");
  ------------------
  |  |   84|     60|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     60|    do {                                                                                 \
  |  |  |  |   77|     60|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 60, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     60|            break;                                                                       \
  |  |  |  |   79|     60|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2297|     60|                    return ret;
 2298|     60|                }
 2299|  69.4k|                if (ret) {
  ------------------
  |  Branch (2299:21): [True: 57.5k, False: 11.9k]
  ------------------
 2300|  57.5k|                    RNP_LOG("Failed to parse SKESK, skipping.");
  ------------------
  |  |   84|  57.5k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  57.5k|    do {                                                                                 \
  |  |  |  |   77|  57.5k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 57.5k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  57.5k|            break;                                                                       \
  |  |  |  |   79|  57.5k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2301|  57.5k|                    errors++;
 2302|  57.5k|                    continue;
 2303|  57.5k|                }
 2304|  11.9k|                param->symencs.push_back(std::move(skey));
 2305|  11.9k|                break;
 2306|  69.4k|            }
 2307|  4.36k|            case PGP_PKT_PK_SESSION_KEY: {
  ------------------
  |  Branch (2307:13): [True: 4.36k, False: 78.7k]
  ------------------
 2308|  4.36k|                pgp_pk_sesskey_t pkey;
 2309|  4.36k|                rnp_result_t     ret = pkey.parse(*param->pkt.readsrc);
 2310|  4.36k|                if (ret == RNP_ERROR_READ) {
  ------------------
  |  Branch (2310:21): [True: 72, False: 4.29k]
  ------------------
 2311|     72|                    RNP_LOG("PKESK: Premature end of data.");
  ------------------
  |  |   84|     72|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     72|    do {                                                                                 \
  |  |  |  |   77|     72|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 72, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     72|            break;                                                                       \
  |  |  |  |   79|     72|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2312|     72|                    return ret;
 2313|     72|                }
 2314|  4.29k|                if (ret) {
  ------------------
  |  Branch (2314:21): [True: 4.17k, False: 113]
  ------------------
 2315|  4.17k|                    RNP_LOG("Failed to parse PKESK, skipping.");
  ------------------
  |  |   84|  4.17k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  4.17k|    do {                                                                                 \
  |  |  |  |   77|  4.17k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4.17k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  4.17k|            break;                                                                       \
  |  |  |  |   79|  4.17k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2316|  4.17k|                    errors++;
 2317|  4.17k|                    continue;
 2318|  4.17k|                }
 2319|    113|                param->pubencs.push_back(std::move(pkey));
 2320|    113|                break;
 2321|  4.29k|            }
 2322|      4|            case PGP_PKT_SE_DATA:
  ------------------
  |  Branch (2322:13): [True: 4, False: 83.0k]
  ------------------
 2323|  6.14k|            case PGP_PKT_SE_IP_DATA:
  ------------------
  |  Branch (2323:13): [True: 6.13k, False: 76.9k]
  ------------------
 2324|  8.76k|            case PGP_PKT_AEAD_ENCRYPTED:
  ------------------
  |  Branch (2324:13): [True: 2.62k, False: 80.4k]
  ------------------
 2325|  8.76k|                stop = true;
 2326|  8.76k|                break;
 2327|    450|            default:
  ------------------
  |  Branch (2327:13): [True: 450, False: 82.6k]
  ------------------
 2328|       |                /* RFC 9580, 4.3: unknown non-critical packets (type IDs 40-63) and
 2329|       |                 * padding packets (5.14) are ignored */
 2330|    450|                if (((ptype >= 40) && (ptype <= 63)) || (ptype == PGP_PKT_PADDING)) {
  ------------------
  |  Branch (2330:22): [True: 61, False: 389]
  |  Branch (2330:39): [True: 61, False: 0]
  |  Branch (2330:57): [True: 15, False: 374]
  ------------------
 2331|     76|                    RNP_LOG("Skipping non-critical packet %d", ptype);
  ------------------
  |  |   84|     76|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     76|    do {                                                                                 \
  |  |  |  |   77|     76|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 76, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     76|            break;                                                                       \
  |  |  |  |   79|     76|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2332|     76|                    if (stream_skip_packet(param->pkt.readsrc)) {
  ------------------
  |  Branch (2332:25): [True: 26, False: 50]
  ------------------
 2333|     26|                        RNP_LOG("failed to skip packet");
  ------------------
  |  |   84|     26|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     26|    do {                                                                                 \
  |  |  |  |   77|     26|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 26, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     26|            break;                                                                       \
  |  |  |  |   79|     26|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2334|     26|                        return RNP_ERROR_READ;
 2335|     26|                    }
 2336|     50|                    continue;
 2337|     76|                }
 2338|    374|                RNP_LOG("unknown packet type: %d", ptype);
  ------------------
  |  |   84|    374|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    374|    do {                                                                                 \
  |  |  |  |   77|    374|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 374, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    374|            break;                                                                       \
  |  |  |  |   79|    374|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2339|    374|                return RNP_ERROR_BAD_FORMAT;
 2340|  83.0k|            }
 2341|  83.0k|        }
 2342|  9.34k|    } catch (const rnp::rnp_exception &e) {
 2343|       |        /* LCOV_EXCL_START */
 2344|      0|        RNP_LOG("%s: %d", e.what(), e.code());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2345|      0|        return e.code();
 2346|       |        /* LCOV_EXCL_END */
 2347|      0|    } catch (const std::exception &e) {
 2348|       |        /* LCOV_EXCL_START */
 2349|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2350|      0|        return RNP_ERROR_GENERIC;
 2351|       |        /* LCOV_EXCL_END */
 2352|      0|    }
 2353|       |
 2354|       |    /* Reading packet length/checking whether it is partial */
 2355|  8.76k|    rnp_result_t errcode = init_packet_params(param->pkt);
 2356|  8.76k|    if (errcode) {
  ------------------
  |  Branch (2356:9): [True: 227, False: 8.53k]
  ------------------
 2357|    227|        return errcode;
 2358|    227|    }
 2359|       |
 2360|       |    /* Reading header of encrypted packet */
 2361|  8.53k|    if (ptype == PGP_PKT_AEAD_ENCRYPTED) {
  ------------------
  |  Branch (2361:9): [True: 2.60k, False: 5.92k]
  ------------------
 2362|  2.60k|        param->auth_type = rnp::AuthType::AEADv1;
 2363|  2.60k|        uint8_t hdr[4];
 2364|  2.60k|        if (!param->pkt.readsrc->peek_eq(hdr, 4)) {
  ------------------
  |  Branch (2364:13): [True: 2, False: 2.60k]
  ------------------
 2365|      2|            return RNP_ERROR_READ;
 2366|      2|        }
 2367|       |
 2368|  2.60k|        if (!get_aead_src_hdr(param->pkt.readsrc, &param->aead_hdr)) {
  ------------------
  |  Branch (2368:13): [True: 9, False: 2.59k]
  ------------------
 2369|      9|            RNP_LOG("failed to read AEAD header");
  ------------------
  |  |   84|      9|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      9|    do {                                                                                 \
  |  |  |  |   77|      9|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 9, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      9|            break;                                                                       \
  |  |  |  |   79|      9|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2370|      9|            return RNP_ERROR_READ;
 2371|      9|        }
 2372|       |
 2373|       |        /* check AEAD encrypted data packet header */
 2374|  2.59k|        if (!is_valid_seipd_version(param->aead_hdr.version)) {
  ------------------
  |  Branch (2374:13): [True: 2, False: 2.59k]
  ------------------
 2375|      2|            RNP_LOG("unknown aead ver: %d", param->aead_hdr.version);
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2376|      2|            return RNP_ERROR_BAD_FORMAT;
 2377|      2|        }
 2378|  2.59k|        if ((param->aead_hdr.aalg != PGP_AEAD_EAX) && (param->aead_hdr.aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (2378:13): [True: 1.93k, False: 664]
  |  Branch (2378:55): [True: 655, False: 1.27k]
  ------------------
 2379|    655|#if defined(ENABLE_AEAD_GCM)
 2380|    655|            && (param->aead_hdr.aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (2380:16): [True: 0, False: 655]
  ------------------
 2381|  2.59k|#endif
 2382|  2.59k|        ) {
 2383|      0|            RNP_LOG("unknown aead alg: %d", (int) param->aead_hdr.aalg);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2384|      0|            return RNP_ERROR_BAD_FORMAT;
 2385|      0|        }
 2386|       |
 2387|       |        /* parse chunk size */
 2388|  2.59k|        if (!parse_aead_chunk_size(param->aead_hdr.csize, param->chunklen)) {
  ------------------
  |  Branch (2388:13): [True: 1, False: 2.59k]
  ------------------
 2389|      1|            return RNP_ERROR_BAD_FORMAT;
 2390|      1|        }
 2391|       |
 2392|       |        /* build additional data */
 2393|  2.59k|        param->aead_adlen = 13;
 2394|  2.59k|        param->aead_ad[0] = param->pkt.hdr.hdr[0];
 2395|  2.59k|        memcpy(param->aead_ad + 1, hdr, 4);
 2396|  2.59k|        memset(param->aead_ad + 5, 0, 8);
 2397|  5.92k|    } else if (ptype == PGP_PKT_SE_IP_DATA) {
  ------------------
  |  Branch (2397:16): [True: 5.92k, False: 4]
  ------------------
 2398|  5.92k|        uint8_t SEIPD_version;
 2399|  5.92k|        if (!param->pkt.readsrc->read_eq(&SEIPD_version, 1)) {
  ------------------
  |  Branch (2399:13): [True: 15, False: 5.90k]
  ------------------
 2400|     15|            return RNP_ERROR_READ;
 2401|     15|        }
 2402|       |
 2403|  5.90k|        if (SEIPD_version == PGP_SE_IP_DATA_V1) {
  ------------------
  |  Branch (2403:13): [True: 4.55k, False: 1.35k]
  ------------------
 2404|  4.55k|            param->auth_type = rnp::AuthType::MDC;
 2405|  4.55k|            param->auth_validated = false;
 2406|  4.55k|        }
 2407|  1.35k|#ifdef ENABLE_CRYPTO_REFRESH
 2408|  1.35k|        else if (SEIPD_version == PGP_SE_IP_DATA_V2) {
  ------------------
  |  Branch (2408:18): [True: 1.35k, False: 5]
  ------------------
 2409|  1.35k|            for (auto symenc : param->symencs) {
  ------------------
  |  Branch (2409:30): [True: 1.35k, False: 1.34k]
  ------------------
 2410|       |                // consistency check if SEIPDv2 is only coupled with SKESKv6
 2411|  1.35k|                if (symenc.version != PGP_SKSK_V6) {
  ------------------
  |  Branch (2411:21): [True: 5, False: 1.35k]
  ------------------
 2412|      5|                    RNP_LOG("SEIPDv2 not usable with SKESK version");
  ------------------
  |  |   84|      5|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      5|    do {                                                                                 \
  |  |  |  |   77|      5|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      5|            break;                                                                       \
  |  |  |  |   79|      5|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2413|      5|                    return RNP_ERROR_BAD_FORMAT;
 2414|      5|                }
 2415|  1.35k|            }
 2416|       |
 2417|  1.34k|            param->auth_type = rnp::AuthType::AEADv2;
 2418|  1.34k|            param->seipdv2_hdr.version = PGP_SE_IP_DATA_V2;
 2419|  1.34k|            uint8_t hdr[4];
 2420|  1.34k|            if (!param->pkt.readsrc->peek_eq(hdr, 4)) {
  ------------------
  |  Branch (2420:17): [True: 1, False: 1.34k]
  ------------------
 2421|      1|                return RNP_ERROR_READ;
 2422|      1|            }
 2423|       |
 2424|  1.34k|            if (!get_seipdv2_src_hdr(param->pkt.readsrc, &param->seipdv2_hdr)) {
  ------------------
  |  Branch (2424:17): [True: 1, False: 1.34k]
  ------------------
 2425|      1|                RNP_LOG("failed to read SEIPDv2 header");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2426|      1|                return RNP_ERROR_READ;
 2427|      1|            }
 2428|       |
 2429|       |            /* check SEIPDv2 packet header */
 2430|  1.34k|            if ((param->seipdv2_hdr.aead_alg != PGP_AEAD_EAX) &&
  ------------------
  |  Branch (2430:17): [True: 791, False: 555]
  ------------------
 2431|    791|                (param->seipdv2_hdr.aead_alg != PGP_AEAD_OCB)
  ------------------
  |  Branch (2431:17): [True: 134, False: 657]
  ------------------
 2432|    134|#if defined(ENABLE_AEAD_GCM)
 2433|    134|                && (param->seipdv2_hdr.aead_alg != PGP_AEAD_GCM)
  ------------------
  |  Branch (2433:20): [True: 2, False: 132]
  ------------------
 2434|  1.34k|#endif
 2435|  1.34k|            ) {
 2436|      2|                RNP_LOG("unknown AEAD alg: %d", (int) param->seipdv2_hdr.aead_alg);
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2437|      2|                return RNP_ERROR_BAD_FORMAT;
 2438|      2|            }
 2439|       |
 2440|       |            /* parse chunk size */
 2441|  1.34k|            if (!parse_aead_chunk_size(param->seipdv2_hdr.chunk_size_octet, param->chunklen)) {
  ------------------
  |  Branch (2441:17): [True: 1, False: 1.34k]
  ------------------
 2442|      1|                return RNP_ERROR_BAD_FORMAT;
 2443|      1|            }
 2444|       |
 2445|       |            /* build additional data */
 2446|  1.34k|            param->aead_adlen = 5;
 2447|  1.34k|            param->aead_ad[0] = param->pkt.hdr.hdr[0];
 2448|  1.34k|            memcpy(param->aead_ad + 1, hdr, 4);
 2449|       |
 2450|  1.34k|            param->aead_hdr.aalg = param->seipdv2_hdr.aead_alg;
 2451|  1.34k|            param->aead_hdr.csize = param->seipdv2_hdr.chunk_size_octet; // needed?
 2452|  1.34k|            param->aead_hdr.ealg = param->seipdv2_hdr.cipher_alg;
 2453|  1.34k|        }
 2454|      5|#endif
 2455|      5|        else {
 2456|      5|            RNP_LOG("unknown SEIPD version: %d", (int) SEIPD_version);
  ------------------
  |  |   84|      5|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      5|    do {                                                                                 \
  |  |  |  |   77|      5|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 5, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      5|            break;                                                                       \
  |  |  |  |   79|      5|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2457|      5|            return RNP_ERROR_BAD_FORMAT;
 2458|      5|        }
 2459|  5.90k|    }
 2460|  8.49k|    param->auth_validated = false;
 2461|       |
 2462|  8.49k|    return RNP_SUCCESS;
 2463|  8.53k|}
stream-parse.cpp:_ZN12_GLOBAL__N_122is_valid_seipd_versionEh:
  206|  2.59k|{
  207|  2.59k|    if (version == 1
  ------------------
  |  Branch (207:9): [True: 2.55k, False: 46]
  ------------------
  208|     46|#ifdef ENABLE_CRYPTO_REFRESH
  209|     46|        || version == 2
  ------------------
  |  Branch (209:12): [True: 44, False: 2]
  ------------------
  210|  2.59k|#endif
  211|  2.59k|    ) {
  212|  2.59k|        return true;
  213|  2.59k|    }
  214|      2|    return false;
  215|  2.59k|}
stream-parse.cpp:_ZL21parse_aead_chunk_sizehRm:
 2216|  3.93k|{
 2217|       |    /* the chunk size must fit size_t: up to 2^62 bytes, or 2^31 with a 32-bit size_t */
 2218|  3.93k|    if ((chunk_size_octet > 56) || (chunk_size_octet + 6 >= sizeof(size_t) * 8)) {
  ------------------
  |  Branch (2218:9): [True: 2, False: 3.93k]
  |  Branch (2218:36): [True: 0, False: 3.93k]
  ------------------
 2219|      2|        RNP_LOG("too large chunk size: %d", chunk_size_octet);
  ------------------
  |  |   84|      2|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      2|    do {                                                                                 \
  |  |  |  |   77|      2|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 2, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      2|            break;                                                                       \
  |  |  |  |   79|      2|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2220|      2|        return false;
 2221|      2|    }
 2222|  3.93k|    if (chunk_size_octet > 16) {
  ------------------
  |  Branch (2222:9): [True: 331, False: 3.60k]
  ------------------
 2223|    331|        RNP_LOG("Warning: AEAD chunk bits > 16.");
  ------------------
  |  |   84|    331|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    331|    do {                                                                                 \
  |  |  |  |   77|    331|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 331, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    331|            break;                                                                       \
  |  |  |  |   79|    331|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2224|    331|    }
 2225|  3.93k|    chunk_size = (size_t) 1 << (chunk_size_octet + 6);
 2226|  3.93k|    return true;
 2227|  3.93k|}
_ZN28pgp_source_encrypted_param_t7use_cfbEv:
  127|  44.0k|    {
  128|  44.0k|        return (auth_type != rnp::AuthType::AEADv1
  ------------------
  |  Branch (128:17): [True: 30.5k, False: 13.5k]
  ------------------
  129|  30.5k|#ifdef ENABLE_CRYPTO_REFRESH
  130|  30.5k|                && auth_type != rnp::AuthType::AEADv2
  ------------------
  |  Branch (130:20): [True: 23.7k, False: 6.71k]
  ------------------
  131|  44.0k|#endif
  132|  44.0k|        );
  133|  44.0k|    }
_ZNK28pgp_source_encrypted_param_t11is_v2_seipdEv:
  138|   181k|    {
  139|   181k|        return auth_type == rnp::AuthType::AEADv2;
  140|   181k|    }
stream-parse.cpp:_ZL23encrypted_src_read_aeadP12pgp_source_tPvmPm:
  822|  7.92k|{
  823|       |#if !defined(ENABLE_AEAD)
  824|       |    return false;
  825|       |#else
  826|  7.92k|    auto   param = (pgp_source_encrypted_param_t *) src->param;
  827|  7.92k|    size_t left = len;
  828|       |
  829|   217k|    do {
  830|       |        /* check whether we have something in the cache */
  831|   217k|        size_t cbytes = param->cachelen - param->cachepos;
  832|   217k|        if (cbytes > 0) {
  ------------------
  |  Branch (832:13): [True: 210k, False: 7.13k]
  ------------------
  833|   210k|            if (cbytes >= left) {
  ------------------
  |  Branch (833:17): [True: 1.84k, False: 208k]
  ------------------
  834|  1.84k|                memcpy(buf, param->cache + param->cachepos, left);
  835|  1.84k|                param->cachepos += left;
  836|  1.84k|                if (param->cachepos == param->cachelen) {
  ------------------
  |  Branch (836:21): [True: 1.00k, False: 840]
  ------------------
  837|  1.00k|                    param->cachepos = param->cachelen = 0;
  838|  1.00k|                }
  839|  1.84k|                *read = len;
  840|  1.84k|                return true;
  841|  1.84k|            }
  842|   208k|            memcpy(buf, param->cache + param->cachepos, cbytes);
  843|   208k|            buf = (uint8_t *) buf + cbytes;
  844|   208k|            left -= cbytes;
  845|   208k|        }
  846|       |
  847|       |        /* read something into cache */
  848|   216k|        if (!encrypted_src_read_aead_part(param)) {
  ------------------
  |  Branch (848:13): [True: 490, False: 215k]
  ------------------
  849|    490|            return false;
  850|    490|        }
  851|   216k|    } while ((left > 0) && (param->cachelen > 0));
  ------------------
  |  Branch (851:14): [True: 215k, False: 0]
  |  Branch (851:28): [True: 210k, False: 5.59k]
  ------------------
  852|       |
  853|  5.59k|    *read = len - left;
  854|  5.59k|    return true;
  855|  7.92k|#endif
  856|  7.92k|}
stream-parse.cpp:_ZL22encrypted_src_read_cfbP12pgp_source_tPvmPm:
  860|  7.59k|{
  861|  7.59k|    pgp_source_encrypted_param_t *param = (pgp_source_encrypted_param_t *) src->param;
  862|  7.59k|    if (!param) {
  ------------------
  |  Branch (862:9): [True: 0, False: 7.59k]
  ------------------
  863|      0|        return false; // LCOV_EXCL_LINE
  864|      0|    }
  865|       |
  866|  7.59k|    if (src->eof_) {
  ------------------
  |  Branch (866:9): [True: 0, False: 7.59k]
  ------------------
  867|      0|        *readres = 0;
  868|      0|        return true;
  869|      0|    }
  870|       |
  871|  7.59k|    size_t read;
  872|  7.59k|    if (!param->pkt.readsrc->read(buf, len, &read)) {
  ------------------
  |  Branch (872:9): [True: 0, False: 7.59k]
  ------------------
  873|      0|        return false;
  874|      0|    }
  875|  7.59k|    if (!read) {
  ------------------
  |  Branch (875:9): [True: 2.90k, False: 4.69k]
  ------------------
  876|  2.90k|        *readres = 0;
  877|  2.90k|        return true;
  878|  2.90k|    }
  879|       |
  880|  4.69k|    bool    parsemdc = false;
  881|  4.69k|    uint8_t mdcbuf[MDC_V1_SIZE];
  882|  4.69k|    if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (882:9): [True: 4.69k, False: 0]
  ------------------
  883|  4.69k|        size_t mdcread = 0;
  884|       |        /* make sure there are always 22 bytes left on input */
  885|  4.69k|        if (!param->pkt.readsrc->peek(mdcbuf, MDC_V1_SIZE, &mdcread) ||
  ------------------
  |  |  148|  4.69k|#define MDC_V1_SIZE 22
  ------------------
  |  Branch (885:13): [True: 0, False: 4.69k]
  ------------------
  886|  4.69k|            (mdcread + read < MDC_V1_SIZE)) {
  ------------------
  |  |  148|  4.69k|#define MDC_V1_SIZE 22
  ------------------
  |  Branch (886:13): [True: 1, False: 4.69k]
  ------------------
  887|      1|            RNP_LOG("wrong mdc read state");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  888|      1|            return false;
  889|      1|        }
  890|  4.69k|        if (mdcread < MDC_V1_SIZE) {
  ------------------
  |  |  148|  4.69k|#define MDC_V1_SIZE 22
  ------------------
  |  Branch (890:13): [True: 4.03k, False: 662]
  ------------------
  891|  4.03k|            param->pkt.readsrc->skip(mdcread);
  892|  4.03k|            size_t mdcsub = MDC_V1_SIZE - mdcread;
  ------------------
  |  |  148|  4.03k|#define MDC_V1_SIZE 22
  ------------------
  893|  4.03k|            memmove(&mdcbuf[mdcsub], mdcbuf, mdcread);
  894|  4.03k|            memcpy(mdcbuf, (uint8_t *) buf + read - mdcsub, mdcsub);
  895|  4.03k|            read -= mdcsub;
  896|  4.03k|            parsemdc = true;
  897|  4.03k|        }
  898|  4.69k|    }
  899|       |
  900|  4.69k|    pgp_cipher_cfb_decrypt(&param->decrypt, (uint8_t *) buf, (uint8_t *) buf, read);
  901|       |
  902|  4.69k|    if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (902:9): [True: 4.69k, False: 0]
  ------------------
  903|  4.69k|        try {
  904|  4.69k|            param->mdc->add(buf, read);
  905|       |
  906|  4.69k|            if (parsemdc) {
  ------------------
  |  Branch (906:17): [True: 4.03k, False: 662]
  ------------------
  907|  4.03k|                pgp_cipher_cfb_decrypt(&param->decrypt, mdcbuf, mdcbuf, MDC_V1_SIZE);
  ------------------
  |  |  148|  4.03k|#define MDC_V1_SIZE 22
  ------------------
  908|  4.03k|                pgp_cipher_cfb_finish(&param->decrypt);
  909|  4.03k|                param->mdc->add(mdcbuf, 2);
  910|  4.03k|                uint8_t hash[PGP_SHA1_HASH_SIZE] = {0};
  911|  4.03k|                param->mdc->finish(hash);
  912|  4.03k|                param->mdc = nullptr;
  913|       |
  914|  4.03k|                if ((mdcbuf[0] != MDC_PKT_TAG) || (mdcbuf[1] != MDC_V1_SIZE - 2)) {
  ------------------
  |  |  147|  4.03k|#define MDC_PKT_TAG 0xd3
  ------------------
                              if ((mdcbuf[0] != MDC_PKT_TAG) || (mdcbuf[1] != MDC_V1_SIZE - 2)) {
  ------------------
  |  |  148|  4.01k|#define MDC_V1_SIZE 22
  ------------------
  |  Branch (914:21): [True: 20, False: 4.01k]
  |  Branch (914:51): [True: 4, False: 4.00k]
  ------------------
  915|     24|                    RNP_LOG("mdc header check failed");
  ------------------
  |  |   84|     24|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     24|    do {                                                                                 \
  |  |  |  |   77|     24|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 24, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     24|            break;                                                                       \
  |  |  |  |   79|     24|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  916|     24|                    return false;
  917|     24|                }
  918|       |
  919|  4.00k|                if (memcmp(&mdcbuf[2], hash, PGP_SHA1_HASH_SIZE) != 0) {
  ------------------
  |  |   42|  4.00k|#define PGP_SHA1_HASH_SIZE 20
  ------------------
  |  Branch (919:21): [True: 1, False: 4.00k]
  ------------------
  920|      1|                    RNP_LOG("mdc hash check failed");
  ------------------
  |  |   84|      1|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      1|    do {                                                                                 \
  |  |  |  |   77|      1|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      1|            break;                                                                       \
  |  |  |  |   79|      1|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  921|      1|                    return false;
  922|      1|                }
  923|  4.00k|                param->auth_validated = true;
  924|  4.00k|            }
  925|  4.69k|        } catch (const std::exception &e) {
  926|       |            /* LCOV_EXCL_START */
  927|      0|            RNP_LOG("mdc update failed: %s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  928|      0|            return false;
  929|       |            /* LCOV_EXCL_END */
  930|      0|        }
  931|  4.69k|    }
  932|  4.67k|    *readres = read;
  933|  4.67k|    return true;
  934|  4.69k|}
stream-parse.cpp:_ZL20encrypted_start_aeadP28pgp_source_encrypted_param_t14pgp_symm_alg_tPh:
 1684|  4.16k|{
 1685|       |#if !defined(ENABLE_AEAD)
 1686|       |    RNP_LOG("AEAD is not enabled.");
 1687|       |    return false;
 1688|       |#else
 1689|  4.16k|    size_t gran;
 1690|       |
 1691|  4.16k|    if (alg != param->aead_hdr.ealg) {
  ------------------
  |  Branch (1691:9): [True: 0, False: 4.16k]
  ------------------
 1692|      0|        return false;
 1693|      0|    }
 1694|  4.16k|#ifdef ENABLE_CRYPTO_REFRESH
 1695|  4.16k|    std::vector<uint8_t> seipd_v2_key;
 1696|  4.16k|    if (param->is_v2_seipd()) {
  ------------------
  |  Branch (1696:9): [True: 1.34k, False: 2.82k]
  ------------------
 1697|  1.34k|        seipd_v2_aead_fields_t aead_fields =
 1698|  1.34k|          seipd_v2_key_and_nonce_derivation(param->seipdv2_hdr, key);
 1699|  1.34k|        seipd_v2_key = aead_fields.key;
 1700|  1.34k|        key = std::move(seipd_v2_key.data());
 1701|       |        // param->seipd_v2_nonce = std::move(aead_fields.nonce);
 1702|  1.34k|        if (aead_fields.nonce.size() > sizeof(param->aead_hdr.iv)) {
  ------------------
  |  Branch (1702:13): [True: 0, False: 1.34k]
  ------------------
 1703|       |            // signalling error would be better here
 1704|      0|            aead_fields.nonce.resize(sizeof(param->aead_hdr.iv));
 1705|      0|        }
 1706|  1.34k|        memcpy(param->aead_hdr.iv, aead_fields.nonce.data(), aead_fields.nonce.size());
 1707|  1.34k|    }
 1708|  4.16k|#endif
 1709|       |
 1710|       |    /* initialize cipher with key */
 1711|  4.16k|    if (!pgp_cipher_aead_init(
  ------------------
  |  Branch (1711:9): [True: 366, False: 3.80k]
  ------------------
 1712|  4.16k|          &param->decrypt, param->aead_hdr.ealg, param->aead_hdr.aalg, key, true)) {
 1713|    366|        return false;
 1714|    366|    }
 1715|       |
 1716|  3.80k|    gran = pgp_cipher_aead_granularity(&param->decrypt);
 1717|  3.80k|    if (gran > sizeof(param->cache)) {
  ------------------
  |  Branch (1717:9): [True: 0, False: 3.80k]
  ------------------
 1718|      0|        RNP_LOG("wrong granularity");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1719|      0|        return false;
 1720|      0|    }
 1721|       |
 1722|  3.80k|    return encrypted_start_aead_chunk(param, 0, false);
 1723|  3.80k|#endif
 1724|  3.80k|}
stream-parse.cpp:_ZL28encrypted_decrypt_cfb_headerP28pgp_source_encrypted_param_t14pgp_symm_alg_tPh:
 1627|  4.98k|{
 1628|  4.98k|    pgp_crypt_t crypt;
 1629|  4.98k|    uint8_t     enchdr[PGP_MAX_BLOCK_SIZE + 2];
 1630|  4.98k|    uint8_t     dechdr[PGP_MAX_BLOCK_SIZE + 2];
 1631|  4.98k|    unsigned    blsize;
 1632|       |
 1633|  4.98k|    if (!(blsize = pgp_block_size(alg))) {
  ------------------
  |  Branch (1633:9): [True: 0, False: 4.98k]
  ------------------
 1634|      0|        return false;
 1635|      0|    }
 1636|       |
 1637|       |    /* reading encrypted header to check the password validity */
 1638|  4.98k|    if (!param->pkt.readsrc->peek_eq(enchdr, blsize + 2)) {
  ------------------
  |  Branch (1638:9): [True: 189, False: 4.79k]
  ------------------
 1639|    189|        RNP_LOG("failed to read encrypted header");
  ------------------
  |  |   84|    189|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    189|    do {                                                                                 \
  |  |  |  |   77|    189|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 189, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    189|            break;                                                                       \
  |  |  |  |   79|    189|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1640|    189|        return false;
 1641|    189|    }
 1642|       |
 1643|       |    /* having symmetric key in keybuf let's decrypt blocksize + 2 bytes and check them */
 1644|  4.79k|    if (!pgp_cipher_cfb_start(&crypt, alg, key, NULL)) {
  ------------------
  |  Branch (1644:9): [True: 0, False: 4.79k]
  ------------------
 1645|      0|        RNP_LOG("failed to start cipher");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1646|      0|        return false;
 1647|      0|    }
 1648|       |
 1649|  4.79k|    pgp_cipher_cfb_decrypt(&crypt, dechdr, enchdr, blsize + 2);
 1650|       |
 1651|  4.79k|    if ((dechdr[blsize] != dechdr[blsize - 2]) || (dechdr[blsize + 1] != dechdr[blsize - 1])) {
  ------------------
  |  Branch (1651:9): [True: 690, False: 4.10k]
  |  Branch (1651:51): [True: 54, False: 4.05k]
  ------------------
 1652|    744|        RNP_LOG("checksum check failed");
  ------------------
  |  |   84|    744|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    744|    do {                                                                                 \
  |  |  |  |   77|    744|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 744, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    744|            break;                                                                       \
  |  |  |  |   79|    744|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1653|    744|        goto error;
 1654|    744|    }
 1655|       |
 1656|  4.05k|    param->pkt.readsrc->skip(blsize + 2);
 1657|  4.05k|    param->decrypt = crypt;
 1658|       |
 1659|       |    /* init mdc if it is here */
 1660|       |    /* RFC 4880, 5.13: Unlike the Symmetrically Encrypted Data Packet, no special CFB
 1661|       |     * resynchronization is done after encrypting this prefix data. */
 1662|  4.05k|    if (param->auth_type == rnp::AuthType::None) {
  ------------------
  |  Branch (1662:9): [True: 0, False: 4.05k]
  ------------------
 1663|      0|        pgp_cipher_cfb_resync(&param->decrypt, enchdr + 2);
 1664|      0|        return true;
 1665|      0|    }
 1666|       |
 1667|  4.05k|    try {
 1668|  4.05k|        param->mdc = rnp::Hash::create(PGP_HASH_SHA1);
 1669|  4.05k|        param->mdc->add(dechdr, blsize + 2);
 1670|  4.05k|    } catch (const std::exception &e) {
 1671|       |        /* LCOV_EXCL_START */
 1672|      0|        RNP_LOG("cannot create sha1 hash: %s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1673|      0|        goto error;
 1674|       |        /* LCOV_EXCL_END */
 1675|      0|    }
 1676|  4.05k|    return true;
 1677|    744|error:
 1678|    744|    pgp_cipher_cfb_finish(&crypt);
 1679|    744|    return false;
 1680|  4.05k|}
stream-parse.cpp:_ZL22encrypted_try_passwordP28pgp_source_encrypted_param_tPKc:
 1865|  8.81k|{
 1866|  8.81k|    bool keyavail = false; /* tried password at least once */
 1867|       |
 1868|  13.4k|    for (auto &skey : param->symencs) {
  ------------------
  |  Branch (1868:21): [True: 13.4k, False: 959]
  ------------------
 1869|  13.4k|        rnp::secure_array<uint8_t, PGP_MAX_KEY_SIZE + 1> keybuf;
 1870|       |        /* deriving symmetric key from password */
 1871|  13.4k|        size_t keysize = pgp_key_size(skey.alg);
 1872|  13.4k|        if (!keysize || !pgp_s2k_derive_key(&skey.s2k, password, keybuf.data(), keysize)) {
  ------------------
  |  Branch (1872:13): [True: 985, False: 12.4k]
  |  Branch (1872:25): [True: 713, False: 11.7k]
  ------------------
 1873|  1.69k|            continue;
 1874|  1.69k|        }
 1875|  11.7k|        pgp_crypt_t    crypt;
 1876|  11.7k|        pgp_symm_alg_t alg;
 1877|       |
 1878|  11.7k|        if (skey.version == PGP_SKSK_V4) {
  ------------------
  |  Branch (1878:13): [True: 7.22k, False: 4.53k]
  ------------------
 1879|       |            /* v4 symmetrically-encrypted session key */
 1880|  7.22k|            if (skey.enckeylen > 0) {
  ------------------
  |  Branch (1880:17): [True: 3.20k, False: 4.01k]
  ------------------
 1881|       |                /* decrypting session key */
 1882|  3.20k|                if (!pgp_cipher_cfb_start(&crypt, skey.alg, keybuf.data(), NULL)) {
  ------------------
  |  Branch (1882:21): [True: 0, False: 3.20k]
  ------------------
 1883|      0|                    continue;
 1884|      0|                }
 1885|       |
 1886|  3.20k|                pgp_cipher_cfb_decrypt(&crypt, keybuf.data(), skey.enckey, skey.enckeylen);
 1887|  3.20k|                pgp_cipher_cfb_finish(&crypt);
 1888|       |
 1889|  3.20k|                alg = (pgp_symm_alg_t) keybuf[0];
 1890|  3.20k|                keysize = pgp_key_size(alg);
 1891|  3.20k|                if (!keysize || (keysize + 1 != skey.enckeylen)) {
  ------------------
  |  Branch (1891:21): [True: 1.17k, False: 2.03k]
  |  Branch (1891:33): [True: 257, False: 1.77k]
  ------------------
 1892|  1.43k|                    continue;
 1893|  1.43k|                }
 1894|  1.77k|                memmove(keybuf.data(), keybuf.data() + 1, keysize);
 1895|  4.01k|            } else {
 1896|  4.01k|                alg = (pgp_symm_alg_t) skey.alg;
 1897|  4.01k|            }
 1898|       |
 1899|  5.79k|            if (!pgp_block_size(alg)) {
  ------------------
  |  Branch (1899:17): [True: 0, False: 5.79k]
  ------------------
 1900|      0|                continue;
 1901|      0|            }
 1902|  5.79k|            keyavail = true;
 1903|  5.79k|        } else if (skey.version == PGP_SKSK_V5
  ------------------
  |  Branch (1903:20): [True: 2.21k, False: 2.32k]
  ------------------
 1904|  2.32k|#if defined(ENABLE_CRYPTO_REFRESH)
 1905|  2.32k|                   || skey.version == PGP_SKSK_V6
  ------------------
  |  Branch (1905:23): [True: 2.32k, False: 0]
  ------------------
 1906|  4.53k|#endif
 1907|  4.53k|        ) {
 1908|       |#if !defined(ENABLE_AEAD)
 1909|       |            continue;
 1910|       |#else
 1911|       |            /* v5 AEAD-encrypted session key */
 1912|  4.53k|            size_t taglen = pgp_cipher_aead_tag_len(skey.aalg);
 1913|  4.53k|            size_t ceklen = pgp_key_size(param->aead_hdr.ealg);
 1914|  4.53k|            if (!taglen || !ceklen || (ceklen + taglen != skey.enckeylen)) {
  ------------------
  |  Branch (1914:17): [True: 0, False: 4.53k]
  |  Branch (1914:28): [True: 341, False: 4.19k]
  |  Branch (1914:39): [True: 212, False: 3.98k]
  ------------------
 1915|    553|                RNP_LOG("CEK len/alg mismatch");
  ------------------
  |  |   84|    553|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    553|    do {                                                                                 \
  |  |  |  |   77|    553|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 553, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    553|            break;                                                                       \
  |  |  |  |   79|    553|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1916|    553|                continue;
 1917|    553|            }
 1918|  3.98k|            alg = skey.alg;
 1919|       |
 1920|       |            /* initialize cipher */
 1921|  3.98k|#if defined(ENABLE_CRYPTO_REFRESH)
 1922|  3.98k|            if (skey.version == PGP_SKSK_V6) {
  ------------------
  |  Branch (1922:17): [True: 1.92k, False: 2.05k]
  ------------------
 1923|       |                /* For v6 SKESK, we use the S2K derived key as input to the KDF */
 1924|  1.92k|                auto kdf = rnp::Hkdf::create(PGP_HASH_SHA256);
 1925|       |
 1926|  1.92k|                std::vector<uint8_t> kdf_info;
 1927|  1.92k|                kdf_info.push_back(PGP_PKT_SK_SESSION_KEY | PGP_PTAG_ALWAYS_SET |
  ------------------
  |  |   47|  1.92k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
 1928|  1.92k|                                   PGP_PTAG_NEW_FORMAT);
  ------------------
  |  |   56|  1.92k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
 1929|  1.92k|                kdf_info.push_back(skey.version);
 1930|  1.92k|                kdf_info.push_back(skey.alg);
 1931|  1.92k|                kdf_info.push_back(skey.aalg);
 1932|       |
 1933|  1.92k|                std::vector<uint8_t> kdf_input(keybuf.data(),
 1934|  1.92k|                                               keybuf.data() + pgp_key_size(skey.alg));
 1935|       |
 1936|  1.92k|                kdf->extract_expand(NULL,
 1937|  1.92k|                                    0, // no salt
 1938|  1.92k|                                    kdf_input.data(),
 1939|  1.92k|                                    kdf_input.size(),
 1940|  1.92k|                                    kdf_info.data(),
 1941|  1.92k|                                    kdf_info.size(),
 1942|  1.92k|                                    keybuf.data(),
 1943|  1.92k|                                    keybuf.size());
 1944|  1.92k|            }
 1945|  3.98k|#endif
 1946|  3.98k|            if (!pgp_cipher_aead_init(&crypt, skey.alg, skey.aalg, keybuf.data(), true)) {
  ------------------
  |  Branch (1946:17): [True: 10, False: 3.97k]
  ------------------
 1947|     10|                continue;
 1948|     10|            }
 1949|       |
 1950|       |            /* set additional data */
 1951|  3.97k|            if (!encrypted_sesk_set_ad(crypt, skey)) {
  ------------------
  |  Branch (1951:17): [True: 0, False: 3.97k]
  ------------------
 1952|      0|                RNP_LOG("failed to set ad");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1953|      0|                continue;
 1954|      0|            }
 1955|       |
 1956|       |            /* calculate nonce */
 1957|  3.97k|            uint8_t nonce[PGP_AEAD_MAX_NONCE_LEN];
 1958|  3.97k|            size_t  noncelen = pgp_cipher_aead_nonce(skey.aalg, skey.iv, nonce, 0);
 1959|       |
 1960|       |            /* start cipher, decrypt key and verify tag */
 1961|  3.97k|            keyavail =
 1962|  3.97k|              pgp_cipher_aead_start(&crypt, nonce, noncelen) &&
  ------------------
  |  Branch (1962:15): [True: 3.97k, False: 0]
  ------------------
 1963|  3.97k|              pgp_cipher_aead_finish(&crypt, keybuf.data(), skey.enckey, skey.enckeylen);
  ------------------
  |  Branch (1963:15): [True: 3.36k, False: 607]
  ------------------
 1964|  3.97k|            pgp_cipher_aead_destroy(&crypt);
 1965|       |
 1966|       |            /* we have decrypted key so let's start decryption */
 1967|  3.97k|            if (!keyavail) {
  ------------------
  |  Branch (1967:17): [True: 607, False: 3.36k]
  ------------------
 1968|    607|                continue;
 1969|    607|            }
 1970|  3.97k|#endif
 1971|  3.97k|        } else {
 1972|      0|            continue;
 1973|      0|        }
 1974|       |
 1975|       |        /* Decrypt header for CFB */
 1976|  9.15k|        if (param->use_cfb() && !encrypted_decrypt_cfb_header(param, alg, keybuf.data())) {
  ------------------
  |  Branch (1976:13): [True: 4.98k, False: 4.16k]
  |  Branch (1976:33): [True: 933, False: 4.05k]
  ------------------
 1977|    933|            continue;
 1978|    933|        }
 1979|  8.22k|        if (!param->use_cfb() &&
  ------------------
  |  Branch (1979:13): [True: 4.16k, False: 4.05k]
  ------------------
 1980|  4.16k|            !encrypted_start_aead(param, param->aead_hdr.ealg, keybuf.data())) {
  ------------------
  |  Branch (1980:13): [True: 366, False: 3.80k]
  ------------------
 1981|    366|            continue;
 1982|    366|        }
 1983|       |
 1984|  7.85k|        param->salg = param->use_cfb() ? alg : param->aead_hdr.ealg;
  ------------------
  |  Branch (1984:23): [True: 4.05k, False: 3.80k]
  ------------------
 1985|       |        /* inform handler that we used this symenc */
 1986|  7.85k|        if (param->handler->on_decryption_start) {
  ------------------
  |  Branch (1986:13): [True: 7.85k, False: 0]
  ------------------
 1987|  7.85k|            param->handler->on_decryption_start(NULL, &skey, param->handler->param);
 1988|  7.85k|        }
 1989|  7.85k|        return 1;
 1990|  8.22k|    }
 1991|       |
 1992|    959|    if (!param->use_cfb() && pgp_block_size(param->aead_hdr.ealg)) {
  ------------------
  |  Branch (1992:9): [True: 210, False: 749]
  |  Branch (1992:30): [True: 162, False: 48]
  ------------------
 1993|       |        /* we know aead symm alg even if we wasn't able to start decryption */
 1994|    162|        param->salg = param->aead_hdr.ealg;
 1995|    162|    }
 1996|       |
 1997|    959|    if (!keyavail) {
  ------------------
  |  Branch (1997:9): [True: 428, False: 531]
  ------------------
 1998|    428|        RNP_LOG("no supported sk available");
  ------------------
  |  |   84|    428|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    428|    do {                                                                                 \
  |  |  |  |   77|    428|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 428, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    428|            break;                                                                       \
  |  |  |  |   79|    428|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1999|    428|        return -1;
 2000|    428|    }
 2001|    531|    return 0;
 2002|    959|}
stream-parse.cpp:_ZL15init_signed_srcP19pgp_parse_handler_tP12pgp_source_tS2_:
 2709|  3.70k|{
 2710|  3.70k|    rnp_result_t               errcode = RNP_ERROR_GENERIC;
 2711|  3.70k|    pgp_source_signed_param_t *param;
 2712|  3.70k|    uint8_t                    ptag;
 2713|  3.70k|    int                        ptype;
 2714|  3.70k|    pgp::pkt::Signature *      sig = nullptr;
 2715|  3.70k|    bool                       cleartext;
 2716|  3.70k|    size_t                     sigerrors = 0;
 2717|       |
 2718|  3.70k|    if (!init_src_common(src, 0)) {
  ------------------
  |  Branch (2718:9): [True: 0, False: 3.70k]
  ------------------
 2719|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2720|      0|    }
 2721|  3.70k|    try {
 2722|  3.70k|        param = new pgp_source_signed_param_t();
 2723|  3.70k|    } catch (const std::exception &e) {
 2724|       |        /* LCOV_EXCL_START */
 2725|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2726|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 2727|       |        /* LCOV_EXCL_END */
 2728|      0|    }
 2729|  3.70k|    src->param = param;
 2730|       |
 2731|  3.70k|    cleartext = readsrc->is_cleartext();
 2732|  3.70k|    param->readsrc = readsrc;
 2733|  3.70k|    param->handler = handler;
 2734|  3.70k|    param->cleartext = cleartext;
 2735|  3.70k|    param->stripped_crs = 0;
 2736|  3.70k|    src->raw_read = cleartext ? cleartext_src_read : signed_src_read;
  ------------------
  |  Branch (2736:21): [True: 4, False: 3.70k]
  ------------------
 2737|  3.70k|    src->raw_close = signed_src_close;
 2738|  3.70k|    src->raw_finish = signed_src_finish;
 2739|  3.70k|    src->type = cleartext ? PGP_STREAM_CLEARTEXT : PGP_STREAM_SIGNED;
  ------------------
  |  Branch (2739:17): [True: 4, False: 3.70k]
  ------------------
 2740|       |
 2741|       |    /* we need key provider to validate signatures */
 2742|  3.70k|    if (!handler->key_provider) {
  ------------------
  |  Branch (2742:9): [True: 0, False: 3.70k]
  ------------------
 2743|       |        /* LCOV_EXCL_START */
 2744|      0|        RNP_LOG("no key provider");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2745|      0|        errcode = RNP_ERROR_BAD_PARAMETERS;
 2746|      0|        goto finish;
 2747|       |        /* LCOV_EXCL_END */
 2748|      0|    }
 2749|       |
 2750|  3.70k|    if (cleartext) {
  ------------------
  |  Branch (2750:9): [True: 4, False: 3.70k]
  ------------------
 2751|      4|        errcode = init_cleartext_signed_src(src);
 2752|      4|        goto finish;
 2753|      4|    }
 2754|       |
 2755|       |    /* Reading one-pass and signature packets */
 2756|   194k|    while (true) {
  ------------------
  |  Branch (2756:12): [True: 194k, Folded]
  ------------------
 2757|       |        /* stop early if we are in zip-bomb with erroneous packets */
 2758|   194k|        if (sigerrors >= MAX_SIG_ERRORS) {
  ------------------
  |  | 2705|   194k|#define MAX_SIG_ERRORS 65536
  ------------------
  |  Branch (2758:13): [True: 0, False: 194k]
  ------------------
 2759|      0|            RNP_LOG("Too many one-pass/signature errors. Stopping.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2760|      0|            errcode = RNP_ERROR_BAD_FORMAT;
 2761|      0|            goto finish;
 2762|      0|        }
 2763|       |
 2764|   194k|        size_t readb = readsrc->readb;
 2765|   194k|        if (!readsrc->peek_eq(&ptag, 1)) {
  ------------------
  |  Branch (2765:13): [True: 13, False: 194k]
  ------------------
 2766|     13|            RNP_LOG("failed to read packet header");
  ------------------
  |  |   84|     13|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     13|    do {                                                                                 \
  |  |  |  |   77|     13|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 13, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     13|            break;                                                                       \
  |  |  |  |   79|     13|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2767|     13|            errcode = RNP_ERROR_READ;
 2768|     13|            goto finish;
 2769|     13|        }
 2770|       |
 2771|   194k|        ptype = get_packet_type(ptag);
 2772|       |
 2773|   194k|        if (ptype == PGP_PKT_ONE_PASS_SIG) {
  ------------------
  |  Branch (2773:13): [True: 139k, False: 55.5k]
  ------------------
 2774|   139k|            if (param->onepasses.size() >= MAX_SIGNATURES) {
  ------------------
  |  | 1224|   139k|#define MAX_SIGNATURES 16384
  ------------------
  |  Branch (2774:17): [True: 0, False: 139k]
  ------------------
 2775|      0|                RNP_LOG("Too many one-pass signatures.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2776|      0|                errcode = RNP_ERROR_BAD_FORMAT;
 2777|      0|                goto finish;
 2778|      0|            }
 2779|   139k|            pgp_one_pass_sig_t onepass;
 2780|   139k|            try {
 2781|   139k|                errcode = onepass.parse(*readsrc);
 2782|   139k|            } catch (const std::exception &e) {
 2783|      0|                errcode = RNP_ERROR_GENERIC; // LCOV_EXCL_LINE
 2784|      0|            }
 2785|   139k|            if (errcode) {
  ------------------
  |  Branch (2785:17): [True: 134k, False: 4.56k]
  ------------------
 2786|   134k|                if (errcode == RNP_ERROR_READ) {
  ------------------
  |  Branch (2786:21): [True: 84, False: 134k]
  ------------------
 2787|     84|                    goto finish;
 2788|     84|                }
 2789|   134k|                if (readb == readsrc->readb) {
  ------------------
  |  Branch (2789:21): [True: 0, False: 134k]
  ------------------
 2790|      0|                    errcode = RNP_ERROR_BAD_FORMAT;
 2791|      0|                    goto finish;
 2792|      0|                }
 2793|   134k|                sigerrors++;
 2794|   134k|                continue;
 2795|   134k|            }
 2796|       |
 2797|  4.56k|            try {
 2798|  4.56k|                param->onepasses.push_back(onepass);
 2799|  4.56k|            } catch (const std::exception &e) {
 2800|       |                /* LCOV_EXCL_START */
 2801|      0|                RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2802|      0|                errcode = RNP_ERROR_OUT_OF_MEMORY;
 2803|      0|                goto finish;
 2804|       |                /* LCOV_EXCL_END */
 2805|      0|            }
 2806|       |
 2807|       |            /* adding hash context */
 2808|  4.56k|            try {
 2809|  4.56k|#if defined(ENABLE_CRYPTO_REFRESH)
 2810|  4.56k|                if (onepass.version == PGP_OPS_V6) {
  ------------------
  |  Branch (2810:21): [True: 996, False: 3.57k]
  ------------------
 2811|    996|                    add_hash_for_sig_v6(param, onepass.type, onepass.halg, onepass.salt);
 2812|    996|                } else
 2813|  3.57k|#endif
 2814|  3.57k|                {
 2815|  3.57k|                    add_hash_for_sig(param, onepass.type, onepass.halg);
 2816|  3.57k|                }
 2817|  4.56k|            } catch (const std::exception &e) {
 2818|     31|                RNP_LOG("Failed to create hash %d for onepass %d : %s.",
  ------------------
  |  |   84|     31|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     31|    do {                                                                                 \
  |  |  |  |   77|     31|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 31, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     31|            break;                                                                       \
  |  |  |  |   79|     31|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2819|     31|                        (int) onepass.halg,
 2820|     31|                        (int) onepass.type,
 2821|     31|                        e.what());
 2822|     31|                errcode = RNP_ERROR_BAD_PARAMETERS;
 2823|     31|                goto finish;
 2824|     31|            }
 2825|       |
 2826|  4.53k|            if (onepass.nested) {
  ------------------
  |  Branch (2826:17): [True: 2.58k, False: 1.95k]
  ------------------
 2827|       |                /* despite the name non-zero value means that it is the last one-pass */
 2828|  2.58k|                break;
 2829|  2.58k|            }
 2830|  55.5k|        } else if (ptype == PGP_PKT_SIGNATURE) {
  ------------------
  |  Branch (2830:20): [True: 54.7k, False: 809]
  ------------------
 2831|       |            /* no need to check the error here - we already know tag */
 2832|  54.7k|            if (signed_read_single_signature(param, readsrc, &sig)) {
  ------------------
  |  Branch (2832:17): [True: 0, False: 54.7k]
  ------------------
 2833|      0|                sigerrors++;
 2834|      0|            }
 2835|       |            /* adding hash context */
 2836|  54.7k|            if (sig) {
  ------------------
  |  Branch (2836:17): [True: 2.07k, False: 52.6k]
  ------------------
 2837|  2.07k|                try {
 2838|  2.07k|#if defined(ENABLE_CRYPTO_REFRESH)
 2839|  2.07k|                    if (sig->version == PGP_V6) {
  ------------------
  |  Branch (2839:25): [True: 73, False: 2.00k]
  ------------------
 2840|     73|                        add_hash_for_sig_v6(param, sig->type(), sig->halg, sig->salt);
 2841|     73|                    } else
 2842|  2.00k|#endif
 2843|  2.00k|                    {
 2844|  2.00k|                        add_hash_for_sig(param, sig->type(), sig->halg);
 2845|  2.00k|                    }
 2846|  2.07k|                } catch (const std::exception &e) {
 2847|     22|                    RNP_LOG("Failed to create hash %d for sig %d : %s.",
  ------------------
  |  |   84|     22|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     22|    do {                                                                                 \
  |  |  |  |   77|     22|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 22, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     22|            break;                                                                       \
  |  |  |  |   79|     22|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2848|     22|                            (int) sig->halg,
 2849|     22|                            (int) sig->type(),
 2850|     22|                            e.what());
 2851|     22|                    errcode = RNP_ERROR_BAD_PARAMETERS;
 2852|     22|                    goto finish;
 2853|     22|                }
 2854|  2.07k|            }
 2855|  54.7k|        } else {
 2856|    809|            break;
 2857|    809|        }
 2858|       |
 2859|       |        /* check if we are not it endless loop */
 2860|  56.6k|        if (readb == readsrc->readb) {
  ------------------
  |  Branch (2860:13): [True: 13, False: 56.6k]
  ------------------
 2861|     13|            errcode = RNP_ERROR_BAD_FORMAT;
 2862|     13|            goto finish;
 2863|     13|        }
 2864|       |        /* for detached signature we'll get eof */
 2865|  56.6k|        if (readsrc->eof()) {
  ------------------
  |  Branch (2865:13): [True: 143, False: 56.5k]
  ------------------
 2866|    143|            param->detached = true;
 2867|    143|            break;
 2868|    143|        }
 2869|  56.6k|    }
 2870|       |
 2871|       |    /* checking what we have now */
 2872|  3.54k|    if (param->onepasses.empty() && param->sigs.empty()) {
  ------------------
  |  Branch (2872:9): [True: 893, False: 2.64k]
  |  Branch (2872:37): [True: 725, False: 168]
  ------------------
 2873|    725|        RNP_LOG("no signatures");
  ------------------
  |  |   84|    725|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    725|    do {                                                                                 \
  |  |  |  |   77|    725|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 725, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    725|            break;                                                                       \
  |  |  |  |   79|    725|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2874|    725|        errcode = RNP_ERROR_BAD_PARAMETERS;
 2875|    725|        goto finish;
 2876|    725|    }
 2877|  2.81k|    if (!param->onepasses.empty() && !param->sigs.empty()) {
  ------------------
  |  Branch (2877:9): [True: 2.64k, False: 168]
  |  Branch (2877:38): [True: 91, False: 2.55k]
  ------------------
 2878|     91|        RNP_LOG("warning: one-passes are mixed with signatures");
  ------------------
  |  |   84|     91|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     91|    do {                                                                                 \
  |  |  |  |   77|     91|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 91, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     91|            break;                                                                       \
  |  |  |  |   79|     91|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2879|     91|    }
 2880|       |
 2881|  2.81k|    errcode = RNP_SUCCESS;
 2882|  3.70k|finish:
 2883|  3.70k|    if (errcode != RNP_SUCCESS) {
  ------------------
  |  Branch (2883:9): [True: 892, False: 2.81k]
  ------------------
 2884|    892|        src->close();
 2885|    892|    }
 2886|       |
 2887|  3.70k|    return errcode;
 2888|  2.81k|}
_ZN25pgp_source_signed_param_tC2Ev:
  169|  3.70k|    pgp_source_signed_param_t() = default;
stream-parse.cpp:_ZL15signed_src_readP12pgp_source_tPvmPm:
 1208|  17.3k|{
 1209|  17.3k|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 1210|  17.3k|    if (!param) {
  ------------------
  |  Branch (1210:9): [True: 0, False: 17.3k]
  ------------------
 1211|      0|        return false;
 1212|      0|    }
 1213|  17.3k|    return param->readsrc->read(buf, len, read);
 1214|  17.3k|}
stream-parse.cpp:_ZL16signed_src_closeP12pgp_source_t:
 1218|  3.70k|{
 1219|  3.70k|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 1220|  3.70k|    delete param;
 1221|       |    src->param = NULL;
 1222|  3.70k|}
_ZN25pgp_source_signed_param_tD2Ev:
  170|  3.70k|    ~pgp_source_signed_param_t() = default;
stream-parse.cpp:_ZL17signed_src_finishP12pgp_source_t:
 1327|  1.66k|{
 1328|  1.66k|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 1329|  1.66k|    rnp_result_t               ret = RNP_ERROR_GENERIC;
 1330|       |
 1331|  1.66k|    if (param->cleartext) {
  ------------------
  |  Branch (1331:9): [True: 0, False: 1.66k]
  ------------------
 1332|      0|        ret = signed_read_cleartext_signatures(*src, param);
 1333|  1.66k|    } else {
 1334|  1.66k|        ret = signed_read_signatures(src);
 1335|  1.66k|    }
 1336|       |
 1337|  1.66k|    if (ret) {
  ------------------
  |  Branch (1337:9): [True: 1.12k, False: 547]
  ------------------
 1338|  1.12k|        return ret;
 1339|  1.12k|    }
 1340|       |
 1341|       |    /* See https://dev.gnupg.org/T6615 for the details */
 1342|    547|    if (param->cleartext) {
  ------------------
  |  Branch (1342:9): [True: 0, False: 547]
  ------------------
 1343|      0|        param->lhdr.format = 't';
 1344|      0|        param->lhdr.fname_len = 0;
 1345|      0|        param->lhdr.timestamp = 0;
 1346|      0|        param->has_lhdr = true;
 1347|      0|    }
 1348|       |
 1349|    547|    if (!src->eof()) {
  ------------------
  |  Branch (1349:9): [True: 43, False: 504]
  ------------------
 1350|     43|        RNP_LOG("warning: unexpected data on the stream end");
  ------------------
  |  |   84|     43|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     43|    do {                                                                                 \
  |  |  |  |   77|     43|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 43, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     43|            break;                                                                       \
  |  |  |  |   79|     43|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1351|     43|    }
 1352|       |
 1353|       |    /* validating signatures */
 1354|    547|    ret = RNP_ERROR_SIGNATURE_INVALID;
 1355|  23.1k|    for (auto &sinfo : param->siginfos) {
  ------------------
  |  Branch (1355:22): [True: 23.1k, False: 547]
  ------------------
 1356|  23.1k|        if (!sinfo.sig) {
  ------------------
  |  Branch (1356:13): [True: 21.9k, False: 1.20k]
  ------------------
 1357|  21.9k|            continue;
 1358|  21.9k|        }
 1359|  1.20k|#if defined(ENABLE_CRYPTO_REFRESH)
 1360|  1.20k|        if (sinfo.sig->version == PGP_V6 && param->cleartext) {
  ------------------
  |  Branch (1360:13): [True: 44, False: 1.15k]
  |  Branch (1360:45): [True: 0, False: 44]
  ------------------
 1361|      0|            RNP_LOG("Skipping signature: Cleartext signature verification currently does not "
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1362|      0|                    "support v6 signatures");
 1363|      0|            continue;
 1364|      0|        }
 1365|  1.20k|#endif
 1366|  1.20k|        try {
 1367|  1.20k|            signed_validate_signature(*param, sinfo);
 1368|  1.20k|        } catch (const std::exception &e) {
 1369|       |            /* LCOV_EXCL_START */
 1370|      0|            RNP_LOG("Signature validation failed: %s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1371|      0|            sinfo.validity.mark_validated(RNP_ERROR_SIG_ERROR);
 1372|       |            /* LCOV_EXCL_END */
 1373|      0|        }
 1374|  1.20k|        if (sinfo.validity.valid()) {
  ------------------
  |  Branch (1374:13): [True: 0, False: 1.20k]
  ------------------
 1375|       |            /* If we have at least one valid signature then data is safe to process */
 1376|      0|            ret = RNP_SUCCESS;
 1377|      0|        }
 1378|  1.20k|    }
 1379|       |
 1380|       |    /* call the callback with signature infos */
 1381|    547|    if (param->handler->on_signatures) {
  ------------------
  |  Branch (1381:9): [True: 547, False: 0]
  ------------------
 1382|    547|        param->handler->on_signatures(param->siginfos, param->handler->param);
 1383|    547|    }
 1384|    547|    return ret;
 1385|    547|}
stream-parse.cpp:_ZL22signed_read_signaturesP12pgp_source_t:
 1301|  1.66k|{
 1302|  1.66k|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 1303|       |
 1304|       |    /* reading signatures */
 1305|  1.91k|    for (auto op = param->onepasses.rbegin(); op != param->onepasses.rend(); op++) {
  ------------------
  |  Branch (1305:47): [True: 1.77k, False: 132]
  ------------------
 1306|  1.77k|        pgp::pkt::Signature *sig = NULL;
 1307|  1.77k|        rnp_result_t         ret = signed_read_single_signature(param, src, &sig);
 1308|       |        /* we have more onepasses then signatures */
 1309|  1.77k|        if (ret == RNP_ERROR_READ) {
  ------------------
  |  Branch (1309:13): [True: 1.49k, False: 282]
  ------------------
 1310|  1.49k|            RNP_LOG("Warning: premature end of signatures");
  ------------------
  |  |   84|  1.49k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.49k|    do {                                                                                 \
  |  |  |  |   77|  1.49k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.49k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.49k|            break;                                                                       \
  |  |  |  |   79|  1.49k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1311|  1.49k|            if (!param->siginfos.empty()) {
  ------------------
  |  Branch (1311:17): [True: 415, False: 1.08k]
  ------------------
 1312|    415|                return RNP_SUCCESS;
 1313|    415|            }
 1314|  1.49k|        }
 1315|  1.36k|        if (ret) {
  ------------------
  |  Branch (1315:13): [True: 1.12k, False: 244]
  ------------------
 1316|  1.12k|            return ret;
 1317|  1.12k|        }
 1318|    244|        if (sig && !sig->matches_onepass(*op)) {
  ------------------
  |  Branch (1318:13): [True: 45, False: 199]
  |  Branch (1318:20): [True: 44, False: 1]
  ------------------
 1319|     44|            RNP_LOG("Warning: signature doesn't match one-pass");
  ------------------
  |  |   84|     44|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     44|    do {                                                                                 \
  |  |  |  |   77|     44|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 44, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     44|            break;                                                                       \
  |  |  |  |   79|     44|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1320|     44|        }
 1321|    244|    }
 1322|    132|    return RNP_SUCCESS;
 1323|  1.66k|}
stream-parse.cpp:_ZL25signed_validate_signatureR25pgp_source_signed_param_tRN3rnp13SignatureInfoE:
 1051|  1.20k|{
 1052|       |    /* Check signature type */
 1053|  1.20k|    if (!sinfo.sig->is_document()) {
  ------------------
  |  Branch (1053:9): [True: 1.00k, False: 200]
  ------------------
 1054|  1.00k|        RNP_LOG("Invalid document signature type: %d", (int) sinfo.sig->type());
  ------------------
  |  |   84|  1.00k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.00k|    do {                                                                                 \
  |  |  |  |   77|  1.00k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.00k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.00k|            break;                                                                       \
  |  |  |  |   79|  1.00k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1055|  1.00k|        sinfo.validity.add_error(RNP_ERROR_SIG_NOT_DOCUMENT);
 1056|  1.00k|    }
 1057|       |    /* Find signing key */
 1058|  1.20k|    std::unique_ptr<rnp::KeySearch> search;
 1059|       |    /* Get signer's fp or keyid */
 1060|  1.20k|    if (sinfo.sig->has_keyfp()) {
  ------------------
  |  Branch (1060:9): [True: 942, False: 258]
  ------------------
 1061|    942|        search = rnp::KeySearch::create(sinfo.sig->keyfp());
 1062|    942|    } else if (sinfo.sig->has_keyid()) {
  ------------------
  |  Branch (1062:16): [True: 194, False: 64]
  ------------------
 1063|    194|        search = rnp::KeySearch::create(sinfo.sig->keyid());
 1064|    194|    } else {
 1065|     64|        RNP_LOG("cannot get signer's key fp or id from signature.");
  ------------------
  |  |   84|     64|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     64|    do {                                                                                 \
  |  |  |  |   77|     64|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 64, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     64|            break;                                                                       \
  |  |  |  |   79|     64|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1066|     64|        sinfo.validity.mark_validated(RNP_ERROR_SIG_NO_SIGNER_ID);
 1067|     64|        return;
 1068|     64|    }
 1069|       |    /* Get the public key */
 1070|  1.13k|    auto key = param.handler->key_provider->request_key(*search, PGP_OP_VERIFY);
 1071|  1.13k|    if (!key) {
  ------------------
  |  Branch (1071:9): [True: 1.13k, False: 0]
  ------------------
 1072|       |        /* fallback to secret key */
 1073|  1.13k|        if (!(key = param.handler->key_provider->request_key(*search, PGP_OP_VERIFY, true))) {
  ------------------
  |  Branch (1073:13): [True: 1.13k, False: 0]
  ------------------
 1074|  1.13k|            RNP_LOG("signer's key not found");
  ------------------
  |  |   84|  1.13k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.13k|    do {                                                                                 \
  |  |  |  |   77|  1.13k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.13k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.13k|            break;                                                                       \
  |  |  |  |   79|  1.13k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1075|  1.13k|            sinfo.validity.mark_validated(RNP_ERROR_SIG_NO_SIGNER_KEY);
 1076|  1.13k|            return;
 1077|  1.13k|        }
 1078|  1.13k|    }
 1079|      0|    if (!key->can_sign()) {
  ------------------
  |  Branch (1079:9): [True: 0, False: 0]
  ------------------
 1080|      0|        RNP_LOG("key is not usable for verification");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1081|      0|        sinfo.validity.mark_validated(RNP_ERROR_SIG_UNUSABLE_KEY);
 1082|      0|        return;
 1083|      0|    }
 1084|       |    /* Get the hash context and clone it. */
 1085|      0|    auto hash = get_hash_for_sig(param, sinfo);
 1086|      0|    if (!hash) {
  ------------------
  |  Branch (1086:9): [True: 0, False: 0]
  ------------------
 1087|      0|        RNP_LOG("failed to get hash context.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1088|      0|        sinfo.validity.mark_validated(RNP_ERROR_SIG_NO_HASH_CTX);
 1089|      0|        return;
 1090|      0|    }
 1091|      0|    auto shash = hash->clone();
 1092|      0|    key->validate_sig(
 1093|      0|      sinfo, *shash, param.handler->ctx->sec_ctx, param.has_lhdr ? &param.lhdr : NULL);
  ------------------
  |  Branch (1093:51): [True: 0, False: 0]
  ------------------
 1094|      0|}
stream-parse.cpp:_ZL25init_cleartext_signed_srcP12pgp_source_t:
 2673|      4|{
 2674|      4|    char                       buf[64];
 2675|      4|    size_t                     hdrlen = strlen(ST_CLEAR_BEGIN);
  ------------------
  |  |   48|      4|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
 2676|      4|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 2677|       |
 2678|       |    /* checking header line */
 2679|      4|    if (!param->readsrc->read_eq(buf, hdrlen)) {
  ------------------
  |  Branch (2679:9): [True: 0, False: 4]
  ------------------
 2680|      0|        RNP_LOG("failed to read header");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2681|      0|        return RNP_ERROR_READ;
 2682|      0|    }
 2683|       |
 2684|      4|    if (memcmp(ST_CLEAR_BEGIN, buf, hdrlen)) {
  ------------------
  |  |   48|      4|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
  |  Branch (2684:9): [True: 4, False: 0]
  ------------------
 2685|      4|        RNP_LOG("wrong header");
  ------------------
  |  |   84|      4|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      4|    do {                                                                                 \
  |  |  |  |   77|      4|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 4, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      4|            break;                                                                       \
  |  |  |  |   79|      4|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2686|      4|        return RNP_ERROR_BAD_FORMAT;
 2687|      4|    }
 2688|       |
 2689|       |    /* eol */
 2690|      0|    if (!param->readsrc->skip_eol()) {
  ------------------
  |  Branch (2690:9): [True: 0, False: 0]
  ------------------
 2691|      0|        RNP_LOG("no eol after the cleartext header");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2692|      0|        return RNP_ERROR_BAD_FORMAT;
 2693|      0|    }
 2694|       |
 2695|       |    /* parsing Hash headers */
 2696|      0|    if (!cleartext_parse_headers(param)) {
  ------------------
  |  Branch (2696:9): [True: 0, False: 0]
  ------------------
 2697|      0|        return RNP_ERROR_BAD_FORMAT;
 2698|      0|    }
 2699|       |
 2700|       |    /* now we are good to go */
 2701|      0|    param->clr_fline = true;
 2702|      0|    return RNP_SUCCESS;
 2703|      0|}
stream-parse.cpp:_ZL19add_hash_for_sig_v6P25pgp_source_signed_param_t14pgp_sig_type_t14pgp_hash_alg_tNSt3__16vectorIhNS3_9allocatorIhEEEE:
 1022|  1.06k|{
 1023|       |    /* Cleartext always uses param->hashes instead of param->txt_hashes */
 1024|  1.06k|    if (!param->cleartext && (stype == PGP_SIG_TEXT)) {
  ------------------
  |  Branch (1024:9): [True: 1.06k, False: 0]
  |  Branch (1024:30): [True: 998, False: 71]
  ------------------
 1025|    998|        param->txt_hashes.add_alg(halg, salt);
 1026|    998|    }
 1027|  1.06k|    param->hashes.add_alg(halg, salt);
 1028|  1.06k|}
stream-parse.cpp:_ZL16add_hash_for_sigP25pgp_source_signed_param_t14pgp_sig_type_t14pgp_hash_alg_t:
 1008|  5.57k|{
 1009|       |    /* Cleartext always uses param->hashes instead of param->txt_hashes */
 1010|  5.57k|    if (!param->cleartext && (stype == PGP_SIG_TEXT)) {
  ------------------
  |  Branch (1010:9): [True: 5.57k, False: 0]
  |  Branch (1010:30): [True: 2.63k, False: 2.93k]
  ------------------
 1011|  2.63k|        param->txt_hashes.add_alg(halg);
 1012|  2.63k|    }
 1013|  5.57k|    param->hashes.add_alg(halg);
 1014|  5.57k|}
stream-parse.cpp:_ZL28signed_read_single_signatureP25pgp_source_signed_param_tP12pgp_source_tPPN3pgp3pkt9SignatureE:
 1230|  56.5k|{
 1231|  56.5k|    uint8_t ptag;
 1232|  56.5k|    if (!readsrc->peek_eq(&ptag, 1)) {
  ------------------
  |  Branch (1232:9): [True: 1.49k, False: 55.0k]
  ------------------
 1233|  1.49k|        RNP_LOG("failed to read signature packet header");
  ------------------
  |  |   84|  1.49k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.49k|    do {                                                                                 \
  |  |  |  |   77|  1.49k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.49k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.49k|            break;                                                                       \
  |  |  |  |   79|  1.49k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1234|  1.49k|        return RNP_ERROR_READ;
 1235|  1.49k|    }
 1236|       |
 1237|  55.0k|    int ptype = get_packet_type(ptag);
 1238|  55.0k|    if (ptype != PGP_PKT_SIGNATURE) {
  ------------------
  |  Branch (1238:9): [True: 38, False: 54.9k]
  ------------------
 1239|     38|        RNP_LOG("unexpected packet %d", ptype);
  ------------------
  |  |   84|     38|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     38|    do {                                                                                 \
  |  |  |  |   77|     38|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 38, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     38|            break;                                                                       \
  |  |  |  |   79|     38|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1240|     38|        return RNP_ERROR_BAD_FORMAT;
 1241|     38|    }
 1242|       |
 1243|  54.9k|    if (param->siginfos.size() >= MAX_SIGNATURES) {
  ------------------
  |  | 1224|  54.9k|#define MAX_SIGNATURES 16384
  ------------------
  |  Branch (1243:9): [True: 0, False: 54.9k]
  ------------------
 1244|      0|        RNP_LOG("Too many signatures in the stream.");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1245|      0|        return RNP_ERROR_BAD_FORMAT;
 1246|      0|    }
 1247|       |
 1248|  54.9k|    try {
 1249|  54.9k|        param->siginfos.emplace_back();
 1250|  54.9k|        rnp::SignatureInfo &siginfo = param->siginfos.back();
 1251|  54.9k|        pgp::pkt::Signature readsig;
 1252|  54.9k|        if (readsig.parse(*readsrc)) {
  ------------------
  |  Branch (1252:13): [True: 52.8k, False: 2.12k]
  ------------------
 1253|  52.8k|            RNP_LOG("failed to parse signature");
  ------------------
  |  |   84|  52.8k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  52.8k|    do {                                                                                 \
  |  |  |  |   77|  52.8k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 52.8k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  52.8k|            break;                                                                       \
  |  |  |  |   79|  52.8k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1254|  52.8k|            siginfo.validity.add_error(RNP_ERROR_SIG_PARSE_ERROR);
 1255|  52.8k|            if (sig) {
  ------------------
  |  Branch (1255:17): [True: 52.8k, False: 0]
  ------------------
 1256|  52.8k|                *sig = NULL;
 1257|  52.8k|            }
 1258|  52.8k|            return RNP_SUCCESS;
 1259|  52.8k|        }
 1260|  2.12k|        param->sigs.push_back(std::move(readsig));
 1261|  2.12k|        siginfo.sig = &param->sigs.back();
 1262|  2.12k|        if (sig) {
  ------------------
  |  Branch (1262:13): [True: 2.12k, False: 0]
  ------------------
 1263|  2.12k|            *sig = siginfo.sig;
 1264|  2.12k|        }
 1265|  2.12k|        return RNP_SUCCESS;
 1266|  54.9k|    } catch (const std::exception &e) {
 1267|       |        /* LCOV_EXCL_START */
 1268|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1269|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1270|       |        /* LCOV_EXCL_END */
 1271|      0|    }
 1272|  54.9k|}
stream-parse.cpp:_ZL21init_armored_sequenceR20pgp_processing_ctx_tR12pgp_source_t:
 3035|  5.02k|{
 3036|  5.02k|    pgp_source_t armorsrc = {};
 3037|  5.02k|    rnp_result_t res;
 3038|       |
 3039|  5.02k|    if ((res = init_armored_src(&armorsrc, &src))) {
  ------------------
  |  Branch (3039:9): [True: 0, False: 5.02k]
  ------------------
 3040|      0|        return res;
 3041|      0|    }
 3042|       |
 3043|  5.02k|    try {
 3044|  5.02k|        ctx.sources.push_back(armorsrc);
 3045|  5.02k|    } catch (const std::exception &e) {
 3046|       |        /* LCOV_EXCL_START */
 3047|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3048|      0|        armorsrc.close();
 3049|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 3050|       |        /* LCOV_EXCL_END */
 3051|      0|    }
 3052|  5.02k|    return init_packet_sequence(ctx, ctx.sources.back());
 3053|  5.02k|}
stream-parse.cpp:_ZL17signed_src_updateP12pgp_source_tPKvm:
 1118|  11.9k|{
 1119|  11.9k|    if (!len) {
  ------------------
  |  Branch (1119:9): [True: 0, False: 11.9k]
  ------------------
 1120|      0|        return;
 1121|      0|    }
 1122|       |    /* check for extremely unlikely pointer overflow/wrap case */
 1123|  11.9k|    if (((uint8_t *) buf + len) < ((uint8_t *) buf + len - 1)) {
  ------------------
  |  Branch (1123:9): [True: 0, False: 11.9k]
  ------------------
 1124|      0|        signed_src_update(src, buf, len - 1);
 1125|      0|        uint8_t last = *((uint8_t *) buf + len - 1);
 1126|      0|        signed_src_update(src, &last, 1);
 1127|      0|    }
 1128|  11.9k|    pgp_source_signed_param_t *param = (pgp_source_signed_param_t *) src->param;
 1129|  11.9k|    try {
 1130|  11.9k|        param->hashes.add(buf, len);
 1131|  11.9k|    } catch (const std::exception &e) {
 1132|      0|        RNP_LOG("%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1133|      0|    }
 1134|       |    /* update text-mode sig hashes */
 1135|  11.9k|    if (param->txt_hashes.hashes.empty()) {
  ------------------
  |  Branch (1135:9): [True: 1.60k, False: 10.3k]
  ------------------
 1136|  1.60k|        return;
 1137|  1.60k|    }
 1138|       |
 1139|  10.3k|    uint8_t *ch = (uint8_t *) buf;
 1140|  10.3k|    uint8_t *linebeg = ch;
 1141|  10.3k|    uint8_t *end = (uint8_t *) buf + len;
 1142|       |    /* we support LF and CRLF line endings */
 1143|   311M|    while (ch < end) {
  ------------------
  |  Branch (1143:12): [True: 311M, False: 10.3k]
  ------------------
 1144|       |        /* continue if not reached LF */
 1145|   311M|        if (*ch != CH_LF) {
  ------------------
  |  |   32|   311M|#define CH_LF ('\n')
  ------------------
  |  Branch (1145:13): [True: 294M, False: 16.9M]
  ------------------
 1146|   294M|            if (*ch != CH_CR && param->stripped_crs > 0) {
  ------------------
  |  |   31|   588M|#define CH_CR ('\r')
  ------------------
  |  Branch (1146:17): [True: 257M, False: 36.9M]
  |  Branch (1146:33): [True: 934, False: 257M]
  ------------------
 1147|  2.80M|                while (param->stripped_crs--) {
  ------------------
  |  Branch (1147:24): [True: 2.80M, False: 934]
  ------------------
 1148|  2.80M|                    try {
 1149|  2.80M|                        param->txt_hashes.add(ST_CR, 1);
  ------------------
  |  |   38|  2.80M|#define ST_CR ("\r")
  ------------------
 1150|  2.80M|                    } catch (const std::exception &e) {
 1151|      0|                        RNP_LOG("%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1152|      0|                    }
 1153|  2.80M|                }
 1154|    934|                param->stripped_crs = 0;
 1155|    934|            }
 1156|       |
 1157|   294M|            if (!param->max_line_warn && param->text_line_len >= MAXIMUM_GNUPG_LINELEN) {
  ------------------
  |  |   74|  21.9M|#define MAXIMUM_GNUPG_LINELEN 19995
  ------------------
  |  Branch (1157:17): [True: 21.9M, False: 272M]
  |  Branch (1157:42): [True: 214, False: 21.9M]
  ------------------
 1158|    214|                RNP_LOG("Canonical text document signature: line is too long, may cause "
  ------------------
  |  |   84|    214|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    214|    do {                                                                                 \
  |  |  |  |   77|    214|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 214, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    214|            break;                                                                       \
  |  |  |  |   79|    214|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1159|    214|                        "incompatibility with other implementations. Consider using binary "
 1160|    214|                        "signature instead.");
 1161|    214|                param->max_line_warn = true;
 1162|    214|            }
 1163|       |
 1164|   294M|            ch++;
 1165|   294M|            param->text_line_len++;
 1166|   294M|            continue;
 1167|   294M|        }
 1168|       |        /* reached eol: dump line contents */
 1169|  16.9M|        param->stripped_crs = 0;
 1170|  16.9M|        param->text_line_len = 0;
 1171|  16.9M|        if (ch > linebeg) {
  ------------------
  |  Branch (1171:13): [True: 11.2M, False: 5.70M]
  ------------------
 1172|  11.2M|            long stripped_len = stripped_line_len(linebeg, ch);
 1173|  11.2M|            if (stripped_len > 0) {
  ------------------
  |  Branch (1173:17): [True: 9.74M, False: 1.50M]
  ------------------
 1174|  9.74M|                try {
 1175|  9.74M|                    param->txt_hashes.add(linebeg, stripped_len);
 1176|  9.74M|                } catch (const std::exception &e) {
 1177|      0|                    RNP_LOG("%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1178|      0|                }
 1179|  9.74M|            }
 1180|  11.2M|        }
 1181|       |        /* dump EOL */
 1182|  16.9M|        try {
 1183|  16.9M|            param->txt_hashes.add(ST_CRLF, 2);
  ------------------
  |  |   40|  16.9M|#define ST_CRLF ("\r\n")
  ------------------
 1184|  16.9M|        } catch (const std::exception &e) {
 1185|      0|            RNP_LOG("%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1186|      0|        }
 1187|  16.9M|        ch++;
 1188|  16.9M|        linebeg = ch;
 1189|  16.9M|    }
 1190|       |    /* check if we have undumped line contents */
 1191|  10.3k|    if (linebeg < end) {
  ------------------
  |  Branch (1191:9): [True: 9.75k, False: 622]
  ------------------
 1192|  9.75k|        long stripped_len = stripped_line_len(linebeg, end - 1);
 1193|  9.75k|        if (stripped_len < end - linebeg) {
  ------------------
  |  Branch (1193:13): [True: 1.40k, False: 8.35k]
  ------------------
 1194|  1.40k|            param->stripped_crs = end - linebeg - stripped_len;
 1195|  1.40k|        }
 1196|  9.75k|        if (stripped_len > 0) {
  ------------------
  |  Branch (1196:13): [True: 9.33k, False: 425]
  ------------------
 1197|  9.33k|            try {
 1198|  9.33k|                param->txt_hashes.add(linebeg, stripped_len);
 1199|  9.33k|            } catch (const std::exception &e) {
 1200|      0|                RNP_LOG("%s", e.what()); // LCOV_EXCL_LINE
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1201|      0|            }
 1202|  9.33k|        }
 1203|  9.75k|    }
 1204|  10.3k|}
stream-parse.cpp:_ZL17stripped_line_lenPhS_:
 1098|  11.2M|{
 1099|  11.2M|    uint8_t *stripped_end = end;
 1100|       |
 1101|  37.4M|    while (stripped_end >= begin && (*stripped_end == CH_CR || *stripped_end == CH_LF)) {
  ------------------
  |  |   31|  71.9M|#define CH_CR ('\r')
  ------------------
                  while (stripped_end >= begin && (*stripped_end == CH_CR || *stripped_end == CH_LF)) {
  ------------------
  |  |   32|  21.0M|#define CH_LF ('\n')
  ------------------
  |  Branch (1101:12): [True: 35.9M, False: 1.50M]
  |  Branch (1101:38): [True: 14.9M, False: 21.0M]
  |  Branch (1101:64): [True: 11.2M, False: 9.75M]
  ------------------
 1102|  26.2M|        stripped_end--;
 1103|  26.2M|    }
 1104|       |
 1105|  11.2M|    return stripped_end - begin + 1;
 1106|  11.2M|}
stream-parse.cpp:_ZL26signed_src_set_literal_hdrR12pgp_source_tRK17pgp_literal_hdr_t:
 1110|  1.36k|{
 1111|  1.36k|    auto param = static_cast<pgp_source_signed_param_t *>(src.param);
 1112|  1.36k|    param->lhdr = hdr;
 1113|  1.36k|    param->has_lhdr = true;
 1114|  1.36k|}

_Z18signature_hash_keyRK13pgp_key_pkt_tRN3rnp4HashE13pgp_version_t:
   53|  45.1k|{
   54|  45.1k|    if (key.pub_data.empty()) {
  ------------------
  |  Branch (54:9): [True: 0, False: 45.1k]
  ------------------
   55|       |        /* call self recursively if hashed data is not filled, to overcome const restriction */
   56|      0|        pgp_key_pkt_t keycp(key, true);
   57|      0|        keycp.fill_hashed_data();
   58|      0|        signature_hash_key(keycp, hash, pgpver);
   59|      0|        return;
   60|      0|    }
   61|       |
   62|  45.1k|    switch (pgpver) {
   63|     31|    case PGP_V2:
  ------------------
  |  Branch (63:5): [True: 31, False: 45.0k]
  ------------------
   64|     31|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     31|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   65|     38|    case PGP_V3:
  ------------------
  |  Branch (65:5): [True: 7, False: 45.1k]
  ------------------
   66|     38|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|     38|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
   67|  43.1k|    case PGP_V4: {
  ------------------
  |  Branch (67:5): [True: 43.1k, False: 1.99k]
  ------------------
   68|       |        /* A v4 fingerprint can only address up to 65535 octets of key data;
   69|       |         * larger key packets cannot have a valid v4 fingerprint. */
   70|  43.1k|        if (key.pub_data.size() > 0xffffu) {
  ------------------
  |  Branch (70:13): [True: 0, False: 43.1k]
  ------------------
   71|      0|            RNP_LOG("v4 key packet too large for a fingerprint");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   72|      0|            throw rnp::rnp_exception(RNP_ERROR_BAD_FORMAT);
   73|      0|        }
   74|  43.1k|        uint8_t hdr[3] = {0x99, 0x00, 0x00};
   75|  43.1k|        write_uint16(hdr + 1, key.pub_data.size());
   76|  43.1k|        hash.add(hdr, 3);
   77|  43.1k|        hash.add(key.pub_data);
   78|  43.1k|        break;
   79|  43.1k|    }
   80|      7|    case PGP_V5: {
  ------------------
  |  Branch (80:5): [True: 7, False: 45.1k]
  ------------------
   81|      7|        if (key.pub_data.size() > 0xffffffffu) {
  ------------------
  |  Branch (81:13): [True: 0, False: 7]
  ------------------
   82|      0|            RNP_LOG("key packet too large for a fingerprint");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   83|      0|            throw rnp::rnp_exception(RNP_ERROR_BAD_FORMAT);
   84|      0|        }
   85|      7|        uint8_t hdr[5] = {0x9A, 0x00, 0x00, 0x00, 0x00};
   86|      7|        write_uint32(hdr + 1, key.pub_data.size());
   87|      7|        hash.add(&hdr, 5);
   88|      7|        hash.add(key.pub_data);
   89|      7|        break;
   90|      7|    }
   91|      0|#if defined(ENABLE_CRYPTO_REFRESH)
   92|  1.94k|    case PGP_V6: {
  ------------------
  |  Branch (92:5): [True: 1.94k, False: 43.1k]
  ------------------
   93|  1.94k|        if (key.pub_data.size() > 0xffffffffu) {
  ------------------
  |  Branch (93:13): [True: 0, False: 1.94k]
  ------------------
   94|      0|            RNP_LOG("key packet too large for a fingerprint");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   95|      0|            throw rnp::rnp_exception(RNP_ERROR_BAD_FORMAT);
   96|      0|        }
   97|  1.94k|        uint8_t hdr[5] = {0x9b, 0x00, 0x00, 0x00, 0x00};
   98|  1.94k|        write_uint32(hdr + 1, key.pub_data.size());
   99|  1.94k|        hash.add(hdr, sizeof(hdr));
  100|  1.94k|        hash.add(key.pub_data);
  101|  1.94k|        break;
  102|  1.94k|    }
  103|      0|#endif
  104|      0|    default:
  ------------------
  |  Branch (104:5): [True: 0, False: 45.1k]
  ------------------
  105|      0|        RNP_LOG("unknown key/sig version: %d", (int) pgpver);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  106|      0|        throw rnp::rnp_exception(RNP_ERROR_OUT_OF_MEMORY);
  107|  45.1k|    }
  108|  45.1k|}
_Z21signature_hash_useridRK16pgp_userid_pkt_tRN3rnp4HashE13pgp_version_t:
  112|  6.20k|{
  113|  6.20k|    if (sigver < PGP_V4) {
  ------------------
  |  Branch (113:9): [True: 0, False: 6.20k]
  ------------------
  114|      0|        hash.add(uid.uid.data(), uid.uid.size());
  115|      0|        return;
  116|      0|    }
  117|       |
  118|  6.20k|    uint8_t hdr[5] = {0};
  119|  6.20k|    switch (uid.tag) {
  120|  6.19k|    case PGP_PKT_USER_ID:
  ------------------
  |  Branch (120:5): [True: 6.19k, False: 17]
  ------------------
  121|  6.19k|        hdr[0] = 0xB4;
  122|  6.19k|        break;
  123|     17|    case PGP_PKT_USER_ATTR:
  ------------------
  |  Branch (123:5): [True: 17, False: 6.19k]
  ------------------
  124|     17|        hdr[0] = 0xD1;
  125|     17|        break;
  126|      0|    default:
  ------------------
  |  Branch (126:5): [True: 0, False: 6.20k]
  ------------------
  127|      0|        RNP_LOG("wrong uid");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  128|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
  129|  6.20k|    }
  130|  6.20k|    write_uint32(hdr + 1, uid.uid.size());
  131|  6.20k|    hash.add(hdr, 5);
  132|  6.20k|    hash.add(uid.uid.data(), uid.uid.size());
  133|  6.20k|}
_Z28signature_hash_certificationRKN3pgp3pkt9SignatureERK13pgp_key_pkt_tRK16pgp_userid_pkt_t:
  139|  6.22k|{
  140|  6.22k|    auto hash = signature_init(key, sig);
  141|  6.22k|    signature_hash_key(key, *hash, sig.version);
  142|  6.22k|    signature_hash_userid(userid, *hash, sig.version);
  143|  6.22k|    return hash;
  144|  6.22k|}
_Z22signature_hash_bindingRKN3pgp3pkt9SignatureERK13pgp_key_pkt_tS6_:
  150|  4.89k|{
  151|  4.89k|    auto hash = signature_init(key, sig);
  152|  4.89k|    signature_hash_key(key, *hash, sig.version);
  153|  4.89k|    signature_hash_key(subkey, *hash, sig.version);
  154|  4.89k|    return hash;
  155|  4.89k|}
_Z21signature_hash_directRKN3pgp3pkt9SignatureERK13pgp_key_pkt_t:
  159|    299|{
  160|    299|    auto hash = signature_init(key, sig);
  161|    299|    signature_hash_key(key, *hash, sig.version);
  162|    299|    return hash;
  163|    299|}
_ZNK3pgp3pkt9Signature6get_idEv:
  228|  81.6k|{
  229|  81.6k|    auto hash = rnp::Hash::create(PGP_HASH_SHA1);
  230|  81.6k|    hash->add(hashed_data);
  231|  81.6k|#if defined(ENABLE_CRYPTO_REFRESH)
  232|       |    /* v6 salt is not a part of the hashed data - cover it, but keep v4 id input unchanged */
  233|  81.6k|    if (version == PGP_V6) {
  ------------------
  |  Branch (233:9): [True: 44, False: 81.5k]
  ------------------
  234|     44|        hash->add(salt);
  235|     44|    }
  236|  81.6k|#endif
  237|  81.6k|    hash->add(material_buf);
  238|  81.6k|    SigID res = {0};
  239|  81.6k|    static_assert(std::tuple_size<decltype(res)>::value == PGP_SHA1_HASH_SIZE,
  240|  81.6k|                  "SigID size mismatch");
  241|  81.6k|    hash->finish(res.data());
  242|  81.6k|    return res;
  243|  81.6k|}
_ZN3pgp3pkt9Signature10get_subpktEhb:
  247|  2.41k|{
  248|  2.41k|    size_t idx = find_subpkt(stype, hashed);
  249|  2.41k|    return idx == SIZE_MAX ? nullptr : subpkts[idx].get();
  ------------------
  |  Branch (249:12): [True: 2.41k, False: 0]
  ------------------
  250|  2.41k|}
_ZNK3pgp3pkt9Signature10get_subpktEhb:
  254|   439k|{
  255|   439k|    size_t idx = find_subpkt(stype, hashed);
  256|   439k|    return idx == SIZE_MAX ? nullptr : subpkts[idx].get();
  ------------------
  |  Branch (256:12): [True: 91.0k, False: 348k]
  ------------------
  257|   439k|}
_ZN3pgp3pkt9Signature10get_subpktENS0_6sigsub4TypeEb:
  261|  2.41k|{
  262|  2.41k|    return get_subpkt(static_cast<uint8_t>(type), hashed);
  263|  2.41k|}
_ZNK3pgp3pkt9Signature10get_subpktENS0_6sigsub4TypeEb:
  267|   439k|{
  268|   439k|    return get_subpkt(static_cast<uint8_t>(type), hashed);
  269|   439k|}
_ZNK3pgp3pkt9Signature10has_subpktEhb:
  273|  32.9k|{
  274|       |    return find_subpkt(stype, hashed) != SIZE_MAX;
  275|  32.9k|}
_ZNK3pgp3pkt9Signature20has_unknown_criticalEv:
  279|  11.3k|{
  280|  67.9k|    for (const auto &sub : subpkts.items) {
  ------------------
  |  Branch (280:26): [True: 67.9k, False: 10.3k]
  ------------------
  281|       |        /* unhashed area is not covered by the signature, so anyone may add a subpacket
  282|       |         * there: do not let it change the signature's validity */
  283|  67.9k|        if (sub->hashed() && (sub->type() == sigsub::Type::Unknown) && sub->critical()) {
  ------------------
  |  Branch (283:13): [True: 57.5k, False: 10.3k]
  |  Branch (283:30): [True: 2.36k, False: 55.2k]
  |  Branch (283:72): [True: 987, False: 1.37k]
  ------------------
  284|    987|            return true;
  285|    987|        }
  286|  67.9k|    }
  287|  10.3k|    return false;
  288|  11.3k|}
_ZNK3pgp3pkt9Signature9has_keyidEv:
  292|  70.2k|{
  293|  70.2k|    return (version < PGP_V4) || has_subpkt(PGP_SIG_SUBPKT_ISSUER_KEY_ID, false) ||
  ------------------
  |  Branch (293:12): [True: 53.3k, False: 16.9k]
  |  Branch (293:34): [True: 13.3k, False: 3.57k]
  ------------------
  294|  3.57k|           has_keyfp();
  ------------------
  |  Branch (294:12): [True: 3, False: 3.57k]
  ------------------
  295|  70.2k|}
_ZNK3pgp3pkt9Signature5keyidEv:
  299|  66.6k|{
  300|       |    /* version 3 uses signature field */
  301|  66.6k|    if (version < PGP_V4) {
  ------------------
  |  Branch (301:9): [True: 53.2k, False: 13.3k]
  ------------------
  302|  53.2k|        return signer;
  303|  53.2k|    }
  304|       |
  305|       |    /* version 4 and up use subpackets */
  306|  13.3k|    if (version == PGP_V4) {
  ------------------
  |  Branch (306:9): [True: 12.8k, False: 517]
  ------------------
  307|  12.8k|        auto sub = dynamic_cast<const sigsub::IssuerKeyID *>(
  308|  12.8k|          get_subpkt(sigsub::Type::IssuerKeyID, false));
  309|  12.8k|        if (sub) {
  ------------------
  |  Branch (309:13): [True: 12.8k, False: 1]
  ------------------
  310|  12.8k|            return sub->keyid();
  311|  12.8k|        }
  312|  12.8k|    }
  313|       |    /* v5 and up must have fingerprint, from which keyid would be extracted */
  314|    518|    return keyfp().keyid();
  315|  13.3k|}
_ZNK3pgp3pkt9Signature9has_keyfpEv:
  332|   172k|{
  333|   172k|    auto sub = dynamic_cast<const sigsub::IssuerFingerprint *>(
  334|   172k|      get_subpkt(sigsub::Type::IssuerFingerprint));
  335|   172k|    if (!sub) {
  ------------------
  |  Branch (335:9): [True: 74.9k, False: 97.4k]
  ------------------
  336|  74.9k|        return false;
  337|  74.9k|    }
  338|  97.4k|    switch (version) {
  339|  95.7k|    case PGP_V4:
  ------------------
  |  Branch (339:5): [True: 95.7k, False: 1.69k]
  ------------------
  340|  95.7k|        return sub->fp().size() == PGP_FINGERPRINT_V4_SIZE;
  ------------------
  |  |   43|  95.7k|#define PGP_FINGERPRINT_V4_SIZE 20
  ------------------
  341|  1.52k|    case PGP_V5:
  ------------------
  |  Branch (341:5): [True: 1.52k, False: 95.9k]
  ------------------
  342|  1.52k|#if defined(ENABLE_CRYPTO_REFRESH)
  343|  1.69k|    case PGP_V6:
  ------------------
  |  Branch (343:5): [True: 178, False: 97.2k]
  ------------------
  344|  1.69k|#endif
  345|  1.69k|        return sub->fp().size() == PGP_FINGERPRINT_V5_SIZE;
  ------------------
  |  |   44|  1.69k|#define PGP_FINGERPRINT_V5_SIZE 32
  ------------------
  346|      0|    default:
  ------------------
  |  Branch (346:5): [True: 0, False: 97.4k]
  ------------------
  347|      0|        return false;
  348|  97.4k|    }
  349|  97.4k|}
_ZNK3pgp3pkt9Signature5keyfpEv:
  353|  93.6k|{
  354|  93.6k|    auto sub = dynamic_cast<const sigsub::IssuerFingerprint *>(
  355|  93.6k|      get_subpkt(sigsub::Type::IssuerFingerprint));
  356|  93.6k|    return sub ? sub->fp() : Fingerprint{};
  ------------------
  |  Branch (356:12): [True: 93.4k, False: 219]
  ------------------
  357|  93.6k|}
_ZNK3pgp3pkt9Signature25issuer_fp_version_matchesEv:
  361|  94.6k|{
  362|  94.6k|    auto sub = dynamic_cast<const sigsub::IssuerFingerprint *>(
  363|  94.6k|      get_subpkt(sigsub::Type::IssuerFingerprint));
  364|  94.6k|    if (!sub) {
  ------------------
  |  Branch (364:9): [True: 0, False: 94.6k]
  ------------------
  365|      0|        return false;
  366|      0|    }
  367|       |    /* Same hashed subpacket as has_keyfp()/keyfp(). v5 is intentionally not enforced:
  368|       |     * LibrePGP describes the version octet but does not require receivers to reject a
  369|       |     * mismatch, and this library used to emit 4 for v5 signatures. */
  370|  94.6k|    if (version == PGP_V4) {
  ------------------
  |  Branch (370:9): [True: 94.4k, False: 186]
  ------------------
  371|  94.4k|        return sub->version() == static_cast<uint8_t>(PGP_V4);
  372|  94.4k|    }
  373|    186|#if defined(ENABLE_CRYPTO_REFRESH)
  374|    186|    if (version == PGP_V6) {
  ------------------
  |  Branch (374:9): [True: 132, False: 54]
  ------------------
  375|    132|        return sub->version() == static_cast<uint8_t>(PGP_V6);
  376|    132|    }
  377|     54|#endif
  378|     54|    return true;
  379|    186|}
_ZNK3pgp3pkt9Signature8creationEv:
  406|  29.3k|{
  407|  29.3k|    if (version < PGP_V4) {
  ------------------
  |  Branch (407:9): [True: 3.45k, False: 25.8k]
  ------------------
  408|  3.45k|        return creation_time;
  409|  3.45k|    }
  410|  25.8k|    auto sub =
  411|  25.8k|      dynamic_cast<const sigsub::CreationTime *>(get_subpkt(sigsub::Type::CreationTime));
  412|  25.8k|    return sub ? sub->time() : 0;
  ------------------
  |  Branch (412:12): [True: 24.1k, False: 1.72k]
  ------------------
  413|  29.3k|}
_ZNK3pgp3pkt9Signature10expirationEv:
  429|  12.8k|{
  430|  12.8k|    auto sub =
  431|  12.8k|      dynamic_cast<const sigsub::ExpirationTime *>(get_subpkt(sigsub::Type::ExpirationTime));
  432|  12.8k|    return sub ? sub->time() : 0;
  ------------------
  |  Branch (432:12): [True: 1.60k, False: 11.2k]
  ------------------
  433|  12.8k|}
_ZNK3pgp3pkt9Signature14key_expirationEv:
  445|  3.67k|{
  446|  3.67k|    auto sub = dynamic_cast<const sigsub::KeyExpirationTime *>(
  447|  3.67k|      get_subpkt(sigsub::Type::KeyExpirationTime));
  448|  3.67k|    return sub ? sub->time() : 0;
  ------------------
  |  Branch (448:12): [True: 853, False: 2.82k]
  ------------------
  449|  3.67k|}
_ZNK3pgp3pkt9Signature9key_flagsEv:
  461|  6.46k|{
  462|  6.46k|    auto sub = dynamic_cast<const sigsub::KeyFlags *>(get_subpkt(sigsub::Type::KeyFlags));
  463|  6.46k|    return sub ? sub->flags() : 0;
  ------------------
  |  Branch (463:12): [True: 6.37k, False: 83]
  ------------------
  464|  6.46k|}
_ZNK3pgp3pkt9Signature17revocation_reasonEv:
  644|  8.50k|{
  645|  8.50k|    auto sub = dynamic_cast<const sigsub::RevocationReason *>(
  646|  8.50k|      get_subpkt(sigsub::Type::RevocationReason));
  647|  8.50k|    return sub ? sub->reason() : "";
  ------------------
  |  Branch (647:12): [True: 8.50k, False: 0]
  ------------------
  648|  8.50k|}
_ZNK3pgp3pkt9Signature15revocation_codeEv:
  652|  8.50k|{
  653|  8.50k|    auto sub = dynamic_cast<const sigsub::RevocationReason *>(
  654|  8.50k|      get_subpkt(sigsub::Type::RevocationReason));
  655|  8.50k|    return sub ? sub->code() : PGP_REVOCATION_NO_REASON;
  ------------------
  |  Branch (655:12): [True: 8.50k, False: 0]
  ------------------
  656|  8.50k|}
_ZNK3pgp3pkt9Signature16key_has_featuresEj:
  682|      7|{
  683|      7|    auto sub = dynamic_cast<const sigsub::Features *>(get_subpkt(sigsub::Type::Features));
  684|      7|    return sub ? sub->features() & flags : false;
  ------------------
  |  Branch (684:12): [True: 7, False: 0]
  ------------------
  685|      7|}
_ZNK3pgp3pkt9Signature15matches_onepassERK18pgp_one_pass_sig_t:
  803|     45|{
  804|     45|    if (!has_keyid()) {
  ------------------
  |  Branch (804:9): [True: 2, False: 43]
  ------------------
  805|      2|        return false;
  806|      2|    }
  807|       |    /* check sig and OPS packet version binding (V3) */
  808|     43|    if (onepass.version == PGP_OPS_V3) {
  ------------------
  |  Branch (808:9): [True: 37, False: 6]
  ------------------
  809|     37|        if (version != PGP_V3 && version != PGP_V4 && version != PGP_V5) {
  ------------------
  |  Branch (809:13): [True: 31, False: 6]
  |  Branch (809:34): [True: 16, False: 15]
  |  Branch (809:55): [True: 15, False: 1]
  ------------------
  810|     15|            return false;
  811|     15|        }
  812|     37|    }
  813|       |    /* check keyid (V3) */
  814|     28|    if (onepass.version == PGP_OPS_V3 && (onepass.keyid != keyid())) {
  ------------------
  |  Branch (814:9): [True: 22, False: 6]
  |  Branch (814:9): [True: 17, False: 11]
  |  Branch (814:42): [True: 17, False: 5]
  ------------------
  815|     17|        return false;
  816|     17|    }
  817|     11|#if defined(ENABLE_CRYPTO_REFRESH)
  818|       |    /* checks for V6 */
  819|     11|    if (onepass.version == PGP_OPS_V6) {
  ------------------
  |  Branch (819:9): [True: 6, False: 5]
  ------------------
  820|       |        /* check version binding) */
  821|      6|        if (onepass.version == PGP_OPS_V6 && version != PGP_V6) {
  ------------------
  |  Branch (821:13): [True: 6, False: 0]
  |  Branch (821:46): [True: 4, False: 2]
  ------------------
  822|      4|            return false;
  823|      4|        }
  824|       |        /* check fp */
  825|      2|        if (onepass.fp != keyfp()) {
  ------------------
  |  Branch (825:13): [True: 2, False: 0]
  ------------------
  826|      2|            return false;
  827|      2|        }
  828|       |        /* check salt */
  829|      0|        if (onepass.salt != salt) {
  ------------------
  |  Branch (829:13): [True: 0, False: 0]
  ------------------
  830|      0|            return false;
  831|      0|        }
  832|      0|    }
  833|      5|#endif
  834|       |    /* check the remaining common attributes */
  835|      5|    return (halg == onepass.halg) && (palg == onepass.palg) && (type_ == onepass.type);
  ------------------
  |  Branch (835:12): [True: 3, False: 2]
  |  Branch (835:38): [True: 2, False: 1]
  |  Branch (835:64): [True: 1, False: 1]
  ------------------
  836|     11|}
_ZN3pgp3pkt9Signature17version_supportedE13pgp_version_t:
  840|  40.8k|{
  841|  40.8k|    if ((version >= PGP_V2) && (version <= PGP_V5)) {
  ------------------
  |  Branch (841:9): [True: 40.8k, False: 0]
  |  Branch (841:32): [True: 40.7k, False: 22]
  ------------------
  842|  40.7k|        return true;
  843|  40.7k|    }
  844|     22|#if defined(ENABLE_CRYPTO_REFRESH)
  845|     22|    return version == PGP_V6;
  846|       |#else
  847|       |    return false;
  848|       |#endif
  849|  40.8k|}
_ZN3pgp3pkt9Signature10parse_v2v3ER17pgp_packet_body_t:
  853|  18.6k|{
  854|       |    /* parse v2/v3-specific fields, not the whole signature */
  855|  18.6k|    uint8_t buf[16] = {};
  856|  18.6k|    if (!pkt.get(buf, 16)) {
  ------------------
  |  Branch (856:9): [True: 57, False: 18.6k]
  ------------------
  857|     57|        RNP_LOG("cannot get enough bytes");
  ------------------
  |  |   84|     57|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     57|    do {                                                                                 \
  |  |  |  |   77|     57|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 57, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     57|            break;                                                                       \
  |  |  |  |   79|     57|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  858|     57|        return RNP_ERROR_BAD_FORMAT;
  859|     57|    }
  860|       |    /* length of hashed data, 5 */
  861|  18.6k|    if (buf[0] != 5) {
  ------------------
  |  Branch (861:9): [True: 860, False: 17.7k]
  ------------------
  862|    860|        RNP_LOG("wrong length of hashed data");
  ------------------
  |  |   84|    860|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    860|    do {                                                                                 \
  |  |  |  |   77|    860|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 860, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    860|            break;                                                                       \
  |  |  |  |   79|    860|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  863|    860|        return RNP_ERROR_BAD_FORMAT;
  864|    860|    }
  865|       |    /* hashed data */
  866|  17.7k|    hashed_data.assign(buf + 1, buf + 6);
  867|       |    /* signature type */
  868|  17.7k|    type_ = (pgp_sig_type_t) buf[1];
  869|       |    /* creation time */
  870|  17.7k|    creation_time = read_uint32(&buf[2]);
  871|       |    /* signer's key id */
  872|  17.7k|    static_assert(std::tuple_size<decltype(signer)>::value == PGP_KEY_ID_SIZE,
  873|  17.7k|                  "v3 signer field size mismatch");
  874|  17.7k|    memcpy(signer.data(), &buf[6], PGP_KEY_ID_SIZE);
  ------------------
  |  |   39|  17.7k|#define PGP_KEY_ID_SIZE 8
  ------------------
  875|       |    /* public key algorithm */
  876|  17.7k|    palg = (pgp_pubkey_alg_t) buf[14];
  877|       |    /* hash algorithm */
  878|  17.7k|    halg = (pgp_hash_alg_t) buf[15];
  879|  17.7k|    return RNP_SUCCESS;
  880|  18.6k|}
_ZN3pgp3pkt9Signature16parse_subpacketsEPhmbm:
  886|  73.1k|{
  887|  73.1k|    bool res = true;
  888|       |
  889|   293k|    while (len) {
  ------------------
  |  Branch (889:12): [True: 228k, False: 64.8k]
  ------------------
  890|   228k|        if (subpkts.size() >= MAX_SUBPACKETS) {
  ------------------
  |  |  882|   228k|#define MAX_SUBPACKETS 64
  ------------------
  |  Branch (890:13): [True: 8, False: 228k]
  ------------------
  891|      8|            RNP_LOG("too many signature subpackets");
  ------------------
  |  |   84|      8|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      8|    do {                                                                                 \
  |  |  |  |   77|      8|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 8, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      8|            break;                                                                       \
  |  |  |  |   79|      8|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  892|      8|            return false;
  893|      8|        }
  894|   228k|        if (len < 2) {
  ------------------
  |  Branch (894:13): [True: 162, False: 228k]
  ------------------
  895|    162|            RNP_LOG("got single byte %" PRIu8, *buf);
  ------------------
  |  |   84|    162|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    162|    do {                                                                                 \
  |  |  |  |   77|    162|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 162, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    162|            break;                                                                       \
  |  |  |  |   79|    162|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  896|    162|            return false;
  897|    162|        }
  898|       |
  899|       |        /* subpacket length */
  900|   228k|        size_t splen = *buf++;
  901|   228k|        len--;
  902|   228k|        if ((splen >= 192) && (splen < 255)) {
  ------------------
  |  Branch (902:13): [True: 4.00k, False: 224k]
  |  Branch (902:31): [True: 3.76k, False: 235]
  ------------------
  903|  3.76k|            splen = ((splen - 192) << 8) + *buf++ + 192;
  904|  3.76k|            len--;
  905|   224k|        } else if (splen == 255) {
  ------------------
  |  Branch (905:20): [True: 235, False: 224k]
  ------------------
  906|    235|            if (len < 4) {
  ------------------
  |  Branch (906:17): [True: 25, False: 210]
  ------------------
  907|     25|                RNP_LOG("got 4-byte len but only %zu bytes in buffer", len);
  ------------------
  |  |   84|     25|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     25|    do {                                                                                 \
  |  |  |  |   77|     25|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 25, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     25|            break;                                                                       \
  |  |  |  |   79|     25|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  908|     25|                return false;
  909|     25|            }
  910|    210|            splen = read_uint32(buf);
  911|    210|            buf += 4;
  912|    210|            len -= 4;
  913|    210|        }
  914|       |
  915|   228k|        if (!splen) {
  ------------------
  |  Branch (915:13): [True: 334, False: 227k]
  ------------------
  916|    334|            RNP_LOG("got subpacket with 0 length");
  ------------------
  |  |   84|    334|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    334|    do {                                                                                 \
  |  |  |  |   77|    334|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 334, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    334|            break;                                                                       \
  |  |  |  |   79|    334|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  917|    334|            return false;
  918|    334|        }
  919|       |
  920|       |        /* subpacket data */
  921|   227k|        if (len < splen) {
  ------------------
  |  Branch (921:13): [True: 7.78k, False: 220k]
  ------------------
  922|  7.78k|            RNP_LOG("got subpacket len %zu, while only %zu bytes left", splen, len);
  ------------------
  |  |   84|  7.78k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  7.78k|    do {                                                                                 \
  |  |  |  |   77|  7.78k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7.78k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  7.78k|            break;                                                                       \
  |  |  |  |   79|  7.78k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  923|  7.78k|            return false;
  924|  7.78k|        }
  925|       |
  926|   220k|        auto subpkt = sigsub::Raw::create(buf, splen, hashed, depth);
  927|   220k|        if (!subpkt) {
  ------------------
  |  Branch (927:13): [True: 5.54k, False: 214k]
  ------------------
  928|  5.54k|            res = false;
  929|   214k|        } else {
  930|   214k|            subpkts.items.push_back(std::move(subpkt));
  931|   214k|        }
  932|   220k|        len -= splen;
  933|   220k|        buf += splen;
  934|   220k|    }
  935|  64.8k|    return res;
  936|  73.1k|}
_ZN3pgp3pkt9Signature14get_subpkt_lenER17pgp_packet_body_tRm:
  940|  75.9k|{
  941|  75.9k|    switch (version) {
  942|  73.3k|    case PGP_V4:
  ------------------
  |  Branch (942:5): [True: 73.3k, False: 2.60k]
  ------------------
  943|  74.7k|    case PGP_V5: {
  ------------------
  |  Branch (943:5): [True: 1.38k, False: 74.6k]
  ------------------
  944|  74.7k|        uint16_t len = 0;
  945|  74.7k|        if (!pkt.get(len)) {
  ------------------
  |  Branch (945:13): [True: 47, False: 74.7k]
  ------------------
  946|     47|            return false;
  947|     47|        }
  948|  74.7k|        splen = len;
  949|  74.7k|        return true;
  950|  74.7k|    }
  951|      0|#if defined(ENABLE_CRYPTO_REFRESH)
  952|  1.21k|    case PGP_V6: {
  ------------------
  |  Branch (952:5): [True: 1.21k, False: 74.7k]
  ------------------
  953|  1.21k|        uint32_t len = 0;
  954|  1.21k|        if (!pkt.get(len)) {
  ------------------
  |  Branch (954:13): [True: 74, False: 1.14k]
  ------------------
  955|     74|            return false;
  956|     74|        }
  957|  1.14k|        splen = len;
  958|  1.14k|        return true;
  959|  1.21k|    }
  960|      0|#endif
  961|      0|    default:
  ------------------
  |  Branch (961:5): [True: 0, False: 75.9k]
  ------------------
  962|      0|        RNP_LOG("unsupported signature version: %d", (int) version);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  963|      0|        return false;
  964|  75.9k|    }
  965|  75.9k|}
_ZNK3pgp3pkt9Signature11find_subpktEhbm:
  969|   474k|{
  970|   474k|    if (version < PGP_V4) {
  ------------------
  |  Branch (970:9): [True: 55.4k, False: 419k]
  ------------------
  971|  55.4k|        return SIZE_MAX;
  972|  55.4k|    }
  973|  1.65M|    for (size_t idx = 0; idx < subpkts.size(); idx++) {
  ------------------
  |  Branch (973:26): [True: 1.60M, False: 42.8k]
  ------------------
  974|  1.60M|        if ((subpkts[idx]->raw_type() != stype) || (hashed && !subpkts[idx]->hashed())) {
  ------------------
  |  Branch (974:13): [True: 1.23M, False: 376k]
  |  Branch (974:53): [True: 350k, False: 26.2k]
  |  Branch (974:63): [True: 8, False: 350k]
  ------------------
  975|  1.23M|            continue;
  976|  1.23M|        }
  977|   376k|        if (!skip) {
  ------------------
  |  Branch (977:13): [True: 376k, False: 0]
  ------------------
  978|   376k|            return idx;
  979|   376k|        }
  980|      0|        skip--;
  981|      0|    }
  982|  42.8k|    return SIZE_MAX;
  983|   419k|}
_ZN3pgp3pkt9Signature10parse_v4upER17pgp_packet_body_tm:
  993|  43.8k|{
  994|       |    /* parse v4 (and up) specific fields, not the whole signature */
  995|  43.8k|    uint8_t buf[3];
  996|  43.8k|    if (!pkt.get(buf, 3)) {
  ------------------
  |  Branch (996:9): [True: 1.27k, False: 42.5k]
  ------------------
  997|  1.27k|        RNP_LOG("cannot get first 3 bytes");
  ------------------
  |  |   84|  1.27k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.27k|    do {                                                                                 \
  |  |  |  |   77|  1.27k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.27k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.27k|            break;                                                                       \
  |  |  |  |   79|  1.27k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  998|  1.27k|        return RNP_ERROR_BAD_FORMAT;
  999|  1.27k|    }
 1000|       |
 1001|       |    /* signature type */
 1002|  42.5k|    type_ = (pgp_sig_type_t) buf[0];
 1003|       |    /* public key algorithm */
 1004|  42.5k|    palg = (pgp_pubkey_alg_t) buf[1];
 1005|       |    /* hash algorithm */
 1006|  42.5k|    halg = (pgp_hash_alg_t) buf[2];
 1007|       |    /* hashed subpackets length */
 1008|       |
 1009|  42.5k|    size_t splen = 0;
 1010|  42.5k|    auto   hash_begin = pkt.cur();
 1011|  42.5k|    if (!get_subpkt_len(pkt, splen)) {
  ------------------
  |  Branch (1011:9): [True: 121, False: 42.4k]
  ------------------
 1012|    121|        RNP_LOG("cannot get hashed len");
  ------------------
  |  |   84|    121|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    121|    do {                                                                                 \
  |  |  |  |   77|    121|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 121, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    121|            break;                                                                       \
  |  |  |  |   79|    121|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1013|    121|        return RNP_ERROR_BAD_FORMAT;
 1014|    121|    }
 1015|  42.4k|    size_t splen_size = pkt.cur() - hash_begin;
 1016|       |    /* hashed subpackets length + splen_size bytes of length of unhashed subpackets. v6 splen
 1017|       |     * is 32-bit, so do not add it to anything: the sum may wrap with a 32-bit size_t. */
 1018|  42.4k|    if ((splen > pkt.left()) || (pkt.left() - splen < splen_size)) {
  ------------------
  |  Branch (1018:9): [True: 1.11k, False: 41.3k]
  |  Branch (1018:33): [True: 6, False: 41.3k]
  ------------------
 1019|  1.12k|        RNP_LOG("wrong packet or hashed subpackets length");
  ------------------
  |  |   84|  1.12k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.12k|    do {                                                                                 \
  |  |  |  |   77|  1.12k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.12k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.12k|            break;                                                                       \
  |  |  |  |   79|  1.12k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1020|  1.12k|        return RNP_ERROR_BAD_FORMAT;
 1021|  1.12k|    }
 1022|       |    /* building hashed data */
 1023|  41.3k|    size_t hlen = 4 + splen + splen_size;
 1024|  41.3k|    hashed_data.resize(hlen);
 1025|  41.3k|    hashed_data[0] = version;
 1026|  41.3k|    static_assert(sizeof(buf) == 3, "Wrong signature header size.");
 1027|  41.3k|    pkt.skip_back(3 + splen_size);
 1028|       |
 1029|  41.3k|    if (!pkt.get(hashed_data.data() + 1, hlen - 1)) {
  ------------------
  |  Branch (1029:9): [True: 0, False: 41.3k]
  ------------------
 1030|      0|        RNP_LOG("cannot get hashed subpackets data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1031|      0|        return RNP_ERROR_BAD_FORMAT;
 1032|      0|    }
 1033|       |    /* parsing hashed subpackets */
 1034|  41.3k|    if (!parse_subpackets(hashed_data.data() + 4 + splen_size, splen, true, depth)) {
  ------------------
  |  Branch (1034:9): [True: 7.93k, False: 33.4k]
  ------------------
 1035|  7.93k|        RNP_LOG("failed to parse hashed subpackets");
  ------------------
  |  |   84|  7.93k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  7.93k|    do {                                                                                 \
  |  |  |  |   77|  7.93k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 7.93k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  7.93k|            break;                                                                       \
  |  |  |  |   79|  7.93k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1036|  7.93k|        return RNP_ERROR_BAD_FORMAT;
 1037|  7.93k|    }
 1038|       |
 1039|       |    /* reading unhashed subpackets */
 1040|  33.4k|    if (!get_subpkt_len(pkt, splen)) {
  ------------------
  |  Branch (1040:9): [True: 0, False: 33.4k]
  ------------------
 1041|      0|        RNP_LOG("cannot get unhashed len");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1042|      0|        return RNP_ERROR_BAD_FORMAT;
 1043|      0|    }
 1044|  33.4k|    if (pkt.left() < splen) {
  ------------------
  |  Branch (1044:9): [True: 1.57k, False: 31.8k]
  ------------------
 1045|  1.57k|        RNP_LOG("not enough data for unhashed subpackets");
  ------------------
  |  |   84|  1.57k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.57k|    do {                                                                                 \
  |  |  |  |   77|  1.57k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.57k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.57k|            break;                                                                       \
  |  |  |  |   79|  1.57k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1046|  1.57k|        return RNP_ERROR_BAD_FORMAT;
 1047|  1.57k|    }
 1048|  31.8k|    if (!parse_subpackets(pkt.cur(), splen, false, depth)) {
  ------------------
  |  Branch (1048:9): [True: 569, False: 31.2k]
  ------------------
 1049|    569|        RNP_LOG("failed to parse unhashed subpackets");
  ------------------
  |  |   84|    569|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    569|    do {                                                                                 \
  |  |  |  |   77|    569|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 569, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    569|            break;                                                                       \
  |  |  |  |   79|    569|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1050|    569|        return RNP_ERROR_BAD_FORMAT;
 1051|    569|    }
 1052|  31.2k|    pkt.skip(splen);
 1053|  31.2k|    return RNP_SUCCESS;
 1054|  31.8k|}
_ZN3pgp3pkt9Signature5parseER17pgp_packet_body_tm:
 1058|  66.0k|{
 1059|  66.0k|    uint8_t ver = 0;
 1060|  66.0k|    if (!pkt.get(ver)) {
  ------------------
  |  Branch (1060:9): [True: 1.75k, False: 64.2k]
  ------------------
 1061|  1.75k|        return RNP_ERROR_BAD_FORMAT;
 1062|  1.75k|    }
 1063|  64.2k|    version = (pgp_version_t) ver;
 1064|       |
 1065|       |    /* v3 or v4 or v6 signature body */
 1066|  64.2k|    rnp_result_t res;
 1067|  64.2k|    switch (ver) {
 1068|  12.1k|    case PGP_V2:
  ------------------
  |  Branch (1068:5): [True: 12.1k, False: 52.1k]
  ------------------
 1069|  12.1k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  12.1k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1070|  18.6k|    case PGP_V3:
  ------------------
  |  Branch (1070:5): [True: 6.53k, False: 57.7k]
  ------------------
 1071|  18.6k|        res = parse_v2v3(pkt);
 1072|  18.6k|        break;
 1073|  41.8k|    case PGP_V4:
  ------------------
  |  Branch (1073:5): [True: 41.8k, False: 22.3k]
  ------------------
 1074|  41.8k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  41.8k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1075|  42.7k|    case PGP_V5:
  ------------------
  |  Branch (1075:5): [True: 883, False: 63.3k]
  ------------------
 1076|  42.7k|#if defined(ENABLE_CRYPTO_REFRESH)
 1077|  42.7k|        FALLTHROUGH_STATEMENT;
  ------------------
  |  |  109|  42.7k|# define FALLTHROUGH_STATEMENT [[fallthrough]]
  ------------------
 1078|  43.8k|    case PGP_V6:
  ------------------
  |  Branch (1078:5): [True: 1.08k, False: 63.1k]
  ------------------
 1079|  43.8k|#endif
 1080|  43.8k|        res = parse_v4up(pkt, depth);
 1081|  43.8k|        break;
 1082|  1.71k|    default:
  ------------------
  |  Branch (1082:5): [True: 1.71k, False: 62.5k]
  ------------------
 1083|  1.71k|        RNP_LOG("unknown signature version: %d", (int) ver);
  ------------------
  |  |   84|  1.71k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.71k|    do {                                                                                 \
  |  |  |  |   77|  1.71k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.71k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.71k|            break;                                                                       \
  |  |  |  |   79|  1.71k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1084|  1.71k|        res = RNP_ERROR_BAD_FORMAT;
 1085|  64.2k|    }
 1086|       |
 1087|  64.2k|    if (res) {
  ------------------
  |  Branch (1087:9): [True: 15.2k, False: 49.0k]
  ------------------
 1088|  15.2k|        return res;
 1089|  15.2k|    }
 1090|       |
 1091|       |    /* left 16 bits of the hash */
 1092|  49.0k|    if (!pkt.get(lbits.data(), 2)) {
  ------------------
  |  Branch (1092:9): [True: 36, False: 48.9k]
  ------------------
 1093|     36|        RNP_LOG("not enough data for hash left bits");
  ------------------
  |  |   84|     36|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     36|    do {                                                                                 \
  |  |  |  |   77|     36|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 36, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     36|            break;                                                                       \
  |  |  |  |   79|     36|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1094|     36|        return RNP_ERROR_BAD_FORMAT;
 1095|     36|    }
 1096|       |
 1097|  48.9k|#if defined(ENABLE_CRYPTO_REFRESH)
 1098|  48.9k|    if (ver == PGP_V6) {
  ------------------
  |  Branch (1098:9): [True: 180, False: 48.8k]
  ------------------
 1099|    180|        uint8_t salt_size = 0;
 1100|    180|        if (!pkt.get(salt_size)) {
  ------------------
  |  Branch (1100:13): [True: 11, False: 169]
  ------------------
 1101|     11|            RNP_LOG("not enough data for v6 salt size octet");
  ------------------
  |  |   84|     11|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     11|    do {                                                                                 \
  |  |  |  |   77|     11|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 11, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     11|            break;                                                                       \
  |  |  |  |   79|     11|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1102|     11|            return RNP_ERROR_BAD_FORMAT;
 1103|     11|        }
 1104|    169|        size_t expect_salt_size;
 1105|    169|        if (!pgp::pkt::Signature::v6_salt_size(halg, &expect_salt_size)) {
  ------------------
  |  Branch (1105:13): [True: 14, False: 155]
  ------------------
 1106|     14|            RNP_LOG("invalid halg");
  ------------------
  |  |   84|     14|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     14|    do {                                                                                 \
  |  |  |  |   77|     14|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 14, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     14|            break;                                                                       \
  |  |  |  |   79|     14|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1107|     14|            return RNP_ERROR_BAD_FORMAT;
 1108|     14|        }
 1109|    155|        if (salt_size != expect_salt_size) {
  ------------------
  |  Branch (1109:13): [True: 55, False: 100]
  ------------------
 1110|     55|            RNP_LOG("invalid salt size");
  ------------------
  |  |   84|     55|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     55|    do {                                                                                 \
  |  |  |  |   77|     55|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 55, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     55|            break;                                                                       \
  |  |  |  |   79|     55|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1111|     55|            return RNP_ERROR_BAD_FORMAT;
 1112|     55|        }
 1113|    100|        salt.resize(salt_size);
 1114|    100|        if (!pkt.get(salt.data(), salt_size)) {
  ------------------
  |  Branch (1114:13): [True: 10, False: 90]
  ------------------
 1115|     10|            RNP_LOG("not enough data for v6 signature salt");
  ------------------
  |  |   84|     10|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     10|    do {                                                                                 \
  |  |  |  |   77|     10|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 10, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     10|            break;                                                                       \
  |  |  |  |   79|     10|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1116|     10|            return RNP_ERROR_BAD_FORMAT;
 1117|     10|        }
 1118|    100|    }
 1119|  48.9k|#endif
 1120|       |
 1121|       |    /* raw signature material */
 1122|       |    /* we cannot fail here */
 1123|  48.9k|    pkt.get(material_buf, pkt.left());
 1124|       |    /* check whether it can be parsed */
 1125|  48.9k|    if (!parse_material()) {
  ------------------
  |  Branch (1125:9): [True: 8.21k, False: 40.6k]
  ------------------
 1126|  8.21k|        return RNP_ERROR_BAD_FORMAT;
 1127|  8.21k|    }
 1128|  40.6k|    return RNP_SUCCESS;
 1129|  48.9k|}
_ZN3pgp3pkt9Signature5parseER12pgp_source_t:
 1133|   352k|{
 1134|   352k|    pgp_packet_body_t pkt(PGP_PKT_SIGNATURE);
 1135|   352k|    rnp_result_t      res = pkt.read(src);
 1136|   352k|    if (res) {
  ------------------
  |  Branch (1136:9): [True: 287k, False: 65.4k]
  ------------------
 1137|   287k|        return res;
 1138|   287k|    }
 1139|  65.4k|    return parse(pkt);
 1140|   352k|}
_ZNK3pgp3pkt9Signature14parse_materialEv:
 1144|  60.2k|{
 1145|  60.2k|    auto sig = SigMaterial::create(palg, halg);
 1146|  60.2k|    if (!sig) {
  ------------------
  |  Branch (1146:9): [True: 3.98k, False: 56.2k]
  ------------------
 1147|  3.98k|        return nullptr;
 1148|  3.98k|    }
 1149|  56.2k|    pgp_packet_body_t pkt(material_buf);
 1150|  56.2k|    if (!sig->parse(pkt)) {
  ------------------
  |  Branch (1150:9): [True: 3.93k, False: 52.3k]
  ------------------
 1151|  3.93k|        return nullptr;
 1152|  3.93k|    }
 1153|  52.3k|    if (pkt.left()) {
  ------------------
  |  Branch (1153:9): [True: 286, False: 52.0k]
  ------------------
 1154|    286|        RNP_LOG("extra %zu bytes in pk packet", pkt.left());
  ------------------
  |  |   84|    286|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    286|    do {                                                                                 \
  |  |  |  |   77|    286|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 286, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    286|            break;                                                                       \
  |  |  |  |   79|    286|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1155|    286|        return nullptr;
 1156|    286|    }
 1157|  52.0k|    return sig;
 1158|  52.3k|}
_ZNK3pgp3pkt9Signature5writeER10pgp_dest_tb:
 1162|  40.8k|{
 1163|  40.8k|    if (!Signature::version_supported(version)) {
  ------------------
  |  Branch (1163:9): [True: 0, False: 40.8k]
  ------------------
 1164|      0|        RNP_LOG("don't know version %d", (int) version);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1165|      0|        throw rnp::rnp_exception(RNP_ERROR_BAD_PARAMETERS);
 1166|      0|    }
 1167|       |
 1168|  40.8k|    pgp_packet_body_t pktbody(PGP_PKT_SIGNATURE);
 1169|       |
 1170|  40.8k|    if (version < PGP_V4) {
  ------------------
  |  Branch (1170:9): [True: 12.0k, False: 28.7k]
  ------------------
 1171|       |        /* for v3 signatures hashed data includes only type + creation_time */
 1172|  12.0k|        pktbody.add_byte(version);
 1173|  12.0k|        pktbody.add_byte(hashed_data.size());
 1174|  12.0k|        pktbody.add(hashed_data);
 1175|  12.0k|        pktbody.add(signer);
 1176|  12.0k|        pktbody.add_byte(palg);
 1177|  12.0k|        pktbody.add_byte(halg);
 1178|  28.7k|    } else {
 1179|       |        /* for v4 sig->hashed_data must contain most of signature fields */
 1180|  28.7k|        pktbody.add(hashed_data);
 1181|  28.7k|        pktbody.add_subpackets(*this, false);
 1182|  28.7k|    }
 1183|  40.8k|    pktbody.add(lbits.data(), 2);
 1184|  40.8k|#if defined(ENABLE_CRYPTO_REFRESH)
 1185|  40.8k|    if (version == PGP_V6) {
  ------------------
  |  Branch (1185:9): [True: 22, False: 40.7k]
  ------------------
 1186|     22|        pktbody.add_byte(salt.size());
 1187|     22|        pktbody.add(salt);
 1188|     22|    }
 1189|  40.8k|#endif
 1190|       |    /* write mpis */
 1191|  40.8k|    pktbody.add(material_buf);
 1192|  40.8k|    pktbody.write(dst, hdr);
 1193|  40.8k|}
_ZNK3pgp3pkt9Signature5writeEb:
 1197|  40.8k|{
 1198|  40.8k|    rnp::MemoryDest dst;
 1199|  40.8k|    write(dst.dst(), hdr);
 1200|  40.8k|    return dst.to_vector();
 1201|  40.8k|}
_ZN3pgp3pkt9Signature12v6_salt_sizeE14pgp_hash_alg_tPm:
 1236|  1.56k|{
 1237|  1.56k|    switch (halg) {
 1238|     70|    case PGP_HASH_SHA256:
  ------------------
  |  Branch (1238:5): [True: 70, False: 1.49k]
  ------------------
 1239|     70|        *salt_size = 16;
 1240|     70|        break;
 1241|      5|    case PGP_HASH_SHA224:
  ------------------
  |  Branch (1241:5): [True: 5, False: 1.56k]
  ------------------
 1242|      5|        *salt_size = 16;
 1243|      5|        break;
 1244|     39|    case PGP_HASH_SHA384:
  ------------------
  |  Branch (1244:5): [True: 39, False: 1.52k]
  ------------------
 1245|     39|        *salt_size = 24;
 1246|     39|        break;
 1247|  1.27k|    case PGP_HASH_SHA512:
  ------------------
  |  Branch (1247:5): [True: 1.27k, False: 296]
  ------------------
 1248|  1.27k|        *salt_size = 32;
 1249|  1.27k|        break;
 1250|      4|    case PGP_HASH_SHA3_256:
  ------------------
  |  Branch (1250:5): [True: 4, False: 1.56k]
  ------------------
 1251|      4|        *salt_size = 16;
 1252|      4|        break;
 1253|    126|    case PGP_HASH_SHA3_512:
  ------------------
  |  Branch (1253:5): [True: 126, False: 1.44k]
  ------------------
 1254|    126|        *salt_size = 32;
 1255|    126|        break;
 1256|     52|    default:
  ------------------
  |  Branch (1256:5): [True: 52, False: 1.51k]
  ------------------
 1257|     52|        RNP_LOG("no V6 salt size for algorithm");
  ------------------
  |  |   84|     52|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|     52|    do {                                                                                 \
  |  |  |  |   77|     52|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 52, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|     52|            break;                                                                       \
  |  |  |  |   79|     52|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1258|     52|        return false;
 1259|  1.56k|    }
 1260|  1.51k|    return true;
 1261|  1.56k|}

_ZN3pgp3pkt9SignatureC2Ev:
   80|   374k|        : type_(PGP_SIG_BINARY), version(PGP_VUNKNOWN), palg(PGP_PKA_NOTHING),
   81|   374k|          halg(PGP_HASH_UNKNOWN), creation_time(0){};
_ZNK3pgp3pkt9Signature4typeEv:
   88|   223k|    {
   89|   223k|        return type_;
   90|   223k|    };
_ZNK3pgp3pkt9Signature11is_documentEv:
   99|  12.5k|    {
  100|  12.5k|        return (type_ == PGP_SIG_BINARY) || (type_ == PGP_SIG_TEXT);
  ------------------
  |  Branch (100:16): [True: 13, False: 12.5k]
  |  Branch (100:45): [True: 187, False: 12.3k]
  ------------------
  101|  12.5k|    };

_Z12rnp_sign_srcR9rnp_ctx_tR12pgp_source_tR10pgp_dest_t:
 2225|    718|{
 2226|       |    /* stack of the streams would be as following:
 2227|       |       [armoring stream] - if armoring is enabled
 2228|       |       [compressing stream, partial writing stream] - compression is enabled, and not detached
 2229|       |       signing stream
 2230|       |       literal data stream, partial writing stream - if not detached or cleartext signature
 2231|       |    */
 2232|    718|    pgp_dest_t   dests[4];
 2233|    718|    size_t       destc = 0;
 2234|    718|    rnp_result_t ret = RNP_ERROR_GENERIC;
 2235|    718|    pgp_dest_t * wstream = NULL;
 2236|    718|    pgp_dest_t * sstream = NULL;
 2237|       |
 2238|       |    /* pushing armoring stream, which will write to the output */
 2239|    718|    if (ctx.armor && !ctx.clearsign) {
  ------------------
  |  Branch (2239:9): [True: 247, False: 471]
  |  Branch (2239:22): [True: 247, False: 0]
  ------------------
 2240|    247|        pgp_armored_msg_t msgt = ctx.detached ? PGP_ARMORED_SIGNATURE : PGP_ARMORED_MESSAGE;
  ------------------
  |  Branch (2240:34): [True: 0, False: 247]
  ------------------
 2241|    247|        ret = init_armored_dst(&dests[destc], &dst, msgt);
 2242|    247|        if (ret) {
  ------------------
  |  Branch (2242:13): [True: 0, False: 247]
  ------------------
 2243|      0|            goto finish;
 2244|      0|        }
 2245|    247|        destc++;
 2246|    247|    }
 2247|       |
 2248|       |    /* if compression is enabled then pushing compressing stream */
 2249|    718|    if (!ctx.detached && !ctx.clearsign && (ctx.zlevel > 0)) {
  ------------------
  |  Branch (2249:9): [True: 718, False: 0]
  |  Branch (2249:26): [True: 718, False: 0]
  |  Branch (2249:44): [True: 0, False: 718]
  ------------------
 2250|      0|        if ((ret = init_compressed_dst(ctx, dests[destc], destc ? dests[destc - 1] : dst))) {
  ------------------
  |  Branch (2250:13): [True: 0, False: 0]
  |  Branch (2250:59): [True: 0, False: 0]
  ------------------
 2251|      0|            goto finish;
 2252|      0|        }
 2253|      0|        destc++;
 2254|      0|    }
 2255|       |
 2256|       |    /* pushing signing stream, which will use handler->ctx to distinguish between
 2257|       |     * attached/detached/cleartext signature */
 2258|    718|    if ((ret = init_signed_dst(ctx, dests[destc], destc ? dests[destc - 1] : dst))) {
  ------------------
  |  Branch (2258:9): [True: 718, False: 0]
  |  Branch (2258:51): [True: 247, False: 471]
  ------------------
 2259|    718|        goto finish;
 2260|    718|    }
 2261|      0|    if (!ctx.clearsign) {
  ------------------
  |  Branch (2261:9): [True: 0, False: 0]
  ------------------
 2262|      0|        sstream = &dests[destc];
 2263|      0|    }
 2264|      0|    if (!ctx.detached) {
  ------------------
  |  Branch (2264:9): [True: 0, False: 0]
  ------------------
 2265|      0|        wstream = &dests[destc];
 2266|      0|    }
 2267|      0|    destc++;
 2268|       |
 2269|       |    /* pushing literal data stream, if not detached/cleartext signature */
 2270|      0|    if (!ctx.no_wrap && !ctx.detached && !ctx.clearsign) {
  ------------------
  |  Branch (2270:9): [True: 0, False: 0]
  |  Branch (2270:25): [True: 0, False: 0]
  |  Branch (2270:42): [True: 0, False: 0]
  ------------------
 2271|      0|        pgp_literal_hdr_t hdr{};
 2272|      0|        bool              v6_output = signing_v6_output(ctx);
 2273|      0|        if (v6_output && (!ctx.filename.empty() || ctx.filemtime)) {
  ------------------
  |  Branch (2273:13): [True: 0, False: 0]
  |  Branch (2273:27): [True: 0, False: 0]
  |  Branch (2273:52): [True: 0, False: 0]
  ------------------
 2274|      0|            RNP_LOG("Warning: filename/mtime is not written for v6 literal packets "
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2275|      0|                    "(RFC 9580)");
 2276|      0|        }
 2277|      0|        build_literal_hdr(ctx, hdr, v6_output);
 2278|       |
 2279|      0|        if ((ret = init_literal_dst(hdr, dests[destc], dests[destc - 1]))) {
  ------------------
  |  Branch (2279:13): [True: 0, False: 0]
  ------------------
 2280|      0|            goto finish;
 2281|      0|        }
 2282|      0|        signed_dst_set_literal_hdr(dests[destc - 1], hdr);
 2283|      0|        wstream = &dests[destc];
 2284|      0|        destc++;
 2285|      0|    }
 2286|       |
 2287|      0|    if (ctx.clearsign) {
  ------------------
  |  Branch (2287:9): [True: 0, False: 0]
  ------------------
 2288|       |        /* See https://dev.gnupg.org/T6615 for the details */
 2289|      0|        pgp_literal_hdr_t hdr{};
 2290|      0|        hdr.format = 't';
 2291|      0|        hdr.fname_len = 0;
 2292|      0|        hdr.timestamp = 0;
 2293|      0|        signed_dst_set_literal_hdr(dests[destc - 1], hdr);
 2294|      0|    }
 2295|       |
 2296|       |    /* process source with streams stack */
 2297|      0|    ret = process_stream_sequence(src, dests, destc, sstream, wstream);
 2298|    718|finish:
 2299|    965|    for (auto i = destc; i > 0; i--) {
  ------------------
  |  Branch (2299:26): [True: 247, False: 718]
  ------------------
 2300|    247|        dst_close(&dests[i - 1], ret);
 2301|    247|    }
 2302|    718|    return ret;
 2303|      0|}
_Z20rnp_encrypt_sign_srcR9rnp_ctx_tR12pgp_source_tR10pgp_dest_t:
 2307|  12.0k|{
 2308|       |    /* stack of the streams would be as following:
 2309|       |       [armoring stream] - if armoring is enabled
 2310|       |       [encrypting stream, partial writing stream]
 2311|       |       [compressing stream, partial writing stream] - compression is enabled
 2312|       |       signing stream
 2313|       |       literal data stream, partial writing stream
 2314|       |    */
 2315|  12.0k|    pgp_dest_t   dests[5];
 2316|  12.0k|    size_t       destc = 0;
 2317|  12.0k|    rnp_result_t ret = RNP_SUCCESS;
 2318|  12.0k|    pgp_dest_t * sstream = NULL;
 2319|       |
 2320|       |    /* we may use only attached signatures here */
 2321|  12.0k|    if (ctx.clearsign || ctx.detached) {
  ------------------
  |  Branch (2321:9): [True: 0, False: 12.0k]
  |  Branch (2321:26): [True: 0, False: 12.0k]
  ------------------
 2322|      0|        RNP_LOG("cannot clearsign or sign detached together with encryption");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2323|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2324|      0|    }
 2325|       |
 2326|       |    /* pushing armoring stream, which will write to the output */
 2327|  12.0k|    if (ctx.armor) {
  ------------------
  |  Branch (2327:9): [True: 4.77k, False: 7.25k]
  ------------------
 2328|  4.77k|        if ((ret = init_armored_dst(&dests[destc], &dst, PGP_ARMORED_MESSAGE))) {
  ------------------
  |  Branch (2328:13): [True: 0, False: 4.77k]
  ------------------
 2329|      0|            goto finish;
 2330|      0|        }
 2331|  4.77k|        destc++;
 2332|  4.77k|    }
 2333|       |
 2334|       |    /* pushing encrypting stream, which will write to the output or armoring stream */
 2335|  12.0k|    if ((ret = init_encrypted_dst(ctx, dests[destc], destc ? dests[destc - 1] : dst))) {
  ------------------
  |  Branch (2335:9): [True: 3.90k, False: 8.12k]
  |  Branch (2335:54): [True: 4.77k, False: 7.25k]
  ------------------
 2336|  3.90k|        goto finish;
 2337|  3.90k|    }
 2338|  8.12k|    destc++;
 2339|       |
 2340|       |    /* if compression is enabled then pushing compressing stream */
 2341|  8.12k|    if (ctx.zlevel > 0) {
  ------------------
  |  Branch (2341:9): [True: 5.29k, False: 2.83k]
  ------------------
 2342|  5.29k|        if ((ret = init_compressed_dst(ctx, dests[destc], dests[destc - 1]))) {
  ------------------
  |  Branch (2342:13): [True: 400, False: 4.89k]
  ------------------
 2343|    400|            goto finish;
 2344|    400|        }
 2345|  4.89k|        destc++;
 2346|  4.89k|    }
 2347|       |
 2348|       |    /* pushing signing stream if we have signers */
 2349|  7.72k|    if (!ctx.signers.empty()) {
  ------------------
  |  Branch (2349:9): [True: 0, False: 7.72k]
  ------------------
 2350|      0|        if ((ret = init_signed_dst(ctx, dests[destc], dests[destc - 1]))) {
  ------------------
  |  Branch (2350:13): [True: 0, False: 0]
  ------------------
 2351|      0|            goto finish;
 2352|      0|        }
 2353|      0|        sstream = &dests[destc];
 2354|      0|        destc++;
 2355|      0|    }
 2356|       |
 2357|       |    /* pushing literal data stream */
 2358|  7.72k|    if (!ctx.no_wrap) {
  ------------------
  |  Branch (2358:9): [True: 1.95k, False: 5.76k]
  ------------------
 2359|  1.95k|        pgp_literal_hdr_t hdr{};
 2360|  1.95k|        bool              v6_output = seipdv2_capable(ctx);
 2361|  1.95k|        if (v6_output && (!ctx.filename.empty() || ctx.filemtime)) {
  ------------------
  |  Branch (2361:13): [True: 1.94k, False: 11]
  |  Branch (2361:27): [True: 1.94k, False: 0]
  |  Branch (2361:52): [True: 0, False: 0]
  ------------------
 2362|  1.94k|            RNP_LOG("Warning: filename/mtime is not written for v6 literal packets "
  ------------------
  |  |   84|  1.94k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  1.94k|    do {                                                                                 \
  |  |  |  |   77|  1.94k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 1.94k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  1.94k|            break;                                                                       \
  |  |  |  |   79|  1.94k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2363|  1.94k|                    "(RFC 9580)");
 2364|  1.94k|        }
 2365|  1.95k|        build_literal_hdr(ctx, hdr, v6_output);
 2366|       |
 2367|  1.95k|        if ((ret = init_literal_dst(hdr, dests[destc], dests[destc - 1]))) {
  ------------------
  |  Branch (2367:13): [True: 0, False: 1.95k]
  ------------------
 2368|      0|            goto finish;
 2369|      0|        }
 2370|       |
 2371|  1.95k|        if (sstream) {
  ------------------
  |  Branch (2371:13): [True: 0, False: 1.95k]
  ------------------
 2372|      0|            signed_dst_set_literal_hdr(*sstream, hdr);
 2373|      0|        }
 2374|       |
 2375|  1.95k|        destc++;
 2376|  1.95k|    }
 2377|       |
 2378|       |    /* process source with streams stack */
 2379|  7.72k|    ret = process_stream_sequence(src, dests, destc, sstream, &dests[destc - 1]);
 2380|  12.0k|finish:
 2381|  31.7k|    for (size_t i = destc; i > 0; i--) {
  ------------------
  |  Branch (2381:28): [True: 19.7k, False: 12.0k]
  ------------------
 2382|  19.7k|        dst_close(&dests[i - 1], ret);
 2383|  19.7k|    }
 2384|  12.0k|    return ret;
 2385|  7.72k|}
stream-write.cpp:_ZL19init_compressed_dstR9rnp_ctx_tR10pgp_dest_tS2_:
 1978|  5.29k|{
 1979|  5.29k|    pgp_dest_compressed_param_t *param = NULL;
 1980|  5.29k|    rnp_result_t                 ret = RNP_ERROR_GENERIC;
 1981|  5.29k|    uint8_t                      buf = 0;
 1982|  5.29k|    int                          zret = 0;
 1983|       |
 1984|  5.29k|    if (!init_dst_common(&dst, sizeof(*param))) {
  ------------------
  |  Branch (1984:9): [True: 0, False: 5.29k]
  ------------------
 1985|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 1986|      0|    }
 1987|       |
 1988|  5.29k|    param = (pgp_dest_compressed_param_t *) dst.param;
 1989|  5.29k|    dst.write = compressed_dst_write;
 1990|  5.29k|    dst.finish = compressed_dst_finish;
 1991|  5.29k|    dst.close = compressed_dst_close;
 1992|  5.29k|    dst.type = PGP_STREAM_COMPRESSED;
 1993|  5.29k|    param->alg = (pgp_compression_type_t) ctx.zalg;
 1994|  5.29k|    param->pkt.partial = true;
 1995|  5.29k|    param->pkt.indeterminate = false;
 1996|  5.29k|    param->pkt.tag = PGP_PKT_COMPRESSED;
 1997|       |
 1998|       |    /* initializing partial length or indeterminate packet, writing header */
 1999|  5.29k|    if (!init_streamed_packet(param->pkt, writedst)) {
  ------------------
  |  Branch (1999:9): [True: 0, False: 5.29k]
  ------------------
 2000|       |        /* LCOV_EXCL_START */
 2001|      0|        RNP_LOG("failed to init streamed packet");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2002|      0|        ret = RNP_ERROR_BAD_PARAMETERS;
 2003|      0|        goto finish;
 2004|       |        /* LCOV_EXCL_END */
 2005|      0|    }
 2006|       |
 2007|       |    /* compression algorithm */
 2008|  5.29k|    buf = param->alg;
 2009|  5.29k|    dst_write(param->pkt.writedst, &buf, 1);
 2010|       |
 2011|       |    /* initializing compression */
 2012|  5.29k|    switch (param->alg) {
 2013|  2.39k|    case PGP_C_ZIP:
  ------------------
  |  Branch (2013:5): [True: 2.39k, False: 2.90k]
  ------------------
 2014|  3.86k|    case PGP_C_ZLIB:
  ------------------
  |  Branch (2014:5): [True: 1.46k, False: 3.83k]
  ------------------
 2015|  3.86k|        (void) memset(&param->z, 0x0, sizeof(param->z));
 2016|  3.86k|        if (param->alg == PGP_C_ZIP) {
  ------------------
  |  Branch (2016:13): [True: 2.39k, False: 1.46k]
  ------------------
 2017|  2.39k|            zret = deflateInit2(&param->z, ctx.zlevel, Z_DEFLATED, -15, 8, Z_DEFAULT_STRATEGY);
 2018|  2.39k|        } else {
 2019|  1.46k|            zret = deflateInit(&param->z, ctx.zlevel);
 2020|  1.46k|        }
 2021|       |
 2022|  3.86k|        if (zret != Z_OK) {
  ------------------
  |  Branch (2022:13): [True: 0, False: 3.86k]
  ------------------
 2023|      0|            RNP_LOG("failed to init zlib, error %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2024|      0|            ret = RNP_ERROR_NOT_SUPPORTED;
 2025|      0|            goto finish;
 2026|      0|        }
 2027|  3.86k|        break;
 2028|  3.86k|#ifdef HAVE_BZLIB_H
 2029|  3.86k|    case PGP_C_BZIP2:
  ------------------
  |  Branch (2029:5): [True: 1.03k, False: 4.26k]
  ------------------
 2030|  1.03k|        (void) memset(&param->bz, 0x0, sizeof(param->bz));
 2031|  1.03k|        zret = BZ2_bzCompressInit(&param->bz, ctx.zlevel, 0, 0);
 2032|  1.03k|        if (zret != BZ_OK) {
  ------------------
  |  Branch (2032:13): [True: 0, False: 1.03k]
  ------------------
 2033|      0|            RNP_LOG("failed to init bz, error %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2034|      0|            ret = RNP_ERROR_NOT_SUPPORTED;
 2035|      0|            goto finish;
 2036|      0|        }
 2037|  1.03k|        break;
 2038|  1.03k|#endif
 2039|  1.03k|    default:
  ------------------
  |  Branch (2039:5): [True: 400, False: 4.89k]
  ------------------
 2040|    400|        RNP_LOG("unknown compression algorithm");
  ------------------
  |  |   84|    400|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|    400|    do {                                                                                 \
  |  |  |  |   77|    400|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 400, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|    400|            break;                                                                       \
  |  |  |  |   79|    400|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2041|    400|        ret = RNP_ERROR_NOT_SUPPORTED;
 2042|    400|        goto finish;
 2043|  5.29k|    }
 2044|  4.89k|    param->zstarted = true;
 2045|  4.89k|    ret = RNP_SUCCESS;
 2046|  5.29k|finish:
 2047|  5.29k|    if (ret != RNP_SUCCESS) {
  ------------------
  |  Branch (2047:9): [True: 400, False: 4.89k]
  ------------------
 2048|    400|        compressed_dst_close(&dst, true);
 2049|    400|    }
 2050|  5.29k|    return ret;
 2051|  4.89k|}
stream-write.cpp:_ZL20compressed_dst_writeP10pgp_dest_tPKvm:
 1819|  6.12k|{
 1820|  6.12k|    pgp_dest_compressed_param_t *param = (pgp_dest_compressed_param_t *) dst->param;
 1821|       |
 1822|  6.12k|    if (!param) {
  ------------------
  |  Branch (1822:9): [True: 0, False: 6.12k]
  ------------------
 1823|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1824|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1825|      0|    }
 1826|       |
 1827|  6.12k|    if ((param->alg == PGP_C_ZIP) || (param->alg == PGP_C_ZLIB)) {
  ------------------
  |  Branch (1827:9): [True: 2.83k, False: 3.28k]
  |  Branch (1827:38): [True: 1.85k, False: 1.42k]
  ------------------
 1828|  4.69k|        param->z.next_in = (unsigned char *) buf;
 1829|  4.69k|        param->z.avail_in = len;
 1830|  4.69k|        param->z.next_out = param->cache + param->len;
 1831|  4.69k|        param->z.avail_out = sizeof(param->cache) - param->len;
 1832|       |
 1833|  9.77k|        while (param->z.avail_in > 0) {
  ------------------
  |  Branch (1833:16): [True: 5.07k, False: 4.69k]
  ------------------
 1834|  5.07k|            int zret = deflate(&param->z, Z_NO_FLUSH);
 1835|       |            /* Z_OK, Z_BUF_ERROR are ok for us, Z_STREAM_END will not happen here */
 1836|  5.07k|            if (zret == Z_STREAM_ERROR) {
  ------------------
  |  Branch (1836:17): [True: 0, False: 5.07k]
  ------------------
 1837|      0|                RNP_LOG("wrong deflate state");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1838|      0|                return RNP_ERROR_BAD_STATE;
 1839|      0|            }
 1840|       |
 1841|       |            /* writing only full blocks, the rest will be written in close */
 1842|  5.07k|            if (param->z.avail_out == 0) {
  ------------------
  |  Branch (1842:17): [True: 1.01k, False: 4.06k]
  ------------------
 1843|  1.01k|                dst_write(param->pkt.writedst, param->cache, sizeof(param->cache));
 1844|  1.01k|                param->len = 0;
 1845|  1.01k|                param->z.next_out = param->cache;
 1846|  1.01k|                param->z.avail_out = sizeof(param->cache);
 1847|  1.01k|            }
 1848|  5.07k|        }
 1849|       |
 1850|  4.69k|        param->len = sizeof(param->cache) - param->z.avail_out;
 1851|  4.69k|        return RNP_SUCCESS;
 1852|  4.69k|    } else if (param->alg == PGP_C_BZIP2) {
  ------------------
  |  Branch (1852:16): [True: 1.42k, False: 0]
  ------------------
 1853|  1.42k|#ifdef HAVE_BZLIB_H
 1854|  1.42k|        param->bz.next_in = (char *) buf;
 1855|  1.42k|        param->bz.avail_in = len;
 1856|  1.42k|        param->bz.next_out = (char *) (param->cache + param->len);
 1857|  1.42k|        param->bz.avail_out = sizeof(param->cache) - param->len;
 1858|       |
 1859|  3.04k|        while (param->bz.avail_in > 0) {
  ------------------
  |  Branch (1859:16): [True: 1.61k, False: 1.42k]
  ------------------
 1860|  1.61k|            int zret = BZ2_bzCompress(&param->bz, BZ_RUN);
 1861|  1.61k|            if (zret < 0) {
  ------------------
  |  Branch (1861:17): [True: 0, False: 1.61k]
  ------------------
 1862|      0|                RNP_LOG("error %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1863|      0|                return RNP_ERROR_BAD_STATE;
 1864|      0|            }
 1865|       |
 1866|       |            /* writing only full blocks, the rest will be written in close */
 1867|  1.61k|            if (param->bz.avail_out == 0) {
  ------------------
  |  Branch (1867:17): [True: 191, False: 1.42k]
  ------------------
 1868|    191|                dst_write(param->pkt.writedst, param->cache, sizeof(param->cache));
 1869|    191|                param->len = 0;
 1870|    191|                param->bz.next_out = (char *) param->cache;
 1871|    191|                param->bz.avail_out = sizeof(param->cache);
 1872|    191|            }
 1873|  1.61k|        }
 1874|       |
 1875|  1.42k|        param->len = sizeof(param->cache) - param->bz.avail_out;
 1876|  1.42k|        return RNP_SUCCESS;
 1877|       |#else
 1878|       |        return RNP_ERROR_NOT_IMPLEMENTED;
 1879|       |#endif
 1880|  1.42k|    } else {
 1881|      0|        RNP_LOG("unknown algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1882|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1883|      0|    }
 1884|  6.12k|}
stream-write.cpp:_ZL21compressed_dst_finishP10pgp_dest_t:
 1888|  4.89k|{
 1889|  4.89k|    int                          zret;
 1890|  4.89k|    pgp_dest_compressed_param_t *param = (pgp_dest_compressed_param_t *) dst->param;
 1891|       |
 1892|  4.89k|    if ((param->alg == PGP_C_ZIP) || (param->alg == PGP_C_ZLIB)) {
  ------------------
  |  Branch (1892:9): [True: 2.39k, False: 2.50k]
  |  Branch (1892:38): [True: 1.46k, False: 1.03k]
  ------------------
 1893|  3.86k|        param->z.next_in = Z_NULL;
 1894|  3.86k|        param->z.avail_in = 0;
 1895|  3.86k|        param->z.next_out = param->cache + param->len;
 1896|  3.86k|        param->z.avail_out = sizeof(param->cache) - param->len;
 1897|  3.90k|        do {
 1898|  3.90k|            zret = deflate(&param->z, Z_FINISH);
 1899|       |
 1900|  3.90k|            if (zret == Z_STREAM_ERROR) {
  ------------------
  |  Branch (1900:17): [True: 0, False: 3.90k]
  ------------------
 1901|      0|                RNP_LOG("wrong deflate state");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1902|      0|                return RNP_ERROR_BAD_STATE;
 1903|      0|            }
 1904|       |
 1905|  3.90k|            if (param->z.avail_out == 0) {
  ------------------
  |  Branch (1905:17): [True: 44, False: 3.86k]
  ------------------
 1906|     44|                dst_write(param->pkt.writedst, param->cache, sizeof(param->cache));
 1907|     44|                param->len = 0;
 1908|     44|                param->z.next_out = param->cache;
 1909|     44|                param->z.avail_out = sizeof(param->cache);
 1910|     44|            }
 1911|  3.90k|        } while (zret != Z_STREAM_END);
  ------------------
  |  Branch (1911:18): [True: 44, False: 3.86k]
  ------------------
 1912|       |
 1913|  3.86k|        param->len = sizeof(param->cache) - param->z.avail_out;
 1914|  3.86k|        dst_write(param->pkt.writedst, param->cache, param->len);
 1915|  3.86k|    }
 1916|  4.89k|#ifdef HAVE_BZLIB_H
 1917|  4.89k|    if (param->alg == PGP_C_BZIP2) {
  ------------------
  |  Branch (1917:9): [True: 1.03k, False: 3.86k]
  ------------------
 1918|  1.03k|        param->bz.next_in = NULL;
 1919|  1.03k|        param->bz.avail_in = 0;
 1920|  1.03k|        param->bz.next_out = (char *) (param->cache + param->len);
 1921|  1.03k|        param->bz.avail_out = sizeof(param->cache) - param->len;
 1922|       |
 1923|  1.29k|        do {
 1924|  1.29k|            zret = BZ2_bzCompress(&param->bz, BZ_FINISH);
 1925|  1.29k|            if (zret < 0) {
  ------------------
  |  Branch (1925:17): [True: 0, False: 1.29k]
  ------------------
 1926|      0|                RNP_LOG("wrong bzip2 state %d", zret);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1927|      0|                return RNP_ERROR_BAD_STATE;
 1928|      0|            }
 1929|       |
 1930|       |            /* writing only full blocks, the rest will be written in close */
 1931|  1.29k|            if (param->bz.avail_out == 0) {
  ------------------
  |  Branch (1931:17): [True: 262, False: 1.03k]
  ------------------
 1932|    262|                dst_write(param->pkt.writedst, param->cache, sizeof(param->cache));
 1933|    262|                param->len = 0;
 1934|    262|                param->bz.next_out = (char *) param->cache;
 1935|    262|                param->bz.avail_out = sizeof(param->cache);
 1936|    262|            }
 1937|  1.29k|        } while (zret != BZ_STREAM_END);
  ------------------
  |  Branch (1937:18): [True: 262, False: 1.03k]
  ------------------
 1938|       |
 1939|  1.03k|        param->len = sizeof(param->cache) - param->bz.avail_out;
 1940|  1.03k|        dst_write(param->pkt.writedst, param->cache, param->len);
 1941|  1.03k|    }
 1942|  4.89k|#endif
 1943|       |
 1944|  4.89k|    if (param->pkt.writedst->werr) {
  ------------------
  |  Branch (1944:9): [True: 0, False: 4.89k]
  ------------------
 1945|      0|        return param->pkt.writedst->werr;
 1946|      0|    }
 1947|       |
 1948|  4.89k|    return finish_streamed_packet(&param->pkt);
 1949|  4.89k|}
stream-write.cpp:_ZL22finish_streamed_packetP23pgp_dest_packet_param_t:
  316|  14.5k|{
  317|  14.5k|    if (param->partial) {
  ------------------
  |  Branch (317:9): [True: 14.5k, False: 0]
  ------------------
  318|  14.5k|        return dst_finish(param->writedst);
  319|  14.5k|    }
  320|      0|    return RNP_SUCCESS;
  321|  14.5k|}
stream-write.cpp:_ZL20compressed_dst_closeP10pgp_dest_tb:
 1953|  5.29k|{
 1954|  5.29k|    pgp_dest_compressed_param_t *param = (pgp_dest_compressed_param_t *) dst->param;
 1955|       |
 1956|  5.29k|    if (!param) {
  ------------------
  |  Branch (1956:9): [True: 0, False: 5.29k]
  ------------------
 1957|      0|        return;
 1958|      0|    }
 1959|       |
 1960|  5.29k|    if (param->zstarted) {
  ------------------
  |  Branch (1960:9): [True: 4.89k, False: 400]
  ------------------
 1961|  4.89k|        if ((param->alg == PGP_C_ZIP) || (param->alg == PGP_C_ZLIB)) {
  ------------------
  |  Branch (1961:13): [True: 2.39k, False: 2.50k]
  |  Branch (1961:42): [True: 1.46k, False: 1.03k]
  ------------------
 1962|  3.86k|            deflateEnd(&param->z);
 1963|  3.86k|        }
 1964|  4.89k|#ifdef HAVE_BZLIB_H
 1965|  4.89k|        if (param->alg == PGP_C_BZIP2) {
  ------------------
  |  Branch (1965:13): [True: 1.03k, False: 3.86k]
  ------------------
 1966|  1.03k|            BZ2_bzCompressEnd(&param->bz);
 1967|  1.03k|        }
 1968|  4.89k|#endif
 1969|  4.89k|    }
 1970|       |
 1971|  5.29k|    close_streamed_packet(&param->pkt, discard);
 1972|  5.29k|    free(param);
 1973|       |    dst->param = NULL;
 1974|  5.29k|}
stream-write.cpp:_ZL21close_streamed_packetP23pgp_dest_packet_param_tb:
  325|  15.7k|{
  326|  15.7k|    if (param->partial) {
  ------------------
  |  Branch (326:9): [True: 15.3k, False: 317]
  ------------------
  327|  15.3k|        dst_close(param->writedst, discard);
  328|  15.3k|        delete param->writedst;
  329|       |        param->writedst = NULL;
  330|  15.3k|    }
  331|  15.7k|}
stream-write.cpp:_ZL20init_streamed_packetR23pgp_dest_packet_param_tR10pgp_dest_t:
  267|  15.3k|{
  268|  15.3k|    rnp_result_t ret = RNP_ERROR_GENERIC;
  269|       |
  270|  15.3k|    if (param.partial) {
  ------------------
  |  Branch (270:9): [True: 15.3k, False: 0]
  ------------------
  271|  15.3k|        param.hdr[0] = param.tag | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   47|  15.3k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                      param.hdr[0] = param.tag | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   56|  15.3k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  272|  15.3k|        dst_write(&dst, &param.hdr, 1);
  273|       |
  274|  15.3k|        if (!(param.writedst = new (std::nothrow) pgp_dest_t)) {
  ------------------
  |  Branch (274:13): [True: 0, False: 15.3k]
  ------------------
  275|      0|            RNP_LOG("part len dest allocation failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  276|      0|            return false;
  277|      0|        }
  278|  15.3k|        ret = init_partial_pkt_dst(*param.writedst, dst);
  279|  15.3k|        if (ret) {
  ------------------
  |  Branch (279:13): [True: 0, False: 15.3k]
  ------------------
  280|       |            /* LCOV_EXCL_START */
  281|      0|            delete param.writedst;
  282|      0|            param.writedst = NULL;
  283|      0|            return false;
  284|       |            /* LCOV_EXCL_END */
  285|      0|        }
  286|  15.3k|        param.origdst = &dst;
  287|       |
  288|  15.3k|        param.hdr[1] = ((pgp_dest_partial_param_t *) param.writedst->param)->parthdr;
  289|  15.3k|        param.hdrlen = 2;
  290|  15.3k|        return true;
  291|  15.3k|    }
  292|       |
  293|       |    /* LCOV_EXCL_START this branch is not used at all */
  294|      0|    if (param.indeterminate) {
  ------------------
  |  Branch (294:9): [True: 0, False: 0]
  ------------------
  295|      0|        if (param.tag > 0xf) {
  ------------------
  |  Branch (295:13): [True: 0, False: 0]
  ------------------
  296|      0|            RNP_LOG("indeterminate tag > 0xf");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  297|      0|        }
  298|       |
  299|      0|        param.hdr[0] = ((param.tag & 0xf) << PGP_PTAG_OF_CONTENT_TAG_SHIFT) |
  ------------------
  |  |   74|      0|#define PGP_PTAG_OF_CONTENT_TAG_SHIFT 2
  ------------------
  300|      0|                       PGP_PTAG_OLD_LEN_INDETERMINATE;
  301|      0|        param.hdrlen = 1;
  302|      0|        dst_write(&dst, &param.hdr, 1);
  303|       |
  304|      0|        param.writedst = &dst;
  305|      0|        param.origdst = &dst;
  306|      0|        return true;
  307|      0|    }
  308|       |
  309|      0|    RNP_LOG("wrong call");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  310|      0|    return false;
  311|       |    /* LCOV_EXCL_END */
  312|      0|}
stream-write.cpp:_ZL20init_partial_pkt_dstR10pgp_dest_tS0_:
  242|  15.3k|{
  243|  15.3k|    pgp_dest_partial_param_t *param = NULL;
  244|       |
  245|  15.3k|    if (!init_dst_common(&dst, sizeof(*param))) {
  ------------------
  |  Branch (245:9): [True: 0, False: 15.3k]
  ------------------
  246|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
  247|      0|    }
  248|       |
  249|  15.3k|    param = (pgp_dest_partial_param_t *) dst.param;
  250|  15.3k|    param->writedst = &writedst;
  251|  15.3k|    param->partlen = PGP_PARTIAL_PKT_BLOCK_SIZE;
  ------------------
  |  |   68|  15.3k|#define PGP_PARTIAL_PKT_BLOCK_SIZE (1 << PGP_PARTIAL_PKT_SIZE_BITS)
  |  |  ------------------
  |  |  |  |   67|  15.3k|#define PGP_PARTIAL_PKT_SIZE_BITS (13)
  |  |  ------------------
  ------------------
  252|  15.3k|    param->parthdr = 0xE0 | PGP_PARTIAL_PKT_SIZE_BITS;
  ------------------
  |  |   67|  15.3k|#define PGP_PARTIAL_PKT_SIZE_BITS (13)
  ------------------
  253|  15.3k|    dst.param = param;
  254|  15.3k|    dst.write = partial_dst_write;
  255|  15.3k|    dst.finish = partial_dst_finish;
  256|  15.3k|    dst.close = partial_dst_close;
  257|  15.3k|    dst.type = PGP_STREAM_PARLEN_PACKET;
  258|       |
  259|  15.3k|    return RNP_SUCCESS;
  260|  15.3k|}
stream-write.cpp:_ZL17partial_dst_writeP10pgp_dest_tPKvm:
  180|  20.8k|{
  181|  20.8k|    pgp_dest_partial_param_t *param = (pgp_dest_partial_param_t *) dst->param;
  182|  20.8k|    if (!param) {
  ------------------
  |  Branch (182:9): [True: 0, False: 20.8k]
  ------------------
  183|       |        /* LCOV_EXCL_START */
  184|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  185|      0|        return RNP_ERROR_BAD_PARAMETERS;
  186|       |        /* LCOV_EXCL_END */
  187|      0|    }
  188|       |
  189|  20.8k|    if (len > param->partlen - param->len) {
  ------------------
  |  Branch (189:9): [True: 7.21k, False: 13.6k]
  ------------------
  190|       |        /* we have full part - in block and in buf */
  191|  7.21k|        size_t wrlen = param->partlen - param->len;
  192|  7.21k|        dst_write(param->writedst, &param->parthdr, 1);
  193|  7.21k|        dst_write(param->writedst, param->part, param->len);
  194|  7.21k|        dst_write(param->writedst, buf, wrlen);
  195|       |
  196|  7.21k|        buf = (uint8_t *) buf + wrlen;
  197|  7.21k|        len -= wrlen;
  198|  7.21k|        param->len = 0;
  199|       |
  200|       |        /* writing all full parts directly from buf */
  201|  26.8k|        while (len >= param->partlen) {
  ------------------
  |  Branch (201:16): [True: 19.6k, False: 7.21k]
  ------------------
  202|  19.6k|            dst_write(param->writedst, &param->parthdr, 1);
  203|  19.6k|            dst_write(param->writedst, buf, param->partlen);
  204|  19.6k|            buf = (uint8_t *) buf + param->partlen;
  205|  19.6k|            len -= param->partlen;
  206|  19.6k|        }
  207|  7.21k|    }
  208|       |
  209|       |    /* caching rest of the buf */
  210|  20.8k|    if (len > 0) {
  ------------------
  |  Branch (210:9): [True: 14.5k, False: 6.28k]
  ------------------
  211|  14.5k|        memcpy(&param->part[param->len], buf, len);
  212|  14.5k|        param->len += len;
  213|  14.5k|    }
  214|       |
  215|  20.8k|    return RNP_SUCCESS;
  216|  20.8k|}
stream-write.cpp:_ZL18partial_dst_finishP10pgp_dest_t:
  220|  14.5k|{
  221|  14.5k|    pgp_dest_partial_param_t *param = (pgp_dest_partial_param_t *) dst->param;
  222|  14.5k|    uint8_t                   hdr[5];
  223|  14.5k|    int                       lenlen;
  224|       |
  225|  14.5k|    lenlen = write_packet_len(hdr, param->len);
  226|  14.5k|    dst_write(param->writedst, hdr, lenlen);
  227|  14.5k|    dst_write(param->writedst, param->part, param->len);
  228|       |
  229|  14.5k|    return param->writedst->werr;
  230|  14.5k|}
stream-write.cpp:_ZL17partial_dst_closeP10pgp_dest_tb:
  234|  15.3k|{
  235|  15.3k|    pgp_dest_partial_param_t *param = (pgp_dest_partial_param_t *) dst->param;
  236|  15.3k|    free(param);
  237|       |    dst->param = NULL;
  238|  15.3k|}
stream-write.cpp:_ZL15init_signed_dstR9rnp_ctx_tR10pgp_dest_tS2_:
 1740|    718|{
 1741|    718|    pgp_dest_signed_param_t *param = NULL;
 1742|    718|    rnp_result_t             ret = RNP_ERROR_GENERIC;
 1743|       |
 1744|    718|    try {
 1745|    718|        dst = pgp_dest_t();
 1746|    718|    } catch (const std::exception &e) {
 1747|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 1748|      0|    }
 1749|    718|    try {
 1750|    718|        param = new pgp_dest_signed_param_t();
 1751|    718|    } catch (const std::exception &e) {
 1752|       |        /* LCOV_EXCL_START */
 1753|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1754|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 1755|       |        /* LCOV_EXCL_END */
 1756|      0|    }
 1757|       |
 1758|    718|    dst.param = param;
 1759|    718|    param->writedst = &writedst;
 1760|    718|    param->ctx = &ctx;
 1761|    718|    param->password_provider = &ctx.pass_provider;
 1762|    718|    if (param->ctx->clearsign) {
  ------------------
  |  Branch (1762:9): [True: 0, False: 718]
  ------------------
 1763|      0|        dst.type = PGP_STREAM_CLEARTEXT;
 1764|      0|        dst.write = cleartext_dst_write;
 1765|      0|        dst.finish = cleartext_dst_finish;
 1766|      0|        param->clr_start = true;
 1767|    718|    } else {
 1768|    718|        dst.type = PGP_STREAM_SIGNED;
 1769|    718|        dst.write = signed_dst_write;
 1770|    718|        dst.finish = param->ctx->detached ? signed_detached_dst_finish : signed_dst_finish;
  ------------------
  |  Branch (1770:22): [True: 0, False: 718]
  ------------------
 1771|    718|    }
 1772|    718|    dst.close = signed_dst_close;
 1773|       |
 1774|       |    /* Getting signer's infos, writing one-pass signatures if needed */
 1775|    718|    for (auto &sg : ctx.signers) {
  ------------------
  |  Branch (1775:19): [True: 0, False: 718]
  ------------------
 1776|      0|        ret =
 1777|      0|          signed_add_signer(*param, sg, param->ctx->sec_ctx.rng, &sg == &ctx.signers.back());
 1778|      0|        if (ret) {
  ------------------
  |  Branch (1778:13): [True: 0, False: 0]
  ------------------
 1779|      0|            RNP_LOG("failed to add one-pass signature for signer");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1780|      0|            goto finish;
 1781|      0|        }
 1782|      0|    }
 1783|       |
 1784|       |    /* Do we have any signatures? */
 1785|    718|    if (param->hashes.hashes.empty()) {
  ------------------
  |  Branch (1785:9): [True: 718, False: 0]
  ------------------
 1786|    718|        ret = RNP_ERROR_BAD_PARAMETERS;
 1787|    718|        goto finish;
 1788|    718|    }
 1789|       |
 1790|       |    /* Writing headers for cleartext signed document */
 1791|      0|    if (param->ctx->clearsign) {
  ------------------
  |  Branch (1791:9): [True: 0, False: 0]
  ------------------
 1792|      0|        dst_write(param->writedst, ST_CLEAR_BEGIN, strlen(ST_CLEAR_BEGIN));
  ------------------
  |  |   48|      0|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
                      dst_write(param->writedst, ST_CLEAR_BEGIN, strlen(ST_CLEAR_BEGIN));
  ------------------
  |  |   48|      0|#define ST_CLEAR_BEGIN ("-----BEGIN PGP SIGNED MESSAGE-----")
  ------------------
 1793|      0|        dst_write(param->writedst, ST_CRLF, strlen(ST_CRLF));
  ------------------
  |  |   40|      0|#define ST_CRLF ("\r\n")
  ------------------
                      dst_write(param->writedst, ST_CRLF, strlen(ST_CRLF));
  ------------------
  |  |   40|      0|#define ST_CRLF ("\r\n")
  ------------------
 1794|      0|        dst_write(param->writedst, ST_HEADER_HASH, strlen(ST_HEADER_HASH));
  ------------------
  |  |   52|      0|#define ST_HEADER_HASH ("Hash: ")
  ------------------
                      dst_write(param->writedst, ST_HEADER_HASH, strlen(ST_HEADER_HASH));
  ------------------
  |  |   52|      0|#define ST_HEADER_HASH ("Hash: ")
  ------------------
 1795|       |
 1796|      0|        auto halg_list = param->hashes.hash_algs();
 1797|      0|        for (pgp_hash_alg_t halg : halg_list) {
  ------------------
  |  Branch (1797:34): [True: 0, False: 0]
  ------------------
 1798|      0|            auto hname = rnp::Hash::name(halg);
 1799|      0|            dst_write(param->writedst, hname, strlen(hname));
 1800|      0|            if (halg != halg_list.back()) {
  ------------------
  |  Branch (1800:17): [True: 0, False: 0]
  ------------------
 1801|      0|                dst_write(param->writedst, ST_COMMA, 1);
  ------------------
  |  |   43|      0|#define ST_COMMA (",")
  ------------------
 1802|      0|            }
 1803|      0|        }
 1804|       |
 1805|      0|        dst_write(param->writedst, ST_CRLFCRLF, strlen(ST_CRLFCRLF));
  ------------------
  |  |   41|      0|#define ST_CRLFCRLF ("\r\n\r\n")
  ------------------
                      dst_write(param->writedst, ST_CRLFCRLF, strlen(ST_CRLFCRLF));
  ------------------
  |  |   41|      0|#define ST_CRLFCRLF ("\r\n\r\n")
  ------------------
 1806|      0|    }
 1807|       |
 1808|      0|    ret = RNP_SUCCESS;
 1809|    718|finish:
 1810|    718|    if (ret != RNP_SUCCESS) {
  ------------------
  |  Branch (1810:9): [True: 718, False: 0]
  ------------------
 1811|    718|        signed_dst_close(&dst, true);
 1812|    718|    }
 1813|       |
 1814|    718|    return ret;
 1815|      0|}
_ZN23pgp_dest_signed_param_tC2Ev:
  166|    718|    pgp_dest_signed_param_t() = default;
stream-write.cpp:_ZL16signed_dst_closeP10pgp_dest_tb:
 1613|    718|{
 1614|    718|    pgp_dest_signed_param_t *param = (pgp_dest_signed_param_t *) dst->param;
 1615|    718|    delete param;
 1616|       |    dst->param = NULL;
 1617|    718|}
_ZN23pgp_dest_signed_param_tD2Ev:
  167|    718|    ~pgp_dest_signed_param_t() = default;
stream-write.cpp:_ZL17build_literal_hdrRK9rnp_ctx_tR17pgp_literal_hdr_tb:
 2109|  1.95k|{
 2110|       |    /* content type - forcing binary now */
 2111|  1.95k|    hdr.format = 'b';
 2112|       |    /* RFC 9580: filename and timestamp SHOULD NOT be written for v6 messages;
 2113|       |     * v4/v5 output keeps them so legacy consumers still see the name. */
 2114|  1.95k|    if (v6_output) {
  ------------------
  |  Branch (2114:9): [True: 1.94k, False: 11]
  ------------------
 2115|  1.94k|        return;
 2116|  1.94k|    }
 2117|       |    /* filename */
 2118|     11|    size_t flen = ctx.filename.size();
 2119|     11|    if (flen > 255) {
  ------------------
  |  Branch (2119:9): [True: 0, False: 11]
  ------------------
 2120|      0|        RNP_LOG("filename too long, truncating");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2121|      0|        flen = 255;
 2122|      0|    }
 2123|     11|    hdr.fname_len = flen;
 2124|     11|    memcpy(hdr.fname, ctx.filename.c_str(), flen);
 2125|       |    /* timestamp */
 2126|     11|    hdr.timestamp = ctx.filemtime;
 2127|     11|}
stream-write.cpp:_ZL16init_literal_dstR17pgp_literal_hdr_tR10pgp_dest_tS2_:
 2131|  1.95k|{
 2132|  1.95k|    pgp_dest_packet_param_t *param = NULL;
 2133|       |
 2134|  1.95k|    if (!init_dst_common(&dst, sizeof(*param))) {
  ------------------
  |  Branch (2134:9): [True: 0, False: 1.95k]
  ------------------
 2135|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 2136|      0|    }
 2137|       |
 2138|  1.95k|    param = (pgp_dest_packet_param_t *) dst.param;
 2139|  1.95k|    dst.write = literal_dst_write;
 2140|  1.95k|    dst.finish = literal_dst_finish;
 2141|  1.95k|    dst.close = literal_dst_close;
 2142|  1.95k|    dst.type = PGP_STREAM_LITERAL;
 2143|  1.95k|    param->partial = true;
 2144|  1.95k|    param->indeterminate = false;
 2145|  1.95k|    param->tag = PGP_PKT_LITDATA;
 2146|       |
 2147|       |    /* initializing partial length or indeterminate packet, writing header */
 2148|  1.95k|    if (!init_streamed_packet(*param, writedst)) {
  ------------------
  |  Branch (2148:9): [True: 0, False: 1.95k]
  ------------------
 2149|       |        /* LCOV_EXCL_START */
 2150|      0|        RNP_LOG("failed to init streamed packet");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2151|      0|        literal_dst_close(&dst, true);
 2152|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2153|       |        /* LCOV_EXCL_END */
 2154|      0|    }
 2155|       |    /* content type - forcing binary now */
 2156|  1.95k|    uint8_t buf[4] = {0};
 2157|  1.95k|    buf[0] = hdr.format;
 2158|       |    /* filename length */
 2159|  1.95k|    buf[1] = hdr.fname_len;
 2160|  1.95k|    dst_write(param->writedst, buf, 2);
 2161|       |    /* filename */
 2162|  1.95k|    if (hdr.fname_len) {
  ------------------
  |  Branch (2162:9): [True: 11, False: 1.94k]
  ------------------
 2163|     11|        dst_write(param->writedst, hdr.fname, hdr.fname_len);
 2164|     11|    }
 2165|       |    /* timestamp */
 2166|  1.95k|    write_uint32(buf, hdr.timestamp);
 2167|  1.95k|    dst_write(param->writedst, buf, 4);
 2168|  1.95k|    return RNP_SUCCESS;
 2169|  1.95k|}
stream-write.cpp:_ZL17literal_dst_writeP10pgp_dest_tPKvm:
 2055|  3.32k|{
 2056|  3.32k|    pgp_dest_packet_param_t *param = (pgp_dest_packet_param_t *) dst->param;
 2057|       |
 2058|  3.32k|    if (!param) {
  ------------------
  |  Branch (2058:9): [True: 0, False: 3.32k]
  ------------------
 2059|       |        /* LCOV_EXCL_START */
 2060|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2061|      0|        return RNP_ERROR_BAD_PARAMETERS;
 2062|       |        /* LCOV_EXCL_END */
 2063|      0|    }
 2064|       |
 2065|  3.32k|    dst_write(param->writedst, buf, len);
 2066|  3.32k|    return RNP_SUCCESS;
 2067|  3.32k|}
stream-write.cpp:_ZL18literal_dst_finishP10pgp_dest_t:
 2071|  1.95k|{
 2072|  1.95k|    return finish_streamed_packet((pgp_dest_packet_param_t *) dst->param);
 2073|  1.95k|}
stream-write.cpp:_ZL17literal_dst_closeP10pgp_dest_tb:
 2077|  1.95k|{
 2078|  1.95k|    pgp_dest_packet_param_t *param = (pgp_dest_packet_param_t *) dst->param;
 2079|       |
 2080|  1.95k|    if (!param) {
  ------------------
  |  Branch (2080:9): [True: 0, False: 1.95k]
  ------------------
 2081|      0|        return; // LCOV_EXCL_LINE
 2082|      0|    }
 2083|       |
 2084|  1.95k|    close_streamed_packet(param, discard);
 2085|  1.95k|    free(param);
 2086|       |    dst->param = NULL;
 2087|  1.95k|}
stream-write.cpp:_ZL23process_stream_sequenceR12pgp_source_tP10pgp_dest_tjS2_S2_:
 2177|  7.72k|{
 2178|  7.72k|    std::unique_ptr<uint8_t[]> readbuf(new (std::nothrow) uint8_t[PGP_INPUT_CACHE_SIZE]);
  ------------------
  |  |   35|  7.72k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
 2179|  7.72k|    if (!readbuf) {
  ------------------
  |  Branch (2179:9): [True: 0, False: 7.72k]
  ------------------
 2180|       |        /* LCOV_EXCL_START */
 2181|      0|        RNP_LOG("allocation failure");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2182|      0|        return RNP_ERROR_OUT_OF_MEMORY;
 2183|       |        /* LCOV_EXCL_END */
 2184|      0|    }
 2185|       |
 2186|       |    /* processing source stream */
 2187|  18.3k|    while (!src.eof_) {
  ------------------
  |  Branch (2187:12): [True: 10.6k, False: 7.72k]
  ------------------
 2188|  10.6k|        size_t read = 0;
 2189|  10.6k|        if (!src.read(readbuf.get(), PGP_INPUT_CACHE_SIZE, &read)) {
  ------------------
  |  |   35|  10.6k|#define PGP_INPUT_CACHE_SIZE 32768
  ------------------
  |  Branch (2189:13): [True: 0, False: 10.6k]
  ------------------
 2190|      0|            RNP_LOG("failed to read from source");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2191|      0|            return RNP_ERROR_READ;
 2192|  10.6k|        } else if (!read) {
  ------------------
  |  Branch (2192:20): [True: 0, False: 10.6k]
  ------------------
 2193|      0|            continue;
 2194|      0|        }
 2195|       |
 2196|  10.6k|        if (sstream) {
  ------------------
  |  Branch (2196:13): [True: 0, False: 10.6k]
  ------------------
 2197|      0|            signed_dst_update(sstream, readbuf.get(), read);
 2198|      0|        }
 2199|       |
 2200|  10.6k|        if (wstream) {
  ------------------
  |  Branch (2200:13): [True: 10.6k, False: 0]
  ------------------
 2201|  10.6k|            dst_write(wstream, readbuf.get(), read);
 2202|       |
 2203|  34.7k|            for (int i = count - 1; i >= 0; i--) {
  ------------------
  |  Branch (2203:37): [True: 24.1k, False: 10.6k]
  ------------------
 2204|  24.1k|                if (streams[i].werr) {
  ------------------
  |  Branch (2204:21): [True: 0, False: 24.1k]
  ------------------
 2205|      0|                    RNP_LOG("failed to process data");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2206|      0|                    return RNP_ERROR_WRITE;
 2207|      0|                }
 2208|  24.1k|            }
 2209|  10.6k|        }
 2210|  10.6k|    }
 2211|       |
 2212|       |    /* finalizing destinations */
 2213|  25.0k|    for (int i = count - 1; i >= 0; i--) {
  ------------------
  |  Branch (2213:29): [True: 17.3k, False: 7.72k]
  ------------------
 2214|  17.3k|        rnp_result_t ret = dst_finish(&streams[i]);
 2215|  17.3k|        if (ret) {
  ------------------
  |  Branch (2215:13): [True: 0, False: 17.3k]
  ------------------
 2216|      0|            RNP_LOG("failed to finish stream");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2217|      0|            return ret;
 2218|      0|        }
 2219|  17.3k|    }
 2220|  7.72k|    return RNP_SUCCESS;
 2221|  7.72k|}
stream-write.cpp:_ZL18init_encrypted_dstR9rnp_ctx_tR10pgp_dest_tS2_:
 1178|  12.0k|{
 1179|  12.0k|    size_t keylen = pgp_key_size(ctx.ealg);
 1180|  12.0k|    if (!keylen) {
  ------------------
  |  Branch (1180:9): [True: 0, False: 12.0k]
  ------------------
 1181|      0|        RNP_LOG("unknown symmetric algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1182|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1183|      0|    }
 1184|       |
 1185|  12.0k|    if (ctx.aalg != PGP_AEAD_NONE) {
  ------------------
  |  Branch (1185:9): [True: 6.35k, False: 5.67k]
  ------------------
 1186|  6.35k|        if ((ctx.aalg != PGP_AEAD_EAX) && (ctx.aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (1186:13): [True: 4.30k, False: 2.04k]
  |  Branch (1186:43): [True: 1.16k, False: 3.14k]
  ------------------
 1187|  1.16k|#if defined(ENABLE_AEAD_GCM)
 1188|  1.16k|            && (ctx.aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (1188:16): [True: 0, False: 1.16k]
  ------------------
 1189|  6.35k|#endif
 1190|  6.35k|        ) {
 1191|       |            /* LCOV_EXCL_START */
 1192|      0|            RNP_LOG("unknown AEAD algorithm: %d", (int) ctx.aalg);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1193|      0|            return RNP_ERROR_BAD_PARAMETERS;
 1194|       |            /* LCOV_EXCL_END */
 1195|      0|        }
 1196|       |
 1197|  6.35k|        if ((pgp_block_size(ctx.ealg) != 16)) {
  ------------------
  |  Branch (1197:13): [True: 0, False: 6.35k]
  ------------------
 1198|       |            /* LCOV_EXCL_START */
 1199|      0|            RNP_LOG("wrong AEAD symmetric algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1200|      0|            return RNP_ERROR_BAD_PARAMETERS;
 1201|       |            /* LCOV_EXCL_END */
 1202|      0|        }
 1203|       |
 1204|  6.35k|        if ((ctx.abits < 0) || (ctx.abits > 16)) {
  ------------------
  |  Branch (1204:13): [True: 0, False: 6.35k]
  |  Branch (1204:32): [True: 0, False: 6.35k]
  ------------------
 1205|       |            /* LCOV_EXCL_START */
 1206|      0|            RNP_LOG("wrong AEAD chunk bits: %d", ctx.abits);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1207|      0|            return RNP_ERROR_BAD_PARAMETERS;
 1208|       |            /* LCOV_EXCL_END */
 1209|      0|        }
 1210|  6.35k|    }
 1211|       |
 1212|  12.0k|    if (ctx.recipients.empty() && ctx.passwords.empty()) {
  ------------------
  |  Branch (1212:9): [True: 11.9k, False: 42]
  |  Branch (1212:35): [True: 3.58k, False: 8.40k]
  ------------------
 1213|  3.58k|        RNP_LOG("no recipients");
  ------------------
  |  |   84|  3.58k|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|  3.58k|    do {                                                                                 \
  |  |  |  |   77|  3.58k|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 3.58k, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|  3.58k|            break;                                                                       \
  |  |  |  |   79|  3.58k|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1214|  3.58k|        return RNP_ERROR_BAD_PARAMETERS;
 1215|  3.58k|    }
 1216|       |
 1217|  8.44k|    try {
 1218|  8.44k|        dst = pgp_dest_t();
 1219|  8.44k|    } catch (const std::exception &e) {
 1220|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 1221|      0|    }
 1222|  8.44k|    auto param = new (std::nothrow) pgp_dest_encrypted_param_t(ctx);
 1223|  8.44k|    if (!param) {
  ------------------
  |  Branch (1223:9): [True: 0, False: 8.44k]
  ------------------
 1224|      0|        return RNP_ERROR_OUT_OF_MEMORY; // LCOV_EXCL_LINE
 1225|      0|    }
 1226|  8.44k|    dst.param = param;
 1227|  8.44k|    param->auth_type = ctx.aalg == PGP_AEAD_NONE ? rnp::AuthType::MDC : rnp::AuthType::AEADv1;
  ------------------
  |  Branch (1227:24): [True: 4.34k, False: 4.10k]
  ------------------
 1228|       |
 1229|  8.44k|#if defined(ENABLE_CRYPTO_REFRESH)
 1230|  8.44k|    if (seipdv2_capable(ctx)) {
  ------------------
  |  Branch (1230:9): [True: 1.83k, False: 6.61k]
  ------------------
 1231|  1.83k|        param->auth_type = rnp::AuthType::AEADv2;
 1232|  1.83k|    }
 1233|  8.44k|#endif
 1234|       |
 1235|  8.44k|    param->aalg = ctx.aalg;
 1236|  8.44k|    param->pkt.origdst = &writedst;
 1237|       |    // the following assignment is covered for the v2 SEIPD case further below
 1238|  8.44k|    dst.write = param->is_aead_auth() ? encrypted_dst_write_aead : encrypted_dst_write_cfb;
  ------------------
  |  Branch (1238:17): [True: 4.10k, False: 4.34k]
  ------------------
 1239|  8.44k|    dst.finish = encrypted_dst_finish;
 1240|  8.44k|    dst.close = encrypted_dst_close;
 1241|  8.44k|    dst.type = PGP_STREAM_ENCRYPTED;
 1242|       |
 1243|  8.44k|    rnp::secure_bytes enckey(keylen, 0); /* content encryption key */
 1244|       |
 1245|       |    /* Build SKESK and generate CEK */
 1246|  8.44k|    rnp_result_t ret = RNP_ERROR_BAD_PARAMETERS;
 1247|  8.44k|    if (!encrypted_build_cek(*param, enckey, keylen)) {
  ------------------
  |  Branch (1247:9): [True: 317, False: 8.12k]
  ------------------
 1248|    317|        goto finish;
 1249|    317|    }
 1250|       |
 1251|       |    /* Configuring and writing pk-encrypted session keys */
 1252|  8.12k|    for (auto recipient : ctx.recipients) {
  ------------------
  |  Branch (1252:25): [True: 41, False: 8.12k]
  ------------------
 1253|     41|        pgp_pkesk_version_t pkesk_version = PGP_PKSK_V3;
 1254|     41|#if defined(ENABLE_CRYPTO_REFRESH)
 1255|     41|        if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1255:13): [True: 0, False: 41]
  ------------------
 1256|      0|            pkesk_version = PGP_PKSK_V6;
 1257|      0|        }
 1258|     41|        if (param->is_aead_auth() && (param->ctx.aalg == PGP_AEAD_NONE)) {
  ------------------
  |  Branch (1258:13): [True: 16, False: 25]
  |  Branch (1258:38): [True: 0, False: 16]
  ------------------
 1259|       |            // set default AEAD if not set
 1260|      0|            param->ctx.aalg = DEFAULT_AEAD_ALG;
  ------------------
  |  |   47|      0|#define DEFAULT_AEAD_ALG PGP_AEAD_OCB
  ------------------
 1261|      0|        }
 1262|     41|#endif
 1263|     41|        ret = encrypted_add_recipient(ctx, dst, recipient, enckey, pkesk_version);
 1264|     41|        if (ret) {
  ------------------
  |  Branch (1264:13): [True: 0, False: 41]
  ------------------
 1265|      0|            goto finish;
 1266|      0|        }
 1267|     41|    }
 1268|       |
 1269|       |    /* Writing sk-encrypted session key(s) */
 1270|  8.12k|    for (auto &skesk : param->skesks) {
  ------------------
  |  Branch (1270:22): [True: 8.10k, False: 8.12k]
  ------------------
 1271|  8.10k|        skesk.write(*param->pkt.origdst);
 1272|  8.10k|    }
 1273|       |
 1274|       |    /* Initializing partial packet writer */
 1275|  8.12k|    param->pkt.partial = true;
 1276|  8.12k|    param->pkt.indeterminate = false;
 1277|  8.12k|    if (param->auth_type == rnp::AuthType::AEADv1) {
  ------------------
  |  Branch (1277:9): [True: 2.08k, False: 6.03k]
  ------------------
 1278|  2.08k|        param->pkt.tag = PGP_PKT_AEAD_ENCRYPTED;
 1279|  6.03k|    } else {
 1280|       |        /* We do not generate PGP_PKT_SE_DATA, leaving this just in case */
 1281|  6.03k|        param->pkt.tag =
 1282|  6.03k|          param->auth_type == rnp::AuthType::MDC ? PGP_PKT_SE_IP_DATA : PGP_PKT_SE_DATA;
  ------------------
  |  Branch (1282:11): [True: 4.34k, False: 1.69k]
  ------------------
 1283|  6.03k|#ifdef ENABLE_CRYPTO_REFRESH
 1284|  6.03k|        if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1284:13): [True: 1.69k, False: 4.34k]
  ------------------
 1285|  1.69k|            param->pkt.tag = PGP_PKT_SE_IP_DATA;
 1286|  1.69k|        }
 1287|  6.03k|#endif
 1288|  6.03k|    }
 1289|       |
 1290|       |    /* initializing partial data length writer */
 1291|       |    /* we may use intederminate len packet here as well, for compatibility or so on */
 1292|  8.12k|    if (!init_streamed_packet(param->pkt, writedst)) {
  ------------------
  |  Branch (1292:9): [True: 0, False: 8.12k]
  ------------------
 1293|       |        /* LCOV_EXCL_START */
 1294|      0|        RNP_LOG("failed to init streamed packet");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1295|      0|        ret = RNP_ERROR_BAD_PARAMETERS;
 1296|      0|        goto finish;
 1297|       |        /* LCOV_EXCL_END */
 1298|      0|    }
 1299|       |
 1300|  8.12k|    if (param->is_aead_auth()) {
  ------------------
  |  Branch (1300:9): [True: 3.78k, False: 4.34k]
  ------------------
 1301|       |        /* initialize AEAD encryption */
 1302|  3.78k|        ret = encrypted_start_aead(param, enckey.data());
 1303|  4.34k|    } else {
 1304|       |        /* initialize old CFB or CFB with MDC */
 1305|  4.34k|        ret = encrypted_start_cfb(param, enckey.data());
 1306|  4.34k|    }
 1307|  8.44k|finish:
 1308|  8.44k|    ctx.passwords.clear();
 1309|  8.44k|    if (ret) {
  ------------------
  |  Branch (1309:9): [True: 317, False: 8.12k]
  ------------------
 1310|    317|        encrypted_dst_close(&dst, true);
 1311|    317|    }
 1312|  8.44k|    return ret;
 1313|  8.12k|}
_ZN26pgp_dest_encrypted_param_tC2ER9rnp_ctx_t:
  115|  8.44k|    pgp_dest_encrypted_param_t(rnp_ctx_t &actx) : ctx(actx), aalg(PGP_AEAD_NONE)
  116|  8.44k|    {
  117|  8.44k|    }
_ZN26pgp_dest_encrypted_param_t12is_aead_authEv:
  121|  44.9k|    {
  122|  44.9k|        switch (this->auth_type) {
  123|  13.0k|        case rnp::AuthType::AEADv1:
  ------------------
  |  Branch (123:9): [True: 13.0k, False: 31.9k]
  ------------------
  124|  13.0k|#ifdef ENABLE_CRYPTO_REFRESH
  125|  23.5k|        case rnp::AuthType::AEADv2:
  ------------------
  |  Branch (125:9): [True: 10.5k, False: 34.4k]
  ------------------
  126|  23.5k|#endif
  127|  23.5k|            return true;
  128|  21.4k|        default:
  ------------------
  |  Branch (128:9): [True: 21.4k, False: 23.5k]
  ------------------
  129|  21.4k|            return false;
  130|  44.9k|        }
  131|  44.9k|    }
stream-write.cpp:_ZL24encrypted_dst_write_aeadP10pgp_dest_tPKvm:
  448|  7.07k|{
  449|       |#if !defined(ENABLE_AEAD)
  450|       |    RNP_LOG("AEAD is not enabled.");
  451|       |    return RNP_ERROR_WRITE;
  452|       |#else
  453|  7.07k|    auto param = static_cast<pgp_dest_encrypted_param_t *>(dst->param);
  454|       |
  455|  7.07k|    size_t       sz;
  456|  7.07k|    size_t       gran;
  457|  7.07k|    rnp_result_t res;
  458|       |
  459|  7.07k|    if (!param) {
  ------------------
  |  Branch (459:9): [True: 0, False: 7.07k]
  ------------------
  460|       |        /* LCOV_EXCL_START */
  461|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  462|      0|        return RNP_ERROR_BAD_PARAMETERS;
  463|       |        /* LCOV_EXCL_END */
  464|      0|    }
  465|       |
  466|  7.07k|    if (!len) {
  ------------------
  |  Branch (466:9): [True: 0, False: 7.07k]
  ------------------
  467|      0|        return RNP_SUCCESS;
  468|      0|    }
  469|       |
  470|       |    /* because of botan's FFI granularity we need to make things a bit complicated */
  471|  7.07k|    gran = pgp_cipher_aead_granularity(&param->encrypt);
  472|       |
  473|  7.07k|    if (param->cachelen > param->chunklen - param->chunkout) {
  ------------------
  |  Branch (473:9): [True: 0, False: 7.07k]
  ------------------
  474|      0|        RNP_LOG("wrong AEAD cache state");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  475|      0|        return RNP_ERROR_BAD_STATE;
  476|      0|    }
  477|       |
  478|   460k|    while (len > 0) {
  ------------------
  |  Branch (478:12): [True: 453k, False: 7.07k]
  ------------------
  479|       |        /* 2 tags to align to the PGP_INPUT_CACHE_SIZE size */
  480|   453k|        sz = std::min(sizeof(param->cache) - 2 * PGP_AEAD_MAX_TAG_LEN - param->cachelen, len);
  ------------------
  |  |   86|   453k|#define PGP_AEAD_MAX_TAG_LEN 16
  ------------------
  481|   453k|        sz = std::min(sz, param->chunklen - param->chunkout - param->cachelen);
  482|   453k|        memcpy(param->cache + param->cachelen, buf, sz);
  483|   453k|        param->cachelen += sz;
  484|       |
  485|   453k|        if (param->cachelen == param->chunklen - param->chunkout) {
  ------------------
  |  Branch (485:13): [True: 447k, False: 5.78k]
  ------------------
  486|       |            /* we have the tail of the chunk in cache */
  487|   447k|            if ((res = encrypted_start_aead_chunk(param, param->chunkidx + 1, false))) {
  ------------------
  |  Branch (487:17): [True: 0, False: 447k]
  ------------------
  488|      0|                return res;
  489|      0|            }
  490|   447k|            param->cachelen = 0;
  491|   447k|        } else if (param->cachelen >= gran) {
  ------------------
  |  Branch (491:20): [True: 5.64k, False: 149]
  ------------------
  492|       |            /* we have part of the chunk - so need to adjust it to the granularity */
  493|  5.64k|            size_t gransz = param->cachelen - param->cachelen % gran;
  494|  5.64k|            size_t inread = 0;
  495|  5.64k|            if (!pgp_cipher_aead_update(
  ------------------
  |  Branch (495:17): [True: 0, False: 5.64k]
  ------------------
  496|  5.64k|                  param->encrypt, param->cache, param->cache, gransz, inread)) {
  497|      0|                return RNP_ERROR_BAD_STATE;
  498|      0|            }
  499|  5.64k|            if (inread != gransz) {
  ------------------
  |  Branch (499:17): [True: 0, False: 5.64k]
  ------------------
  500|       |                /* LCOV_EXCL_START */
  501|      0|                RNP_LOG("Unexpected aead update: read %zu instead of %zu.", inread, gransz);
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  502|      0|                return RNP_ERROR_BAD_STATE;
  503|       |                /* LCOV_EXCL_END */
  504|      0|            }
  505|  5.64k|            dst_write(param->pkt.writedst, param->cache, gransz);
  506|  5.64k|            memmove(param->cache, param->cache + gransz, param->cachelen - gransz);
  507|  5.64k|            param->cachelen -= gransz;
  508|  5.64k|            param->chunkout += gransz;
  509|  5.64k|        }
  510|       |
  511|   453k|        len -= sz;
  512|   453k|        buf = (uint8_t *) buf + sz;
  513|   453k|    }
  514|       |
  515|  7.07k|    return RNP_SUCCESS;
  516|  7.07k|#endif
  517|  7.07k|}
stream-write.cpp:_ZL26encrypted_start_aead_chunkP26pgp_dest_encrypted_param_tmb:
  369|   455k|{
  370|   455k|    uint8_t  nonce[PGP_AEAD_MAX_NONCE_LEN];
  371|   455k|    size_t   nlen;
  372|   455k|    size_t   taglen;
  373|   455k|    bool     res;
  374|   455k|    uint64_t total;
  375|       |
  376|   455k|    taglen = pgp_cipher_aead_tag_len(param->aalg);
  377|       |
  378|       |    /* finish the previous chunk if needed*/
  379|   455k|    if ((idx > 0) && (param->chunkout + param->cachelen > 0)) {
  ------------------
  |  Branch (379:9): [True: 451k, False: 3.78k]
  |  Branch (379:22): [True: 450k, False: 849]
  ------------------
  380|   450k|        if (param->cachelen + taglen > sizeof(param->cache)) {
  ------------------
  |  Branch (380:13): [True: 0, False: 450k]
  ------------------
  381|      0|            RNP_LOG("wrong state in aead");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  382|      0|            return RNP_ERROR_BAD_STATE;
  383|      0|        }
  384|       |
  385|   450k|        if (!pgp_cipher_aead_finish(
  ------------------
  |  Branch (385:13): [True: 0, False: 450k]
  ------------------
  386|   450k|              &param->encrypt, param->cache, param->cache, param->cachelen)) {
  387|      0|            return RNP_ERROR_BAD_STATE;
  388|      0|        }
  389|       |
  390|   450k|        dst_write(param->pkt.writedst, param->cache, param->cachelen + taglen);
  391|   450k|    }
  392|       |
  393|       |    /* set chunk index for additional data */
  394|   455k|    if (param->auth_type == rnp::AuthType::AEADv1) {
  ------------------
  |  Branch (394:9): [True: 112k, False: 342k]
  ------------------
  395|   112k|        write_uint64(param->ad + param->adlen - 8, idx);
  396|   112k|    }
  397|       |
  398|   455k|    if (last) {
  ------------------
  |  Branch (398:9): [True: 3.69k, False: 451k]
  ------------------
  399|  3.69k|        if (!(param->chunkout + param->cachelen)) {
  ------------------
  |  Branch (399:13): [True: 849, False: 2.84k]
  ------------------
  400|       |            /* we need to clearly reset it since cipher was initialized but not finished */
  401|    849|            pgp_cipher_aead_reset(&param->encrypt);
  402|    849|        }
  403|       |
  404|  3.69k|        total = idx * param->chunklen;
  405|  3.69k|        if (param->cachelen + param->chunkout) {
  ------------------
  |  Branch (405:13): [True: 2.84k, False: 849]
  ------------------
  406|  2.84k|            if (param->chunklen < (param->cachelen + param->chunkout)) {
  ------------------
  |  Branch (406:17): [True: 0, False: 2.84k]
  ------------------
  407|      0|                RNP_LOG("wrong last chunk state in aead");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  408|      0|                return RNP_ERROR_BAD_STATE;
  409|      0|            }
  410|  2.84k|            total -= param->chunklen - param->cachelen - param->chunkout;
  411|  2.84k|        }
  412|       |
  413|  3.69k|        write_uint64(param->ad + param->adlen, total);
  414|  3.69k|        param->adlen += 8;
  415|  3.69k|    }
  416|   455k|    if (!pgp_cipher_aead_set_ad(&param->encrypt, param->ad, param->adlen)) {
  ------------------
  |  Branch (416:9): [True: 0, False: 455k]
  ------------------
  417|      0|        RNP_LOG("failed to set ad");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  418|      0|        return RNP_ERROR_BAD_STATE;
  419|      0|    }
  420|       |
  421|       |    /* set chunk index for nonce */
  422|   455k|    nlen = pgp_cipher_aead_nonce(param->aalg, param->iv, nonce, idx);
  423|   455k|    if (!nlen) {
  ------------------
  |  Branch (423:9): [True: 0, False: 455k]
  ------------------
  424|      0|        RNP_LOG(
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  425|      0|          "ERROR: when starting encrypted AEAD chunk: could not determine nonce length"); // LCOV_EXCL_LINE
  426|      0|    }
  427|       |
  428|       |    /* start cipher */
  429|   455k|    res = pgp_cipher_aead_start(&param->encrypt, nonce, nlen);
  430|       |
  431|       |    /* write final authentication tag */
  432|   455k|    if (last) {
  ------------------
  |  Branch (432:9): [True: 3.69k, False: 451k]
  ------------------
  433|  3.69k|        res = res && pgp_cipher_aead_finish(&param->encrypt, param->cache, param->cache, 0);
  ------------------
  |  Branch (433:15): [True: 3.69k, False: 0]
  |  Branch (433:22): [True: 3.69k, False: 0]
  ------------------
  434|  3.69k|        if (res) {
  ------------------
  |  Branch (434:13): [True: 3.69k, False: 0]
  ------------------
  435|  3.69k|            dst_write(param->pkt.writedst, param->cache, taglen);
  436|  3.69k|        }
  437|  3.69k|    }
  438|       |
  439|   455k|    param->chunkidx = idx;
  440|   455k|    param->chunkout = 0;
  441|       |
  442|   455k|    return res ? RNP_SUCCESS : RNP_ERROR_BAD_PARAMETERS;
  ------------------
  |  Branch (442:12): [True: 455k, False: 0]
  ------------------
  443|   455k|}
stream-write.cpp:_ZL23encrypted_dst_write_cfbP10pgp_dest_tPKvm:
  335|  4.74k|{
  336|  4.74k|    auto param = static_cast<pgp_dest_encrypted_param_t *>(dst->param);
  337|  4.74k|    if (!param) {
  ------------------
  |  Branch (337:9): [True: 0, False: 4.74k]
  ------------------
  338|       |        /* LCOV_EXCL_START */
  339|      0|        RNP_LOG("wrong param");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  340|      0|        return RNP_ERROR_BAD_PARAMETERS;
  341|       |        /* LCOV_EXCL_END */
  342|      0|    }
  343|       |
  344|  4.74k|    if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (344:9): [True: 4.74k, False: 0]
  ------------------
  345|  4.74k|        try {
  346|  4.74k|            param->mdc->add(buf, len);
  347|  4.74k|        } catch (const std::exception &e) {
  348|       |            /* LCOV_EXCL_START */
  349|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  350|      0|            return RNP_ERROR_BAD_STATE;
  351|       |            /* LCOV_EXCL_END */
  352|      0|        }
  353|  4.74k|    }
  354|       |
  355|  9.48k|    while (len > 0) {
  ------------------
  |  Branch (355:12): [True: 4.74k, False: 4.74k]
  ------------------
  356|  4.74k|        size_t sz = len > sizeof(param->cache) ? sizeof(param->cache) : len;
  ------------------
  |  Branch (356:21): [True: 0, False: 4.74k]
  ------------------
  357|  4.74k|        pgp_cipher_cfb_encrypt(&param->encrypt, param->cache, (const uint8_t *) buf, sz);
  358|  4.74k|        dst_write(param->pkt.writedst, param->cache, sz);
  359|  4.74k|        len -= sz;
  360|  4.74k|        buf = (uint8_t *) buf + sz;
  361|  4.74k|    }
  362|       |
  363|  4.74k|    return RNP_SUCCESS;
  364|  4.74k|}
stream-write.cpp:_ZL20encrypted_dst_finishP10pgp_dest_t:
  600|  7.72k|{
  601|  7.72k|    auto param = static_cast<pgp_dest_encrypted_param_t *>(dst->param);
  602|       |
  603|  7.72k|#if defined(ENABLE_CRYPTO_REFRESH)
  604|  7.72k|    if (param->is_v2_seipd()) {
  ------------------
  |  Branch (604:9): [True: 1.66k, False: 6.06k]
  ------------------
  605|       |        /* RFC 9580, 10.3.1: the Padding packet is the last packet of an
  606|       |         * Optionally Padded Message. */
  607|  1.66k|        encrypted_add_padding(dst);
  608|  1.66k|    }
  609|  7.72k|#endif
  610|       |
  611|  7.72k|    if (param->is_aead_auth()) {
  ------------------
  |  Branch (611:9): [True: 3.69k, False: 4.03k]
  ------------------
  612|       |#if !defined(ENABLE_AEAD)
  613|       |        RNP_LOG("AEAD is not enabled.");
  614|       |        rnp_result_t res = RNP_ERROR_NOT_IMPLEMENTED;
  615|       |#else
  616|  3.69k|        size_t chunks = param->chunkidx;
  617|       |        /* if we didn't write anything in current chunk then discard it and restart */
  618|  3.69k|        if (param->chunkout || param->cachelen) {
  ------------------
  |  Branch (618:13): [True: 2.77k, False: 926]
  |  Branch (618:32): [True: 77, False: 849]
  ------------------
  619|  2.84k|            chunks++;
  620|  2.84k|        }
  621|       |
  622|  3.69k|        rnp_result_t res = encrypted_start_aead_chunk(param, chunks, true);
  623|  3.69k|        pgp_cipher_aead_destroy(&param->encrypt);
  624|  3.69k|#endif
  625|  3.69k|        if (res) {
  ------------------
  |  Branch (625:13): [True: 0, False: 3.69k]
  ------------------
  626|      0|            finish_streamed_packet(&param->pkt);
  627|      0|            return res;
  628|      0|        }
  629|  4.03k|    } else if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (629:16): [True: 4.03k, False: 0]
  ------------------
  630|  4.03k|        uint8_t mdcbuf[MDC_V1_SIZE];
  631|  4.03k|        mdcbuf[0] = MDC_PKT_TAG;
  ------------------
  |  |  147|  4.03k|#define MDC_PKT_TAG 0xd3
  ------------------
  632|  4.03k|        mdcbuf[1] = MDC_V1_SIZE - 2;
  ------------------
  |  |  148|  4.03k|#define MDC_V1_SIZE 22
  ------------------
  633|  4.03k|        try {
  634|  4.03k|            param->mdc->add(mdcbuf, 2);
  635|  4.03k|            param->mdc->finish(&mdcbuf[2]);
  636|  4.03k|            param->mdc = nullptr;
  637|  4.03k|        } catch (const std::exception &e) {
  638|       |            /* LCOV_EXCL_START */
  639|      0|            RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  640|      0|            return RNP_ERROR_BAD_STATE;
  641|       |            /* LCOV_EXCL_END */
  642|      0|        }
  643|  4.03k|        pgp_cipher_cfb_encrypt(&param->encrypt, mdcbuf, mdcbuf, MDC_V1_SIZE);
  ------------------
  |  |  148|  4.03k|#define MDC_V1_SIZE 22
  ------------------
  644|  4.03k|        dst_write(param->pkt.writedst, mdcbuf, MDC_V1_SIZE);
  ------------------
  |  |  148|  4.03k|#define MDC_V1_SIZE 22
  ------------------
  645|  4.03k|    }
  646|       |
  647|  7.72k|    return finish_streamed_packet(&param->pkt);
  648|  7.72k|}
_ZNK26pgp_dest_encrypted_param_t11is_v2_seipdEv:
  136|  7.72k|    {
  137|  7.72k|        return this->auth_type == rnp::AuthType::AEADv2;
  138|  7.72k|    }
stream-write.cpp:_ZL21encrypted_add_paddingP10pgp_dest_t:
  561|  1.66k|{
  562|  1.66k|    auto   param = static_cast<pgp_dest_encrypted_param_t *>(dst->param);
  563|  1.66k|    size_t total = param->chunkidx * param->chunklen + param->chunkout + param->cachelen;
  564|       |    /* header: one packet tag octet plus the encoded length */
  565|  1.66k|    size_t overhead = 1 + 5;
  566|       |
  567|  1.66k|    size_t bucket = 0;
  568|  3.96k|    for (size_t cand : padding_buckets) {
  ------------------
  |  Branch (568:22): [True: 3.96k, False: 3]
  ------------------
  569|  3.96k|        if (cand >= total + overhead + 128) {
  ------------------
  |  Branch (569:13): [True: 1.66k, False: 2.30k]
  ------------------
  570|  1.66k|            bucket = cand;
  571|  1.66k|            break;
  572|  1.66k|        }
  573|  3.96k|    }
  574|  1.66k|    if (!bucket) {
  ------------------
  |  Branch (574:9): [True: 3, False: 1.66k]
  ------------------
  575|       |        /* Message is already above the largest bucket, so padding would
  576|       |         * not hide its size anyway. */
  577|      3|        return;
  578|      3|    }
  579|       |
  580|       |    /* fit the padding exactly into the bucket */
  581|  1.66k|    size_t padlen = bucket - total - overhead;
  582|  1.66k|    size_t lenoct = padding_length_octets(padlen);
  583|  1.66k|    padlen = bucket - total - 1 - lenoct;
  584|  1.66k|    if (!padlen) {
  ------------------
  |  Branch (584:9): [True: 0, False: 1.66k]
  ------------------
  585|      0|        return;
  586|      0|    }
  587|       |
  588|  1.66k|    std::vector<uint8_t> pad(1 + lenoct + padlen);
  589|  1.66k|    pad[0] = (uint8_t)(0xc0 | PGP_PKT_PADDING);
  590|  1.66k|    padding_write_length(pad.data() + 1, padlen);
  591|  1.66k|    param->ctx.sec_ctx.rng.get(pad.data() + 1 + lenoct, padlen);
  592|       |    /* write via the AEAD writer directly: the destination cache may hold
  593|       |     * the earlier content, and the padding must be encrypted immediately,
  594|       |     * before the final chunk is finished. */
  595|  1.66k|    encrypted_dst_write_aead(dst, pad.data(), pad.size());
  596|  1.66k|}
stream-write.cpp:_ZL21padding_length_octetsm:
  527|  1.66k|{
  528|  1.66k|    if (len < 192) {
  ------------------
  |  Branch (528:9): [True: 46, False: 1.61k]
  ------------------
  529|     46|        return 1;
  530|     46|    }
  531|  1.61k|    if (len <= 8383) {
  ------------------
  |  Branch (531:9): [True: 1.28k, False: 335]
  ------------------
  532|  1.28k|        return 2;
  533|  1.28k|    }
  534|    335|    return 5;
  535|  1.61k|}
stream-write.cpp:_ZL20padding_write_lengthPhm:
  539|  1.66k|{
  540|  1.66k|    if (len < 192) {
  ------------------
  |  Branch (540:9): [True: 44, False: 1.61k]
  ------------------
  541|     44|        buf[0] = (uint8_t) len;
  542|     44|        return;
  543|     44|    }
  544|  1.61k|    if (len <= 8383) {
  ------------------
  |  Branch (544:9): [True: 1.28k, False: 335]
  ------------------
  545|  1.28k|        buf[0] = (uint8_t)(((len - 192) >> 8) + 192);
  546|  1.28k|        buf[1] = (uint8_t)((len - 192) & 0xff);
  547|  1.28k|        return;
  548|  1.28k|    }
  549|    335|    buf[0] = 255;
  550|    335|    buf[1] = (uint8_t)(len >> 24);
  551|    335|    buf[2] = (uint8_t)(len >> 16);
  552|    335|    buf[3] = (uint8_t)(len >> 8);
  553|    335|    buf[4] = (uint8_t) len;
  554|    335|}
stream-write.cpp:_ZL19encrypted_dst_closeP10pgp_dest_tb:
  652|  8.44k|{
  653|  8.44k|    auto param = static_cast<pgp_dest_encrypted_param_t *>(dst->param);
  654|  8.44k|    if (!param) {
  ------------------
  |  Branch (654:9): [True: 0, False: 8.44k]
  ------------------
  655|      0|        return; // LCOV_EXCL_LINE
  656|      0|    }
  657|       |
  658|  8.44k|    if (param->is_aead_auth()) {
  ------------------
  |  Branch (658:9): [True: 4.10k, False: 4.34k]
  ------------------
  659|  4.10k|#if defined(ENABLE_AEAD)
  660|  4.10k|        pgp_cipher_aead_destroy(&param->encrypt);
  661|  4.10k|#endif
  662|  4.34k|    } else {
  663|  4.34k|        pgp_cipher_cfb_finish(&param->encrypt);
  664|  4.34k|    }
  665|  8.44k|    close_streamed_packet(&param->pkt, discard);
  666|  8.44k|    delete param;
  667|       |    dst->param = NULL;
  668|  8.44k|}
stream-write.cpp:_ZL19encrypted_build_cekR26pgp_dest_encrypted_param_tRNSt3__16vectorIhN3rnp16secure_allocatorIhEEEEm:
  940|  8.44k|{
  941|  8.44k|    auto &ctx = param.ctx;
  942|  8.44k|    if (ctx.passwords.empty()) {
  ------------------
  |  Branch (942:9): [True: 20, False: 8.42k]
  ------------------
  943|     20|        ctx.sec_ctx.rng.get(key.data(), keylen);
  944|     20|        return true;
  945|     20|    }
  946|       |
  947|       |    /* v4 single-password encryption case */
  948|  8.42k|    if (ctx.recipients.empty() && (ctx.passwords.size() == 1) && !param.is_aead_auth()) {
  ------------------
  |  Branch (948:9): [True: 8.40k, False: 22]
  |  Branch (948:35): [True: 8.40k, False: 0]
  |  Branch (948:66): [True: 4.31k, False: 4.08k]
  ------------------
  949|  4.31k|        encrypted_add_password_v4_single(param, key, keylen);
  950|  4.31k|        return true;
  951|  4.31k|    }
  952|       |
  953|  4.10k|    size_t attempts = 0;
  954|  4.10k|gencek:
  955|  4.10k|    ctx.sec_ctx.rng.get(key.data(), keylen);
  956|  4.10k|    for (auto &pass : param.ctx.passwords) {
  ------------------
  |  Branch (956:21): [True: 4.10k, False: 3.79k]
  ------------------
  957|  4.10k|        bool res = false;
  958|  4.10k|        if (param.auth_type == rnp::AuthType::AEADv1) {
  ------------------
  |  Branch (958:13): [True: 2.26k, False: 1.84k]
  ------------------
  959|  2.26k|            res = encrypted_add_password_v5(param, pass, key);
  960|  2.26k|        }
  961|  1.84k|#if defined(ENABLE_CRYPTO_REFRESH)
  962|  1.84k|        else if (param.auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (962:18): [True: 1.83k, False: 16]
  ------------------
  963|  1.83k|            res = encrypted_add_password_v6(param, pass, key);
  964|  1.83k|        }
  965|     16|#endif
  966|     16|        else {
  967|     16|            res = encrypted_add_password_v4(param, pass, key);
  968|     16|        }
  969|  4.10k|        if (!res) {
  ------------------
  |  Branch (969:13): [True: 317, False: 3.79k]
  ------------------
  970|    317|            return false;
  971|    317|        }
  972|  4.10k|    }
  973|       |
  974|  3.79k|    if (param.is_aead_auth()) {
  ------------------
  |  Branch (974:9): [True: 3.77k, False: 16]
  ------------------
  975|  3.77k|        return true;
  976|  3.77k|    }
  977|       |    /* Workaround for GnuPG symmetric key validity check: if first byte of the decrypted data
  978|       |     * is a valid symmetric algorithm number then it uses password provided, producing an error
  979|       |     * afterwards. */
  980|     16|    for (auto &pass : param.ctx.passwords) {
  ------------------
  |  Branch (980:21): [True: 16, False: 16]
  ------------------
  981|     16|        for (auto &skey : param.skesks) {
  ------------------
  |  Branch (981:25): [True: 16, False: 16]
  ------------------
  982|       |            /* attempt to decrypt cek */
  983|     16|            pgp_crypt_t crypt;
  984|     16|            if (!pgp_cipher_cfb_start(&crypt, skey.alg, pass.key.data(), NULL)) {
  ------------------
  |  Branch (984:17): [True: 0, False: 16]
  ------------------
  985|      0|                return false;
  986|      0|            }
  987|     16|            assert(skey.enckeylen == keylen + 1);
  988|     16|            rnp::secure_bytes dec(skey.enckeylen, 0);
  989|     16|            pgp_cipher_cfb_decrypt(&crypt, dec.data(), skey.enckey, skey.enckeylen);
  990|     16|            pgp_cipher_cfb_finish(&crypt);
  991|       |
  992|       |            /* using the correct key */
  993|     16|            if (!memcmp(dec.data() + 1, key.data(), keylen)) {
  ------------------
  |  Branch (993:17): [True: 16, False: 0]
  ------------------
  994|     16|                continue;
  995|     16|            }
  996|       |
  997|       |            /* check whether the first byte decrypts to valid alg name */
  998|      0|            if (pgp_key_size(static_cast<pgp_symm_alg_t>(dec[0]))) {
  ------------------
  |  Branch (998:17): [True: 0, False: 0]
  ------------------
  999|       |                /* Do not do too many attempts */
 1000|      0|                attempts++;
 1001|      0|                if (attempts >= 8) {
  ------------------
  |  Branch (1001:21): [True: 0, False: 0]
  ------------------
 1002|      0|                    break;
 1003|      0|                }
 1004|       |                /* re-generate CEK */
 1005|      0|                param.skesks.clear();
 1006|      0|                goto gencek;
 1007|      0|            }
 1008|      0|        }
 1009|     16|    }
 1010|     16|    return true;
 1011|     16|}
stream-write.cpp:_ZL32encrypted_add_password_v4_singleR26pgp_dest_encrypted_param_tRNSt3__16vectorIhN3rnp16secure_allocatorIhEEEEm:
  767|  4.31k|{
  768|  4.31k|    assert(param.ctx.passwords.size() == 1);
  769|  4.31k|    pgp_sk_sesskey_t skey{};
  770|  4.31k|    auto &           pass = param.ctx.passwords.front();
  771|  4.31k|    skey.version = PGP_SKSK_V4;
  772|  4.31k|    skey.s2k = pass.s2k;
  773|       |    /* if there are no public keys then we do not encrypt session key in the packet */
  774|  4.31k|    skey.alg = param.ctx.ealg;
  775|  4.31k|    skey.enckeylen = 0;
  776|  4.31k|    key.assign(pass.key.data(), pass.key.data() + keylen);
  777|  4.31k|    param.skesks.push_back(std::move(skey));
  778|  4.31k|}
stream-write.cpp:_ZL25encrypted_add_password_v5R26pgp_dest_encrypted_param_tRK25rnp_symmetric_pass_info_tRKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEE:
  808|  2.26k|{
  809|       |#if !defined(ENABLE_AEAD)
  810|       |    RNP_LOG("AEAD support is not enabled.");
  811|       |    return RNP_ERROR_NOT_IMPLEMENTED;
  812|       |#else
  813|       |    /* AEAD-encrypted v5 packet */
  814|  2.26k|    if ((param.ctx.aalg != PGP_AEAD_EAX) && (param.ctx.aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (814:9): [True: 1.81k, False: 447]
  |  Branch (814:45): [True: 692, False: 1.12k]
  ------------------
  815|    692|#if defined(ENABLE_AEAD_GCM)
  816|    692|        && (param.ctx.aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (816:12): [True: 0, False: 692]
  ------------------
  817|  2.26k|#endif
  818|  2.26k|    ) {
  819|      0|        RNP_LOG("unsupported AEAD algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  820|      0|        return false;
  821|      0|    }
  822|       |
  823|  2.26k|    pgp_sk_sesskey_t skey{};
  824|  2.26k|    skey.version = PGP_SKSK_V5;
  825|  2.26k|    skey.s2k = pass.s2k;
  826|  2.26k|    skey.alg = pass.s2k_cipher;
  827|  2.26k|    skey.aalg = param.ctx.aalg;
  828|  2.26k|    skey.ivlen = pgp_cipher_aead_nonce_len(skey.aalg);
  829|  2.26k|    skey.enckeylen = key.size() + pgp_cipher_aead_tag_len(skey.aalg);
  830|  2.26k|    param.ctx.sec_ctx.rng.get(skey.iv, skey.ivlen);
  831|       |
  832|       |    /* initialize cipher */
  833|  2.26k|    pgp_crypt_t kcrypt;
  834|  2.26k|    if (!pgp_cipher_aead_init(&kcrypt, skey.alg, skey.aalg, pass.key.data(), false)) {
  ------------------
  |  Branch (834:9): [True: 82, False: 2.17k]
  ------------------
  835|     82|        return false;
  836|     82|    }
  837|       |
  838|       |    /* set additional data */
  839|  2.17k|    if (!encrypted_sesk_set_ad(kcrypt, skey)) {
  ------------------
  |  Branch (839:9): [True: 0, False: 2.17k]
  ------------------
  840|      0|        return false; // LCOV_EXCL_LINE
  841|      0|    }
  842|       |
  843|       |    /* calculate nonce */
  844|  2.17k|    uint8_t nonce[PGP_AEAD_MAX_NONCE_LEN];
  845|  2.17k|    size_t  nlen = pgp_cipher_aead_nonce(skey.aalg, skey.iv, nonce, 0);
  846|       |
  847|       |    /* start cipher, encrypt key and get tag */
  848|  2.17k|    bool res = pgp_cipher_aead_start(&kcrypt, nonce, nlen) &&
  ------------------
  |  Branch (848:16): [True: 2.17k, False: 0]
  ------------------
  849|  2.17k|               pgp_cipher_aead_finish(&kcrypt, skey.enckey, key.data(), key.size());
  ------------------
  |  Branch (849:16): [True: 2.07k, False: 102]
  ------------------
  850|       |
  851|  2.17k|    pgp_cipher_aead_destroy(&kcrypt);
  852|  2.17k|    if (res) {
  ------------------
  |  Branch (852:9): [True: 2.07k, False: 102]
  ------------------
  853|  2.07k|        param.skesks.push_back(std::move(skey));
  854|  2.07k|    }
  855|  2.17k|    return res;
  856|  2.17k|#endif
  857|  2.17k|}
stream-write.cpp:_ZL25encrypted_add_password_v6R26pgp_dest_encrypted_param_tRK25rnp_symmetric_pass_info_tRKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEE:
  864|  1.83k|{
  865|       |#if !defined(ENABLE_AEAD)
  866|       |    RNP_LOG("AEAD support is not enabled.");
  867|       |    return RNP_ERROR_NOT_IMPLEMENTED;
  868|       |#else
  869|  1.83k|    if ((param.ctx.aalg != PGP_AEAD_EAX) && (param.ctx.aalg != PGP_AEAD_OCB)
  ------------------
  |  Branch (869:9): [True: 1.09k, False: 741]
  |  Branch (869:45): [True: 268, False: 823]
  ------------------
  870|    268|#if defined(ENABLE_AEAD_GCM)
  871|    268|        && (param.ctx.aalg != PGP_AEAD_GCM)
  ------------------
  |  Branch (871:12): [True: 0, False: 268]
  ------------------
  872|  1.83k|#endif
  873|  1.83k|    ) {
  874|      0|        RNP_LOG("unsupported AEAD algorithm");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  875|      0|        return false;
  876|      0|    }
  877|       |
  878|  1.83k|    pgp_sk_sesskey_t skey{};
  879|  1.83k|    skey.version = PGP_SKSK_V6;
  880|  1.83k|    skey.s2k = pass.s2k;
  881|  1.83k|    skey.alg = pass.s2k_cipher;
  882|  1.83k|    skey.aalg = param.ctx.aalg;
  883|  1.83k|    skey.ivlen = pgp_cipher_aead_nonce_len(skey.aalg);
  884|  1.83k|    skey.enckeylen = key.size() + pgp_cipher_aead_tag_len(skey.aalg);
  885|       |
  886|  1.83k|    auto kdf = rnp::Hkdf::create(PGP_HASH_SHA256);
  887|       |
  888|  1.83k|    std::vector<uint8_t> kdf_info;
  889|  1.83k|    kdf_info.push_back(PGP_PKT_SK_SESSION_KEY | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT);
  ------------------
  |  |   47|  1.83k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                  kdf_info.push_back(PGP_PKT_SK_SESSION_KEY | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT);
  ------------------
  |  |   56|  1.83k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
  890|  1.83k|    kdf_info.push_back(skey.version);
  891|  1.83k|    kdf_info.push_back(skey.alg);
  892|  1.83k|    kdf_info.push_back(skey.aalg);
  893|       |
  894|  1.83k|    std::vector<uint8_t> kdf_input(pass.key.data(), pass.key.data() + pgp_key_size(skey.alg));
  895|  1.83k|    std::vector<uint8_t> derived_key(pgp_key_size(skey.alg));
  896|       |
  897|  1.83k|    kdf->extract_expand(NULL,
  898|  1.83k|                        0, // no salt
  899|  1.83k|                        kdf_input.data(),
  900|  1.83k|                        kdf_input.size(),
  901|  1.83k|                        kdf_info.data(),
  902|  1.83k|                        kdf_info.size(),
  903|  1.83k|                        derived_key.data(),
  904|  1.83k|                        derived_key.size());
  905|       |
  906|  1.83k|    param.ctx.sec_ctx.rng.get(skey.iv, skey.ivlen);
  907|       |
  908|       |    /* initialize cipher */
  909|  1.83k|    pgp_crypt_t kcrypt;
  910|  1.83k|    if (!pgp_cipher_aead_init(&kcrypt, skey.alg, skey.aalg, derived_key.data(), false)) {
  ------------------
  |  Branch (910:9): [True: 70, False: 1.76k]
  ------------------
  911|     70|        return false;
  912|     70|    }
  913|       |
  914|       |    /* set additional data */
  915|  1.76k|    if (!encrypted_sesk_set_ad(kcrypt, skey)) {
  ------------------
  |  Branch (915:9): [True: 0, False: 1.76k]
  ------------------
  916|      0|        return false; // LCOV_EXCL_LINE
  917|      0|    }
  918|       |
  919|       |    /* calculate nonce */
  920|  1.76k|    uint8_t nonce[PGP_AEAD_MAX_NONCE_LEN];
  921|  1.76k|    size_t  nlen = pgp_cipher_aead_nonce(skey.aalg, skey.iv, nonce, 0);
  922|       |
  923|       |    /* start cipher, encrypt key and get tag */
  924|  1.76k|    bool res = pgp_cipher_aead_start(&kcrypt, nonce, nlen) &&
  ------------------
  |  Branch (924:16): [True: 1.76k, False: 0]
  ------------------
  925|  1.76k|               pgp_cipher_aead_finish(&kcrypt, skey.enckey, key.data(), key.size());
  ------------------
  |  Branch (925:16): [True: 1.69k, False: 63]
  ------------------
  926|       |
  927|  1.76k|    pgp_cipher_aead_destroy(&kcrypt);
  928|  1.76k|    if (res) {
  ------------------
  |  Branch (928:9): [True: 1.69k, False: 63]
  ------------------
  929|  1.69k|        param.skesks.push_back(std::move(skey));
  930|  1.69k|    }
  931|  1.76k|    return res;
  932|  1.76k|#endif
  933|  1.76k|}
stream-write.cpp:_ZL25encrypted_add_password_v4R26pgp_dest_encrypted_param_tRK25rnp_symmetric_pass_info_tRKNSt3__16vectorIhN3rnp16secure_allocatorIhEEEE:
  784|     16|{
  785|     16|    pgp_sk_sesskey_t skey{};
  786|     16|    skey.version = PGP_SKSK_V4;
  787|     16|    skey.s2k = pass.s2k;
  788|       |    /* We may use different algo for CEK and KEK */
  789|     16|    skey.enckeylen = key.size() + 1;
  790|     16|    skey.enckey[0] = param.ctx.ealg;
  791|     16|    memcpy(&skey.enckey[1], key.data(), key.size());
  792|     16|    skey.alg = pass.s2k_cipher;
  793|     16|    pgp_crypt_t kcrypt;
  794|     16|    if (!pgp_cipher_cfb_start(&kcrypt, skey.alg, pass.key.data(), NULL)) {
  ------------------
  |  Branch (794:9): [True: 0, False: 16]
  ------------------
  795|      0|        RNP_LOG("key encryption failed");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  796|      0|        return false;
  797|      0|    }
  798|     16|    pgp_cipher_cfb_encrypt(&kcrypt, skey.enckey, skey.enckey, skey.enckeylen);
  799|     16|    pgp_cipher_cfb_finish(&kcrypt);
  800|     16|    param.skesks.push_back(std::move(skey));
  801|     16|    return true;
  802|     16|}
stream-write.cpp:_ZL23encrypted_add_recipientR9rnp_ctx_tR10pgp_dest_tPN3rnp3KeyERKNSt3__16vectorIhNS3_16secure_allocatorIhEEEE19pgp_pkesk_version_t:
  676|     41|{
  677|     41|    auto param = static_cast<pgp_dest_encrypted_param_t *>(dst.param);
  678|       |
  679|       |    /* Use primary key if good for encryption, otherwise look in subkey list */
  680|     41|    userkey = find_suitable_key(PGP_OP_ENCRYPT, userkey, &ctx.key_provider);
  681|     41|    if (!userkey) {
  ------------------
  |  Branch (681:9): [True: 0, False: 41]
  ------------------
  682|      0|        return RNP_ERROR_NO_SUITABLE_KEY;
  683|      0|    }
  684|       |
  685|     41|#if defined(ENABLE_CRYPTO_REFRESH)
  686|       |    /* Crypto Refresh: For X25519/X448 PKESKv3, AES is mandated */
  687|       |    /* PQC: AES is mandated for PKESKv3 */
  688|     41|    if (!check_enforce_aes_v3_pkesk(userkey->alg(), param->ctx.ealg, pkesk_version)) {
  ------------------
  |  Branch (688:9): [True: 0, False: 41]
  ------------------
  689|      0|        RNP_LOG("attempting to use v3 PKESK with an unencrypted algorithm id in "
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  690|      0|                "combination with a symmetric "
  691|      0|                "algorithm that is not AES.");
  692|      0|        return RNP_ERROR_ENCRYPT_FAILED;
  693|      0|    }
  694|     41|#endif
  695|       |
  696|       |    /* Fill pkey */
  697|     41|    pgp_pk_sesskey_t pkey;
  698|     41|    pkey.version = pkesk_version;
  699|     41|    pkey.alg = userkey->alg();
  700|     41|    pkey.salg = param->ctx.ealg;
  701|       |    /* set key_id (used for PKESK v3) and fingerprint (used for PKESK v6) */
  702|     41|    pkey.key_id = userkey->keyid();
  703|     41|#if defined(ENABLE_CRYPTO_REFRESH)
  704|     41|    if (pkey.version == (uint8_t) PGP_V6) {
  ------------------
  |  Branch (704:9): [True: 0, False: 41]
  ------------------
  705|      0|        pkey.fp = userkey->fp();
  706|      0|    }
  707|     41|#endif
  708|       |
  709|       |    /* Encrypt the session key */
  710|     41|    rnp::secure_bytes enckey;
  711|     41|#if defined(ENABLE_CRYPTO_REFRESH) || defined(ENABLE_PQC)
  712|     41|    if ((pkey.version == PGP_PKSK_V3) && do_encrypt_pkesk_v3_alg_id(pkey.alg)) {
  ------------------
  |  Branch (712:9): [True: 41, False: 0]
  |  Branch (712:42): [True: 41, False: 0]
  ------------------
  713|       |        /* for pre-crypto-refresh algorithms, algorithm ID is part of the session key */
  714|     41|        enckey.push_back(pkey.salg);
  715|     41|    }
  716|       |#else
  717|       |    enckey.push_back(pkey.salg);
  718|       |#endif
  719|     41|    enckey.insert(enckey.end(), key.begin(), key.end());
  720|       |
  721|     41|    if (have_pkesk_checksum(pkey.alg)) {
  ------------------
  |  Branch (721:9): [True: 41, False: 0]
  ------------------
  722|       |        /* Calculate checksum */
  723|     41|        rnp::secure_array<uint16_t, 1> checksum;
  724|  1.07k|        for (size_t i = 0; i < key.size(); i++) {
  ------------------
  |  Branch (724:28): [True: 1.03k, False: 41]
  ------------------
  725|  1.03k|            checksum[0] += key[i];
  726|  1.03k|        }
  727|     41|        enckey.push_back(checksum[0] >> 8);
  728|     41|        enckey.push_back(checksum[0] & 0xff);
  729|     41|    }
  730|       |
  731|       |#if defined(ENABLE_PQC_DBG_LOG)
  732|       |    RNP_LOG_U8VEC("Key: %s", std::vector<uint8_t>(key.begin(), key.end()));
  733|       |    RNP_LOG_U8VEC("Session Key: %s", std::vector<uint8_t>(enckey.begin(), enckey.end()));
  734|       |#endif
  735|       |
  736|     41|    auto material = pgp::EncMaterial::create(pkey.alg);
  737|     41|#if defined(ENABLE_CRYPTO_REFRESH)
  738|     41|    material->version = pkey.version;
  739|     41|#endif
  740|     41|#if defined(ENABLE_PQC) || defined(ENABLE_CRYPTO_REFRESH)
  741|     41|    material->salg = pkey.salg;
  742|     41|#endif
  743|     41|    if (userkey->alg() == PGP_PKA_ECDH) {
  ------------------
  |  Branch (743:9): [True: 0, False: 41]
  ------------------
  744|      0|        auto ecdh = dynamic_cast<pgp::ECDHEncMaterial *>(material.get());
  745|      0|        assert(ecdh);
  746|      0|        ecdh->enc.fp = userkey->fp().vec();
  747|      0|    }
  748|     41|    auto ret = userkey->pkt().material->encrypt(ctx.sec_ctx, *material, enckey);
  749|     41|    if (ret) {
  ------------------
  |  Branch (749:9): [True: 0, False: 41]
  ------------------
  750|      0|        return ret;
  751|      0|    }
  752|       |
  753|       |    /* Writing symmetric key encrypted session key packet */
  754|     41|    try {
  755|     41|        pkey.write_material(*material);
  756|     41|        pkey.write(*param->pkt.origdst);
  757|     41|        return param->pkt.origdst->werr;
  758|     41|    } catch (const std::exception &e) {
  759|      0|        return RNP_ERROR_WRITE; // LCOV_EXCL_LINE
  760|      0|    }
  761|     41|}
stream-write.cpp:_ZL20encrypted_start_aeadP26pgp_dest_encrypted_param_tPh:
 1070|  3.78k|{
 1071|       |#if !defined(ENABLE_AEAD)
 1072|       |    RNP_LOG("AEAD support is not enabled.");
 1073|       |    return RNP_ERROR_NOT_IMPLEMENTED;
 1074|       |#else
 1075|  3.78k|    uint8_t hdr[4 + PGP_AEAD_MAX_NONCE_OR_SALT_LEN];
 1076|  3.78k|    size_t  nlen;
 1077|       |
 1078|  3.78k|    if (pgp_block_size(param->ctx.ealg) != 16) {
  ------------------
  |  Branch (1078:9): [True: 0, False: 3.78k]
  ------------------
 1079|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1080|      0|    }
 1081|       |
 1082|       |    /* fill header */
 1083|  3.78k|#ifdef ENABLE_CRYPTO_REFRESH
 1084|  3.78k|    hdr[0] = param->auth_type == rnp::AuthType::AEADv2 ? 2 : 1;
  ------------------
  |  Branch (1084:14): [True: 1.69k, False: 2.08k]
  ------------------
 1085|       |#else
 1086|       |    hdr[0] = 1;
 1087|       |#endif
 1088|  3.78k|    hdr[1] = param->ctx.ealg;
 1089|  3.78k|    hdr[2] = param->ctx.aalg;
 1090|  3.78k|    hdr[3] = param->ctx.abits;
 1091|       |
 1092|       |    /* generate iv */
 1093|  3.78k|    nlen = pgp_cipher_aead_nonce_len(param->ctx.aalg);
 1094|  3.78k|    uint8_t *iv_or_salt = param->iv;
 1095|  3.78k|    size_t   iv_or_salt_len = nlen;
 1096|  3.78k|#ifdef ENABLE_CRYPTO_REFRESH
 1097|  3.78k|    if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1097:9): [True: 1.69k, False: 2.08k]
  ------------------
 1098|  1.69k|        iv_or_salt = param->v2_seipd_salt.data();
 1099|  1.69k|        iv_or_salt_len = param->v2_seipd_salt.size();
 1100|  1.69k|    }
 1101|  3.78k|#endif
 1102|  3.78k|    try {
 1103|  3.78k|        param->ctx.sec_ctx.rng.get(iv_or_salt, iv_or_salt_len);
 1104|  3.78k|    } catch (const std::exception &e) {
 1105|      0|        return RNP_ERROR_RNG; // LCOV_EXCL_LINE
 1106|      0|    }
 1107|  3.78k|    memcpy(hdr + 4, iv_or_salt, iv_or_salt_len);
 1108|       |    /* output header */
 1109|  3.78k|    dst_write(param->pkt.writedst, hdr, 4 + iv_or_salt_len);
 1110|       |
 1111|       |    /* initialize encryption */
 1112|  3.78k|    param->chunklen = 1L << (hdr[3] + 6);
 1113|  3.78k|    param->chunkout = 0;
 1114|       |
 1115|       |    /* fill additional/authenticated data */
 1116|  3.78k|    uint8_t raw_packet_tag = PGP_PKT_AEAD_ENCRYPTED;
 1117|  3.78k|#ifdef ENABLE_CRYPTO_REFRESH
 1118|  3.78k|    if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1118:9): [True: 1.69k, False: 2.08k]
  ------------------
 1119|  1.69k|        raw_packet_tag = PGP_PKT_SE_IP_DATA;
 1120|  1.69k|    }
 1121|  3.78k|#endif
 1122|  3.78k|    param->ad[0] = raw_packet_tag | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   47|  3.78k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                  param->ad[0] = raw_packet_tag | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT;
  ------------------
  |  |   56|  3.78k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
 1123|  3.78k|    memcpy(param->ad + 1, hdr, 4);
 1124|  3.78k|#ifdef ENABLE_CRYPTO_REFRESH
 1125|  3.78k|    if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1125:9): [True: 1.69k, False: 2.08k]
  ------------------
 1126|  1.69k|        param->adlen = 5;
 1127|  2.08k|    } else {
 1128|  2.08k|#endif
 1129|  2.08k|        memset(param->ad + 5, 0, 8);
 1130|  2.08k|        param->adlen = 13;
 1131|  2.08k|#ifdef ENABLE_CRYPTO_REFRESH
 1132|  2.08k|    }
 1133|  3.78k|    seipd_v2_aead_fields_t s2_fields;
 1134|  3.78k|    if (param->auth_type == rnp::AuthType::AEADv2) {
  ------------------
  |  Branch (1134:9): [True: 1.69k, False: 2.08k]
  ------------------
 1135|  1.69k|        param->aalg = param->ctx.aalg;
 1136|  1.69k|        pgp_seipdv2_hdr_t v2_seipd_hdr;
 1137|  1.69k|        v2_seipd_hdr.cipher_alg = param->ctx.ealg;
 1138|  1.69k|        v2_seipd_hdr.aead_alg = param->ctx.aalg;
 1139|  1.69k|        v2_seipd_hdr.chunk_size_octet = param->ctx.abits;
 1140|  1.69k|        v2_seipd_hdr.version = PGP_SE_IP_DATA_V2;
 1141|  1.69k|        memcpy(v2_seipd_hdr.salt, iv_or_salt, PGP_SEIPDV2_SALT_LEN);
  ------------------
  |  |  101|  1.69k|#define PGP_SEIPDV2_SALT_LEN 32
  ------------------
 1142|  1.69k|        s2_fields = seipd_v2_key_and_nonce_derivation(v2_seipd_hdr, enckey);
 1143|  1.69k|        enckey = s2_fields.key.data();
 1144|  1.69k|        if (s2_fields.nonce.size() > sizeof(param->iv)) {
  ------------------
  |  Branch (1144:13): [True: 0, False: 1.69k]
  ------------------
 1145|       |            // would be better to indicate an error
 1146|      0|            s2_fields.nonce.resize(sizeof(param->iv));
 1147|      0|        }
 1148|  1.69k|        std::memcpy(param->iv, s2_fields.nonce.data(), s2_fields.nonce.size());
 1149|  1.69k|    }
 1150|  3.78k|#endif
 1151|       |
 1152|       |    /* initialize cipher */
 1153|  3.78k|    if (!pgp_cipher_aead_init(
  ------------------
  |  Branch (1153:9): [True: 0, False: 3.78k]
  ------------------
 1154|  3.78k|          &param->encrypt, param->ctx.ealg, param->ctx.aalg, enckey, false)) {
 1155|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1156|      0|    }
 1157|       |
 1158|  3.78k|    return encrypted_start_aead_chunk(param, 0, false);
 1159|  3.78k|#endif
 1160|  3.78k|}
stream-write.cpp:_ZL19encrypted_start_cfbP26pgp_dest_encrypted_param_tPh:
 1015|  4.34k|{
 1016|  4.34k|    uint8_t mdcver = 1;
 1017|  4.34k|    uint8_t enchdr[PGP_MAX_BLOCK_SIZE + 2]; /* encrypted header */
 1018|       |
 1019|  4.34k|    if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (1019:9): [True: 4.34k, False: 0]
  ------------------
 1020|       |        /* initializing the mdc */
 1021|  4.34k|        dst_write(param->pkt.writedst, &mdcver, 1);
 1022|       |
 1023|  4.34k|        try {
 1024|  4.34k|            param->mdc = rnp::Hash::create(PGP_HASH_SHA1);
 1025|  4.34k|        } catch (const std::exception &e) {
 1026|       |            /* LCOV_EXCL_START */
 1027|      0|            RNP_LOG("cannot create sha1 hash: %s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1028|      0|            return RNP_ERROR_GENERIC;
 1029|       |            /* LCOV_EXCL_END */
 1030|      0|        }
 1031|  4.34k|    }
 1032|       |
 1033|       |    /* initializing the crypto */
 1034|  4.34k|    size_t blsize = pgp_block_size(param->ctx.ealg);
 1035|  4.34k|    if (!blsize || !pgp_cipher_cfb_start(&param->encrypt, param->ctx.ealg, enckey, NULL)) {
  ------------------
  |  Branch (1035:9): [True: 0, False: 4.34k]
  |  Branch (1035:20): [True: 0, False: 4.34k]
  ------------------
 1036|      0|        return RNP_ERROR_BAD_PARAMETERS;
 1037|      0|    }
 1038|       |
 1039|       |    /* generating and writing iv/password check bytes */
 1040|  4.34k|    try {
 1041|  4.34k|        param->ctx.sec_ctx.rng.get(enchdr, blsize);
 1042|  4.34k|        enchdr[blsize] = enchdr[blsize - 2];
 1043|  4.34k|        enchdr[blsize + 1] = enchdr[blsize - 1];
 1044|       |
 1045|  4.34k|        if (param->auth_type == rnp::AuthType::MDC) {
  ------------------
  |  Branch (1045:13): [True: 4.34k, False: 0]
  ------------------
 1046|  4.34k|            param->mdc->add(enchdr, blsize + 2);
 1047|  4.34k|        }
 1048|  4.34k|    } catch (const std::exception &e) {
 1049|       |        /* LCOV_EXCL_START */
 1050|      0|        RNP_LOG("%s", e.what());
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1051|      0|        return RNP_ERROR_BAD_STATE;
 1052|       |        /* LCOV_EXCL_END */
 1053|      0|    }
 1054|       |
 1055|  4.34k|    pgp_cipher_cfb_encrypt(&param->encrypt, enchdr, enchdr, blsize + 2);
 1056|       |
 1057|       |    /* RFC 4880, 5.13: Unlike the Symmetrically Encrypted Data Packet, no special CFB
 1058|       |     * resynchronization is done after encrypting this prefix data. */
 1059|  4.34k|    if (param->auth_type == rnp::AuthType::None) {
  ------------------
  |  Branch (1059:9): [True: 0, False: 4.34k]
  ------------------
 1060|      0|        pgp_cipher_cfb_resync(&param->encrypt, enchdr + 2);
 1061|      0|    }
 1062|       |
 1063|  4.34k|    dst_write(param->pkt.writedst, enchdr, blsize + 2);
 1064|       |
 1065|  4.34k|    return RNP_SUCCESS;
 1066|  4.34k|}
stream-write.cpp:_ZL15seipdv2_capableR9rnp_ctx_t:
 1164|  10.4k|{
 1165|  10.4k|#if defined(ENABLE_CRYPTO_REFRESH)
 1166|  10.4k|    bool use_v6_pkesk =
 1167|  10.4k|      ctx.enable_pkesk_v6 && !ctx.recipients.empty() && ctx.pkeskv6_capable(&ctx.key_provider);
  ------------------
  |  Branch (1167:7): [True: 2.79k, False: 7.61k]
  |  Branch (1167:30): [True: 31, False: 2.76k]
  |  Branch (1167:57): [True: 0, False: 31]
  ------------------
 1168|  10.4k|    bool use_v6_skesk = ctx.enable_skesk_v6 && (ctx.aalg != PGP_AEAD_NONE);
  ------------------
  |  Branch (1168:25): [True: 4.62k, False: 5.78k]
  |  Branch (1168:48): [True: 2.11k, False: 2.50k]
  ------------------
 1169|  10.4k|    return (use_v6_pkesk || ctx.recipients.empty()) && (use_v6_skesk || ctx.passwords.empty());
  ------------------
  |  Branch (1169:13): [True: 0, False: 10.4k]
  |  Branch (1169:29): [True: 10.3k, False: 53]
  |  Branch (1169:57): [True: 2.10k, False: 8.24k]
  |  Branch (1169:73): [True: 1.67k, False: 6.57k]
  ------------------
 1170|       |#else
 1171|       |    (void) ctx;
 1172|       |    return false;
 1173|       |#endif
 1174|  10.4k|}

_Z33seipd_v2_key_and_nonce_derivationR17pgp_seipdv2_hdr_tPh:
   37|  3.04k|{
   38|  3.04k|    auto hkdf = rnp::Hkdf::create(PGP_HASH_SHA256);
   39|       |
   40|  3.04k|    size_t   sesskey_len = pgp_key_size(hdr.cipher_alg);
   41|  3.04k|    uint32_t nonce_size = 0;
   42|  3.04k|    uint32_t key_size = pgp_key_size(hdr.cipher_alg);
   43|       |
   44|  3.04k|    switch (hdr.aead_alg) {
  ------------------
  |  Branch (44:13): [True: 3.04k, False: 0]
  ------------------
   45|  1.23k|    case PGP_AEAD_EAX:
  ------------------
  |  Branch (45:5): [True: 1.23k, False: 1.80k]
  ------------------
   46|  1.23k|        nonce_size = PGP_AEAD_EAX_NONCE_LEN;
  ------------------
  |  |   64|  1.23k|#define PGP_AEAD_EAX_NONCE_LEN 16
  ------------------
   47|  1.23k|        break;
   48|  1.45k|    case PGP_AEAD_OCB:
  ------------------
  |  Branch (48:5): [True: 1.45k, False: 1.58k]
  ------------------
   49|  1.45k|        nonce_size = PGP_AEAD_OCB_NONCE_LEN;
  ------------------
  |  |   67|  1.45k|#define PGP_AEAD_OCB_NONCE_LEN 15
  ------------------
   50|  1.45k|        break;
   51|    355|    case PGP_AEAD_GCM:
  ------------------
  |  Branch (51:5): [True: 355, False: 2.68k]
  ------------------
   52|    355|        nonce_size = PGP_AEAD_GCM_NONCE_LEN;
  ------------------
  |  |   68|    355|#define PGP_AEAD_GCM_NONCE_LEN 12
  ------------------
   53|    355|        break;
   54|      0|    case PGP_AEAD_NONE:
  ------------------
  |  Branch (54:5): [True: 0, False: 3.04k]
  ------------------
   55|      0|    case PGP_AEAD_UNKNOWN:
  ------------------
  |  Branch (55:5): [True: 0, False: 3.04k]
  ------------------
   56|      0|        RNP_LOG("EAX, OCB or GCM must be used for v2 SEIPD packets");
  ------------------
  |  |   84|      0|#define RNP_LOG(...) RNP_LOG_FD(stderr, __VA_ARGS__)
  |  |  ------------------
  |  |  |  |   76|      0|    do {                                                                                 \
  |  |  |  |   77|      0|        if (!rnp_log_switch())                                                           \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:13): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   78|      0|            break;                                                                       \
  |  |  |  |   79|      0|        (void) fprintf((fd), "[%s() %s:%d] ", __func__, __SOURCE_PATH_FILE__, __LINE__); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   72|      0|#define __SOURCE_PATH_FILE__ (__FILE__)
  |  |  |  |  ------------------
  |  |  |  |   80|      0|        (void) fprintf((fd), __VA_ARGS__);                                               \
  |  |  |  |   81|      0|        (void) fprintf((fd), "\n");                                                      \
  |  |  |  |   82|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (82:14): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   57|      0|        throw rnp::rnp_exception(RNP_ERROR_NOT_SUPPORTED);
   58|  3.04k|    }
   59|  3.04k|    const uint8_t info[5] = {
   60|  3.04k|      static_cast<uint8_t>(PGP_PKT_SE_IP_DATA | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT),
  ------------------
  |  |   47|  3.04k|#define PGP_PTAG_ALWAYS_SET 0x80
  ------------------
                    static_cast<uint8_t>(PGP_PKT_SE_IP_DATA | PGP_PTAG_ALWAYS_SET | PGP_PTAG_NEW_FORMAT),
  ------------------
  |  |   56|  3.04k|#define PGP_PTAG_NEW_FORMAT 0x40
  ------------------
   61|  3.04k|      static_cast<uint8_t>(hdr.version),
   62|  3.04k|      static_cast<uint8_t>(hdr.cipher_alg),
   63|  3.04k|      static_cast<uint8_t>(hdr.aead_alg),
   64|  3.04k|      hdr.chunk_size_octet};
   65|  3.04k|    uint32_t             out_size = key_size + nonce_size - 8;
   66|  3.04k|    std::vector<uint8_t> hkdf_out(out_size);
   67|  3.04k|    hkdf->extract_expand(hdr.salt,
   68|  3.04k|                         sizeof(hdr.salt),
   69|  3.04k|                         sesskey,
   70|  3.04k|                         sesskey_len,
   71|  3.04k|                         info,
   72|  3.04k|                         sizeof(info),
   73|  3.04k|                         hkdf_out.data(),
   74|  3.04k|                         hkdf_out.size());
   75|       |
   76|  3.04k|    seipd_v2_aead_fields_t result;
   77|  3.04k|    result.key = std::vector<uint8_t>(hkdf_out.data(), hkdf_out.data() + key_size);
   78|  3.04k|    result.nonce =
   79|  3.04k|      std::vector<uint8_t>(hkdf_out.data() + key_size, hkdf_out.data() + hkdf_out.size());
   80|  27.3k|    for (uint32_t i = 0; i < 8; i++) {
  ------------------
  |  Branch (80:26): [True: 24.3k, False: 3.04k]
  ------------------
   81|       |        // fill up the nonce with zero octets
   82|  24.3k|        result.nonce.push_back(0);
   83|  24.3k|    }
   84|  3.04k|    return result;
   85|  3.04k|}

