Boost logo

Boost :

From: Jooseong Lee (frozenca91_at_[hidden])
Date: 2022-07-30 04:38:55


Dear Rainer,

Compared with boost::unordered_map and boost::container::flat_set,
I repeated inserting/retrieving/erasing 1,000,000 random std::int64_t in
random order,
and see the following results in my machine: (gcc 11.2 -O3)
(repeated 200 times for each target for B-Tree and unordered_set, repeated
10 times for flat_set)

My B-Tree: insert 196.22 ms, lookup 205.64 ms, erase 233.24 ms
boost::container::flat_set : insert 58402.9 ms, lookup 217.73 ms, erase
59075.2 ms
boost::unordered_set : insert 189.45 ms, lookup 232.19 ms, erase 268.01 ms

Regards,
Jooseong

2022년 7월 29일 (금) 오후 10:35, Rainer Deyke via Boost <boost_at_[hidden]>님이
작성:

> On 25.07.22 05:45, Jooseong Lee via Boost wrote:
> > I recently wrote a general-purpose STL-like ordered associative B-Tree
> > based container in C++.
> > .
> > Its API and usage is very similar to std::set, std::map, std::multiset,
> > std::multimap,
> > and when the number of elements is relatively large, my benchmark shows
> > that it is 2.5~3 times faster than std::set and its friends.
>
> I've pretty much stopped using std::set and co. What I do use is
> boost::unordered_map when order doesn't matter and boost::flat_map (from
> Boost.Container) when it does. How does your container compare to
> these, performance-wise?
>
>
> --
> Rainer Deyke (rainerd_at_[hidden])
>
>
> _______________________________________________
> Unsubscribe & other changes:
> http://lists.boost.org/mailman/listinfo.cgi/boost
>


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk