|
Boost : |
Subject: Re: [boost] [sort] [container] Challenge for sorting experts, improved stable sort
From: Phil Endecott (spam_from_boost_dev_at_[hidden])
Date: 2015-09-21 14:53:39
Ion Gazta?aga wrote:
> I'm trying to improve insertion times for flat associative containers.
> In range insertions one optimization is to insert the whole range in the
> end of the container and sort the whole vector instead of trying a loop.
Hi Ion,
We've discussed this before...
Why do you (still) want to sort the whole container, rather than just
sorting the new items and then using inplace_merge?
The idea of using the allocated-but-unused part of the buffer for
temporary storage is an interesting one, which would benefit
inplace_merge as well as stable_sort. Have you tried to quantify
the benefits?
Cheers, Phil.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk