|
Boost : |
Subject: Re: [boost] Proposal: Monotonic Containers
From: Christian Schladetsch (christian.schladetsch_at_[hidden])
Date: 2009-06-16 23:02:12
Hi Frank,
I do think your allocator could be useful, it just needs to be paired with
> containers that it is guaranteed to work with.
I empathise, so I added monotonic::static_storage<> and
monotonic::static_shared_storage<>. See http://tinyurl.com/lmojlv.
I then re-ran test_map_list(), see http://tinyurl.com/n59qb8.
MSVC /O2:
test_map_list
count mono std mono_static mono/std mono_static/std
100 0.136 0.219 0.412 0.330097% 0.531553%
1100 1.831 1.717 4.398 0.416326% 0.390405%
2100 3.558 3.531 8.466 0.420269% 0.41708%
3100 5.592 5.576 13.065 0.428014% 0.426789%
4100 7.757 8.225 17.522 0.442701% 0.46941%
5100 10.138 10.114 21.922 0.462458% 0.461363%
6100 12.684 12.588 26.46 0.479365% 0.475737%
7100 14.636 15.233 30.796 0.475257% 0.494642%
8100 17.816 17.014 35.67 0.499467% 0.476983%
9100 19.358 19.199 39.872 0.485504% 0.481516%
And for GCC 4.3.3 -O4:
100 0.08 0.07 0.13 0.615385% 0.538462%
1100 1.2 1.18 1.86 0.645161% 0.634409%
2100 2.53 2.62 3.56 0.710674% 0.735955%
3100 3.9 3.81 5.48 0.711679% 0.695255%
4100 5.26 5.28 7.58 0.693931% 0.69657%
5100 6.77 6.96 9.87 0.685917% 0.705167%
6100 8.54 8.36 12.36 0.690939% 0.676375%
7100 10.76 10.96 15.47 0.69554% 0.708468%
8100 11.81 11.76 16.46 0.717497% 0.714459%
9100 13.28 13.57 18.98 0.699684% 0.714963%
I believe this resolves the issue of default-constructed monotonic
containers. You don't need to make an explicit storage now, but I still
think it's better to do so.
> Anyways, I'm beginning to find this thread frustrating and don't intend to
> comment further.
Sorry to see you go.
Regards,
Christian.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk