Skip to content

Commit

Permalink
[MISC] Split timer into two classes
Browse files Browse the repository at this point in the history
  • Loading branch information
eseiler committed Nov 3, 2023
1 parent 84c4aea commit fa87b7f
Show file tree
Hide file tree
Showing 10 changed files with 326 additions and 118 deletions.
8 changes: 4 additions & 4 deletions include/hibf/build/build_data.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ struct build_data
std::vector<double> fpr_correction{};

// Timers do not copy the stored duration upon copy construction/assignment
mutable timer<concurrent::yes> index_allocation_timer{};
mutable timer<concurrent::yes> user_bin_io_timer{};
mutable timer<concurrent::yes> merge_kmers_timer{};
mutable timer<concurrent::yes> fill_ibf_timer{};
mutable concurrent_timer index_allocation_timer{};
mutable concurrent_timer user_bin_io_timer{};
mutable concurrent_timer merge_kmers_timer{};
mutable concurrent_timer fill_ibf_timer{};

size_t request_ibf_idx()
{
Expand Down
2 changes: 1 addition & 1 deletion include/hibf/build/insert_into_ibf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void insert_into_ibf(robin_hood::unordered_flat_set<uint64_t> const & kmers,
size_t const number_of_bins,
size_t const bin_index,
seqan::hibf::interleaved_bloom_filter & ibf,
timer<concurrent::yes> & fill_ibf_timer);
concurrent_timer & fill_ibf_timer);

//!\overload
void insert_into_ibf(build_data const & data,
Expand Down
4 changes: 2 additions & 2 deletions include/hibf/build/update_parent_kmers.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ namespace seqan::hibf::build
*/
inline void update_parent_kmers(robin_hood::unordered_flat_set<uint64_t> & parent_kmers,
robin_hood::unordered_flat_set<uint64_t> const & kmers,
timer<concurrent::yes> & merge_kmers_timer)
concurrent_timer & merge_kmers_timer)
{
timer<concurrent::no> local_merge_kmers_timer{};
serial_timer local_merge_kmers_timer{};
local_merge_kmers_timer.start();
parent_kmers.insert(kmers.begin(), kmers.end());
local_merge_kmers_timer.stop();
Expand Down
8 changes: 4 additions & 4 deletions include/hibf/hierarchical_interleaved_bloom_filter.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,10 +249,10 @@ class hierarchical_interleaved_bloom_filter
* \brief Only contains values after the HIBF has been constructed.
* \{
*/
timer<concurrent::yes> index_allocation_timer{};
timer<concurrent::yes> user_bin_io_timer{};
timer<concurrent::yes> merge_kmers_timer{};
timer<concurrent::yes> fill_ibf_timer{};
concurrent_timer index_allocation_timer{};
concurrent_timer user_bin_io_timer{};
concurrent_timer merge_kmers_timer{};
concurrent_timer fill_ibf_timer{};
//!\}
//!\endcond
};
Expand Down
Loading

0 comments on commit fa87b7f

Please sign in to comment.